SwingConstantspublic class MetalTabbedPaneUI extends BasicTabbedPaneUI
 Warning: Serialized objects of this class will not be compatible with future Swing releases. The current serialization support is appropriate for short term storage or RMI between applications running the same version of Swing. As of 1.4, support for long term storage of all JavaBeans has been added to the java.beans package. Please see XMLEncoder.
| Modifier and Type | Class | Description | 
|---|---|---|
| class  | MetalTabbedPaneUI.TabbedPaneLayout | This class should be treated as a "protected" inner class. | 
BasicTabbedPaneUI.FocusHandler, BasicTabbedPaneUI.MouseHandler, BasicTabbedPaneUI.PropertyChangeHandler, BasicTabbedPaneUI.TabSelectionHandler
| Modifier and Type | Field | Description | 
|---|---|---|
| protected int | minTabWidth | The minimum width of a pane. | 
| protected Color | selectColor | The color of the selected pane. | 
| protected Color | selectHighlight | The color of the highlight. | 
| protected Color | tabAreaBackground | The color of tab's background. | 
calcRect, contentBorderInsets, darkShadow, downKey, focus, focusListener, highlight, leftKey, lightHighlight, maxTabHeight, maxTabWidth, mouseListener, propertyChangeListener, rects, rightKey, runCount, selectedRun, selectedTabPadInsets, shadow, tabAreaInsets, tabChangeListener, tabInsets, tabPane, tabRunOverlay, tabRuns, textIconGap, upKey
BOTTOM, CENTER, EAST, HORIZONTAL, LEADING, LEFT, NEXT, NORTH, NORTH_EAST, NORTH_WEST, PREVIOUS, RIGHT, SOUTH, SOUTH_EAST, SOUTH_WEST, TOP, TRAILING, VERTICAL, WEST
| Constructor | Description | 
|---|---|
| MetalTabbedPaneUI() | Constructs a  MetalTabbedPaneUI. | 
| Modifier and Type | Method | Description | 
|---|---|---|
| static ComponentUI | createUI | Constructs  MetalTabbedPaneUI. | 
| protected int | getBaselineOffset() | Returns the amount the baseline is offset by. | 
| protected Color | getColorForGap | Returns the color of the gap. | 
| protected int | getTabLabelShiftX | Overridden to do nothing for the Java L&F. | 
| protected int | getTabLabelShiftY | Overridden to do nothing for the Java L&F. | 
| protected void | paintBottomTabBorder | Paints the bottom tab border. | 
| protected void | paintHighlightBelowTab() | Paints highlights below tab. | 
| protected void | paintLeftTabBorder | Paints the left tab border. | 
| protected void | paintRightTabBorder | Paints the right tab border. | 
| protected void | paintTopTabBorder | Paints the top tab border. | 
| protected boolean | shouldFillGap | Returns  trueif the gap should be filled. | 
| protected boolean | shouldRotateTabRuns | Returns  trueif tab runs should be rotated. | 
assureRectsCreated, calculateMaxTabHeight, calculateMaxTabWidth, calculateTabAreaHeight, calculateTabAreaWidth, calculateTabHeight, calculateTabWidth, createChangeListener, createFocusListener, createLayoutManager, createMouseListener, createPropertyChangeListener, createScrollButton, expandTabRunsArray, getBaseline, getBaseline, getBaselineResizeBehavior, getContentBorderInsets, getFocusIndex, getFontMetrics, getIconForTab, getNextTabIndex, getNextTabIndexInRun, getNextTabRun, getPreviousTabIndex, getPreviousTabIndexInRun, getPreviousTabRun, getRolloverTab, getRunForTab, getSelectedTabPadInsets, getTabAreaInsets, getTabBounds, getTabBounds, getTabInsets, getTabRunCount, getTabRunIndent, getTabRunOffset, getTabRunOverlay, getTextViewForTab, getVisibleComponent, installComponents, installDefaults, installKeyboardActions, installListeners, lastTabInRun, layoutLabel, navigateSelectedTab, paintContentBorder, paintContentBorderBottomEdge, paintContentBorderLeftEdge, paintContentBorderRightEdge, paintContentBorderTopEdge, paintFocusIndicator, paintIcon, paintTab, paintTabArea, paintTabBackground, paintTabBorder, paintText, rotateInsets, selectAdjacentRunTab, selectNextTab, selectNextTabInRun, selectPreviousTab, selectPreviousTabInRun, setRolloverTab, setVisibleComponent, shouldPadTabRun, shouldRotateTabRuns, tabForCoordinate, uninstallComponents, uninstallDefaults, uninstallKeyboardActions, uninstallListeners
contains, getAccessibleChild, getAccessibleChildrenCount, getMaximumSize, getMinimumSize, getPreferredSize, installUI, paint, uninstallUI, update
protected int minTabWidth
protected Color tabAreaBackground
protected Color selectColor
protected Color selectHighlight
public MetalTabbedPaneUI()
MetalTabbedPaneUI.public static ComponentUI createUI(JComponent x)
MetalTabbedPaneUI.x - a componentMetalTabbedPaneUI
protected void paintTopTabBorder(int tabIndex, Graphics g, int x, int y, int w, int h, int btm, int rght, boolean isSelected)
tabIndex - a tab indexg - an instance of Graphics
x - an X coordinatey - an Y coordinatew - a widthh - a heightbtm - bottomrght - rightisSelected - a selectionprotected boolean shouldFillGap(int currentRun, int tabIndex, int x, int y)
true if the gap should be filled.currentRun - the current runtabIndex - the tab indexx - an X coordinatey - an Y coordinatetrue if the gap should be filledprotected Color getColorForGap(int currentRun, int x, int y)
currentRun - the current runx - an X coordinatey - an Y coordinateprotected void paintLeftTabBorder(int tabIndex, Graphics g, int x, int y, int w, int h, int btm, int rght, boolean isSelected)
tabIndex - a tab indexg - an instance of Graphics
x - an X coordinatey - an Y coordinatew - a widthh - a heightbtm - bottomrght - rightisSelected - a selectionprotected void paintBottomTabBorder(int tabIndex, Graphics g, int x, int y, int w, int h, int btm, int rght, boolean isSelected)
tabIndex - a tab indexg - an instance of Graphics
x - an X coordinatey - an Y coordinatew - a widthh - a heightbtm - bottomrght - rightisSelected - a selectionprotected void paintRightTabBorder(int tabIndex, Graphics g, int x, int y, int w, int h, int btm, int rght, boolean isSelected)
tabIndex - a tab indexg - an instance of Graphics
x - an X coordinatey - an Y coordinatew - a widthh - a heightbtm - bottomrght - rightisSelected - a selectionprotected int getTabLabelShiftX(int tabPlacement, int tabIndex, boolean isSelected)
getTabLabelShiftX in class BasicTabbedPaneUI
tabPlacement - the tab placementtabIndex - the tab indexisSelected - selection statusprotected int getTabLabelShiftY(int tabPlacement, int tabIndex, boolean isSelected)
getTabLabelShiftY in class BasicTabbedPaneUI
tabPlacement - the tab placementtabIndex - the tab indexisSelected - selection statusprotected int getBaselineOffset()
getTabLabelShiftY.getBaselineOffset in class BasicTabbedPaneUI
protected void paintHighlightBelowTab()
protected boolean shouldRotateTabRuns(int tabPlacement, int selectedRun)
true if tab runs should be rotated.tabPlacement - a tab placementselectedRun - a selected runtrue if tab runs should be rotated.
    © 1993, 2023, Oracle and/or its affiliates. All rights reserved.
Documentation extracted from Debian's OpenJDK Development Kit package.
Licensed under the GNU General Public License, version 2, with the Classpath Exception.
Various third party code in OpenJDK is licensed under different licenses (see Debian package).
Java and OpenJDK are trademarks or registered trademarks of Oracle and/or its affiliates.
    https://docs.oracle.com/en/java/javase/21/docs/api/java.desktop/javax/swing/plaf/metal/MetalTabbedPaneUI.html