java.lang.Object | +--java.awt.Component | +--java.awt.Container | +--java.awt.ScrollPane
Unsafe:
static int
SCROLLBARS_ALWAYS
static int
SCROLLBARS_AS_NEEDED
static int
SCROLLBARS_NEVER
private boolean
wheelScrollingEnabled
component, containerListener, descendantsCount, INCLUDE_SELF, layoutMgr, listeningBoundsChildren, listeningChildren, ncomponents, SEARCH_HEAVYWEIGHTS
accessibleContext, actionListenerK, adjustmentListenerK, appContext, background, BOTTOM_ALIGNMENT, bufferStrategy, CENTER_ALIGNMENT, componentListener, componentListenerK, componentOrientation, containerListenerK, cursor, dropTarget, enabled, eventMask, focusListener, focusListenerK, focusTraversalKeys, font, foreground, graphicsConfig, height, hierarchyBoundsListener, hierarchyBoundsListenerK, hierarchyListener, hierarchyListenerK, ignoreRepaint, incRate, inputMethodListener, inputMethodListenerK, isInc, isPacked, itemListenerK, keyListener, keyListenerK, LEFT_ALIGNMENT, locale, LOCK, metrics, minSize, mouseListener, mouseListenerK, mouseMotionListener, mouseMotionListenerK, mouseWheelListener, mouseWheelListenerK, newEventsOnly, ownedWindowK, parent, peer, peerFont, popups, prefSize, RIGHT_ALIGNMENT, textListenerK, TOP_ALIGNMENT, valid, visible, width, windowClosingException, windowFocusListenerK, windowListenerK, windowStateListenerK, x, y
ScrollPane()
ScrollPane(int scrollbarDisplayPolicy)
protected void
addImpl(Component comp,
Object constraints,
int index)
(package private) Dimension
calculateChildSize()
protected boolean
eventTypeEnabled(int type)
AccessibleContext
getAccessibleContext()
Adjustable
getHAdjustable()
ScrollPaneAdjustable object which
represents the state of the horizontal scrollbar.
int
getHScrollbarHeight()
Point
getScrollPosition()
Adjustable
getVAdjustable()
ScrollPaneAdjustable object which
represents the state of the vertical scrollbar.
int
getVScrollbarWidth()
boolean
isWheelScrollingEnabled()
protected void
processMouseWheelEvent(MouseWheelEvent e)
ScrollPane by scrolling an appropriate amount.
void
setScrollPosition(int x,
int y)
void
setScrollPosition(Point p)
void
setWheelScrollingEnabled(boolean handleWheel)
add, add, add, add, add, addContainerListener, addPropertyChangeListener, addPropertyChangeListener, adjustDecendantsOnParent, adjustDescendants, adjustListeningChildren, applyComponentOrientation, areFocusTraversalKeysSet, checkGD, clearCurrentFocusCycleRootOnHide, clearMostRecentFocusOwnerOnHide, containsFocus, countComponents, countHierarchyMembers, createChildHierarchyEvents, createHierarchyEvents, deliverEvent, dispatchEventImpl, dispatchEventToSelf, eventEnabled, findComponentAt, findComponentAt, findComponentAt, get, getAccessibleAt, getAccessibleChild, getAccessibleChildrenCount, getAlignmentX, getAlignmentY, getComponent, getComponentAt, getComponentAt, getComponentCount, getComponents_NoClientCode, getComponents, getContainerListeners, getDropTargetEventTarget, getFocusTraversalKeys, getFocusTraversalPolicy, getInsets, getLayout, getListeners, getMaximumSize, getMinimumSize, getMouseEventTarget, getPreferredSize, initializeFocusTraversalKeys, insets, invalidate, invalidateTree, isAncestorOf, isFocusCycleRoot, isFocusCycleRoot, isFocusTraversalPolicySet, iterate, lightweightPaint, lightweightPrint, list, list, locate, minimumSize, nextFocusHelper, numListening, paint, paintComponents, paintHeavyweightComponents, postProcessKeyEvent, postsOldMouseEvents, preferredSize, preProcessKeyEvent, print, printHeavyweightComponents, processContainerEvent, processEvent, proxyEnableEvents, remove, remove, removeAll, removeContainerListener, removeNotify, setFocusCycleRoot, setFocusTraversalKeys, setFocusTraversalPolicy, setFont, setZOrder, size, transferFocusBackward, transferFocusDownCycle, update, validate, validateTree
action, add, addComponentListener, addFocusListener, addHierarchyBoundsListener, addHierarchyListener, addInputMethodListener, addKeyListener, addMouseListener, addMouseMotionListener, addMouseWheelListener, adjustListeningChildrenOnParent, areInputMethodsEnabled, autoTransferFocus, bounds, checkImage, checkImage, checkWindowClosingException, coalesceEvents, contains, contains, createBufferStrategy, createBufferStrategy, createImage, createImage, createVolatileImage, createVolatileImage, disable, disableEvents, dispatchEvent, dispatchMouseWheelToAncestor, enable, enable, enableEvents, enableInputMethods, firePropertyChange, firePropertyChange, firePropertyChange, getAccessibleIndexInParent, getAccessibleStateSet, getBackBuffer, getBackground, getBounds, getBounds, getBufferStrategy, getColorModel, getComponentListeners, getComponentOrientation, getCursor, getDropTarget, getFocusCycleRootAncestor, getFocusListeners, getFocusTraversalKeys_NoIDCheck, getFocusTraversalKeysEnabled, getFont_NoClientCode, getFont, getFontMetrics, getForeground, getGraphics, getGraphicsConfiguration, getHeight, getHierarchyBoundsListeners, getHierarchyListeners, getIgnoreRepaint, getInputContext, getInputMethodListeners, getInputMethodRequests, getKeyListeners, getLocale, getLocation, getLocation, getLocationOnScreen_NoTreeLock, getLocationOnScreen, getMouseListeners, getMouseMotionListeners, getMouseWheelListeners, getName, getNativeContainer, getParent_NoClientCode, getParent, getPeer, getPropertyChangeListeners, getPropertyChangeListeners, getSize, getSize, getToolkit, getToolkitImpl, getTreeLock, getWidth, getX, getY, gotFocus, handleEvent, hasFocus, hide, imageUpdate, inside, isBackgroundSet, isCursorSet, isDisplayable, isDoubleBuffered, isEnabled, isEnabledImpl, isFocusable, isFocusOwner, isFocusTraversable, isFocusTraversableOverridden, isFontSet, isForegroundSet, isLightweight, isOpaque, isRecursivelyVisible, isShowing, isValid, isVisible, keyDown, keyUp, list, list, list, location, lostFocus, mouseDown, mouseDrag, mouseEnter, mouseExit, mouseMove, mouseUp, move, nextFocus, paintAll, postEvent, prepareImage, prepareImage, printAll, processComponentEvent, processFocusEvent, processHierarchyBoundsEvent, processHierarchyEvent, processInputMethodEvent, processKeyEvent, processMouseEvent, processMouseMotionEvent, remove, removeComponentListener, removeFocusListener, removeHierarchyBoundsListener, removeHierarchyListener, removeInputMethodListener, removeKeyListener, removeMouseListener, removeMouseMotionListener, removeMouseWheelListener, removePropertyChangeListener, removePropertyChangeListener, repaint, repaint, repaint, repaint, requestFocus, requestFocus, requestFocusHelper, requestFocusInWindow, requestFocusInWindow, resetGC, reshape, resize, resize, setBackground, setBounds, setBounds, setComponentOrientation, setCursor, setDropTarget, setEnabled, setFocusable, setFocusTraversalKeys_NoIDCheck, setFocusTraversalKeysEnabled, setForeground, setGCFromPeer, setIgnoreRepaint, setLocale, setLocation, setLocation, setName, setSize, setSize, setVisible, show, show, toString, transferFocus, transferFocus, transferFocusUpCycle, updateCursorImmediately
public static final int SCROLLBARS_AS_NEEDED
public static final int SCROLLBARS_ALWAYS
public static final int SCROLLBARS_NEVER
private int scrollbarDisplayPolicy
getScrollbarDisplayPolicy()private ScrollPaneAdjustable vAdjustable
Adjustable methods, namely:
setMinimum(), setMaximum(),
setVisibleAmount().
getVAdjustable()private ScrollPaneAdjustable hAdjustable
Adjustable methods, namely:
setMinimum(), setMaximum(),
setVisibleAmount().
getHAdjustable()private static final String base
private static int nameCounter
private static final boolean defaultWheelScroll
private boolean wheelScrollingEnabled
private static final long serialVersionUID
public ScrollPane() throws HeadlessException
HeadlessException - if GraphicsEnvironment.isHeadless()
returns truejava.awt.GraphicsEnvironment#isHeadlesspublic ScrollPane(int scrollbarDisplayPolicy) throws HeadlessException
scrollbarDisplayPolicy - policy for when scrollbars should be shown
IllegalArgumentException - if the specified scrollbar
display policy is invalid
HeadlessException - if GraphicsEnvironment.isHeadless()
returns truejava.awt.GraphicsEnvironment#isHeadlessprivate static void initIDs()
String constructComponentName()
constructComponentName in class Componentprotected final void addImpl(Component comp, Object constraints, int index)
comp - the component to be addedconstraints - not applicableindex - position of child component (must be <= 0)Container.add(Component),
Container.add(Component, int),
Container.add(Component, java.lang.Object),
LayoutManager,
LayoutManager2public int getScrollbarDisplayPolicy()
public Dimension getViewportSize()
public int getHScrollbarHeight()
public int getVScrollbarWidth()
public Adjustable getVAdjustable()
ScrollPaneAdjustable object which
represents the state of the vertical scrollbar.
The declared return type of this method is
Adjustable to maintain backward compatibility.
java.awt.ScrollPaneAdjustablepublic Adjustable getHAdjustable()
ScrollPaneAdjustable object which
represents the state of the horizontal scrollbar.
The declared return type of this method is
Adjustable to maintain backward compatibility.
java.awt.ScrollPaneAdjustablepublic void setScrollPosition(int x, int y)
x - the x position to scroll toy - the y position to scroll to
NullPointerException - if the scrollpane does not contain
a childpublic void setScrollPosition(Point p)
p - the Point representing the position to scroll topublic Point getScrollPosition()
NullPointerException - if the scrollpane does not contain
a childpublic final void setLayout(LayoutManager mgr)
mgr - the specified layout managerContainer.doLayout(),
Container.getLayout()public void doLayout()
Component.validate()Dimension calculateChildSize()
public void layout()
doLayout().
public void printComponents(Graphics g)
printComponents in class Containerg - the specified Graphics windowComponent.print(java.awt.Graphics),
Component.printAll(java.awt.Graphics)public void addNotify()
public String paramString()
ScrollPane. This
method is intended to be used only for debugging purposes, and the
content and format of the returned string may vary between
implementations. The returned string may be empty but may not be
null.
paramString in class Containervoid autoProcessMouseWheel(MouseWheelEvent e)
autoProcessMouseWheel in class Componentprotected void processMouseWheelEvent(MouseWheelEvent e)
ScrollPane by scrolling an appropriate amount.
Note that if the event parameter is null
the behavior is unspecified and may result in an
exception.
processMouseWheelEvent in class Componente - the mouse wheel eventjava.awt.event.MouseWheelEvent,
java.awt.event.MouseWheelListener,
Component.addMouseWheelListener(java.awt.event.MouseWheelListener),
Component.enableEvents(long)protected boolean eventTypeEnabled(int type)
eventTypeEnabled in class Componentpublic void setWheelScrollingEnabled(boolean handleWheel)
handleWheel - true if scrolling should be done
automatically for a MouseWheelEvent,
false otherwise.isWheelScrollingEnabled(),
java.awt.event.MouseWheelEvent,
java.awt.event.MouseWheelListenerpublic boolean isWheelScrollingEnabled()
setWheelScrollingEnabled(boolean)private void writeObject(ObjectOutputStream s) throws IOException
s - the ObjectOutputStream to write
IOExceptionAWTEventMulticaster.save(java.io.ObjectOutputStream, java.lang.String, java.util.EventListener),
Component.containerListenerK,
Container.readObject(java.io.ObjectInputStream)private void readObject(ObjectInputStream s) throws ClassNotFoundException, IOException, HeadlessException
s - the ObjectInputStream to read
ClassNotFoundException
IOException
HeadlessExceptionjava.awt.GraphicsEnvironment#isHeadlesspublic AccessibleContext getAccessibleContext()
getAccessibleContext in interface AccessiblegetAccessibleContext in class Component