Package Summary  Overview Summary

class:BasicTabbedPaneUI [NONE]

All Implemented Interfaces:
SwingConstants
Direct Known Subclasses:
MetalTabbedPaneUI, SynthTabbedPaneUI

public class BasicTabbedPaneUIextends TabbedPaneUI implements SwingConstants
A Basic L&F implementation of TabbedPaneUI.

field:tabPane [NONE]

  • tabPane

    protected JTabbedPane tabPane
    The tab pane
  • field:highlight [NONE]

    highlight

    protected Color highlight
    Highlight color

    field:lightHighlight [NONE]

    lightHighlight

    protected Color lightHighlight
    Light highlight color

    field:shadow [NONE]

    shadow

    protected Color shadow
    Shadow color

    field:darkShadow [NONE]

    darkShadow

    protected Color darkShadow
    Dark shadow color

    field:focus [NONE]

    focus

    protected Color focus
    Focus color

    field:textIconGap [NONE]

    textIconGap

    protected int textIconGap
    Text icon gap

    field:tabRunOverlay [NONE]

    tabRunOverlay

    protected int tabRunOverlay
    Tab run overlay

    field:tabInsets [NONE]

    tabInsets

    protected Insets tabInsets
    Tab insets

    field:selectedTabPadInsets [NONE]

    selectedTabPadInsets

    protected Insets selectedTabPadInsets
    Selected tab insets

    field:tabAreaInsets [NONE]

    tabAreaInsets

    protected Insets tabAreaInsets
    Tab area insets

    field:contentBorderInsets [NONE]

    contentBorderInsets

    protected Insets contentBorderInsets
    Content border insets

    field:upKey [NONE]

    upKey

    @Deprecatedprotected KeyStroke upKey
    Deprecated.
    As of Java 2 platform v1.3.
    As of Java 2 platform v1.3 this previously undocumented field is no longer used. Key bindings are now defined by the LookAndFeel, please refer to the key bindings specification for further details.

    field:downKey [NONE]

    downKey

    @Deprecatedprotected KeyStroke downKey
    Deprecated.
    As of Java 2 platform v1.3.
    As of Java 2 platform v1.3 this previously undocumented field is no longer used. Key bindings are now defined by the LookAndFeel, please refer to the key bindings specification for further details.

    field:leftKey [NONE]

    leftKey

    @Deprecatedprotected KeyStroke leftKey
    Deprecated.
    As of Java 2 platform v1.3.
    As of Java 2 platform v1.3 this previously undocumented field is no longer used. Key bindings are now defined by the LookAndFeel, please refer to the key bindings specification for further details.

    field:rightKey [NONE]

    rightKey

    @Deprecatedprotected KeyStroke rightKey
    Deprecated.
    As of Java 2 platform v1.3.
    As of Java 2 platform v1.3 this previously undocumented field is no longer used. Key bindings are now defined by the LookAndFeel, please refer to the key bindings specification for further details.

    field:tabRuns [NONE]

    tabRuns

    protected int[] tabRuns
    Tab runs

    field:runCount [NONE]

    runCount

    protected int runCount
    Run count

    field:selectedRun [NONE]

    selectedRun

    protected int selectedRun
    Selected run

    field:rects [NONE]

    rects

    protected Rectangle[] rects
    Tab rects

    field:maxTabHeight [NONE]

    maxTabHeight

    protected int maxTabHeight
    Maximum tab height

    field:maxTabWidth [NONE]

    maxTabWidth

    protected int maxTabWidth
    Maximum tab width

    field:tabChangeListener [NONE]

    tabChangeListener

    protected ChangeListener tabChangeListener
    Tab change listener

    field:propertyChangeListener [NONE]

    propertyChangeListener

    protected PropertyChangeListener propertyChangeListener
    Property change listener

    field:mouseListener [NONE]

    mouseListener

    protected MouseListener mouseListener
    Mouse change listener

    field:focusListener [NONE]

    focusListener

    protected FocusListener focusListener
    Focus change listener

    field:calcRect [NONE]

    calcRect

    protected transient  Rectangle calcRect
    A rectangle used for general layout calculations in order to avoid constructing many new Rectangles on the fly.

    constructor:BasicTabbedPaneUI() [NONE]

    • BasicTabbedPaneUI

      public BasicTabbedPaneUI()
      Constructs a BasicTabbedPaneUI.

    method:createUI(javax.swing.JComponent) [NONE]

  • createUI

    public static  ComponentUI createUI (JComponent c)
    Creates a UI.
    Parameters:
    c - a component
    Returns:
    a UI
  • method:installUI(javax.swing.JComponent) [NONE]

    installUI

    public void installUI (JComponent c)
    Description copied from class: ComponentUI
    Configures the specified component appropriately for the look and feel. This method is invoked when the ComponentUI instance is being installed as the UI delegate on the specified component. This method should completely configure the component for the look and feel, including the following:
    1. Install default property values for color, fonts, borders, icons, opacity, etc. on the component. Whenever possible, property values initialized by the client program should not be overridden.
    2. Install a LayoutManager on the component if necessary.
    3. Create/add any required sub-components to the component.
    4. Create/install event listeners on the component.
    5. Create/install a PropertyChangeListener on the component in order to detect and respond to component property changes appropriately.
    6. Install keyboard UI (mnemonics, traversal, etc.) on the component.
    7. Initialize any appropriate instance data.
    Overrides:
    installUI in class ComponentUI
    Parameters:
    c - the component where this UI delegate is being installed
    See Also:

    method:uninstallUI(javax.swing.JComponent) [NONE]

    uninstallUI

    public void uninstallUI (JComponent c)
    Description copied from class: ComponentUI
    Reverses configuration which was done on the specified component during installUI. This method is invoked when this UIComponent instance is being removed as the UI delegate for the specified component. This method should undo the configuration performed in installUI, being careful to leave the JComponent instance in a clean state (no extraneous listeners, look-and-feel-specific property objects, etc.). This should include the following:
    1. Remove any UI-set borders from the component.
    2. Remove any UI-set layout managers on the component.
    3. Remove any UI-added sub-components from the component.
    4. Remove any UI-added event/property listeners from the component.
    5. Remove any UI-installed keyboard UI from the component.
    6. Nullify any allocated instance data objects to allow for GC.
    Overrides:
    uninstallUI in class ComponentUI
    Parameters:
    c - the component from which this UI delegate is being removed; this argument is often ignored, but might be used if the UI object is stateless and shared by multiple components
    See Also:

    method:createLayoutManager() [NONE]

    createLayoutManager

    protected LayoutManager createLayoutManager()
    Invoked by installUI to create a layout manager object to manage the JTabbedPane.
    Returns:
    a layout manager object
    See Also:

    method:installComponents() [NONE]

    installComponents

    protected void installComponents()
    Creates and installs any required subcomponents for the JTabbedPane. Invoked by installUI.
    Since:
    1.4

    method:createScrollButton(int) [NONE]

    createScrollButton

    protected JButton createScrollButton (int direction)
    Creates and returns a JButton that will provide the user with a way to scroll the tabs in a particular direction. The returned JButton must be instance of UIResource.
    Parameters:
    direction - One of the SwingConstants constants: SOUTH, NORTH, EAST or WEST
    Returns:
    Widget for user to
    Throws:
    IllegalArgumentException - if direction is not one of NORTH, SOUTH, EAST or WEST
    Since:
    1.5
    See Also:

    method:uninstallComponents() [NONE]

    uninstallComponents

    protected void uninstallComponents()
    Removes any installed subcomponents from the JTabbedPane. Invoked by uninstallUI.
    Since:
    1.4

    method:installDefaults() [NONE]

    installDefaults

    protected void installDefaults()
    Installs the defaults.

    method:uninstallDefaults() [NONE]

    uninstallDefaults

    protected void uninstallDefaults()
    Uninstalls the defaults.

    method:installListeners() [NONE]

    installListeners

    protected void installListeners()
    Installs the listeners.

    method:uninstallListeners() [NONE]

    uninstallListeners

    protected void uninstallListeners()
    Uninstalls the listeners.

    method:createMouseListener() [NONE]

    createMouseListener

    protected MouseListener createMouseListener()
    Creates a mouse listener.
    Returns:
    a mouse listener

    method:createFocusListener() [NONE]

    createFocusListener

    protected FocusListener createFocusListener()
    Creates a focus listener.
    Returns:
    a focus listener

    method:createChangeListener() [NONE]

    createChangeListener

    protected ChangeListener createChangeListener()
    Creates a change listener.
    Returns:
    a change listener

    method:createPropertyChangeListener() [NONE]

    createPropertyChangeListener

    protected PropertyChangeListener createPropertyChangeListener()
    Creates a property change listener.
    Returns:
    a property change listener

    method:installKeyboardActions() [NONE]

    installKeyboardActions

    protected void installKeyboardActions()
    Installs the keyboard actions.

    method:uninstallKeyboardActions() [NONE]

    uninstallKeyboardActions

    protected void uninstallKeyboardActions()
    Uninstalls the keyboard actions.

    method:setRolloverTab(int) [NONE]

    setRolloverTab

    protected void setRolloverTab (int index)
    Sets the tab the mouse is currently over to index. index will be -1 if the mouse is no longer over any tab. No checking is done to ensure the passed in index identifies a valid tab.
    Parameters:
    index - Index of the tab the mouse is over.
    Since:
    1.5

    method:getRolloverTab() [NONE]

    getRolloverTab

    protected int getRolloverTab()
    Returns the tab the mouse is currently over, or -1 if the mouse is no longer over any tab.
    Returns:
    the tab the mouse is currently over, or -1 if the mouse is no longer over any tab
    Since:
    1.5

    method:getMinimumSize(javax.swing.JComponent) [NONE]

    getMinimumSize

    public Dimension getMinimumSize (JComponent c)
    Description copied from class: ComponentUI
    Returns the specified component's minimum size appropriate for the look and feel. If null is returned, the minimum size will be calculated by the component's layout manager instead (this is the preferred approach for any component with a specific layout manager installed). The default implementation of this method invokes getPreferredSize and returns that value.
    Overrides:
    getMinimumSize in class ComponentUI
    Parameters:
    c - the component whose minimum size is being queried; this argument is often ignored, but might be used if the UI object is stateless and shared by multiple components
    Returns:
    a Dimension object or null
    See Also:

    method:getMaximumSize(javax.swing.JComponent) [NONE]

    getMaximumSize

    public Dimension getMaximumSize (JComponent c)
    Description copied from class: ComponentUI
    Returns the specified component's maximum size appropriate for the look and feel. If null is returned, the maximum size will be calculated by the component's layout manager instead (this is the preferred approach for any component with a specific layout manager installed). The default implementation of this method invokes getPreferredSize and returns that value.
    Overrides:
    getMaximumSize in class ComponentUI
    Parameters:
    c - the component whose maximum size is being queried; this argument is often ignored, but might be used if the UI object is stateless and shared by multiple components
    Returns:
    a Dimension object or null
    See Also:

    method:getBaseline(javax.swing.JComponent,int,int) [NONE]

    getBaseline

    public int getBaseline (JComponent c, int width, int height)
    Returns the baseline.
    Overrides:
    getBaseline in class ComponentUI
    Parameters:
    c - JComponent baseline is being requested for
    width - the width to get the baseline for
    height - the height to get the baseline for
    Returns:
    baseline or a value < 0 indicating there is no reasonable baseline
    Throws:
    NullPointerException - if c is null
    IllegalArgumentException - if width or height is < 0
    Since:
    1.6
    See Also:

    method:getBaselineResizeBehavior(javax.swing.JComponent) [NONE]

    getBaselineResizeBehavior

    public Component.BaselineResizeBehavior getBaselineResizeBehavior (JComponent c)
    Returns an enum indicating how the baseline of the component changes as the size changes.
    Overrides:
    getBaselineResizeBehavior in class ComponentUI
    Parameters:
    c - JComponent to return baseline resize behavior for
    Returns:
    an enum indicating how the baseline changes as the component size changes
    Throws:
    NullPointerException - if c is null
    Since:
    1.6
    See Also:

    method:getBaseline(int) [NONE]

    getBaseline

    protected int getBaseline (int tab)
    Returns the baseline for the specified tab.
    Parameters:
    tab - index of tab to get baseline for
    Returns:
    baseline or a value < 0 indicating there is no reasonable baseline
    Throws:
    IndexOutOfBoundsException - if index is out of range (index < 0 || index >= tab count)
    Since:
    1.6

    method:getBaselineOffset() [NONE]

    getBaselineOffset

    protected int getBaselineOffset()
    Returns the amount the baseline is offset by. This is typically the same as getTabLabelShiftY.
    Returns:
    amount to offset the baseline by
    Since:
    1.6

    method:paint(java.awt.Graphics,javax.swing.JComponent) [NONE]

    paint

    public void paint (Graphics g, JComponent c)
    Description copied from class: ComponentUI
    Paints the specified component appropriately for the look and feel. This method is invoked from the ComponentUI.update method when the specified component is being painted. Subclasses should override this method and use the specified Graphics object to render the content of the component.
    Overrides:
    paint in class ComponentUI
    Parameters:
    g - the Graphics context in which to paint
    c - the component being painted; this argument is often ignored, but might be used if the UI object is stateless and shared by multiple components
    See Also:

    method:paintTabArea(java.awt.Graphics,int,int) [NONE]

    paintTabArea

    protected void paintTabArea (Graphics g, int tabPlacement, int selectedIndex)
    Paints the tabs in the tab area. Invoked by paint(). The graphics parameter must be a valid Graphics object. Tab placement may be either: JTabbedPane.TOP, JTabbedPane.BOTTOM, JTabbedPane.LEFT, or JTabbedPane.RIGHT. The selected index must be a valid tabbed pane tab index (0 to tab count - 1, inclusive) or -1 if no tab is currently selected. The handling of invalid parameters is unspecified.
    Parameters:
    g - the graphics object to use for rendering
    tabPlacement - the placement for the tabs within the JTabbedPane
    selectedIndex - the tab index of the selected component
    Since:
    1.4

    method:paintTab(java.awt.Graphics,int,java.awt.Rectangle[],int,java.awt.Rectangle,java.awt.Rectangle) [NONE]

    paintTab

    protected void paintTab (Graphics g, int tabPlacement, Rectangle[] rects, int tabIndex, Rectangle iconRect, Rectangle textRect)
    Paints a tab.
    Parameters:
    g - the graphics
    tabPlacement - the tab placement
    rects - the tab rectangles
    tabIndex - the tab index
    iconRect - the icon rectangle
    textRect - the text rectangle

    method:layoutLabel(int,java.awt.FontMetrics,int,java.lang.String,javax.swing.Icon,java.awt.Rectangle,java.awt.Rectangle,java.awt.Rectangle,boolean) [NONE]

    layoutLabel

    protected void layoutLabel (int tabPlacement, FontMetrics metrics, int tabIndex, String title, Icon icon, Rectangle tabRect, Rectangle iconRect, Rectangle textRect, boolean isSelected)
    Lays out a label.
    Parameters:
    tabPlacement - the tab placement
    metrics - the font metrics
    tabIndex - the tab index
    title - the title
    icon - the icon
    tabRect - the tab rectangle
    iconRect - the icon rectangle
    textRect - the text rectangle
    isSelected - selection status

    method:paintIcon(java.awt.Graphics,int,int,javax.swing.Icon,java.awt.Rectangle,boolean) [NONE]

    paintIcon

    protected void paintIcon (Graphics g, int tabPlacement, int tabIndex, Icon icon, Rectangle iconRect, boolean isSelected)
    Paints an icon.
    Parameters:
    g - the graphics
    tabPlacement - the tab placement
    tabIndex - the tab index
    icon - the icon
    iconRect - the icon rectangle
    isSelected - selection status

    method:paintText(java.awt.Graphics,int,java.awt.Font,java.awt.FontMetrics,int,java.lang.String,java.awt.Rectangle,boolean) [NONE]

    paintText

    protected void paintText (Graphics g, int tabPlacement, Font font, FontMetrics metrics, int tabIndex, String title, Rectangle textRect, boolean isSelected)
    Paints text.
    Parameters:
    g - the graphics
    tabPlacement - the tab placement
    font - the font
    metrics - the font metrics
    tabIndex - the tab index
    title - the title
    textRect - the text rectangle
    isSelected - selection status

    method:getTabLabelShiftX(int,int,boolean) [NONE]

    getTabLabelShiftX

    protected int getTabLabelShiftX (int tabPlacement, int tabIndex, boolean isSelected)
    Returns the tab label shift x.
    Parameters:
    tabPlacement - the tab placement
    tabIndex - the tab index
    isSelected - selection status
    Returns:
    the tab label shift x

    method:getTabLabelShiftY(int,int,boolean) [NONE]

    getTabLabelShiftY

    protected int getTabLabelShiftY (int tabPlacement, int tabIndex, boolean isSelected)
    Returns the tab label shift y.
    Parameters:
    tabPlacement - the tab placement
    tabIndex - the tab index
    isSelected - selection status
    Returns:
    the tab label shift y

    method:paintFocusIndicator(java.awt.Graphics,int,java.awt.Rectangle[],int,java.awt.Rectangle,java.awt.Rectangle,boolean) [NONE]

    paintFocusIndicator

    protected void paintFocusIndicator (Graphics g, int tabPlacement, Rectangle[] rects, int tabIndex, Rectangle iconRect, Rectangle textRect, boolean isSelected)
    Paints the focus indicator.
    Parameters:
    g - the graphics
    tabPlacement - the tab placement
    rects - the tab rectangles
    tabIndex - the tab index
    iconRect - the icon rectangle
    textRect - the text rectangle
    isSelected - selection status

    method:paintTabBorder(java.awt.Graphics,int,int,int,int,int,int,boolean) [NONE]

    paintTabBorder

    protected void paintTabBorder (Graphics g, int tabPlacement, int tabIndex, int x, int y, int w, int h, boolean isSelected)
    Paints the border around a tab. Note that this function does not paint the background of the tab, that is done elsewhere.
    Parameters:
    g - the graphics context in which to paint
    tabPlacement - the placement (left, right, bottom, top) of the tab
    tabIndex - the index of the tab with respect to other tabs
    x - the x coordinate of tab
    y - the y coordinate of tab
    w - the width of the tab
    h - the height of the tab
    isSelected - a boolean which determines whether or not the tab is selected

    method:paintTabBackground(java.awt.Graphics,int,int,int,int,int,int,boolean) [NONE]

    paintTabBackground

    protected void paintTabBackground (Graphics g, int tabPlacement, int tabIndex, int x, int y, int w, int h, boolean isSelected)
    Paints the tab background.
    Parameters:
    g - the graphics context in which to paint
    tabPlacement - the placement (left, right, bottom, top) of the tab
    tabIndex - the index of the tab with respect to other tabs
    x - the x coordinate of tab
    y - the y coordinate of tab
    w - the width of the tab
    h - the height of the tab
    isSelected - a boolean which determines whether or not the tab is selected

    method:paintContentBorder(java.awt.Graphics,int,int) [NONE]

    paintContentBorder

    protected void paintContentBorder (Graphics g, int tabPlacement, int selectedIndex)
    Paints the content border.
    Parameters:
    g - the graphics context in which to paint
    tabPlacement - the placement (left, right, bottom, top) of the tab
    selectedIndex - the tab index of the selected component

    method:paintContentBorderTopEdge(java.awt.Graphics,int,int,int,int,int,int) [NONE]

    paintContentBorderTopEdge

    protected void paintContentBorderTopEdge (Graphics g, int tabPlacement, int selectedIndex, int x, int y, int w, int h)
    Paints the content border top edge.
    Parameters:
    g - the graphics context in which to paint
    tabPlacement - the placement (left, right, bottom, top) of the tab
    selectedIndex - the tab index of the selected component
    x - the x coordinate of tab
    y - the y coordinate of tab
    w - the width of the tab
    h - the height of the tab

    method:paintContentBorderLeftEdge(java.awt.Graphics,int,int,int,int,int,int) [NONE]

    paintContentBorderLeftEdge

    protected void paintContentBorderLeftEdge (Graphics g, int tabPlacement, int selectedIndex, int x, int y, int w, int h)
    Paints the content border left edge.
    Parameters:
    g - the graphics context in which to paint
    tabPlacement - the placement (left, right, bottom, top) of the tab
    selectedIndex - the tab index of the selected component
    x - the x coordinate of tab
    y - the y coordinate of tab
    w - the width of the tab
    h - the height of the tab

    method:paintContentBorderBottomEdge(java.awt.Graphics,int,int,int,int,int,int) [NONE]

    paintContentBorderBottomEdge

    protected void paintContentBorderBottomEdge (Graphics g, int tabPlacement, int selectedIndex, int x, int y, int w, int h)
    Paints the content border bottom edge.
    Parameters:
    g - the graphics context in which to paint
    tabPlacement - the placement (left, right, bottom, top) of the tab
    selectedIndex - the tab index of the selected component
    x - the x coordinate of tab
    y - the y coordinate of tab
    w - the width of the tab
    h - the height of the tab

    method:paintContentBorderRightEdge(java.awt.Graphics,int,int,int,int,int,int) [NONE]

    paintContentBorderRightEdge

    protected void paintContentBorderRightEdge (Graphics g, int tabPlacement, int selectedIndex, int x, int y, int w, int h)
    Paints the content border right edge.
    Parameters:
    g - the graphics context in which to paint
    tabPlacement - the placement (left, right, bottom, top) of the tab
    selectedIndex - the tab index of the selected component
    x - the x coordinate of tab
    y - the y coordinate of tab
    w - the width of the tab
    h - the height of the tab

    method:getTabBounds(javax.swing.JTabbedPane,int) [NONE]

    getTabBounds

    public Rectangle getTabBounds (JTabbedPane pane, int i)
    Returns the bounds of the specified tab index. The bounds are with respect to the JTabbedPane's coordinate space.
    Specified by:
    getTabBounds in class TabbedPaneUI
    Parameters:
    pane - the pane
    i - the index
    Returns:
    the rectangle for the tab bounds

    method:getTabRunCount(javax.swing.JTabbedPane) [NONE]

    getTabRunCount

    public int getTabRunCount (JTabbedPane pane)
    Description copied from class: TabbedPaneUI
    Returns the tab run count.
    Specified by:
    getTabRunCount in class TabbedPaneUI
    Parameters:
    pane - the pane
    Returns:
    the tab run count

    method:tabForCoordinate(javax.swing.JTabbedPane,int,int) [NONE]

    tabForCoordinate

    public int tabForCoordinate (JTabbedPane pane, int x, int y)
    Returns the tab index which intersects the specified point in the JTabbedPane's coordinate space.
    Specified by:
    tabForCoordinate in class TabbedPaneUI
    Parameters:
    pane - the pane
    x - the x coordinate
    y - the y coordinate
    Returns:
    the tab for the coordinate

    method:getTabBounds(int,java.awt.Rectangle) [NONE]

    getTabBounds

    protected Rectangle getTabBounds (int tabIndex, Rectangle dest)
    Returns the bounds of the specified tab in the coordinate space of the JTabbedPane component. This is required because the tab rects are by default defined in the coordinate space of the component where they are rendered, which could be the JTabbedPane (for WRAP_TAB_LAYOUT) or a ScrollableTabPanel (SCROLL_TAB_LAYOUT). This method should be used whenever the tab rectangle must be relative to the JTabbedPane itself and the result should be placed in a designated Rectangle object (rather than instantiating and returning a new Rectangle each time). The tab index parameter must be a valid tabbed pane tab index (0 to tab count - 1, inclusive). The destination rectangle parameter must be a valid Rectangle instance. The handling of invalid parameters is unspecified.
    Parameters:
    tabIndex - the index of the tab
    dest - the rectangle where the result should be placed
    Returns:
    the resulting rectangle
    Since:
    1.4

    method:getVisibleComponent() [NONE]

    getVisibleComponent

    protected Component getVisibleComponent()
    Returns the visible component.
    Returns:
    the visible component

    method:setVisibleComponent(java.awt.Component) [NONE]

    setVisibleComponent

    protected void setVisibleComponent (Component component)
    Sets the visible component.
    Parameters:
    component - the component

    method:assureRectsCreated(int) [NONE]

    assureRectsCreated

    protected void assureRectsCreated (int tabCount)
    Assures the tab rectangles are created.
    Parameters:
    tabCount - the tab count

    method:expandTabRunsArray() [NONE]

    expandTabRunsArray

    protected void expandTabRunsArray()
    Expands the tab runs array.

    method:getRunForTab(int,int) [NONE]

    getRunForTab

    protected int getRunForTab (int tabCount, int tabIndex)
    Returns the run for a tab.
    Parameters:
    tabCount - the tab count
    tabIndex - the tab index.
    Returns:
    the run for a tab

    method:lastTabInRun(int,int) [NONE]

    lastTabInRun

    protected int lastTabInRun (int tabCount, int run)
    Returns the last tab in a run.
    Parameters:
    tabCount - the tab count
    run - the run
    Returns:
    the last tab in a run

    method:getTabRunOverlay(int) [NONE]

    getTabRunOverlay

    protected int getTabRunOverlay (int tabPlacement)
    Returns the tab run overlay.
    Parameters:
    tabPlacement - the placement (left, right, bottom, top) of the tab
    Returns:
    the tab run overlay

    method:getTabRunIndent(int,int) [NONE]

    getTabRunIndent

    protected int getTabRunIndent (int tabPlacement, int run)
    Returns the tab run indent.
    Parameters:
    tabPlacement - the placement (left, right, bottom, top) of the tab
    run - the tab run
    Returns:
    the tab run indent

    method:shouldPadTabRun(int,int) [NONE]

    shouldPadTabRun

    protected boolean shouldPadTabRun (int tabPlacement, int run)
    Returns whether or not the tab run should be padded.
    Parameters:
    tabPlacement - the placement (left, right, bottom, top) of the tab
    run - the tab run
    Returns:
    whether or not the tab run should be padded

    method:shouldRotateTabRuns(int) [NONE]

    shouldRotateTabRuns

    protected boolean shouldRotateTabRuns (int tabPlacement)
    Returns whether or not the tab run should be rotated.
    Parameters:
    tabPlacement - the placement (left, right, bottom, top) of the tab
    Returns:
    whether or not the tab run should be rotated

    method:getIconForTab(int) [NONE]

    getIconForTab

    protected Icon getIconForTab (int tabIndex)
    Returns the icon for a tab.
    Parameters:
    tabIndex - the index of the tab
    Returns:
    the icon for a tab

    method:getTextViewForTab(int) [NONE]

    getTextViewForTab

    protected View getTextViewForTab (int tabIndex)
    Returns the text View object required to render stylized text (HTML) for the specified tab or null if no specialized text rendering is needed for this tab. This is provided to support html rendering inside tabs.
    Parameters:
    tabIndex - the index of the tab
    Returns:
    the text view to render the tab's text or null if no specialized rendering is required
    Since:
    1.4

    method:calculateTabHeight(int,int,int) [NONE]

    calculateTabHeight

    protected int calculateTabHeight (int tabPlacement, int tabIndex, int fontHeight)
    Calculates the tab height.
    Parameters:
    tabPlacement - the placement (left, right, bottom, top) of the tab
    tabIndex - the index of the tab with respect to other tabs
    fontHeight - the font height
    Returns:
    the tab height

    method:calculateMaxTabHeight(int) [NONE]

    calculateMaxTabHeight

    protected int calculateMaxTabHeight (int tabPlacement)
    Calculates the maximum tab height.
    Parameters:
    tabPlacement - the placement (left, right, bottom, top) of the tab
    Returns:
    the maximum tab height

    method:calculateTabWidth(int,int,java.awt.FontMetrics) [NONE]

    calculateTabWidth

    protected int calculateTabWidth (int tabPlacement, int tabIndex, FontMetrics metrics)
    Calculates the tab width.
    Parameters:
    tabPlacement - the placement (left, right, bottom, top) of the tab
    tabIndex - the index of the tab with respect to other tabs
    metrics - the font metrics
    Returns:
    the tab width

    method:calculateMaxTabWidth(int) [NONE]

    calculateMaxTabWidth

    protected int calculateMaxTabWidth (int tabPlacement)
    Calculates the maximum tab width.
    Parameters:
    tabPlacement - the placement (left, right, bottom, top) of the tab
    Returns:
    the maximum tab width

    method:calculateTabAreaHeight(int,int,int) [NONE]

    calculateTabAreaHeight

    protected int calculateTabAreaHeight (int tabPlacement, int horizRunCount, int maxTabHeight)
    Calculates the tab area height.
    Parameters:
    tabPlacement - the placement (left, right, bottom, top) of the tab
    horizRunCount - horizontal run count
    maxTabHeight - maximum tab height
    Returns:
    the tab area height

    method:calculateTabAreaWidth(int,int,int) [NONE]

    calculateTabAreaWidth

    protected int calculateTabAreaWidth (int tabPlacement, int vertRunCount, int maxTabWidth)
    Calculates the tab area width.
    Parameters:
    tabPlacement - the placement (left, right, bottom, top) of the tab
    vertRunCount - vertical run count
    maxTabWidth - maximum tab width
    Returns:
    the tab area width

    method:getTabInsets(int,int) [NONE]

    getTabInsets

    protected Insets getTabInsets (int tabPlacement, int tabIndex)
    Returns the tab insets.
    Parameters:
    tabPlacement - the placement (left, right, bottom, top) of the tab
    tabIndex - the tab index
    Returns:
    the tab insets

    method:getSelectedTabPadInsets(int) [NONE]

    getSelectedTabPadInsets

    protected Insets getSelectedTabPadInsets (int tabPlacement)
    Returns the selected tab pad insets.
    Parameters:
    tabPlacement - the placement (left, right, bottom, top) of the tab
    Returns:
    the selected tab pad insets

    method:getTabAreaInsets(int) [NONE]

    getTabAreaInsets

    protected Insets getTabAreaInsets (int tabPlacement)
    Returns the tab area insets.
    Parameters:
    tabPlacement - the placement (left, right, bottom, top) of the tab
    Returns:
    the pad area insets

    method:getContentBorderInsets(int) [NONE]

    getContentBorderInsets

    protected Insets getContentBorderInsets (int tabPlacement)
    Returns the content border insets.
    Parameters:
    tabPlacement - the placement (left, right, bottom, top) of the tab
    Returns:
    the content border insets

    method:getFontMetrics() [NONE]

    getFontMetrics

    protected FontMetrics getFontMetrics()
    Returns the font metrics.
    Returns:
    the font metrics

    method:navigateSelectedTab(int) [NONE]

    method:selectNextTabInRun(int) [NONE]

    selectNextTabInRun

    protected void selectNextTabInRun (int current)
    Selects the next tab in the run.
    Parameters:
    current - the current tab

    method:selectPreviousTabInRun(int) [NONE]

    selectPreviousTabInRun

    protected void selectPreviousTabInRun (int current)
    Selects the previous tab in the run.
    Parameters:
    current - the current tab

    method:selectNextTab(int) [NONE]

    selectNextTab

    protected void selectNextTab (int current)
    Selects the next tab.
    Parameters:
    current - the current tab

    method:selectPreviousTab(int) [NONE]

    selectPreviousTab

    protected void selectPreviousTab (int current)
    Selects the previous tab.
    Parameters:
    current - the current tab

    method:selectAdjacentRunTab(int,int,int) [NONE]

    selectAdjacentRunTab

    protected void selectAdjacentRunTab (int tabPlacement, int tabIndex, int offset)
    Selects an adjacent run of tabs.
    Parameters:
    tabPlacement - the placement (left, right, bottom, top) of the tab
    tabIndex - the index of the tab with respect to other tabs
    offset - selection offset

    method:getFocusIndex() [NONE]

    getFocusIndex

    protected int getFocusIndex()
    Returns the index of the tab that has focus.
    Returns:
    index of tab that has focus
    Since:
    1.5

    method:getTabRunOffset(int,int,int,boolean) [NONE]

    getTabRunOffset

    protected int getTabRunOffset (int tabPlacement, int tabCount, int tabIndex, boolean forward)
    Returns the tab run offset.
    Parameters:
    tabPlacement - the placement (left, right, bottom, top) of the tab
    tabCount - the tab count
    tabIndex - the index of the tab with respect to other tabs
    forward - forward or not
    Returns:
    the tab run offset

    method:getPreviousTabIndex(int) [NONE]

    getPreviousTabIndex

    protected int getPreviousTabIndex (int base)
    Returns the previous tab index.
    Parameters:
    base - the base
    Returns:
    the previous tab index

    method:getNextTabIndex(int) [NONE]

    getNextTabIndex

    protected int getNextTabIndex (int base)
    Returns the next tab index.
    Parameters:
    base - the base
    Returns:
    the next tab index

    method:getNextTabIndexInRun(int,int) [NONE]

    getNextTabIndexInRun

    protected int getNextTabIndexInRun (int tabCount, int base)
    Returns the next tab index in the run.
    Parameters:
    tabCount - the tab count
    base - the base
    Returns:
    the next tab index in the run

    method:getPreviousTabIndexInRun(int,int) [NONE]

    getPreviousTabIndexInRun

    protected int getPreviousTabIndexInRun (int tabCount, int base)
    Returns the previous tab index in the run.
    Parameters:
    tabCount - the tab count
    base - the base
    Returns:
    the previous tab index in the run

    method:getPreviousTabRun(int) [NONE]

    getPreviousTabRun

    protected int getPreviousTabRun (int baseRun)
    Returns the previous tab run.
    Parameters:
    baseRun - the base run
    Returns:
    the previous tab run

    method:getNextTabRun(int) [NONE]

    getNextTabRun

    protected int getNextTabRun (int baseRun)
    Returns the next tab run.
    Parameters:
    baseRun - the base run
    Returns:
    the next tab run

    method:rotateInsets(java.awt.Insets,java.awt.Insets,int) [NONE]

    rotateInsets

    protected static  void rotateInsets (Insets topInsets, Insets targetInsets, int targetPlacement)
    Rotates the insets.
    Parameters:
    topInsets - the top insets
    targetInsets - the target insets
    targetPlacement - the target placement

    © 2023 Oracle Corporation and/or its affiliates