public class RootPanel extends JPanel implements Scrollable, UserInterface, FSCanvas, RepaintListener
JPanel.AccessibleJPanelJComponent.AccessibleJComponentContainer.AccessibleAWTContainerComponent.AccessibleAWTComponent, Component.BaselineResizeBehavior, Component.BltBufferStrategy, Component.FlipBufferStrategy| Modifier and Type | Field and Description |
|---|---|
Element |
active_element |
protected Document |
doc |
Element |
focus_element |
Element |
hovered_element |
protected SharedContext |
sharedContext |
listenerList, TOOL_TIP_TEXT_KEY, ui, UNDEFINED_CONDITION, WHEN_ANCESTOR_OF_FOCUSED_COMPONENT, WHEN_FOCUSED, WHEN_IN_FOCUSED_WINDOWaccessibleContext, BOTTOM_ALIGNMENT, CENTER_ALIGNMENT, LEFT_ALIGNMENT, RIGHT_ALIGNMENT, TOP_ALIGNMENTABORT, ALLBITS, ERROR, FRAMEBITS, HEIGHT, PROPERTIES, SOMEBITS, WIDTH| Constructor and Description |
|---|
RootPanel() |
| Modifier and Type | Method and Description |
|---|---|
void |
addDocumentListener(DocumentListener listener)
Adds the specified Document listener to receive Document events from this
component.
|
void |
addNotify()
Overrides the default implementation to test for and configure any
JScrollPane parent. |
void |
doDocumentLayout(Graphics g) |
void |
doLayout() |
Box |
find(int x,
int y) |
Box |
find(MouseEvent e) |
protected void |
fireDocumentLoaded() |
protected void |
fireDocumentStarted() |
protected void |
fireOnLayoutException(Throwable t) |
protected void |
fireOnRenderException(Throwable t) |
CellRendererPane |
getCellRendererPane() |
protected JScrollPane |
getEnclosingScrollPane() |
Rectangle |
getFixedRectangle()
Gets the fixedRectangle attribute of the BasicPanel object
|
LayoutContext |
getLayoutContext() |
double |
getLayoutWidth() |
Dimension |
getPreferredScrollableViewportSize() |
Box |
getRootBox() |
Layer |
getRootLayer() |
Rectangle |
getScreenExtents() |
int |
getScrollableBlockIncrement(Rectangle visibleRect,
int orientation,
int direction) |
boolean |
getScrollableTracksViewportHeight() |
boolean |
getScrollableTracksViewportWidth() |
int |
getScrollableUnitIncrement(Rectangle visibleRect,
int orientation,
int direction) |
SharedContext |
getSharedContext() |
protected boolean |
hasDocumentListeners() |
protected void |
init() |
boolean |
isActive(Element e)
Gets the active attribute of the UserInterface object
|
boolean |
isDefaultFontFromComponent() |
protected boolean |
isExtentsHaveChanged() |
boolean |
isFocus(Element e)
Gets the focus attribute of the UserInterface object
|
boolean |
isHover(Element e)
Gets the hover attribute of the UserInterface object
|
protected boolean |
isNeedRelayout() |
boolean |
isPrintView() |
protected LayoutContext |
newLayoutContext(Graphics2D g) |
RenderingContext |
newRenderingContext(Graphics2D g) |
protected void |
relayout() |
void |
removeDocumentListener(DocumentListener listener)
Removes the specified Document listener from receive Document events from this
component.
|
void |
removeNotify()
Overrides the default implementation unconfigure any
JScrollPane
parent. |
void |
repaintRequested(boolean doLayout) |
void |
resetScrollPosition() |
void |
setDefaultFontFromComponent(boolean defaultFontFromComponent) |
void |
setDocument(Document doc,
String url,
NamespaceHandler nsh) |
protected void |
setEnclosingScrollPane(JScrollPane scrollPane)
The method is invoked by
addNotify() and removeNotify() to
ensure that any enclosing JScrollPane works correctly with this
panel. |
protected void |
setNeedRelayout(boolean needRelayout) |
void |
setRootBox(Box rootBox) |
void |
validate() |
getAccessibleContext, getUI, getUIClassID, paramString, setUI, updateUIaddAncestorListener, addVetoableChangeListener, computeVisibleRect, contains, createToolTip, disable, enable, firePropertyChange, firePropertyChange, firePropertyChange, fireVetoableChange, getActionForKeyStroke, getActionMap, getAlignmentX, getAlignmentY, getAncestorListeners, getAutoscrolls, getBaseline, getBaselineResizeBehavior, getBorder, getBounds, getClientProperty, getComponentGraphics, getComponentPopupMenu, getConditionForKeyStroke, getDebugGraphicsOptions, getDefaultLocale, getFontMetrics, getGraphics, getHeight, getInheritsPopupMenu, getInputMap, getInputMap, getInputVerifier, getInsets, getInsets, getListeners, getLocation, getMaximumSize, getMinimumSize, getNextFocusableComponent, getPopupLocation, getPreferredSize, getRegisteredKeyStrokes, getRootPane, getSize, getToolTipLocation, getToolTipText, getToolTipText, getTopLevelAncestor, getTransferHandler, getVerifyInputWhenFocusTarget, getVetoableChangeListeners, getVisibleRect, getWidth, getX, getY, grabFocus, hide, isDoubleBuffered, isLightweightComponent, isManagingFocus, isOpaque, isOptimizedDrawingEnabled, isPaintingForPrint, isPaintingOrigin, isPaintingTile, isRequestFocusEnabled, isValidateRoot, paint, paintBorder, paintChildren, paintComponent, paintImmediately, paintImmediately, print, printAll, printBorder, printChildren, printComponent, processComponentKeyEvent, processKeyBinding, processKeyEvent, processMouseEvent, processMouseMotionEvent, putClientProperty, registerKeyboardAction, registerKeyboardAction, removeAncestorListener, removeVetoableChangeListener, repaint, repaint, requestDefaultFocus, requestFocus, requestFocus, requestFocusInWindow, requestFocusInWindow, resetKeyboardActions, reshape, revalidate, scrollRectToVisible, setActionMap, setAlignmentX, setAlignmentY, setAutoscrolls, setBackground, setBorder, setComponentPopupMenu, setDebugGraphicsOptions, setDefaultLocale, setDoubleBuffered, setEnabled, setFocusTraversalKeys, setFont, setForeground, setInheritsPopupMenu, setInputMap, setInputVerifier, setMaximumSize, setMinimumSize, setNextFocusableComponent, setOpaque, setPreferredSize, setRequestFocusEnabled, setToolTipText, setTransferHandler, setUI, setVerifyInputWhenFocusTarget, setVisible, unregisterKeyboardAction, updateadd, add, add, add, add, addContainerListener, addImpl, addPropertyChangeListener, addPropertyChangeListener, applyComponentOrientation, areFocusTraversalKeysSet, countComponents, deliverEvent, findComponentAt, findComponentAt, getComponent, getComponentAt, getComponentAt, getComponentCount, getComponents, getComponentZOrder, getContainerListeners, getFocusTraversalKeys, getFocusTraversalPolicy, getLayout, getMousePosition, insets, invalidate, isAncestorOf, isFocusCycleRoot, isFocusCycleRoot, isFocusTraversalPolicyProvider, isFocusTraversalPolicySet, layout, list, list, locate, minimumSize, paintComponents, preferredSize, printComponents, processContainerEvent, processEvent, remove, remove, removeAll, removeContainerListener, setComponentZOrder, setFocusCycleRoot, setFocusTraversalPolicy, setFocusTraversalPolicyProvider, setLayout, transferFocusDownCycle, validateTreeaction, add, addComponentListener, addFocusListener, addHierarchyBoundsListener, addHierarchyListener, addInputMethodListener, addKeyListener, addMouseListener, addMouseMotionListener, addMouseWheelListener, bounds, checkImage, checkImage, coalesceEvents, contains, createImage, createImage, createVolatileImage, createVolatileImage, disableEvents, dispatchEvent, enable, enableEvents, enableInputMethods, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, firePropertyChange, getBackground, getBounds, getColorModel, getComponentListeners, getComponentOrientation, getCursor, getDropTarget, getFocusCycleRootAncestor, getFocusListeners, getFocusTraversalKeysEnabled, getFont, getForeground, getGraphicsConfiguration, getHierarchyBoundsListeners, getHierarchyListeners, getIgnoreRepaint, getInputContext, getInputMethodListeners, getInputMethodRequests, getKeyListeners, getLocale, getLocation, getLocationOnScreen, getMouseListeners, getMouseMotionListeners, getMousePosition, getMouseWheelListeners, getName, getParent, getPeer, getPropertyChangeListeners, getPropertyChangeListeners, getSize, getToolkit, getTreeLock, gotFocus, handleEvent, hasFocus, imageUpdate, inside, isBackgroundSet, isCursorSet, isDisplayable, isEnabled, isFocusable, isFocusOwner, isFocusTraversable, isFontSet, isForegroundSet, isLightweight, isMaximumSizeSet, isMinimumSizeSet, isPreferredSizeSet, isShowing, isValid, isVisible, keyDown, keyUp, list, list, list, location, lostFocus, mouseDown, mouseDrag, mouseEnter, mouseExit, mouseMove, mouseUp, move, nextFocus, paintAll, postEvent, prepareImage, prepareImage, processComponentEvent, processFocusEvent, processHierarchyBoundsEvent, processHierarchyEvent, processInputMethodEvent, processMouseWheelEvent, remove, removeComponentListener, removeFocusListener, removeHierarchyBoundsListener, removeHierarchyListener, removeInputMethodListener, removeKeyListener, removeMouseListener, removeMouseMotionListener, removeMouseWheelListener, removePropertyChangeListener, removePropertyChangeListener, repaint, repaint, repaint, resize, resize, setBounds, setBounds, setComponentOrientation, setCursor, setDropTarget, setFocusable, setFocusTraversalKeysEnabled, setIgnoreRepaint, setLocale, setLocation, setLocation, setName, setSize, setSize, show, show, size, toString, transferFocus, transferFocusBackward, transferFocusUpCycleprotected SharedContext sharedContext
protected Document doc
public Element hovered_element
public Element active_element
public Element focus_element
public SharedContext getSharedContext()
public LayoutContext getLayoutContext()
public void setDocument(Document doc, String url, NamespaceHandler nsh)
public void resetScrollPosition()
protected void setEnclosingScrollPane(JScrollPane scrollPane)
addNotify() and removeNotify() to
ensure that any enclosing JScrollPane works correctly with this
panel. This method can be safely invoked with a null scrollPane.scrollPane - the enclosing JScrollPane or null if
the panel is no longer enclosed in a JScrollPane.protected JScrollPane getEnclosingScrollPane()
public Rectangle getFixedRectangle()
getFixedRectangle in interface FSCanvaspublic void addNotify()
JScrollPane parent.addNotify in class JComponentpublic void removeNotify()
JScrollPane
parent.removeNotify in class JComponentprotected void init()
public RenderingContext newRenderingContext(Graphics2D g)
protected LayoutContext newLayoutContext(Graphics2D g)
public Rectangle getScreenExtents()
public void doDocumentLayout(Graphics g)
public void addDocumentListener(DocumentListener listener)
listener - Contains the DocumentListener for DocumentEvent data.public void removeDocumentListener(DocumentListener listener)
listener - Contains the DocumentListener to remove.protected boolean hasDocumentListeners()
protected void fireDocumentStarted()
protected void fireDocumentLoaded()
protected void fireOnLayoutException(Throwable t)
protected void fireOnRenderException(Throwable t)
public CellRendererPane getCellRendererPane()
public boolean isHover(Element e)
UserInterfaceisHover in interface UserInterfacee - PARAMpublic boolean isActive(Element e)
UserInterfaceisActive in interface UserInterfacee - PARAMpublic boolean isFocus(Element e)
UserInterfaceisFocus in interface UserInterfacee - PARAMprotected void relayout()
public double getLayoutWidth()
public boolean isPrintView()
public Box getRootBox()
public void setRootBox(Box rootBox)
public Layer getRootLayer()
public Box find(MouseEvent e)
public Box find(int x, int y)
protected boolean isExtentsHaveChanged()
protected boolean isNeedRelayout()
protected void setNeedRelayout(boolean needRelayout)
public void repaintRequested(boolean doLayout)
repaintRequested in interface RepaintListenerpublic boolean isDefaultFontFromComponent()
public void setDefaultFontFromComponent(boolean defaultFontFromComponent)
public Dimension getPreferredScrollableViewportSize()
getPreferredScrollableViewportSize in interface Scrollablepublic int getScrollableUnitIncrement(Rectangle visibleRect, int orientation, int direction)
getScrollableUnitIncrement in interface Scrollablepublic int getScrollableBlockIncrement(Rectangle visibleRect, int orientation, int direction)
getScrollableBlockIncrement in interface Scrollablepublic boolean getScrollableTracksViewportWidth()
getScrollableTracksViewportWidth in interface Scrollablepublic boolean getScrollableTracksViewportHeight()
getScrollableTracksViewportHeight in interface ScrollableCopyright © 2018. All rights reserved.