moved tab stuff to its own file