Package Summary  Overview Summary

class:BasicSliderUI [NONE]

field:POSITIVE_SCROLL [CHANGED]

field:NEGATIVE_SCROLL [CHANGED]

field:MIN_SCROLL [CHANGED]

field:MAX_SCROLL [CHANGED]

field:scrollTimer [CHANGED]

  • scrollTimer

    protected Timer scrollTimer
    Scroll timer
  • scrollTimer

    protected Timer scrollTimer
  • scrollTimer

    protected Timer scrollTimer
    Scroll timer

field:slider [CHANGED]

  • slider

    protected JSlider slider
    Slider
  • slider

    protected JSlider slider
    Slider

field:focusInsets [CHANGED]

  • focusInsets

    protected Insets focusInsets
    Focus insets
  • focusInsets

    protected Insets focusInsets
  • focusInsets

    protected Insets focusInsets
    Focus insets

field:insetCache [CHANGED]

  • insetCache

    protected Insets insetCache
    Inset cache
  • insetCache

    protected Insets insetCache
  • insetCache

    protected Insets insetCache
    Inset cache

field:leftToRightCache [CHANGED]

  • leftToRightCache

    protected boolean leftToRightCache
    Left-to-right cache
  • leftToRightCache

    protected boolean leftToRightCache
  • leftToRightCache

    protected boolean leftToRightCache
    Left-to-right cache

field:focusRect [CHANGED]

  • focusRect

    protected Rectangle focusRect
    Focus rectangle
  • focusRect

    protected Rectangle focusRect
    Focus rectangle

field:contentRect [CHANGED]

  • contentRect

    protected Rectangle contentRect
    Content rectangle
  • contentRect

    protected Rectangle contentRect
  • contentRect

    protected Rectangle contentRect
    Content rectangle

field:labelRect [CHANGED]

  • labelRect

    protected Rectangle labelRect
    Label rectangle
  • labelRect

    protected Rectangle labelRect
    Label rectangle

field:tickRect [CHANGED]

  • tickRect

    protected Rectangle tickRect
    Tick rectangle
  • tickRect

    protected Rectangle tickRect
    Tick rectangle

field:trackRect [CHANGED]

  • trackRect

    protected Rectangle trackRect
    Track rectangle
  • trackRect

    protected Rectangle trackRect
    Track rectangle

field:thumbRect [CHANGED]

  • thumbRect

    protected Rectangle thumbRect
    Thumb rectangle
  • thumbRect

    protected Rectangle thumbRect
    Thumb rectangle

field:trackBuffer [CHANGED]

  • trackBuffer

    protected int trackBuffer
    The distance that the track is from the side of the control
  • trackBuffer

    protected int trackBuffer
  • trackBuffer

    protected int trackBuffer
    The distance that the track is from the side of the control

field:trackListener [CHANGED]

field:changeListener [CHANGED]

  • changeListener

    protected ChangeListener changeListener
    Change listener
  • changeListener

    protected ChangeListener changeListener
    Change listener

field:componentListener [CHANGED]

  • componentListener

    protected ComponentListener componentListener
    Component listener
  • componentListener

    protected ComponentListener componentListener
    Component listener

field:focusListener [CHANGED]

  • focusListener

    protected FocusListener focusListener
    Focus listener
  • focusListener

    protected FocusListener focusListener
    Focus listener

field:scrollListener [CHANGED]

field:propertyChangeListener [CHANGED]

constructor:BasicSliderUI(javax.swing.JSlider) [CHANGED]

  • BasicSliderUI

    public BasicSliderUIpublic BasicSliderUI​(JSlider b)
    Constructs a BasicSliderUI.
    Parameters:
    b - a slider
  • BasicSliderUI

    public BasicSliderUI(JSlider b)
  • BasicSliderUI

    public BasicSliderUI​(JSlider b)
    Constructs a BasicSliderUI.
    Parameters:
    b - a slider

method:getShadowColor() [CHANGED]

  • getShadowColor

    protected Color getShadowColor getShadowColor​()
    Returns the shadow color.
    Returns:
    the shadow color
  • getShadowColor

    protected Color getShadowColor()
  • getShadowColor

    protected Color getShadowColor​()
    Returns the shadow color.
    Returns:
    the shadow color

method:getHighlightColor() [CHANGED]

  • getHighlightColor

    protected Color getHighlightColor getHighlightColor​()
    Returns the highlight color.
    Returns:
    the highlight color
  • getHighlightColor

    protected Color getHighlightColor()
  • getHighlightColor

    protected Color getHighlightColor​()
    Returns the highlight color.
    Returns:
    the highlight color

method:getFocusColor() [CHANGED]

  • getFocusColor

    protected Color getFocusColor getFocusColor​()
    Returns the focus color.
    Returns:
    the focus color
  • getFocusColor

    protected Color getFocusColor()
  • getFocusColor

    protected Color getFocusColor​()
    Returns the focus color.
    Returns:
    the focus color

method:isDragging() [CHANGED]

  • isDragging

    protected boolean isDraggingprotected boolean isDragging​()
    Returns true if the user is dragging the slider.
    Returns:
    true if the user is dragging the slider
    Since:
    1.5
  • isDragging

    protected boolean isDragging()
    Returns true if the user is dragging the slider.
    Returns:
    true if the user is dragging the slider
    Since:
    1.5
  • isDragging

    protected boolean isDragging​()
    Returns true if the user is dragging the slider.
    Returns:
    true if the user is dragging the slider
    Since:
    1.5

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

  • createUI

    public static ComponentUI createUI createUI​(JComponent b)
    Creates a UI.
    Parameters:
    b - a component
    Returns:
    a UI
  • createUI

    public static ComponentUI createUI​(JComponent b)
    Creates a UI.
    Parameters:
    b - a component
    Returns:
    a UI

method:installUI(javax.swing.JComponent) [CHANGED]

  • installUI

    public void installUIpublic void installUI​(JComponent c)
    Descriptioncopiedfromclass: 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:
  • 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.
  • InstallInstalls a LayoutManager on the component if necessary.
  • Create/add any required sub-components to the component.
  • Create/install event listeners on the component.
  • Create/install a PropertyChangeListener on the component in order to detect and respond to component property changes appropriately.
  • Install keyboardUI (mnemonics, traversal, etc.) on the component.Initialize any appropriate instance data.
    Overrides:
    installUI in class ComponentUI
    Parameters:
    c - thea component where this UI delegate is being installed
    See Also:
    ComponentUI.uninstallUI(javax.swing.JComponent), JComponent.setUI(javax.swing.plaf.ComponentUI), JComponent.updateUI()
  • 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:
    ComponentUI.uninstallUI(javax.swing.JComponent), JComponent.setUI(javax.swing.plaf.ComponentUI), JComponent.updateUI()

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

  • uninstallUI

    public void uninstallUIpublic void uninstallUI​(JComponent c)
    Descriptioncopiedfromclass: 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 inUninstalls a clean state (no extraneous listeners, look-and-feel-specific property objects, etc.). This should include the following:Remove anyUI-set borders from the component.
  • Remove any UI-set layout managers on the component.
  • Remove any UI-added sub-components from the component.
  • Remove any UI-added event/property listeners from the component.
  • Remove any UI-installed keyboard UI from the component.
  • Nullify any allocated instance data objects to allow for GC.
    Overrides:
    uninstallUI in class ComponentUI
    Parameters:
    c - thea 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:
    ComponentUI.installUI(javax.swing.JComponent), JComponent.updateUI()
  • 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:
    ComponentUI.installUI(javax.swing.JComponent), JComponent.updateUI()

method:installDefaults(javax.swing.JSlider) [CHANGED]

  • installDefaults

    protected void installDefaultsprotected void installDefaults​(JSlider slider)
    Installs the defaults.
    Parameters:
    slider - a slider
  • installDefaults

    protected void installDefaults(JSlider slider)
  • installDefaults

    protected void installDefaults​(JSlider slider)
    Installs the defaults.
    Parameters:
    slider - a slider

method:uninstallDefaults(javax.swing.JSlider) [CHANGED]

  • uninstallDefaults

    protected void uninstallDefaultsprotected void uninstallDefaults​(JSlider slider)
    Uninstalls the defaults.
    Parameters:
    slider - a slider
  • uninstallDefaults

    protected void uninstallDefaults(JSlider slider)
  • uninstallDefaults

    protected void uninstallDefaults​(JSlider slider)
    Uninstalls the defaults.
    Parameters:
    slider - a slider

method:createTrackListener(javax.swing.JSlider) [CHANGED]

  • createTrackListener

    protected BasicSliderUI.TrackListener createTrackListener createTrackListener​(JSlider slider)
    Creates a track listener.
    Parameters:
    slider - a slider
    Returns:
    a track listener
  • createTrackListener

    protected BasicSliderUI.TrackListener createTrackListener​(JSlider slider)
    Creates a track listener.
    Parameters:
    slider - a slider
    Returns:
    a track listener

method:createChangeListener(javax.swing.JSlider) [CHANGED]

  • createChangeListener

    protected ChangeListener createChangeListener createChangeListener​(JSlider slider)
    Creates a change listener.
    Parameters:
    slider - a slider
    Returns:
    a change listener
  • createChangeListener

    protected ChangeListener createChangeListener​(JSlider slider)
    Creates a change listener.
    Parameters:
    slider - a slider
    Returns:
    a change listener

method:createComponentListener(javax.swing.JSlider) [CHANGED]

  • createComponentListener

    protected ComponentListener createComponentListener createComponentListener​(JSlider slider)
    Creates a composite listener.
    Parameters:
    slider - a slider
    Returns:
    a composite listener
  • createComponentListener

    protected ComponentListener createComponentListener​(JSlider slider)
    Creates a composite listener.
    Parameters:
    slider - a slider
    Returns:
    a composite listener

method:createFocusListener(javax.swing.JSlider) [CHANGED]

  • createFocusListener

    protected FocusListener createFocusListener createFocusListener​(JSlider slider)
    Creates a focus listener.
    Parameters:
    slider - a slider
    Returns:
    a focus listener
  • createFocusListener

    protected FocusListener createFocusListener​(JSlider slider)
    Creates a focus listener.
    Parameters:
    slider - a slider
    Returns:
    a focus listener

method:createScrollListener(javax.swing.JSlider) [CHANGED]

  • createScrollListener

    protected BasicSliderUI.ScrollListener createScrollListener createScrollListener​(JSlider slider)
    Creates a scroll listener.
    Parameters:
    slider - a slider
    Returns:
    a scroll listener
  • createScrollListener

    protected BasicSliderUI.ScrollListener createScrollListener​(JSlider slider)
    Creates a scroll listener.
    Parameters:
    slider - a slider
    Returns:
    a scroll listener

method:createPropertyChangeListener(javax.swing.JSlider) [CHANGED]

  • createPropertyChangeListener

    protected PropertyChangeListener createPropertyChangeListener createPropertyChangeListener​(JSlider slider)
    Creates a property change listener.
    Parameters:
    slider - a slider
    Returns:
    a property change listener
  • createPropertyChangeListener

    protected PropertyChangeListener createPropertyChangeListener​(JSlider slider)
    Creates a property change listener.
    Parameters:
    slider - a slider
    Returns:
    a property change listener

method:installListeners(javax.swing.JSlider) [CHANGED]

  • installListeners

    protected void installListenersprotected void installListeners​(JSlider slider)
    Installs listeners.
    Parameters:
    slider - a slider
  • installListeners

    protected void installListeners(JSlider slider)
  • installListeners

    protected void installListeners​(JSlider slider)
    Installs listeners.
    Parameters:
    slider - a slider

method:uninstallListeners(javax.swing.JSlider) [CHANGED]

  • uninstallListeners

    protected void uninstallListenersprotected void uninstallListeners​(JSlider slider)
    Uninstalls listeners.
    Parameters:
    slider - a slider
  • uninstallListeners

    protected void uninstallListeners(JSlider slider)
  • uninstallListeners

    protected void uninstallListeners​(JSlider slider)
    Uninstalls listeners.
    Parameters:
    slider - a slider

method:installKeyboardActions(javax.swing.JSlider) [CHANGED]

  • installKeyboardActions

    protected void installKeyboardActionsprotected void installKeyboardActions​(JSlider slider)
    Installs keyboard actions.
    Parameters:
    slider - a slider
  • installKeyboardActions

    protected void installKeyboardActions(JSlider slider)
  • installKeyboardActions

    protected void installKeyboardActions​(JSlider slider)
    Installs keyboard actions.
    Parameters:
    slider - a slider

method:uninstallKeyboardActions(javax.swing.JSlider) [CHANGED]

  • uninstallKeyboardActions

    protected void uninstallKeyboardActionsprotected void uninstallKeyboardActions​(JSlider slider)
    Uninstalls keyboard actions.
    Parameters:
    slider - a slider
  • uninstallKeyboardActions

    protected void uninstallKeyboardActions(JSlider slider)
  • uninstallKeyboardActions

    protected void uninstallKeyboardActions​(JSlider slider)
    Uninstalls keyboard actions.
    Parameters:
    slider - a slider

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

  • getBaseline

    public int getBaselinepublic 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:
    JComponent.getBaseline(int, int)

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

method:labelsHaveSameBaselines() [CHANGED]

  • labelsHaveSameBaselines

    protected boolean labelsHaveSameBaselinesprotected boolean labelsHaveSameBaselines​()
    Returns true if all the labels from the label table have the same baseline.
    Returns:
    true if all the labels from the label table have the same baseline
    Since:
    1.6
  • labelsHaveSameBaselines

    protected boolean labelsHaveSameBaselines()
    Returns true if all the labels from the label table have the same baseline.
    Returns:
    true if all the labels from the label table have the same baseline
    Since:
    1.6
  • labelsHaveSameBaselines

    protected boolean labelsHaveSameBaselines​()
    Returns true if all the labels from the label table have the same baseline.
    Returns:
    true if all the labels from the label table have the same baseline
    Since:
    1.6

method:getPreferredHorizontalSize() [CHANGED]

  • getPreferredHorizontalSize

    public Dimension getPreferredHorizontalSize getPreferredHorizontalSize​()
    Returns the preferred horizontal size.
    Returns:
    the preferred horizontal size
  • getPreferredHorizontalSize

    public Dimension getPreferredHorizontalSize()
  • getPreferredHorizontalSize

    public Dimension getPreferredHorizontalSize​()
    Returns the preferred horizontal size.
    Returns:
    the preferred horizontal size

method:getPreferredVerticalSize() [CHANGED]

  • getPreferredVerticalSize

    public Dimension getPreferredVerticalSize getPreferredVerticalSize​()
    Returns the preferred vertical size.
    Returns:
    the preferred vertical size
  • getPreferredVerticalSize

    public Dimension getPreferredVerticalSize()
  • getPreferredVerticalSize

    public Dimension getPreferredVerticalSize​()
    Returns the preferred vertical size.
    Returns:
    the preferred vertical size

method:getMinimumHorizontalSize() [CHANGED]

  • getMinimumHorizontalSize

    public Dimension getMinimumHorizontalSize getMinimumHorizontalSize​()
    Returns the minimum horizontal size.
    Returns:
    the minimum horizontal size
  • getMinimumHorizontalSize

    public Dimension getMinimumHorizontalSize()
  • getMinimumHorizontalSize

    public Dimension getMinimumHorizontalSize​()
    Returns the minimum horizontal size.
    Returns:
    the minimum horizontal size

method:getMinimumVerticalSize() [CHANGED]

  • getMinimumVerticalSize

    public Dimension getMinimumVerticalSize getMinimumVerticalSize​()
    Returns the minimum vertical size.
    Returns:
    the minimum vertical size
  • getMinimumVerticalSize

    public Dimension getMinimumVerticalSize()
  • getMinimumVerticalSize

    public Dimension getMinimumVerticalSize​()
    Returns the minimum vertical size.
    Returns:
    the minimum vertical size

method:getPreferredSize(javax.swing.JComponent) [CHANGED]

  • getPreferredSize

    public Dimension getPreferredSize getPreferredSize​(JComponent c)
    Descriptioncopiedfromclass: ComponentUI
    Returns the specified component's preferred size appropriate for the look and feel. If null is returned,the preferred 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 returns null.
    Overrides:
    getPreferredSize in class ComponentUI
    Parameters:
    c - a component
    Returns:
    the component whosepreferred size is being queried; this argument is often ignored, but might be used if the UI object is stateless and shared by multiple components
    See Also:
    JComponent.getPreferredSize(), LayoutManager.preferredLayoutSize(java.awt.Container)
  • getPreferredSize

    public Dimension getPreferredSize(JComponent c)
    Description copied from class: ComponentUI
    Returns the specified component's preferred size appropriate for the look and feel. If null is returned, the preferred 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 returns null.
    Overrides:
    getPreferredSize in class ComponentUI
    Parameters:
    c - the component whose preferred size is being queried; this argument is often ignored, but might be used if the UI object is stateless and shared by multiple components
    See Also:
    JComponent.getPreferredSize(), LayoutManager.preferredLayoutSize(java.awt.Container)

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

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

  • getMaximumSize

    public Dimension getMaximumSize getMaximumSize​(JComponent c)
    Descriptioncopiedfromclass: 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 - thea 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
    the maximum size
    See Also:
    JComponent.getMaximumSize(), LayoutManager2.maximumLayoutSize(java.awt.Container)
  • 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:
    JComponent.getMaximumSize(), LayoutManager2.maximumLayoutSize(java.awt.Container)

method:calculateGeometry() [CHANGED]

  • calculateGeometry

    protected void calculateGeometryprotected void calculateGeometry​()
    Calculates the geometry.
  • calculateGeometry

    protected void calculateGeometry()
  • calculateGeometry

    protected void calculateGeometry​()
    Calculates the geometry.

method:calculateFocusRect() [CHANGED]

  • calculateFocusRect

    protected void calculateFocusRectprotected void calculateFocusRect​()
    Calculates the focus rectangle.
  • calculateFocusRect

    protected void calculateFocusRect()
  • calculateFocusRect

    protected void calculateFocusRect​()
    Calculates the focus rectangle.

method:calculateThumbSize() [CHANGED]

  • calculateThumbSize

    protected void calculateThumbSizeprotected void calculateThumbSize​()
    Calculates the thumb size rectangle.
  • calculateThumbSize

    protected void calculateThumbSize()
  • calculateThumbSize

    protected void calculateThumbSize​()
    Calculates the thumb size rectangle.

method:calculateContentRect() [CHANGED]

  • calculateContentRect

    protected void calculateContentRectprotected void calculateContentRect​()
    Calculates the content rectangle.
  • calculateContentRect

    protected void calculateContentRect()
  • calculateContentRect

    protected void calculateContentRect​()
    Calculates the content rectangle.

method:calculateThumbLocation() [CHANGED]

  • calculateThumbLocation

    protected void calculateThumbLocationprotected void calculateThumbLocation​()
    Calculates the thumb location.
  • calculateThumbLocation

    protected void calculateThumbLocation()
  • calculateThumbLocation

    protected void calculateThumbLocation​()
    Calculates the thumb location.

method:calculateTrackBuffer() [CHANGED]

  • calculateTrackBuffer

    protected void calculateTrackBufferprotected void calculateTrackBuffer​()
    Calculates the track buffer.
  • calculateTrackBuffer

    protected void calculateTrackBuffer()
  • calculateTrackBuffer

    protected void calculateTrackBuffer​()
    Calculates the track buffer.

method:calculateTrackRect() [CHANGED]

  • calculateTrackRect

    protected void calculateTrackRectprotected void calculateTrackRect​()
    Calculates the track rectangle.
  • calculateTrackRect

    protected void calculateTrackRect()
  • calculateTrackRect

    protected void calculateTrackRect​()
    Calculates the track rectangle.

method:getTickLength() [CHANGED]

  • getTickLength

    protected int getTickLengthprotected 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. If you want to give your ticks some room, make this larger than you need and paint your ticks away from the sides in paintTicks().
    Returns:
    an integer representing the height of the tick area for horizontal sliders, and the width of the tick area for the vertical sliders
  • getTickLength

    protected 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. If you want to give your ticks some room, make this larger than you need and paint your ticks away from the sides in paintTicks().
  • getTickLength

    protected 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. If you want to give your ticks some room, make this larger than you need and paint your ticks away from the sides in paintTicks().
    Returns:
    an integer representing the height of the tick area for horizontal sliders, and the width of the tick area for the vertical sliders

method:calculateTickRect() [CHANGED]

  • calculateTickRect

    protected void calculateTickRectprotected void calculateTickRect​()
    Calculates the tick rectangle.
  • calculateTickRect

    protected void calculateTickRect()
  • calculateTickRect

    protected void calculateTickRect​()
    Calculates the tick rectangle.

method:calculateLabelRect() [CHANGED]

  • calculateLabelRect

    protected void calculateLabelRectprotected void calculateLabelRect​()
    Calculates the label rectangle.
  • calculateLabelRect

    protected void calculateLabelRect()
  • calculateLabelRect

    protected void calculateLabelRect​()
    Calculates the label rectangle.

method:getThumbSize() [CHANGED]

  • getThumbSize

    protected Dimension getThumbSize getThumbSize​()
    Returns the thumb size.
    Returns:
    the thumb size
  • getThumbSize

    protected Dimension getThumbSize()
  • getThumbSize

    protected Dimension getThumbSize​()
    Returns the thumb size.
    Returns:
    the thumb size

method:getWidthOfWidestLabel() [CHANGED]

  • getWidthOfWidestLabel

    protected int getWidthOfWidestLabelprotected int getWidthOfWidestLabel​()
    Returns the width of the widest label.
    Returns:
    the width of the widest label
  • getWidthOfWidestLabel

    protected int getWidthOfWidestLabel()
  • getWidthOfWidestLabel

    protected int getWidthOfWidestLabel​()
    Returns the width of the widest label.
    Returns:
    the width of the widest label

method:getHeightOfTallestLabel() [CHANGED]

  • getHeightOfTallestLabel

    protected int getHeightOfTallestLabelprotected int getHeightOfTallestLabel​()
    Returns the height of the tallest label.
    Returns:
    the height of the tallest label
  • getHeightOfTallestLabel

    protected int getHeightOfTallestLabel()
  • getHeightOfTallestLabel

    protected int getHeightOfTallestLabel​()
    Returns the height of the tallest label.
    Returns:
    the height of the tallest label

method:getWidthOfHighValueLabel() [CHANGED]

  • getWidthOfHighValueLabel

    protected int getWidthOfHighValueLabelprotected int getWidthOfHighValueLabel​()
    Returns the width of the highest value label.
    Returns:
    the width of the highest value label
  • getWidthOfHighValueLabel

    protected int getWidthOfHighValueLabel()
  • getWidthOfHighValueLabel

    protected int getWidthOfHighValueLabel​()
    Returns the width of the highest value label.
    Returns:
    the width of the highest value label

method:getWidthOfLowValueLabel() [CHANGED]

  • getWidthOfLowValueLabel

    protected int getWidthOfLowValueLabelprotected int getWidthOfLowValueLabel​()
    Returns the width of the lowest value label.
    Returns:
    the width of the lowest value label
  • getWidthOfLowValueLabel

    protected int getWidthOfLowValueLabel()
  • getWidthOfLowValueLabel

    protected int getWidthOfLowValueLabel​()
    Returns the width of the lowest value label.
    Returns:
    the width of the lowest value label

method:getHeightOfHighValueLabel() [CHANGED]

  • getHeightOfHighValueLabel

    protected int getHeightOfHighValueLabelprotected int getHeightOfHighValueLabel​()
    Returns the height of the highest value label.
    Returns:
    the height of the highest value label
  • getHeightOfHighValueLabel

    protected int getHeightOfHighValueLabel()
  • getHeightOfHighValueLabel

    protected int getHeightOfHighValueLabel​()
    Returns the height of the highest value label.
    Returns:
    the height of the highest value label

method:getHeightOfLowValueLabel() [CHANGED]

  • getHeightOfLowValueLabel

    protected int getHeightOfLowValueLabelprotected int getHeightOfLowValueLabel​()
    Returns the height of the lowest value label.
    Returns:
    the height of the lowest value label
  • getHeightOfLowValueLabel

    protected int getHeightOfLowValueLabel()
  • getHeightOfLowValueLabel

    protected int getHeightOfLowValueLabel​()
    Returns the height of the lowest value label.
    Returns:
    the height of the lowest value label

method:drawInverted() [CHANGED]

  • drawInverted

    protected boolean drawInvertedprotected boolean drawInverted​()
    Draws inverted.
    Returns:
    the inverted-ness
  • drawInverted

    protected boolean drawInverted()
  • drawInverted

    protected boolean drawInverted​()
    Draws inverted.
    Returns:
    the inverted-ness

method:getHighestValue() [CHANGED]

  • getHighestValue

    protected Integer getHighestValue getHighestValue​()
    Returns the biggest value that has an entry in the label table.
    Returns:
    biggest value that has an entry in the label table, or null.
    Since:
    1.6
  • getHighestValue

    protected Integer getHighestValue()
    Returns the biggest value that has an entry in the label table.
    Returns:
    biggest value that has an entry in the label table, or null.
    Since:
    1.6
  • getHighestValue

    protected Integer getHighestValue​()
    Returns the biggest value that has an entry in the label table.
    Returns:
    biggest value that has an entry in the label table, or null.
    Since:
    1.6

method:getLowestValue() [CHANGED]

  • getLowestValue

    protected Integer getLowestValue getLowestValue​()
    Returns the smallest value that has an entry in the label table.
    Returns:
    smallest value that has an entry in the label table, or null.
    Since:
    1.6
  • getLowestValue

    protected Integer getLowestValue()
    Returns the smallest value that has an entry in the label table.
    Returns:
    smallest value that has an entry in the label table, or null.
    Since:
    1.6
  • getLowestValue

    protected Integer getLowestValue​()
    Returns the smallest value that has an entry in the label table.
    Returns:
    smallest value that has an entry in the label table, or null.
    Since:
    1.6

method:getLowestValueLabel() [CHANGED]

  • getLowestValueLabel

    protected Component getLowestValueLabel getLowestValueLabel​()
    Returns the label that corresponds to the highest slider value in the label table.
    Returns:
    the label that corresponds to the highest slider value in the label table
    See Also:
    JSlider.setLabelTable(java.util.Dictionary)
  • getLowestValueLabel

    protected Component getLowestValueLabel​()
    Returns the label that corresponds to the highest slider value in the label table.
    Returns:
    the label that corresponds to the highest slider value in the label table
    See Also:
    JSlider.setLabelTable(java.util.Dictionary)

method:getHighestValueLabel() [CHANGED]

  • getHighestValueLabel

    protected Component getHighestValueLabel getHighestValueLabel​()
    Returns the label that corresponds to the lowest slider value in the label table.
    Returns:
    the label that corresponds to the lowest slider value in the label table
    See Also:
    JSlider.setLabelTable(java.util.Dictionary)
  • getHighestValueLabel

    protected Component getHighestValueLabel​()
    Returns the label that corresponds to the lowest slider value in the label table.
    Returns:
    the label that corresponds to the lowest slider value in the label table
    See Also:
    JSlider.setLabelTable(java.util.Dictionary)

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

  • paint

    public void paintpublic 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:
    ComponentUI.update(java.awt.Graphics, javax.swing.JComponent)
  • 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:
    ComponentUI.update(java.awt.Graphics, javax.swing.JComponent)
  • 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:
    ComponentUI.update(java.awt.Graphics, javax.swing.JComponent)

method:recalculateIfInsetsChanged() [CHANGED]

  • recalculateIfInsetsChanged

    protected void recalculateIfInsetsChangedprotected void recalculateIfInsetsChanged​()
    Recalculates if the insets have changed.
  • recalculateIfInsetsChanged

    protected void recalculateIfInsetsChanged()
  • recalculateIfInsetsChanged

    protected void recalculateIfInsetsChanged​()
    Recalculates if the insets have changed.

method:recalculateIfOrientationChanged() [CHANGED]

  • recalculateIfOrientationChanged

    protected void recalculateIfOrientationChangedprotected void recalculateIfOrientationChanged​()
    Recalculates if the orientation has changed.
  • recalculateIfOrientationChanged

    protected void recalculateIfOrientationChanged()
  • recalculateIfOrientationChanged

    protected void recalculateIfOrientationChanged​()
    Recalculates if the orientation has changed.

method:paintFocus(java.awt.Graphics) [CHANGED]

  • paintFocus

    public void paintFocuspublic void paintFocus​(Graphics g)
    Paints focus.
    Parameters:
    g - the graphics
  • paintFocus

    public void paintFocus(Graphics g)
  • paintFocus

    public void paintFocus​(Graphics g)
    Paints focus.
    Parameters:
    g - the graphics

method:paintTrack(java.awt.Graphics) [CHANGED]

  • paintTrack

    public void paintTrackpublic void paintTrack​(Graphics g)
    Paints track.
    Parameters:
    g - the graphics
  • paintTrack

    public void paintTrack(Graphics g)
  • paintTrack

    public void paintTrack​(Graphics g)
    Paints track.
    Parameters:
    g - the graphics

method:paintTicks(java.awt.Graphics) [CHANGED]

  • paintTicks

    public void paintTickspublic void paintTicks​(Graphics g)
    Paints ticks.
    Parameters:
    g - the graphics
  • paintTicks

    public void paintTicks(Graphics g)
  • paintTicks

    public void paintTicks​(Graphics g)
    Paints ticks.
    Parameters:
    g - the graphics

method:paintMinorTickForHorizSlider(java.awt.Graphics, java.awt.Rectangle, int) [CHANGED]

  • paintMinorTickForHorizSlider

    protected void paintMinorTickForHorizSliderprotected void paintMinorTickForHorizSlider​(Graphics g,
                                                Rectangle tickBounds,
                                                int x)
    Paints minor tick for horizontal slider.
    Parameters:
    g - the graphics
    tickBounds - the tick bounds
    x - the x coordinate
  • paintMinorTickForHorizSlider

    protected void paintMinorTickForHorizSlider(Graphics g,
                                                Rectangle tickBounds,
                                                int x)
  • paintMinorTickForHorizSlider

    protected void paintMinorTickForHorizSlider​(Graphics g,
                                                Rectangle tickBounds,
                                                int x)
    Paints minor tick for horizontal slider.
    Parameters:
    g - the graphics
    tickBounds - the tick bounds
    x - the x coordinate

method:paintMajorTickForHorizSlider(java.awt.Graphics, java.awt.Rectangle, int) [CHANGED]

  • paintMajorTickForHorizSlider

    protected void paintMajorTickForHorizSliderprotected void paintMajorTickForHorizSlider​(Graphics g,
                                                Rectangle tickBounds,
                                                int x)
    Paints major tick for horizontal slider.
    Parameters:
    g - the graphics
    tickBounds - the tick bounds
    x - the x coordinate
  • paintMajorTickForHorizSlider

    protected void paintMajorTickForHorizSlider(Graphics g,
                                                Rectangle tickBounds,
                                                int x)
  • paintMajorTickForHorizSlider

    protected void paintMajorTickForHorizSlider​(Graphics g,
                                                Rectangle tickBounds,
                                                int x)
    Paints major tick for horizontal slider.
    Parameters:
    g - the graphics
    tickBounds - the tick bounds
    x - the x coordinate

method:paintMinorTickForVertSlider(java.awt.Graphics, java.awt.Rectangle, int) [CHANGED]

  • paintMinorTickForVertSlider

    protected void paintMinorTickForVertSliderprotected void paintMinorTickForVertSlider​(Graphics g,
                                               Rectangle tickBounds,
                                               int y)
    Paints minor tick for vertical slider.
    Parameters:
    g - the graphics
    tickBounds - the tick bounds
    y - the y coordinate
  • paintMinorTickForVertSlider

    protected void paintMinorTickForVertSlider(Graphics g,
                                               Rectangle tickBounds,
                                               int y)
  • paintMinorTickForVertSlider

    protected void paintMinorTickForVertSlider​(Graphics g,
                                               Rectangle tickBounds,
                                               int y)
    Paints minor tick for vertical slider.
    Parameters:
    g - the graphics
    tickBounds - the tick bounds
    y - the y coordinate

method:paintMajorTickForVertSlider(java.awt.Graphics, java.awt.Rectangle, int) [CHANGED]

  • paintMajorTickForVertSlider

    protected void paintMajorTickForVertSliderprotected void paintMajorTickForVertSlider​(Graphics g,
                                               Rectangle tickBounds,
                                               int y)
    Paints major tick for vertical slider.
    Parameters:
    g - the graphics
    tickBounds - the tick bounds
    y - the y coordinate
  • paintMajorTickForVertSlider

    protected void paintMajorTickForVertSlider(Graphics g,
                                               Rectangle tickBounds,
                                               int y)
  • paintMajorTickForVertSlider

    protected void paintMajorTickForVertSlider​(Graphics g,
                                               Rectangle tickBounds,
                                               int y)
    Paints major tick for vertical slider.
    Parameters:
    g - the graphics
    tickBounds - the tick bounds
    y - the y coordinate

method:paintLabels(java.awt.Graphics) [CHANGED]

  • paintLabels

    public void paintLabelspublic void paintLabels​(Graphics g)
    Paints the labels.
    Parameters:
    g - the graphics
  • paintLabels

    public void paintLabels(Graphics g)
  • paintLabels

    public void paintLabels​(Graphics g)
    Paints the labels.
    Parameters:
    g - the graphics

method:paintHorizontalLabel(java.awt.Graphics, int, java.awt.Component) [CHANGED]

  • paintHorizontalLabel

    protected void paintHorizontalLabelprotected void paintHorizontalLabel​(Graphics g,
                                        int value,
                                        Component label)
    Called for every label in the label table. Used to draw the labels for horizontal sliders. The graphics have been translated to labelRect.y already.
    Parameters:
    g - the graphics context in which to paint
    value - the value of the slider
    label - the component label in the label table that needs to be painted
    See Also:
    JSlider.setLabelTable(java.util.Dictionary)
  • paintHorizontalLabel

    protected void paintHorizontalLabel(Graphics g,
                                        int value,
                                        Component label)
    Called for every label in the label table. Used to draw the labels for horizontal sliders. The graphics have been translated to labelRect.y already.
    See Also:
    JSlider.setLabelTable(java.util.Dictionary)
  • paintHorizontalLabel

    protected void paintHorizontalLabel​(Graphics g,
                                        int value,
                                        Component label)
    Called for every label in the label table. Used to draw the labels for horizontal sliders. The graphics have been translated to labelRect.y already.
    Parameters:
    g - the graphics context in which to paint
    value - the value of the slider
    label - the component label in the label table that needs to be painted
    See Also:
    JSlider.setLabelTable(java.util.Dictionary)

method:paintVerticalLabel(java.awt.Graphics, int, java.awt.Component) [CHANGED]

  • paintVerticalLabel

    protected void paintVerticalLabelprotected void paintVerticalLabel​(Graphics g,
                                      int value,
                                      Component label)
    Called for every label in the label table. Used to draw the labels for vertical sliders. The graphics have been translated to labelRect.x already.
    Parameters:
    g - the graphics context in which to paint
    value - the value of the slider
    label - the component label in the label table that needs to be painted
    See Also:
    JSlider.setLabelTable(java.util.Dictionary)
  • paintVerticalLabel

    protected void paintVerticalLabel(Graphics g,
                                      int value,
                                      Component label)
    Called for every label in the label table. Used to draw the labels for vertical sliders. The graphics have been translated to labelRect.x already.
    See Also:
    JSlider.setLabelTable(java.util.Dictionary)
  • paintVerticalLabel

    protected void paintVerticalLabel​(Graphics g,
                                      int value,
                                      Component label)
    Called for every label in the label table. Used to draw the labels for vertical sliders. The graphics have been translated to labelRect.x already.
    Parameters:
    g - the graphics context in which to paint
    value - the value of the slider
    label - the component label in the label table that needs to be painted
    See Also:
    JSlider.setLabelTable(java.util.Dictionary)

method:paintThumb(java.awt.Graphics) [CHANGED]

  • paintThumb

    public void paintThumbpublic void paintThumb​(Graphics g)
    Paints the thumb.
    Parameters:
    g - the graphics
  • paintThumb

    public void paintThumb(Graphics g)
  • paintThumb

    public void paintThumb​(Graphics g)
    Paints the thumb.
    Parameters:
    g - the graphics

method:setThumbLocation(int, int) [CHANGED]

  • setThumbLocation

    public void setThumbLocationpublic void setThumbLocation​(int x,
                                 int y)
    Sets the thumb location.
    Parameters:
    x - the x coordinate
    y - the y coordinate
  • setThumbLocation

    public void setThumbLocation(int x,
                                 int y)
  • setThumbLocation

    public void setThumbLocation​(int x,
                                 int y)
    Sets the thumb location.
    Parameters:
    x - the x coordinate
    y - the y coordinate

method:scrollByBlock(int) [CHANGED]

  • scrollByBlock

    public void scrollByBlockpublic void scrollByBlock​(int direction)
    Scrolls by block.
    Parameters:
    direction - the direction
  • scrollByBlock

    public void scrollByBlock(int direction)
  • scrollByBlock

    public void scrollByBlock​(int direction)
    Scrolls by block.
    Parameters:
    direction - the direction

method:scrollByUnit(int) [CHANGED]

  • scrollByUnit

    public void scrollByUnitpublic void scrollByUnit​(int direction)
    Scrolls by unit.
    Parameters:
    direction - the direction
  • scrollByUnit

    public void scrollByUnit(int direction)
  • scrollByUnit

    public void scrollByUnit​(int direction)
    Scrolls by unit.
    Parameters:
    direction - the direction

method:scrollDueToClickInTrack(int) [CHANGED]

  • scrollDueToClickInTrack

    protected void scrollDueToClickInTrackprotected void scrollDueToClickInTrack​(int dir)
    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.
    Parameters:
    dir - the direction and number of blocks to scroll
  • scrollDueToClickInTrack

    protected void scrollDueToClickInTrack(int dir)
    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.
  • scrollDueToClickInTrack

    protected void scrollDueToClickInTrack​(int dir)
    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.
    Parameters:
    dir - the direction and number of blocks to scroll

method:xPositionForValue(int) [CHANGED]

  • xPositionForValue

    protected int xPositionForValueprotected int xPositionForValue​(int value)
    Returns the x position for a value.
    Parameters:
    value - the value
    Returns:
    the x position for a value
  • xPositionForValue

    protected int xPositionForValue(int value)
  • xPositionForValue

    protected int xPositionForValue​(int value)
    Returns the x position for a value.
    Parameters:
    value - the value
    Returns:
    the x position for a value

method:yPositionForValue(int) [CHANGED]

  • yPositionForValue

    protected int yPositionForValueprotected int yPositionForValue​(int value)
    Returns the y position for a value.
    Parameters:
    value - the value
    Returns:
    the y position for a value
  • yPositionForValue

    protected int yPositionForValue(int value)
  • yPositionForValue

    protected int yPositionForValue​(int value)
    Returns the y position for a value.
    Parameters:
    value - the value
    Returns:
    the y position for a value

method:yPositionForValue(int, int, int) [CHANGED]

  • yPositionForValue

    protected int yPositionForValueprotected int yPositionForValue​(int value,
                                    int trackY,
                                    int trackHeight)
    Returns the y location for the specified value. No checking is done on the arguments. In particular if trackHeight is negative undefined results may occur.
    Parameters:
    value - the slider value to get the location for
    trackY - y-origin of the track
    trackHeight - the height of the track
    Returns:
    the y location for the specified value of the slider
    Since:
    1.6
  • yPositionForValue

    protected int yPositionForValue(int value,
                                    int trackY,
                                    int trackHeight)
    Returns the y location for the specified value. No checking is done on the arguments. In particular if trackHeight is negative undefined results may occur.
    Parameters:
    value - the slider value to get the location for
    trackY - y-origin of the track
    trackHeight - the height of the track
    Since:
    1.6
  • yPositionForValue

    protected int yPositionForValue​(int value,
                                    int trackY,
                                    int trackHeight)
    Returns the y location for the specified value. No checking is done on the arguments. In particular if trackHeight is negative undefined results may occur.
    Parameters:
    value - the slider value to get the location for
    trackY - y-origin of the track
    trackHeight - the height of the track
    Returns:
    the y location for the specified value of the slider
    Since:
    1.6

method:valueForYPosition(int) [CHANGED]

  • valueForYPosition

    public int valueForYPositionpublic int valueForYPosition​(int yPos)
    Returns the value at the y position. If yPos is beyond the track at thethe bottom or the top, this method sets the value to either the minimum or maximum value of the slider, depending on if the slider is inverted or not.
    Parameters:
    yPos - the location of the slider along the y axis
    Returns:
    the value at the y position
  • valueForYPosition

    public int valueForYPosition(int yPos)
    Returns the value at the y position. If yPos is beyond the track at the the bottom or the top, this method sets the value to either the minimum or maximum value of the slider, depending on if the slider is inverted or not.
  • valueForYPosition

    public int valueForYPosition​(int yPos)
    Returns the value at the y position. If yPos is beyond the track at the bottom or the top, this method sets the value to either the minimum or maximum value of the slider, depending on if the slider is inverted or not.
    Parameters:
    yPos - the location of the slider along the y axis
    Returns:
    the value at the y position

method:valueForXPosition(int) [CHANGED]

  • valueForXPosition

    public int valueForXPositionpublic int valueForXPosition​(int xPos)
    Returns the value at the x position. If xPos is beyond the track at the left or the right, this method sets the value to either the minimum or maximum value of the slider, depending on if the slider is inverted or not.
    Parameters:
    xPos - the location of the slider along the x axis
    Returns:
    the value of the x position
  • valueForXPosition

    public int valueForXPosition(int xPos)
    Returns the value at the x position. If xPos is beyond the track at the left or the right, this method sets the value to either the minimum or maximum value of the slider, depending on if the slider is inverted or not.
  • valueForXPosition

    public int valueForXPosition​(int xPos)
    Returns the value at the x position. If xPos is beyond the track at the left or the right, this method sets the value to either the minimum or maximum value of the slider, depending on if the slider is inverted or not.
    Parameters:
    xPos - the location of the slider along the x axis
    Returns:
    the value of the x position

© 2017 Oracle Corporation and/or its affiliates