Package org.loboevolution.html.renderer
Class BaseBoundableRenderable
java.lang.Object
org.loboevolution.html.renderer.BaseRenderable
org.loboevolution.html.renderer.RRectangle
org.loboevolution.html.renderer.BaseBoundableRenderable
- All Implemented Interfaces:
BoundableRenderable,Renderable
- Direct Known Subclasses:
BaseRCollection,TranslatedRenderable
Author J. H. S.
-
Field Summary
FieldsModifier and TypeFieldDescriptionprotected final RenderableContainerprotected booleanprotected final ModelNodeprotected RCollectionprotected RCollectionprotected static final ColorConstant SELECTION_COLORprotected static final ColorConstant SELECTION_XORFields inherited from interface org.loboevolution.html.renderer.Renderable
EMPTY_ARRAY -
Constructor Summary
ConstructorsConstructorDescriptionBaseBoundableRenderable(RenderableContainer container, ModelNode modelNode) Constructor for BaseBoundableRenderable. -
Method Summary
Modifier and TypeMethodDescriptionbooleancontains(int x, int y) contains.getBlockBackgroundColor.getBounds.getGUIPoint(int clientX, int clientY) getGUIPoint.getModelNode.getOrigin.getOriginalOrCurrentParent.getOriginalParent.getOriginRelativeTo(RCollection ancestor) getOriginRelativeTo.getOriginRelativeToAbs(RCollection ancestor) getOriginRelativeToAbs.getOriginRelativeToNoScroll(RCollection ancestor) getOriginRelativeToNoScroll.getParent.getRenderablePoint(int guiX, int guiY) getRenderablePoint.getSize()getSize.getVisualBounds.intgetVisualHeight.intgetVisualWidth.protected abstract voidinvalidateLayoutLocal.final voidinvalidateLayoutUpTree.booleanisDelegated.booleanisValid()isValid.voidmarkLayoutValid.booleanonDoubleClick(MouseEvent event, int x, int y) onDoubleClick.booleanonMouseClick(MouseEvent event, int x, int y) onMouseClick.booleanonMouseDisarmed(MouseEvent event) onMouseDisarmed.voidonMouseMoved(MouseEvent event, int x, int y, boolean triggerEvent, ModelNode limit) onMouseMoved.voidonMouseOut(MouseEvent event, int x, int y, ModelNode limit) onMouseOut.booleanonMousePressed(MouseEvent event, int x, int y) onMousePressed.booleanonMouseReleased(MouseEvent event, int x, int y) onMouseReleased.voidbooleanonRightClick(MouseEvent event, int x, int y) onRightClick.final voidpaintTranslated.voidrelayout()relayout.voidrelayoutIfValid.voidrepaint()repaint.voidrepaint(int x, int y, int width, int height) repaint.voidsetOriginalParent(RCollection origParent) setOriginalParent.voidsetParent(RCollection parent) setParent.Methods inherited from class org.loboevolution.html.renderer.RRectangle
setBounds, setOriginMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.loboevolution.html.renderer.BoundableRenderable
extractSelectionText, getHeight, getLowestRenderableSpot, getOrdinal, getWidth, getX, getY, getZIndex, isContainedByNode, paintSelection, setBounds, setDelegator, setHeight, setOrdinal, setOrigin, setWidth, setX, setYMethods inherited from interface org.loboevolution.html.renderer.Renderable
findHtmlRenderable, isFixed, paint
-
Field Details
-
SELECTION_COLOR
Constant SELECTION_COLOR -
SELECTION_XOR
Constant SELECTION_XOR -
container
-
layoutUpTreeCanBeInvalidated
protected boolean layoutUpTreeCanBeInvalidated -
modelNode
-
originalParent
-
parent
-
-
Constructor Details
-
BaseBoundableRenderable
Constructor for BaseBoundableRenderable.
- Parameters:
container- aRenderableContainerobject.modelNode- aModelNodeobject.
-
-
Method Details
-
contains
public boolean contains(int x, int y) contains.
- Specified by:
containsin interfaceBoundableRenderable- Parameters:
x- aIntegerobject.y- aIntegerobject.- Returns:
- a boolean.
-
getBlockBackgroundColor
getBlockBackgroundColor.
- Returns:
- a
Colorobject.
-
getBounds
getBounds.
- Specified by:
getBoundsin interfaceBoundableRenderable- Returns:
- a
Rectangleobject.
-
getVisualHeight
public int getVisualHeight()getVisualHeight.
- Specified by:
getVisualHeightin interfaceBoundableRenderable- Returns:
- a
Integerobject.
-
getVisualWidth
public int getVisualWidth()getVisualWidth.
- Specified by:
getVisualWidthin interfaceBoundableRenderable- Returns:
- a
Integerobject.
-
getVisualBounds
getVisualBounds.
- Specified by:
getVisualBoundsin interfaceBoundableRenderable- Returns:
- a
Rectangleobject.
-
getGUIPoint
getGUIPoint.
- Specified by:
getGUIPointin interfaceBoundableRenderable- Parameters:
clientX- aIntegerobject.clientY- aIntegerobject.- Returns:
- a
Pointobject.
-
getModelNode
getModelNode.
- Specified by:
getModelNodein interfaceBoundableRenderable- Specified by:
getModelNodein interfaceRenderable- Returns:
- a
ModelNodeobject.
-
getOrigin
getOrigin.
- Specified by:
getOriginin interfaceBoundableRenderable- Returns:
- a
Pointobject.
-
getOriginalOrCurrentParent
getOriginalOrCurrentParent.
- Specified by:
getOriginalOrCurrentParentin interfaceBoundableRenderable- Returns:
- a
RCollectionobject.
-
getOriginalParent
getOriginalParent.
This is the parent based on the original element hierarchy.- Specified by:
getOriginalParentin interfaceBoundableRenderable- Returns:
- a
RCollectionobject.
-
getOriginRelativeTo
getOriginRelativeTo.
- Specified by:
getOriginRelativeToin interfaceBoundableRenderable- Parameters:
ancestor- aRCollectionobject.- Returns:
- a
Pointobject.
-
getOriginRelativeToNoScroll
getOriginRelativeToNoScroll.
- Specified by:
getOriginRelativeToNoScrollin interfaceBoundableRenderable- Parameters:
ancestor- aRCollectionobject.- Returns:
- a
Pointobject.
-
getOriginRelativeToAbs
getOriginRelativeToAbs.
- Specified by:
getOriginRelativeToAbsin interfaceBoundableRenderable- Parameters:
ancestor- aRCollectionobject.- Returns:
- a
Pointobject.
-
getParent
getParent.
- Specified by:
getParentin interfaceBoundableRenderable- Returns:
- a
RCollectionobject.
-
getRenderablePoint
getRenderablePoint.
- Specified by:
getRenderablePointin interfaceBoundableRenderable- Parameters:
guiX- aIntegerobject.guiY- aIntegerobject.- Returns:
- a
Pointobject.
-
getSize
getSize.
- Specified by:
getSizein interfaceBoundableRenderable- Returns:
- a
Dimensionobject.
-
invalidateLayoutLocal
protected abstract void invalidateLayoutLocal()invalidateLayoutLocal.
-
invalidateLayoutUpTree
public final void invalidateLayoutUpTree()invalidateLayoutUpTree.
Invalidates this Renderable and its parent (i.e. all ancestors).- Specified by:
invalidateLayoutUpTreein interfaceBoundableRenderable
-
isValid
public boolean isValid()isValid.
- Returns:
- a boolean.
-
markLayoutValid
public void markLayoutValid()markLayoutValid.
-
onDoubleClick
onDoubleClick.
- Specified by:
onDoubleClickin interfaceBoundableRenderable- Parameters:
event- aMouseEventobject.x- aIntegerobject.y- aIntegerobject.- Returns:
- a boolean.
-
onMouseClick
onMouseClick.
- Specified by:
onMouseClickin interfaceBoundableRenderable- Parameters:
event- aMouseEventobject.x- aIntegerobject.y- aIntegerobject.- Returns:
- a boolean.
-
onMouseDisarmed
onMouseDisarmed.
- Specified by:
onMouseDisarmedin interfaceBoundableRenderable- Parameters:
event- aMouseEventobject.- Returns:
- a boolean.
-
onMousePressed
onMousePressed.
- Specified by:
onMousePressedin interfaceBoundableRenderable- Parameters:
event- aMouseEventobject.x- aIntegerobject.y- aIntegerobject.- Returns:
- a boolean.
-
onMouseReleased
onMouseReleased.
- Specified by:
onMouseReleasedin interfaceBoundableRenderable- Parameters:
event- aMouseEventobject.x- aIntegerobject.y- aIntegerobject.- Returns:
- a boolean.
-
onRightClick
onRightClick.
- Specified by:
onRightClickin interfaceBoundableRenderable- Parameters:
event- aMouseEventobject.x- aIntegerobject.y- aIntegerobject.- Returns:
- a boolean.
-
onMouseMoved
onMouseMoved.
- Specified by:
onMouseMovedin interfaceBoundableRenderable- Parameters:
event- aMouseEventobject.x- aIntegerobject.y- aIntegerobject.triggerEvent- a boolean.limit- aModelNodeobject.
-
onMouseOut
onMouseOut.
- Specified by:
onMouseOutin interfaceBoundableRenderable- Parameters:
event- aMouseEventobject.x- aIntegerobject.y- aIntegerobject.limit- aModelNodeobject.
-
onMouseScroll
public void onMouseScroll()- Specified by:
onMouseScrollin interfaceBoundableRenderable
-
paintTranslated
paintTranslated.
- Specified by:
paintTranslatedin interfaceBoundableRenderable- Parameters:
g- aGraphicsobject.
-
relayout
public void relayout()relayout.
Invalidates the current Renderable (which invalidates its ancestors) and then requests the top level GUI container to do the layout and repaint. It's safe to call this method outside the GUI thread.- Specified by:
relayoutin interfaceBoundableRenderable
-
relayoutIfValid
public void relayoutIfValid()relayoutIfValid.
-
repaint
public void repaint()repaint.
- Specified by:
repaintin interfaceBoundableRenderable
-
repaint
public void repaint(int x, int y, int width, int height) repaint.
-
setOriginalParent
setOriginalParent.
- Specified by:
setOriginalParentin interfaceBoundableRenderable- Parameters:
origParent- aRCollectionobject.
-
setParent
setParent.
- Specified by:
setParentin interfaceBoundableRenderable- Parameters:
parent- aRCollectionobject.
-
isDelegated
public boolean isDelegated()Description copied from interface:BoundableRenderableisDelegated.
- Specified by:
isDelegatedin interfaceBoundableRenderable- Returns:
- a boolean.
-
getRectangle
- Specified by:
getRectanglein interfaceBoundableRenderable
-