protected void scrollForward ( ) { int selectedIndex = tabPane . getSelectedIndex ( ) ; if ( ++ selectedIndex >= tabPane . getTabCount ( ) ) { tabPane . setSelectedIndex ( tabPane . getTabCount ( ) - 1 ) ; } else { tabPane . setSelectedIndex ( selectedIndex ) ; } tabPane . repaint ( ) ; }
Scroll the tab buttons forwards .