Package Summary  Overview Summary

class:MetalScrollBarUI [NONE]

All Implemented Interfaces:
LayoutManager, SwingConstants

public class MetalScrollBarUI
extends BasicScrollBarUI
Implementation of ScrollBarUI for the Metal Look and Feel

field:increaseButton [NONE]

  • increaseButton

    protected MetalScrollButton increaseButton
    The increase button.
  • field:decreaseButton [NONE]

    decreaseButton

    protected MetalScrollButton decreaseButton
    The decrease button.

    field:scrollBarWidth [NONE]

    scrollBarWidth

    protected int scrollBarWidth
    The width of the scroll bar.

    field:FREE_STANDING_PROP [NONE]

    FREE_STANDING_PROP

    public static final  String FREE_STANDING_PROP
    The property JScrollBar.isFreeStanding.
    See Also:
    Constant Field Values

    field:isFreeStanding [NONE]

    isFreeStanding

    protected boolean isFreeStanding
    The value of the property JScrollBar.isFreeStanding.

    constructor:MetalScrollBarUI() [NONE]

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

  • createUI

    public static  ComponentUI createUI?(JComponent c)
    Constructs a new MetalScrollBarUI instance.
    Parameters:
    c - a component
    Returns:
    a new MetalScrollBarUI instance
  • method:installDefaults() [NONE]

    installDefaults

    protected void installDefaults()
    Description copied from class: BasicScrollBarUI
    Installs the defaults.
    Overrides:
    installDefaults in class BasicScrollBarUI

    method:installListeners() [NONE]

    installListeners

    protected void installListeners()
    Description copied from class: BasicScrollBarUI
    Installs the listeners.
    Overrides:
    installListeners in class BasicScrollBarUI

    method:createPropertyChangeListener() [NONE]

    createPropertyChangeListener

    protected PropertyChangeListener createPropertyChangeListener()
    Description copied from class: BasicScrollBarUI
    Creates a property change listener.
    Overrides:
    createPropertyChangeListener in class BasicScrollBarUI
    Returns:
    a property change listener

    method:configureScrollBarColors() [NONE]

    configureScrollBarColors

    protected void configureScrollBarColors()
    Description copied from class: BasicScrollBarUI
    Configures the scroll bar colors.
    Overrides:
    configureScrollBarColors in class BasicScrollBarUI

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

    getPreferredSize

    public Dimension getPreferredSize?(JComponent c)
    Description copied from class: BasicScrollBarUI
    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. 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.

    Overrides:
    getPreferredSize in class BasicScrollBarUI
    Parameters:
    c - the JScrollBar that's delegating this method to us
    Returns:
    the preferred size of a Basic JScrollBar
    See Also:
    BasicScrollBarUI.getMaximumSize(javax.swing.JComponent), ComponentUI.getMinimumSize(javax.swing.JComponent)

    method:createDecreaseButton(int) [NONE]

    createDecreaseButton

    protected JButton createDecreaseButton?(int orientation)
    Returns the view that represents the decrease view.
    Overrides:
    createDecreaseButton in class BasicScrollBarUI
    Parameters:
    orientation - the orientation
    Returns:
    a decrease button

    method:createIncreaseButton(int) [NONE]

    createIncreaseButton

    protected JButton createIncreaseButton?(int orientation)
    Returns the view that represents the increase view.
    Overrides:
    createIncreaseButton in class BasicScrollBarUI
    Parameters:
    orientation - the orientation
    Returns:
    an increase button

    method:paintTrack(java.awt.Graphics,javax.swing.JComponent,java.awt.Rectangle) [NONE]

    paintTrack

    protected void paintTrack?(Graphics g, JComponent c, Rectangle trackBounds)
    Description copied from class: BasicScrollBarUI
    Paints the track.
    Overrides:
    paintTrack in class BasicScrollBarUI
    Parameters:
    g - the graphics
    c - the component
    trackBounds - the track bounds

    method:paintThumb(java.awt.Graphics,javax.swing.JComponent,java.awt.Rectangle) [NONE]

    paintThumb

    protected void paintThumb?(Graphics g, JComponent c, Rectangle thumbBounds)
    Description copied from class: BasicScrollBarUI
    Paints the thumb.
    Overrides:
    paintThumb in class BasicScrollBarUI
    Parameters:
    g - the graphics
    c - the component
    thumbBounds - the thumb bounds

    method:getMinimumThumbSize() [NONE]

    getMinimumThumbSize

    protected Dimension getMinimumThumbSize()
    Description copied from class: BasicScrollBarUI
    Returns the smallest acceptable size for the thumb. If the scrollbar becomes so small that this size isn't available, the thumb will be hidden.

    Warning : the value returned by this method should not be be modified, it's a shared static constant.

    Overrides:
    getMinimumThumbSize in class BasicScrollBarUI
    Returns:
    The smallest acceptable size for the thumb.
    See Also:
    BasicScrollBarUI.getMaximumThumbSize()

    method:setThumbBounds(int,int,int,int) [NONE]

    setThumbBounds

    protected void setThumbBounds?(int x, int y, int width, int height)
    This is overridden only to increase the invalid area. This ensures that the "Shadow" below the thumb is invalidated
    Overrides:
    setThumbBounds in class BasicScrollBarUI
    Parameters:
    x - set the x location of the thumb
    y - set the y location of the thumb
    width - set the width of the thumb
    height - set the height of the thumb
    See Also:
    BasicScrollBarUI.getThumbBounds()

    © 2020 Oracle Corporation and/or its affiliates