7034619: Scrollable Tabs don't appear with JDK7 Synth based LaF, different from Java 5/6
Reviewed-by: alexp
--- a/jdk/src/share/classes/javax/swing/plaf/synth/SynthTabbedPaneUI.java Fri May 06 16:01:17 2011 +0400
+++ b/jdk/src/share/classes/javax/swing/plaf/synth/SynthTabbedPaneUI.java Tue May 10 17:06:26 2011 +0400
@@ -488,6 +488,18 @@
paintContentBorder(tabContentContext, g, tabPlacement, selectedIndex);
}
+ protected void paintTabArea(Graphics g, int tabPlacement,
+ int selectedIndex) {
+ // This can be invoked from ScrollabeTabPanel
+ Insets insets = tabPane.getInsets();
+ int x = insets.left;
+ int y = insets.top;
+ int width = tabPane.getWidth() - insets.left - insets.right;
+ int height = tabPane.getHeight() - insets.top - insets.bottom;
+
+ paintTabArea(tabAreaContext, g, tabPlacement, selectedIndex,
+ new Rectangle(x, y, width, height));
+ }
private void paintTabArea(SynthContext ss, Graphics g,
int tabPlacement, int selectedIndex,