javax.swing.plaf.metal
Class MetalSliderUI
java.lang.Object
|
+--javax.swing.plaf.ComponentUI
|
+--javax.swing.plaf.SliderUI
|
+--javax.swing.plaf.basic.BasicSliderUI
|
+--javax.swing.plaf.metal.MetalSliderUI
public class MetalSliderUI extends BasicSliderUI
A Java L&F implementation of SliderUI.
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. A future release of Swing will provide support for
long term persistence.
Fields inherited from class javax.swing.plaf.basic.BasicSliderUI
changeListener ,
componentListener ,
contentRect ,
focusInsets ,
focusListener ,
focusRect ,
insetCache ,
labelRect ,
MAX_SCROLL ,
MIN_SCROLL ,
NEGATIVE_SCROLL ,
POSITIVE_SCROLL ,
propertyChangeListener ,
scrollListener ,
scrollTimer ,
slider ,
thumbRect ,
tickRect ,
trackBuffer ,
trackListener ,
trackRect
Methods inherited from class javax.swing.plaf.basic.BasicSliderUI
calculateContentRect ,
calculateFocusRect ,
calculateGeometry ,
calculateLabelRect ,
calculateThumbLocation ,
calculateThumbSize ,
calculateTickRect ,
calculateTrackBuffer ,
calculateTrackRect ,
createChangeListener ,
createComponentListener ,
createFocusListener ,
createScrollListener ,
createTrackListener ,
getFocusColor ,
getHeightOfHighValueLabel ,
getHeightOfLowValueLabel ,
getHeightOfTallestLabel ,
getHighestValueLabel ,
getHighlightColor ,
getLowestValueLabel ,
getMaximumSize ,
getMinimumHorizontalSize ,
getMinimumSize ,
getMinimumVerticalSize ,
getPreferredHorizontalSize ,
getPreferredSize ,
getPreferredVerticalSize ,
getShadowColor ,
getWidthOfHighValueLabel ,
getWidthOfLowValueLabel ,
getWidthOfWidestLabel ,
installDefaults ,
installKeyboardActions ,
installListeners ,
paint ,
paintHorizontalLabel ,
paintLabels ,
paintTicks ,
paintVerticalLabel ,
recalculateIfInsetsChanged ,
scrollByBlock ,
scrollByUnit ,
setThumbLocation ,
uninstallKeyboardActions ,
uninstallListeners ,
uninstallUI ,
valueForXPosition ,
valueForYPosition ,
xPositionForValue ,
yPositionForValue
Methods inherited from class java.lang.Object
clone ,
equals ,
finalize ,
getClass ,
hashCode ,
notify ,
notifyAll ,
toString ,
wait ,
wait ,
wait
TICK_BUFFER
protected final int TICK_BUFFER
filledSlider
protected boolean filledSlider
thumbColor
protected static Color thumbColor
highlightColor
protected static Color highlightColor
darkShadowColor
protected static Color darkShadowColor
trackWidth
protected static int trackWidth
tickLength
protected static int tickLength
horizThumbIcon
protected static Icon horizThumbIcon
vertThumbIcon
protected static Icon vertThumbIcon
SLIDER_FILL
protected final String SLIDER_FILL
MetalSliderUI
public MetalSliderUI ()
createUI
public static ComponentUI createUI (JComponent c)
installUI
public void installUI (JComponent c)
Overrides: installUI in class BasicSliderUI
createPropertyChangeListener
protected PropertyChangeListener createPropertyChangeListener (JSlider slider)
Overrides: createPropertyChangeListener in class BasicSliderUI
paintThumb
public void paintThumb (Graphics g)
Overrides: paintThumb in class BasicSliderUI
paintTrack
public void paintTrack (Graphics g)
Overrides: paintTrack in class BasicSliderUI
paintFocus
public void paintFocus (Graphics g)
Overrides: paintFocus in class BasicSliderUI
getThumbSize
protected Dimension getThumbSize ()
Overrides: getThumbSize in class BasicSliderUI
getTickLength
public int getTickLength ()
Gets the height of the tick area for horizontal sliders and the width of the
tick area for vertical sliders. BasicSliderUI uses the returned value to
determine the tick area rectangle.
Overrides: getTickLength in class BasicSliderUI
getTrackWidth
protected int getTrackWidth ()
Returns the shorter dimension of the track.
getTrackLength
protected int getTrackLength ()
Returns the longer dimension of the slide bar. (The slide bar is only the
part that runs directly under the thumb)
getThumbOverhang
protected int getThumbOverhang ()
Returns the amount that the thumb goes past the slide bar.
scrollDueToClickInTrack
protected void scrollDueToClickInTrack (int dir)
Description copied from class: BasicSliderUI
This function is called when a mousePressed was detected in the track, not
in the thumb. The default behavior is to scroll by block. You can
override this method to stop it from scrolling or to add additional behavior.
Overrides: scrollDueToClickInTrack in class BasicSliderUI
paintMinorTickForHorizSlider
protected void paintMinorTickForHorizSlider (Graphics g,
Rectangle tickBounds,
int x)
Overrides: paintMinorTickForHorizSlider in class BasicSliderUI
paintMajorTickForHorizSlider
protected void paintMajorTickForHorizSlider (Graphics g,
Rectangle tickBounds,
int x)
Overrides: paintMajorTickForHorizSlider in class BasicSliderUI
paintMinorTickForVertSlider
protected void paintMinorTickForVertSlider (Graphics g,
Rectangle tickBounds,
int y)
Overrides: paintMinorTickForVertSlider in class BasicSliderUI
paintMajorTickForVertSlider
protected void paintMajorTickForVertSlider (Graphics g,
Rectangle tickBounds,
int y)
Overrides: paintMajorTickForVertSlider in class BasicSliderUI
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.