All Packages Class Hierarchy This Package Previous Next Index
Class java.awt.swing.basic.BasicTabbedPaneUI
java.lang.Object
|
+----java.awt.swing.plaf.ComponentUI
|
+----java.awt.swing.plaf.TabbedPaneUI
|
+----java.awt.swing.basic.BasicTabbedPaneUI
- public class BasicTabbedPaneUI
- extends TabbedPaneUI
- implements LayoutManager, ChangeListener, Serializable
A Windows L&F implementation of TabbedPaneUI.
focusColor-
focusGetter-
iconSpacingWidth-
magicHackCalledD- this variable was called "d" by the original author
we're really not sure what that stood for.
maxTabHeight-
mouseGetter-
nRows-
overlay-
rects-
spacingHeight-
spacingWidth-
tabBackgroundColor-
tabDarkShadowColor-
tabHighlightColor-
tabShadowColor-
tabTextColor-
xNudge-
yNudge-
BasicTabbedPaneUI()
-
addLayoutComponent(String, Component)
-
arrangeTabs(int, int, int, int, int, Font, int, int, int, JTabbedPane)
-
assureRectsCreated(int)
-
calculateLayoutInfo(JTabbedPane)
-
calculateXNudge(Rectangle)
-
calculateYNudge(Rectangle)
-
createUI(JComponent)
-
drawBezelNoTop(Graphics, int, int, int, int)
- This function draws the etch around the content area of the pane
note: content area means the area below the tabs
drawLineBelowTabs(Graphics, int, int, int)
- this function draws the line which separates the tabs from the content area below.
drawTabBorder(Graphics, int, int, int, int)
- this function draws the border around each tab
note that this function does now draw the background of the tab.
getMaximumSize(JComponent)
-
getMetrics(JTabbedPane)
-
getMinimumSize(JComponent)
-
getPreferredSize(JComponent)
-
getTabBounds(JTabbedPane, int)
-
getVisibleComponent(JTabbedPane)
-
initColors(JComponent)
-
installFont(JComponent)
-
installUI(JComponent)
-
layoutContainer(Container)
-
layoutLabel(FontMetrics, String, Icon, Rectangle, Rectangle, Rectangle, boolean)
-
maxTabHeight(JTabbedPane)
-
maxTabWidth(JTabbedPane)
-
minimumLayoutSize(Container)
-
padRow(int, int, int)
-
padSelectedTab(JTabbedPane)
-
paint(Graphics, JComponent)
-
paintFocusIndicator(Graphics, JTabbedPane, Rectangle[], int, Rectangle, Rectangle)
-
paintIcon(Graphics, JTabbedPane, Icon, int, Rectangle, boolean)
-
paintTab(Graphics, JTabbedPane, Rectangle[], int, Rectangle, Rectangle)
-
paintTabBackground(Graphics, int, int, int, int)
-
paintText(Graphics, JTabbedPane, String, int, Font, Rectangle, FontMetrics, boolean)
-
preferredLayoutSize(Container)
-
removeComponent(JTabbedPane, Component)
-
removeLayoutComponent(Component)
-
selectAdjacentTab(JTabbedPane, int)
-
selectNextTab(JTabbedPane)
-
selectPrevTab(JTabbedPane)
-
selectTabAbove(JTabbedPane)
-
selectTabBelow(JTabbedPane)
-
stateChanged(ChangeEvent)
-
tabForCoordinate(JTabbedPane, int, int)
-
tabHeight()
-
tabWidth(JTabbedPane, int, FontMetrics)
-
uninstallUI(JComponent)
-
overlay
protected static int overlay
spacingHeight
protected static int spacingHeight
spacingWidth
protected static int spacingWidth
iconSpacingWidth
protected static int iconSpacingWidth
xNudge
protected int xNudge
yNudge
protected int yNudge
magicHackCalledD
protected int magicHackCalledD
- this variable was called "d" by the original author
we're really not sure what that stood for.
As far as we can tell, this variable refers to:
the position of the current tab relative to the selected tab
it is used to ensure proper drawing of overlapping tabs
tabTextColor
protected Color tabTextColor
focusColor
protected Color focusColor
tabBackgroundColor
protected Color tabBackgroundColor
tabHighlightColor
protected Color tabHighlightColor
tabShadowColor
protected Color tabShadowColor
tabDarkShadowColor
protected Color tabDarkShadowColor
nRows
protected int nRows
maxTabHeight
protected int maxTabHeight
rects
protected Rectangle[] rects
mouseGetter
protected BasicTabbedPaneUI.MouseGetter mouseGetter
focusGetter
protected BasicTabbedPaneUI.FocusGetter focusGetter
BasicTabbedPaneUI
public BasicTabbedPaneUI()
selectNextTab
public void selectNextTab(JTabbedPane pane)
selectPrevTab
public void selectPrevTab(JTabbedPane pane)
getPreferredSize
public Dimension getPreferredSize(JComponent container)
- Overrides:
- getPreferredSize in class ComponentUI
getMinimumSize
public Dimension getMinimumSize(JComponent container)
- Overrides:
- getMinimumSize in class ComponentUI
getMaximumSize
public Dimension getMaximumSize(JComponent container)
- Overrides:
- getMaximumSize in class ComponentUI
addLayoutComponent
public void addLayoutComponent(String name,
Component comp)
removeLayoutComponent
public void removeLayoutComponent(Component comp)
preferredLayoutSize
public Dimension preferredLayoutSize(Container parent)
minimumLayoutSize
public Dimension minimumLayoutSize(Container parent)
getVisibleComponent
protected Component getVisibleComponent(JTabbedPane pane)
removeComponent
protected void removeComponent(JTabbedPane pane,
Component component)
stateChanged
public void stateChanged(ChangeEvent e)
padRow
protected void padRow(int rowI,
int i,
int maxX)
assureRectsCreated
protected void assureRectsCreated(int tabCount)
arrangeTabs
protected void arrangeTabs(int paddingExemptRow,
int firstRowIndent,
int otherRowIndent,
int maxTabHeight,
int overlay,
Font font,
int maxX,
int returnAt,
int tabCount,
JTabbedPane pane)
maxTabHeight
protected int maxTabHeight(JTabbedPane pane)
tabWidth
protected int tabWidth(JTabbedPane pane,
int index,
FontMetrics metrics)
maxTabWidth
protected int maxTabWidth(JTabbedPane pane)
getMetrics
protected FontMetrics getMetrics(JTabbedPane pane)
createUI
public static ComponentUI createUI(JComponent x)
installUI
public void installUI(JComponent container)
- Overrides:
- installUI in class ComponentUI
uninstallUI
public void uninstallUI(JComponent container)
- Overrides:
- uninstallUI in class ComponentUI
initColors
protected void initColors(JComponent c)
installFont
protected void installFont(JComponent c)
selectAdjacentTab
protected void selectAdjacentTab(JTabbedPane pane,
int heightOffset)
selectTabAbove
protected void selectTabAbove(JTabbedPane pane)
selectTabBelow
protected void selectTabBelow(JTabbedPane pane)
paintTab
protected void paintTab(Graphics g,
JTabbedPane pane,
Rectangle[] rects,
int i,
Rectangle iconRect,
Rectangle textRect)
layoutLabel
protected void layoutLabel(FontMetrics metrics,
String title,
Icon icon,
Rectangle tabRect,
Rectangle iconRect,
Rectangle textRect,
boolean isSelected)
paintIcon
protected void paintIcon(Graphics g,
JTabbedPane pane,
Icon icon,
int tabIndex,
Rectangle iconRect,
boolean isSelected)
paintText
protected void paintText(Graphics g,
JTabbedPane pane,
String title,
int tabIndex,
Font font,
Rectangle textRect,
FontMetrics metrics,
boolean isSelected)
calculateXNudge
protected int calculateXNudge(Rectangle tabRect)
calculateYNudge
protected int calculateYNudge(Rectangle tabRect)
paintFocusIndicator
protected void paintFocusIndicator(Graphics g,
JTabbedPane pane,
Rectangle[] rects,
int i,
Rectangle iconRect,
Rectangle textRect)
paint
public void paint(Graphics g,
JComponent container)
- Overrides:
- paint in class ComponentUI
drawLineBelowTabs
protected void drawLineBelowTabs(Graphics g,
int selectedIndex,
int tabHeight,
int width)
- this function draws the line which separates the tabs from the content area below.
this implementation leaves a gap to complete the illution that the tab is part of
the content area.
drawBezelNoTop
protected void drawBezelNoTop(Graphics g,
int x,
int y,
int w,
int h)
- This function draws the etch around the content area of the pane
note: content area means the area below the tabs
drawTabBorder
protected void drawTabBorder(Graphics g,
int x,
int y,
int w,
int h)
- this function draws the border around each tab
note that this function does now draw the background of the tab.
that is done elsewhere
paintTabBackground
protected void paintTabBackground(Graphics g,
int x,
int y,
int w,
int h)
layoutContainer
public void layoutContainer(Container parent)
calculateLayoutInfo
protected void calculateLayoutInfo(JTabbedPane pane)
padSelectedTab
protected void padSelectedTab(JTabbedPane pane)
tabForCoordinate
public int tabForCoordinate(JTabbedPane pane,
int x,
int y)
- Overrides:
- tabForCoordinate in class TabbedPaneUI
getTabBounds
public Rectangle getTabBounds(JTabbedPane pane,
int i)
- Overrides:
- getTabBounds in class TabbedPaneUI
tabHeight
protected int tabHeight()
All Packages Class Hierarchy This Package Previous Next Index
Submit a bug or feature