mirror of
https://github.com/JFormDesigner/FlatLaf.git
synced 2025-12-08 15:00:54 +03:00
JIDE: JideTabbedPane: hide tab selection and tab area separator for tabbedPane.setHideOneTab(true) if tabbed pane contains only one tab
This commit is contained in:
@@ -415,6 +415,9 @@ public class FlatJideTabbedPaneUI
|
|||||||
}
|
}
|
||||||
|
|
||||||
protected void paintTabSelection( Graphics g, int tabPlacement, int x, int y, int w, int h ) {
|
protected void paintTabSelection( Graphics g, int tabPlacement, int x, int y, int w, int h ) {
|
||||||
|
if( !_tabPane.isTabShown() )
|
||||||
|
return;
|
||||||
|
|
||||||
// increase clip bounds in scroll-tab-layout to paint over the separator line
|
// increase clip bounds in scroll-tab-layout to paint over the separator line
|
||||||
Rectangle clipBounds = scrollableTabLayoutEnabled() ? g.getClipBounds() : null;
|
Rectangle clipBounds = scrollableTabLayoutEnabled() ? g.getClipBounds() : null;
|
||||||
if( clipBounds != null ) {
|
if( clipBounds != null ) {
|
||||||
@@ -480,7 +483,7 @@ public class FlatJideTabbedPaneUI
|
|||||||
*/
|
*/
|
||||||
@Override
|
@Override
|
||||||
protected void paintContentBorder( Graphics g, int tabPlacement, int selectedIndex ) {
|
protected void paintContentBorder( Graphics g, int tabPlacement, int selectedIndex ) {
|
||||||
if( _tabPane.getTabCount() <= 0 )
|
if( !_tabPane.isTabShown() )
|
||||||
return;
|
return;
|
||||||
|
|
||||||
Insets insets = _tabPane.getInsets();
|
Insets insets = _tabPane.getInsets();
|
||||||
|
|||||||
Reference in New Issue
Block a user