Rectangle (SingleRowPassInfo data) { Insets insets = myTabs.getActionsInsets(); Dimension entryPointSize = myTabs.getEntryPointPreferredSize(); if (ExperimentalUI.isNewUI()) { return new Rectangle(myTabs.getHeaderFitSize().width - entryPointSize.width - data.insets.right - insets.right - 1, myTabs.getHeight() - entryPointSize.height - data.insets.bottom - insets.bottom, entryPointSize.width, entryPointSize.height); } else { return new Rectangle(data.insets.left + JBTabsImpl.getSelectionTabVShift(), myTabs.getHeight() - entryPointSize.height - data.insets.bottom - insets.bottom, myTabs.getHeaderFitSize().width, entryPointSize.height); } }