public class MetalScrollBarUI extends BasicScrollBarUI
BasicScrollBarUI.ArrowButtonListener , BasicScrollBarUI.ModelListener , BasicScrollBarUI.PropertyChangeHandler , BasicScrollBarUI.ScrollListener , BasicScrollBarUI.TrackListener | Modifier and Type | Field and Description |
|---|---|
protected javax |
bumps
|
protected MetalScrollButton |
decreaseButton
|
static String |
FREE_STANDING_PROP
|
protected MetalScrollButton |
increaseButton
|
protected boolean |
isFreeStanding
|
protected int |
scrollBarWidth
|
buttonListener, decrButton, DECREASE_HIGHLIGHT, decrGap, incrButton, INCREASE_HIGHLIGHT, incrGap, isDragging, maximumThumbSize, minimumThumbSize, modelListener, NO_HIGHLIGHT, propertyChangeListener, scrollbar, scrollListener, scrollTimer, thumbDarkShadowColor, thumbLightShadowColor, thumbRect, trackColor, trackHighlight, trackHighlightColor, trackListener, trackRectBOTTOM, CENTER, EAST, HORIZONTAL, LEADING, LEFT, NEXT, NORTH, NORTH_EAST, NORTH_WEST, PREVIOUS, RIGHT, SOUTH, SOUTH_EAST, SOUTH_WEST, TOP, TRAILING, VERTICAL, WEST| Constructor and Description |
|---|
MetalScrollBarUI()
|
| Modifier and Type | Method and Description |
|---|---|
protected void |
configureScrollBarColors()
|
protected JButton |
createDecreaseButton(int orientation)
Returns the view that represents the decrease view.
|
protected JButton |
createIncreaseButton(int orientation)
Returns the view that represents the increase view.
|
protected PropertyChangeListener |
createPropertyChangeListener()
|
static ComponentUI |
createUI(JComponent
|
protected Dimension |
getMinimumThumbSize()
Returns the smallest acceptable size for the thumb.
|
Dimension |
getPreferredSize(JComponent
A vertical scrollbar's preferred width is the maximum of preferred widths of the (non
null) increment/decrement buttons, and the minimum width of the thumb.
|
protected void |
installDefaults()
|
protected void |
installListeners()
|
protected void |
paintThumb(Graphics
|
protected void |
paintTrack(Graphics
|
protected void |
setThumbBounds(int x, int y, int width, int height)
This is overridden only to increase the invalid area.
|
addLayoutComponent, createArrowButtonListener, createModelListener, createScrollListener, createTrackListener, getMaximumSize, getMaximumThumbSize, getSupportsAbsolutePositioning, getThumbBounds, getTrackBounds, installComponents, installKeyboardActions, installUI, isThumbRollover, layoutContainer, layoutHScrollbar, layoutVScrollbar, minimumLayoutSize, paint, paintDecreaseHighlight, paintIncreaseHighlight, preferredLayoutSize, removeLayoutComponent, scrollByBlock, scrollByUnit, setThumbRollover, uninstallComponents, uninstallDefaults, uninstallKeyboardActions, uninstallListeners, uninstallUIcontains, getAccessibleChild, getAccessibleChildrenCount, getBaseline, getBaselineResizeBehavior, getMinimumSize, updateprotected javax.swing .plaf .metal .MetalBumps bumps
protected MetalScrollButtonincreaseButton
protected MetalScrollButtondecreaseButton
protected int scrollBarWidth
public static final StringFREE_STANDING_PROP
protected boolean isFreeStanding
public static ComponentUIcreateUI(JComponent c)
protected void installDefaults()
protected void installListeners()
protected PropertyChangeListenercreatePropertyChangeListener()
protected void configureScrollBarColors()
public DimensiongetPreferredSize(JComponent c)
BasicScrollBarUI
null) increment/decrement buttons, and the minimum width of the thumb. The preferred height is the sum of the preferred heights of the same parts. The basis for the preferred size of a horizontal scrollbar is similar.
The preferredSize is only computed once, subsequent calls to this method just return a cached size.
getPreferredSize in class
BasicScrollBarUI
c - the
JScrollBar that's delegating this method to us
BasicScrollBarUI.getMaximumSize(javax.swing.JComponent) ,
ComponentUI.getMinimumSize(javax.swing.JComponent)
protected JButtoncreateDecreaseButton(int orientation)
protected JButtoncreateIncreaseButton(int orientation)
protected void paintTrack(Graphicsg, JComponent c, Rectangle trackBounds)
protected void paintThumb(Graphicsg, JComponent c, Rectangle thumbBounds)
protected DimensiongetMinimumThumbSize()
BasicScrollBarUI
Warning : the value returned by this method should not be be modified, it's a shared static constant.
getMinimumThumbSize in class
BasicScrollBarUI
BasicScrollBarUI.getMaximumThumbSize()
protected void setThumbBounds(int x,
int y,
int width,
int height)
setThumbBounds in class
BasicScrollBarUI
BasicScrollBarUI.getThumbBounds()