Overview | Package | Class | Use | Tree | Deprecated | Index | Help
| Swing 1.1
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## 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.

Inner Class Summary
`class` | `BasicTabbedPaneUI.FocusHandler` This inner class is marked "public" due to a compiler bug.
`class` | `BasicTabbedPaneUI.MouseHandler` This inner class is marked "public" due to a compiler bug.
`class` | `BasicTabbedPaneUI.PropertyChangeHandler` This inner class is marked "public" due to a compiler bug.
`class` | `BasicTabbedPaneUI.TabbedPaneLayout` This inner class is marked "public" due to a compiler bug.
`class` | `BasicTabbedPaneUI.TabSelectionHandler` This inner class is marked "public" due to a compiler bug.

Field Summary
`protected java.awt.Insets` | `contentBorderInsets`
`protected java.awt.Color` | `darkShadow`
`protected KeyStroke` | `downKey`
`protected java.awt.Color` | `focus`
`protected java.awt.event.FocusListener` | `focusListener`
`protected java.awt.Color` | `highlight`
`protected KeyStroke` | `leftKey`
`protected java.awt.Color` | `lightHighlight`
`protected int` | `maxTabHeight`
`protected int` | `maxTabWidth`
`protected java.awt.event.MouseListener` | `mouseListener`
`protected java.beans.PropertyChangeListener` | `propertyChangeListener`
`protected java.awt.Rectangle[]` | `rects`
`protected KeyStroke` | `rightKey`
`protected int` | `runCount`
`protected int` | `selectedRun`
`protected java.awt.Insets` | `selectedTabPadInsets`
`protected java.awt.Color` | `shadow`
`protected java.awt.Insets` | `tabAreaInsets`
`protected ChangeListener` | `tabChangeListener`
`protected java.awt.Insets` | `tabInsets`
`protected JTabbedPane` | `tabPane`
`protected int` | `tabRunOverlay`
`protected int[]` | `tabRuns`
`protected int` | `textIconGap`
`protected KeyStroke` | `upKey`

Constructor Summary
`BasicTabbedPaneUI()`

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, java.awt.FontMetrics metrics)`
`protected ChangeListener` | `createChangeListener()`
`protected java.awt.event.FocusListener` | `createFocusListener()`
`protected java.awt.LayoutManager` | `createLayoutManager()`
`protected java.awt.event.MouseListener` | `createMouseListener()`
`protected java.beans.PropertyChangeListener` | `createPropertyChangeListener()`
`static ComponentUI` | `createUI(JComponent c)`
`protected void` | `expandTabRunsArray()`
`protected java.awt.Insets` | `getContentBorderInsets(int tabPlacement)`
`protected java.awt.FontMetrics` | `getFontMetrics()`
`protected Icon` | `getIconForTab(int tabIndex)`
`java.awt.Dimension` | `getMaximumSize(JComponent c)`
`java.awt.Dimension` | `getMinimumSize(JComponent c)`
`protected int` | `getNextTabIndex(int base)`
`java.awt.Dimension` | `getPreferredSize(JComponent c)`
`protected int` | `getPreviousTabIndex(int base)`
`protected int` | `getRunForTab(int tabCount, int tabIndex)`
`protected java.awt.Insets` | `getSelectedTabPadInsets(int tabPlacement)`
`protected java.awt.Insets` | `getTabAreaInsets(int tabPlacement)`
`java.awt.Rectangle` | `getTabBounds(JTabbedPane pane, int i)`
`protected java.awt.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 java.awt.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, java.awt.FontMetrics metrics, int tabIndex, java.lang.String title, Icon icon, java.awt.Rectangle tabRect, java.awt.Rectangle iconRect, java.awt.Rectangle textRect, boolean isSelected)`
`protected void` | `navigateSelectedTab(int direction)`
`void` | `paint(java.awt.Graphics g, JComponent c)`
`protected void` | `paintContentBorder(java.awt.Graphics g, int tabPlacement, int selectedIndex)`
`protected void` | `paintContentBorderBottomEdge(java.awt.Graphics g, int tabPlacement, int selectedIndex, int x, int y, int w, int h)`
`protected void` | `paintContentBorderLeftEdge(java.awt.Graphics g, int tabPlacement, int selectedIndex, int x, int y, int w, int h)`
`protected void` | `paintContentBorderRightEdge(java.awt.Graphics g, int tabPlacement, int selectedIndex, int x, int y, int w, int h)`
`protected void` | `paintContentBorderTopEdge(java.awt.Graphics g, int tabPlacement, int selectedIndex, int x, int y, int w, int h)`
`protected void` | `paintFocusIndicator(java.awt.Graphics g, int tabPlacement, java.awt.Rectangle[] rects, int tabIndex, java.awt.Rectangle iconRect, java.awt.Rectangle textRect, boolean isSelected)`
`protected void` | `paintIcon(java.awt.Graphics g, int tabPlacement, int tabIndex, Icon icon, java.awt.Rectangle iconRect, boolean isSelected)`
`protected void` | `paintTab(java.awt.Graphics g, int tabPlacement, java.awt.Rectangle[] rects, int tabIndex, java.awt.Rectangle iconRect, java.awt.Rectangle textRect)`
`protected void` | `paintTabBackground(java.awt.Graphics g, int tabPlacement, int tabIndex, int x, int y, int w, int h, boolean isSelected)`
`protected void` | `paintTabBorder(java.awt.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(java.awt.Graphics g, int tabPlacement, java.awt.Font font, java.awt.FontMetrics metrics, int tabIndex, java.lang.String title, java.awt.Rectangle textRect, boolean isSelected)`
`protected static void` | `rotateInsets(java.awt.Insets topInsets, java.awt.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(java.awt.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 javax.swing.plaf.ComponentUI
`contains, getAccessibleChild, getAccessibleChildrenCount, update`

Methods inherited from class java.lang.Object
`clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

Field Detail

### tabPane

    protected JTabbedPane tabPane

### highlight

    protected java.awt.Color highlight

### lightHighlight

    protected java.awt.Color lightHighlight

### shadow

    protected java.awt.Color shadow

### darkShadow

    protected java.awt.Color darkShadow

### focus

    protected java.awt.Color focus

### textIconGap

    protected int textIconGap

### tabRunOverlay

    protected int tabRunOverlay

### tabInsets

    protected java.awt.Insets tabInsets

### selectedTabPadInsets

    protected java.awt.Insets selectedTabPadInsets

### tabAreaInsets

    protected java.awt.Insets tabAreaInsets

### contentBorderInsets

    protected java.awt.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 java.awt.Rectangle[] rects

### maxTabHeight

    protected int maxTabHeight

### maxTabWidth

    protected int maxTabWidth

### tabChangeListener

    protected ChangeListener tabChangeListener

### propertyChangeListener

    protected java.beans.PropertyChangeListener propertyChangeListener

### mouseListener

    protected java.awt.event.MouseListener mouseListener

### focusListener

    protected java.awt.event.FocusListener focusListener

Constructor Detail

### BasicTabbedPaneUI

    public BasicTabbedPaneUI()

Method Detail

### 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 java.awt.LayoutManager createLayoutManager()

### installDefaults

    protected void installDefaults()

### uninstallDefaults

    protected void uninstallDefaults()

### installListeners

    protected void installListeners()

### uninstallListeners

    protected void uninstallListeners()

### createMouseListener

    protected java.awt.event.MouseListener createMouseListener()

### createFocusListener

    protected java.awt.event.FocusListener createFocusListener()

### createChangeListener

    protected ChangeListener createChangeListener()

### createPropertyChangeListener

    protected java.beans.PropertyChangeListener createPropertyChangeListener()

### installKeyboardActions

    protected void installKeyboardActions()

### uninstallKeyboardActions

    protected void uninstallKeyboardActions()

### getPreferredSize

    public java.awt.Dimension getPreferredSize(JComponent c)

  Overrides:
    getPreferredSize in class ComponentUI

### getMinimumSize

    public java.awt.Dimension getMinimumSize(JComponent c)

  Overrides:
    getMinimumSize in class ComponentUI

### getMaximumSize

    public java.awt.Dimension getMaximumSize(JComponent c)

  Overrides:
    getMaximumSize in class ComponentUI

### paint

    public void paint(java.awt.Graphics g,
                      JComponent c)

  Overrides:
    paint in class ComponentUI

### paintTab

    protected void paintTab(java.awt.Graphics g,
                            int tabPlacement,
                            java.awt.Rectangle[] rects,
                            int tabIndex,
                            java.awt.Rectangle iconRect,
                            java.awt.Rectangle textRect)

### layoutLabel

    protected void layoutLabel(int tabPlacement,
                               java.awt.FontMetrics metrics,
                               int tabIndex,
                               java.lang.String title,
                               Icon icon,
                               java.awt.Rectangle tabRect,
                               java.awt.Rectangle iconRect,
                               java.awt.Rectangle textRect,
                               boolean isSelected)

### paintIcon

    protected void paintIcon(java.awt.Graphics g,
                             int tabPlacement,
                             int tabIndex,
                             Icon icon,
                             java.awt.Rectangle iconRect,
                             boolean isSelected)

### paintText

    protected void paintText(java.awt.Graphics g,
                             int tabPlacement,
                             java.awt.Font font,
                             java.awt.FontMetrics metrics,
                             int tabIndex,
                             java.lang.String title,
                             java.awt.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(java.awt.Graphics g,
                                       int tabPlacement,
                                       java.awt.Rectangle[] rects,
                                       int tabIndex,
                                       java.awt.Rectangle iconRect,
                                       java.awt.Rectangle textRect,
                                       boolean isSelected)

### paintTabBorder

    protected void paintTabBorder(java.awt.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(java.awt.Graphics g,
                                      int tabPlacement,
                                      int tabIndex,
                                      int x,
                                      int y,
                                      int w,
                                      int h,
                                      boolean isSelected)

### paintContentBorder

    protected void paintContentBorder(java.awt.Graphics g,
                                      int tabPlacement,
                                      int selectedIndex)

### paintContentBorderTopEdge

    protected void paintContentBorderTopEdge(java.awt.Graphics g,
                                             int tabPlacement,
                                             int selectedIndex,
                                             int x,
                                             int y,
                                             int w,
                                             int h)

### paintContentBorderLeftEdge

    protected void paintContentBorderLeftEdge(java.awt.Graphics g,
                                              int tabPlacement,
                                              int selectedIndex,
                                              int x,
                                              int y,
                                              int w,
                                              int h)

### paintContentBorderBottomEdge

    protected void paintContentBorderBottomEdge(java.awt.Graphics g,
                                                int tabPlacement,
                                                int selectedIndex,
                                                int x,
                                                int y,
                                                int w,
                                                int h)

### paintContentBorderRightEdge

    protected void paintContentBorderRightEdge(java.awt.Graphics g,
                                               int tabPlacement,
                                               int selectedIndex,
                                               int x,
                                               int y,
                                               int w,
                                               int h)

### getTabBounds

    public java.awt.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 java.awt.Component getVisibleComponent()

### setVisibleComponent

    protected void setVisibleComponent(java.awt.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,
                                    java.awt.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 java.awt.Insets getTabInsets(int tabPlacement,
                                           int tabIndex)

### getSelectedTabPadInsets

    protected java.awt.Insets getSelectedTabPadInsets(int tabPlacement)

### getTabAreaInsets

    protected java.awt.Insets getTabAreaInsets(int tabPlacement)

### getContentBorderInsets

    protected java.awt.Insets getContentBorderInsets(int tabPlacement)

### getFontMetrics

    protected java.awt.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(java.awt.Insets topInsets,
                                       java.awt.Insets targetInsets,
                                       int targetPlacement)

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
| Swing 1.1
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

Submit a bug or feature
Java is a trademark or registered trademark of Sun Microsystems, Inc. in the US and other countries.
Copyright 1993-1998 Sun Microsystems, Inc. 901 San Antonio Road,
Palo Alto, California, 94303, U.S.A. All Rights Reserved.