ch.randelshofer.quaqua
Class QuaquaScrollPaneUI
java.lang.Object
javax.swing.plaf.ComponentUI
javax.swing.plaf.ScrollPaneUI
javax.swing.plaf.basic.BasicScrollPaneUI
ch.randelshofer.quaqua.QuaquaScrollPaneUI
- All Implemented Interfaces:
- VisuallyLayoutable, javax.swing.ScrollPaneConstants
public class QuaquaScrollPaneUI
- extends javax.swing.plaf.basic.BasicScrollPaneUI
- implements VisuallyLayoutable
QuaquaScrollPaneUI.
- Version:
- $Id: QuaquaScrollPaneUI.java 266 2010-07-28 16:47:42Z wrandelshofer $
- Author:
- Werner Randelshofer
| Nested classes/interfaces inherited from class javax.swing.plaf.basic.BasicScrollPaneUI |
javax.swing.plaf.basic.BasicScrollPaneUI.HSBChangeListener, javax.swing.plaf.basic.BasicScrollPaneUI.MouseWheelHandler, javax.swing.plaf.basic.BasicScrollPaneUI.PropertyChangeHandler, javax.swing.plaf.basic.BasicScrollPaneUI.ViewportChangeHandler, javax.swing.plaf.basic.BasicScrollPaneUI.VSBChangeListener |
| Fields inherited from class javax.swing.plaf.basic.BasicScrollPaneUI |
hsbChangeListener, scrollpane, spPropertyChangeListener, viewportChangeListener, vsbChangeListener |
| Fields inherited from interface javax.swing.ScrollPaneConstants |
COLUMN_HEADER, HORIZONTAL_SCROLLBAR, HORIZONTAL_SCROLLBAR_ALWAYS, HORIZONTAL_SCROLLBAR_AS_NEEDED, HORIZONTAL_SCROLLBAR_NEVER, HORIZONTAL_SCROLLBAR_POLICY, LOWER_LEADING_CORNER, LOWER_LEFT_CORNER, LOWER_RIGHT_CORNER, LOWER_TRAILING_CORNER, ROW_HEADER, UPPER_LEADING_CORNER, UPPER_LEFT_CORNER, UPPER_RIGHT_CORNER, UPPER_TRAILING_CORNER, VERTICAL_SCROLLBAR, VERTICAL_SCROLLBAR_ALWAYS, VERTICAL_SCROLLBAR_AS_NEEDED, VERTICAL_SCROLLBAR_NEVER, VERTICAL_SCROLLBAR_POLICY, VIEWPORT |
| Methods inherited from class javax.swing.plaf.basic.BasicScrollPaneUI |
getBaselineResizeBehavior, getMaximumSize, installKeyboardActions, paint, uninstallKeyboardActions, uninstallUI, updateColumnHeader, updateRowHeader, updateScrollBarDisplayPolicy, updateViewport |
| Methods inherited from class javax.swing.plaf.ComponentUI |
contains, getAccessibleChild, getAccessibleChildrenCount, getMinimumSize, getPreferredSize |
| Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
QuaquaScrollPaneUI
public QuaquaScrollPaneUI()
- Creates a new instance.
createUI
public static javax.swing.plaf.ComponentUI createUI(javax.swing.JComponent c)
installUI
public void installUI(javax.swing.JComponent c)
- Overrides:
installUI in class javax.swing.plaf.basic.BasicScrollPaneUI
createPropertyChangeListener
protected java.beans.PropertyChangeListener createPropertyChangeListener()
- Overrides:
createPropertyChangeListener in class javax.swing.plaf.basic.BasicScrollPaneUI
installDefaults
protected void installDefaults(javax.swing.JScrollPane scrollpane)
- Overrides:
installDefaults in class javax.swing.plaf.basic.BasicScrollPaneUI
uninstallDefaults
protected void uninstallDefaults(javax.swing.JScrollPane scrollpane)
- Overrides:
uninstallDefaults in class javax.swing.plaf.basic.BasicScrollPaneUI
installListeners
protected void installListeners(javax.swing.JScrollPane c)
- Overrides:
installListeners in class javax.swing.plaf.basic.BasicScrollPaneUI
uninstallListeners
protected void uninstallListeners(javax.swing.JComponent c)
- Overrides:
uninstallListeners in class javax.swing.plaf.basic.BasicScrollPaneUI
createMouseWheelListener
protected java.awt.event.MouseWheelListener createMouseWheelListener()
- Creates an instance of MouseWheelListener, which is added to the
JScrollPane by installUI(). The returned MouseWheelListener is used
to handle mouse wheel-driven scrolling.
- Overrides:
createMouseWheelListener in class javax.swing.plaf.basic.BasicScrollPaneUI
- Returns:
- MouseWheelListener which implements wheel-driven scrolling
createVSBChangeListener
protected javax.swing.event.ChangeListener createVSBChangeListener()
- Overrides:
createVSBChangeListener in class javax.swing.plaf.basic.BasicScrollPaneUI
createHSBChangeListener
protected javax.swing.event.ChangeListener createHSBChangeListener()
- Overrides:
createHSBChangeListener in class javax.swing.plaf.basic.BasicScrollPaneUI
createViewportChangeListener
protected javax.swing.event.ChangeListener createViewportChangeListener()
- Overrides:
createViewportChangeListener in class javax.swing.plaf.basic.BasicScrollPaneUI
getVisualMargin
public java.awt.Insets getVisualMargin(java.awt.Component c)
update
public void update(java.awt.Graphics g,
javax.swing.JComponent c)
- Overrides:
update in class javax.swing.plaf.ComponentUI
getBaseline
public int getBaseline(javax.swing.JComponent c,
int width,
int height)
- Description copied from interface:
VisuallyLayoutable
- Returns the baseline for the specified component, or -1 if the
baseline can not be determined. The baseline is measured from
the top of the component.
- Specified by:
getBaseline in interface VisuallyLayoutable- Overrides:
getBaseline in class javax.swing.plaf.basic.BasicScrollPaneUI
- Parameters:
c - JComponent to calculate baseline forwidth - Width of the component to determine baseline for.height - Height of the component to determine baseline for.
- Returns:
- baseline for the specified component
getVisualBounds
public java.awt.Rectangle getVisualBounds(javax.swing.JComponent c,
int type,
int width,
int height)
- Description copied from interface:
VisuallyLayoutable
- Returns the visual bounds for the specified component, or null if the
visual bounds can not be determined.
- Specified by:
getVisualBounds in interface VisuallyLayoutable
- Parameters:
c - JComponent to calculate visual margin fortype - The type of the visual margin.width - Width of the componentheight - Height of the component
- Returns:
- The visual bounds in component coordinates.
syncScrollPaneWithViewport
protected void syncScrollPaneWithViewport()
- Overrides:
syncScrollPaneWithViewport in class javax.swing.plaf.basic.BasicScrollPaneUI