public class BambiSliderUI extends BasicSliderUI
JSlider
UI that conveys Bambi look. It paints custom track,
thumb and adds icons at both ends of the track. The icons and color track
are defined via SliderDecor
.BasicSliderUI.ActionScroller, BasicSliderUI.ChangeHandler, BasicSliderUI.ComponentHandler, BasicSliderUI.FocusHandler, BasicSliderUI.PropertyChangeHandler, BasicSliderUI.ScrollListener, BasicSliderUI.TrackListener
Modifier and Type | Field and Description |
---|---|
protected Image |
largeIcon |
protected JSlider |
slider |
protected Image |
smallIcon |
changeListener, componentListener, contentRect, focusInsets, focusListener, focusRect, insetCache, labelRect, leftToRightCache, MAX_SCROLL, MIN_SCROLL, NEGATIVE_SCROLL, POSITIVE_SCROLL, propertyChangeListener, scrollListener, scrollTimer, thumbRect, tickRect, trackBuffer, trackListener, trackRect
Constructor and Description |
---|
BambiSliderUI(JSlider slider,
SliderDecor decor) |
Modifier and Type | Method and Description |
---|---|
protected Dimension |
getThumbSize() |
void |
paintFocus(Graphics g) |
void |
paintThumb(Graphics g) |
void |
paintTrack(Graphics g) |
calculateContentRect, calculateFocusRect, calculateGeometry, calculateLabelRect, calculateThumbLocation, calculateThumbSize, calculateTickRect, calculateTrackBuffer, calculateTrackRect, createChangeListener, createComponentListener, createFocusListener, createPropertyChangeListener, createScrollListener, createTrackListener, createUI, drawInverted, getBaseline, getBaselineResizeBehavior, getFocusColor, getHeightOfHighValueLabel, getHeightOfLowValueLabel, getHeightOfTallestLabel, getHighestValue, getHighestValueLabel, getHighlightColor, getLowestValue, getLowestValueLabel, getMaximumSize, getMinimumHorizontalSize, getMinimumSize, getMinimumVerticalSize, getPreferredHorizontalSize, getPreferredSize, getPreferredVerticalSize, getShadowColor, getTickLength, getWidthOfHighValueLabel, getWidthOfLowValueLabel, getWidthOfWidestLabel, installDefaults, installKeyboardActions, installListeners, installUI, isDragging, labelsHaveSameBaselines, paint, paintHorizontalLabel, paintLabels, paintMajorTickForHorizSlider, paintMajorTickForVertSlider, paintMinorTickForHorizSlider, paintMinorTickForVertSlider, paintTicks, paintVerticalLabel, recalculateIfInsetsChanged, recalculateIfOrientationChanged, scrollByBlock, scrollByUnit, scrollDueToClickInTrack, setThumbLocation, uninstallDefaults, uninstallKeyboardActions, uninstallListeners, uninstallUI, valueForXPosition, valueForYPosition, xPositionForValue, yPositionForValue, yPositionForValue
contains, getAccessibleChild, getAccessibleChildrenCount, update
protected JSlider slider
protected Image smallIcon
protected Image largeIcon
public BambiSliderUI(JSlider slider, SliderDecor decor)
slider
- - slider for which this UI strategy should be applieddecor
- - grapical artifacts to decorate slider withIllegalArgumentException
- if either argument is nullpublic void paintTrack(Graphics g)
paintTrack
in class BasicSliderUI
public void paintThumb(Graphics g)
paintThumb
in class BasicSliderUI
protected Dimension getThumbSize()
getThumbSize
in class BasicSliderUI
public void paintFocus(Graphics g)
paintFocus
in class BasicSliderUI
Copyright © 2012-2013 Bambi Software Foundation. All Rights Reserved.