refactoring the tab situation a bit