Spec-Zone .ru
спецификации, руководства, описания, API
javax.swing.plaf.basic
Class BasicTabbedPaneUI
java.lang.Object
|
+--javax.swing.plaf.ComponentUI
|
+--javax.swing.plaf.TabbedPaneUI
|
+--javax.swing.plaf.basic.BasicTabbedPaneUI
Direct Known Subclasses: MetalTabbedPaneUI
public class BasicTabbedPaneUI extends TabbedPaneUI implements SwingConstants
A Basic L&F implementation of TabbedPaneUI.
Fields inherited from interface javax.swing.SwingConstants
BOTTOM ,
CENTER ,
EAST ,
HORIZONTAL ,
LEADING ,
LEFT ,
NORTH ,
NORTH_EAST ,
NORTH_WEST ,
RIGHT ,
SOUTH ,
SOUTH_EAST ,
SOUTH_WEST ,
TOP ,
TRAILING ,
VERTICAL ,
WEST
Method Summary
protected void
assureRectsCreated (int tabCount)
protected int
calculateMaxTabHeight (int tabPlacement)
protected int
calculateMaxTabWidth (int tabPlacement)
protected int
calculateTabAreaHeight (int tabPlacement,
int horizRunCount,
int maxTabHeight)
protected int
calculateTabAreaWidth (int tabPlacement,
int vertRunCount,
int maxTabWidth)
protected int
calculateTabHeight (int tabPlacement,
int tabIndex,
int fontHeight)
protected int
calculateTabWidth (int tabPlacement,
int tabIndex,
FontMetrics metrics)
protected ChangeListener
createChangeListener ()
protected FocusListener
createFocusListener ()
protected LayoutManager
createLayoutManager ()
protected MouseListener
createMouseListener ()
protected PropertyChangeListener
createPropertyChangeListener ()
static ComponentUI
createUI (JComponent c)
protected void
expandTabRunsArray ()
protected Insets
getContentBorderInsets (int tabPlacement)
protected FontMetrics
getFontMetrics ()
protected Icon
getIconForTab (int tabIndex)
Dimension
getMaximumSize (JComponent c)
Dimension
getMinimumSize (JComponent c)
protected int
getNextTabIndex (int base)
Dimension
getPreferredSize (JComponent c)
protected int
getPreviousTabIndex (int base)
protected int
getRunForTab (int tabCount,
int tabIndex)
protected Insets
getSelectedTabPadInsets (int tabPlacement)
protected Insets
getTabAreaInsets (int tabPlacement)
Rectangle
getTabBounds (JTabbedPane pane,
int i)
protected Insets
getTabInsets (int tabPlacement,
int tabIndex)
protected int
getTabLabelShiftX (int tabPlacement,
int tabIndex,
boolean isSelected)
protected int
getTabLabelShiftY (int tabPlacement,
int tabIndex,
boolean isSelected)
int
getTabRunCount (JTabbedPane pane)
protected int
getTabRunIndent (int tabPlacement,
int run)
protected int
getTabRunOffset (int tabPlacement,
int tabCount,
int tabIndex,
boolean forward)
protected int
getTabRunOverlay (int tabPlacement)
protected Component
getVisibleComponent ()
protected void
installDefaults ()
protected void
installKeyboardActions ()
protected void
installListeners ()
void
installUI (JComponent c)
protected int
lastTabInRun (int tabCount,
int run)
protected void
layoutLabel (int tabPlacement,
FontMetrics metrics,
int tabIndex,
String title,
Icon icon,
Rectangle tabRect,
Rectangle iconRect,
Rectangle textRect,
boolean isSelected)
protected void
navigateSelectedTab (int direction)
void
paint (Graphics g,
JComponent c)
protected void
paintContentBorder (Graphics g,
int tabPlacement,
int selectedIndex)
protected void
paintContentBorderBottomEdge (Graphics g,
int tabPlacement,
int selectedIndex,
int x,
int y,
int w,
int h)
protected void
paintContentBorderLeftEdge (Graphics g,
int tabPlacement,
int selectedIndex,
int x,
int y,
int w,
int h)
protected void
paintContentBorderRightEdge (Graphics g,
int tabPlacement,
int selectedIndex,
int x,
int y,
int w,
int h)
protected void
paintContentBorderTopEdge (Graphics g,
int tabPlacement,
int selectedIndex,
int x,
int y,
int w,
int h)
protected void
paintFocusIndicator (Graphics g,
int tabPlacement,
Rectangle [] rects,
int tabIndex,
Rectangle iconRect,
Rectangle textRect,
boolean isSelected)
protected void
paintIcon (Graphics g,
int tabPlacement,
int tabIndex,
Icon icon,
Rectangle iconRect,
boolean isSelected)
protected void
paintTab (Graphics g,
int tabPlacement,
Rectangle [] rects,
int tabIndex,
Rectangle iconRect,
Rectangle textRect)
protected void
paintTabBackground (Graphics g,
int tabPlacement,
int tabIndex,
int x,
int y,
int w,
int h,
boolean isSelected)
protected void
paintTabBorder (Graphics g,
int tabPlacement,
int tabIndex,
int x,
int y,
int w,
int h,
boolean isSelected)
this function draws the border around each tab
note that this function does now draw the background of the tab.
protected void
paintText (Graphics g,
int tabPlacement,
Font font,
FontMetrics metrics,
int tabIndex,
String title,
Rectangle textRect,
boolean isSelected)
protected static void
rotateInsets (Insets topInsets,
Insets targetInsets,
int targetPlacement)
protected void
selectAdjacentRunTab (int tabPlacement,
int tabIndex,
int offset)
protected void
selectNextTab (int current)
protected void
selectPreviousTab (int current)
protected void
setVisibleComponent (Component component)
protected boolean
shouldPadTabRun (int tabPlacement,
int run)
protected boolean
shouldRotateTabRuns (int tabPlacement)
int
tabForCoordinate (JTabbedPane pane,
int x,
int y)
protected void
uninstallDefaults ()
protected void
uninstallKeyboardActions ()
protected void
uninstallListeners ()
void
uninstallUI (JComponent c)
Methods inherited from class java.lang.Object
clone ,
equals ,
finalize ,
getClass ,
hashCode ,
notify ,
notifyAll ,
toString ,
wait ,
wait ,
wait
tabPane
protected JTabbedPane tabPane
highlight
protected Color highlight
lightHighlight
protected Color lightHighlight
shadow
protected Color shadow
darkShadow
protected Color darkShadow
focus
protected Color focus
textIconGap
protected int textIconGap
tabRunOverlay
protected int tabRunOverlay
tabInsets
protected Insets tabInsets
selectedTabPadInsets
protected Insets selectedTabPadInsets
tabAreaInsets
protected Insets tabAreaInsets
contentBorderInsets
protected Insets contentBorderInsets
upKey
protected KeyStroke upKey
downKey
protected KeyStroke downKey
leftKey
protected KeyStroke leftKey
rightKey
protected KeyStroke rightKey
tabRuns
protected int[] tabRuns
runCount
protected int runCount
selectedRun
protected int selectedRun
rects
protected Rectangle [] rects
maxTabHeight
protected int maxTabHeight
maxTabWidth
protected int maxTabWidth
tabChangeListener
protected ChangeListener tabChangeListener
propertyChangeListener
protected PropertyChangeListener propertyChangeListener
mouseListener
protected MouseListener mouseListener
focusListener
protected FocusListener focusListener
BasicTabbedPaneUI
public BasicTabbedPaneUI ()
createUI
public static ComponentUI createUI (JComponent c)
installUI
public void installUI (JComponent c)
Overrides: installUI in class ComponentUI
uninstallUI
public void uninstallUI (JComponent c)
Overrides: uninstallUI in class ComponentUI
createLayoutManager
protected LayoutManager createLayoutManager ()
installDefaults
protected void installDefaults ()
uninstallDefaults
protected void uninstallDefaults ()
installListeners
protected void installListeners ()
uninstallListeners
protected void uninstallListeners ()
createMouseListener
protected MouseListener createMouseListener ()
createFocusListener
protected FocusListener createFocusListener ()
createChangeListener
protected ChangeListener createChangeListener ()
createPropertyChangeListener
protected PropertyChangeListener createPropertyChangeListener ()
installKeyboardActions
protected void installKeyboardActions ()
uninstallKeyboardActions
protected void uninstallKeyboardActions ()
getPreferredSize
public Dimension getPreferredSize (JComponent c)
Overrides: getPreferredSize in class ComponentUI
getMinimumSize
public Dimension getMinimumSize (JComponent c)
Overrides: getMinimumSize in class ComponentUI
getMaximumSize
public Dimension getMaximumSize (JComponent c)
Overrides: getMaximumSize in class ComponentUI
paint
public void paint (Graphics g,
JComponent c)
Overrides: paint in class ComponentUI
paintTab
protected void paintTab (Graphics g,
int tabPlacement,
Rectangle [] rects,
int tabIndex,
Rectangle iconRect,
Rectangle textRect)
layoutLabel
protected void layoutLabel (int tabPlacement,
FontMetrics metrics,
int tabIndex,
String title,
Icon icon,
Rectangle tabRect,
Rectangle iconRect,
Rectangle textRect,
boolean isSelected)
paintIcon
protected void paintIcon (Graphics g,
int tabPlacement,
int tabIndex,
Icon icon,
Rectangle iconRect,
boolean isSelected)
paintText
protected void paintText (Graphics g,
int tabPlacement,
Font font,
FontMetrics metrics,
int tabIndex,
String title,
Rectangle textRect,
boolean isSelected)
getTabLabelShiftX
protected int getTabLabelShiftX (int tabPlacement,
int tabIndex,
boolean isSelected)
getTabLabelShiftY
protected int getTabLabelShiftY (int tabPlacement,
int tabIndex,
boolean isSelected)
paintFocusIndicator
protected void paintFocusIndicator (Graphics g,
int tabPlacement,
Rectangle [] rects,
int tabIndex,
Rectangle iconRect,
Rectangle textRect,
boolean isSelected)
paintTabBorder
protected void paintTabBorder (Graphics g,
int tabPlacement,
int tabIndex,
int x,
int y,
int w,
int h,
boolean isSelected)
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 tabPlacement,
int tabIndex,
int x,
int y,
int w,
int h,
boolean isSelected)
paintContentBorder
protected void paintContentBorder (Graphics g,
int tabPlacement,
int selectedIndex)
paintContentBorderTopEdge
protected void paintContentBorderTopEdge (Graphics g,
int tabPlacement,
int selectedIndex,
int x,
int y,
int w,
int h)
paintContentBorderLeftEdge
protected void paintContentBorderLeftEdge (Graphics g,
int tabPlacement,
int selectedIndex,
int x,
int y,
int w,
int h)
paintContentBorderBottomEdge
protected void paintContentBorderBottomEdge (Graphics g,
int tabPlacement,
int selectedIndex,
int x,
int y,
int w,
int h)
paintContentBorderRightEdge
protected void paintContentBorderRightEdge (Graphics g,
int tabPlacement,
int selectedIndex,
int x,
int y,
int w,
int h)
getTabBounds
public Rectangle getTabBounds (JTabbedPane pane,
int i)
Overrides: getTabBounds in class TabbedPaneUI
getTabRunCount
public int getTabRunCount (JTabbedPane pane)
Overrides: getTabRunCount in class TabbedPaneUI
tabForCoordinate
public int tabForCoordinate (JTabbedPane pane,
int x,
int y)
Overrides: tabForCoordinate in class TabbedPaneUI
getVisibleComponent
protected Component getVisibleComponent ()
setVisibleComponent
protected void setVisibleComponent (Component component)
assureRectsCreated
protected void assureRectsCreated (int tabCount)
expandTabRunsArray
protected void expandTabRunsArray ()
getRunForTab
protected int getRunForTab (int tabCount,
int tabIndex)
lastTabInRun
protected int lastTabInRun (int tabCount,
int run)
getTabRunOverlay
protected int getTabRunOverlay (int tabPlacement)
getTabRunIndent
protected int getTabRunIndent (int tabPlacement,
int run)
shouldPadTabRun
protected boolean shouldPadTabRun (int tabPlacement,
int run)
shouldRotateTabRuns
protected boolean shouldRotateTabRuns (int tabPlacement)
getIconForTab
protected Icon getIconForTab (int tabIndex)
calculateTabHeight
protected int calculateTabHeight (int tabPlacement,
int tabIndex,
int fontHeight)
calculateMaxTabHeight
protected int calculateMaxTabHeight (int tabPlacement)
calculateTabWidth
protected int calculateTabWidth (int tabPlacement,
int tabIndex,
FontMetrics metrics)
calculateMaxTabWidth
protected int calculateMaxTabWidth (int tabPlacement)
calculateTabAreaHeight
protected int calculateTabAreaHeight (int tabPlacement,
int horizRunCount,
int maxTabHeight)
calculateTabAreaWidth
protected int calculateTabAreaWidth (int tabPlacement,
int vertRunCount,
int maxTabWidth)
getTabInsets
protected Insets getTabInsets (int tabPlacement,
int tabIndex)
getSelectedTabPadInsets
protected Insets getSelectedTabPadInsets (int tabPlacement)
getTabAreaInsets
protected Insets getTabAreaInsets (int tabPlacement)
getContentBorderInsets
protected Insets getContentBorderInsets (int tabPlacement)
getFontMetrics
protected FontMetrics getFontMetrics ()
navigateSelectedTab
protected void navigateSelectedTab (int direction)
selectNextTab
protected void selectNextTab (int current)
selectPreviousTab
protected void selectPreviousTab (int current)
selectAdjacentRunTab
protected void selectAdjacentRunTab (int tabPlacement,
int tabIndex,
int offset)
getTabRunOffset
protected int getTabRunOffset (int tabPlacement,
int tabCount,
int tabIndex,
boolean forward)
getPreviousTabIndex
protected int getPreviousTabIndex (int base)
getNextTabIndex
protected int getNextTabIndex (int base)
rotateInsets
protected static void rotateInsets (Insets topInsets,
Insets targetInsets,
int targetPlacement)
Submit a bug or feature Java, Java 2D, and JDBC are a trademarks or registered trademarks of Sun Microsystems, Inc. in the US and other countries. Copyright 1993-1999 Sun Microsystems, Inc. 901 San Antonio Road, Palo Alto, California, 94303, U.S.A. All Rights Reserved.