Package com.ardor3d.extension.ui.text
Class RenderedText
java.lang.Object
com.ardor3d.scenegraph.Spatial
com.ardor3d.scenegraph.Node
com.ardor3d.extension.ui.text.RenderedText
- All Implemented Interfaces:
Hintable,Renderable,Savable
-
Nested Class Summary
Nested Classes -
Field Summary
FieldsModifier and TypeFieldDescriptionprotected floatprotected Stringprotected booleanprotected floatprotected final RenderedText.RenderedTextDataFields inherited from class com.ardor3d.scenegraph.Spatial
_controllers, _delegateMap, _dirtyMark, _frustumIntersects, _listener, _localTransform, _name, _parent, _queueDistance, _renderStateList, _sceneHints, _userData, _worldBound, _worldTransform, ON_DIRTY_ATTACHED, ON_DIRTY_BOUNDING, ON_DIRTY_RENDERSTATE, ON_DIRTY_TRANSFORM, ON_DIRTY_TRANSFORM_ONLY -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionintattachChild(Spatial child) attachChildattaches a child to this node.intattachChildAt(Spatial child, int index) attachChildAtattaches a child to this node at an index.voiddrawcalls the onDraw method for each child maintained by this node.intfindCaretPosition(int x, int y) findCaretTranslation(int caretPosition, Vector2 store) getData()floatintgetLineHeight(int caretPosition) getText()floatgetWidth()booleanisStyled()voidRender the object using the supplied renderer instance.voidsetHeight(float height) voidsetParsedStyleSpans(Collection<StyleSpan> spans) voidsetPlainText(String text) voidsetStyled(boolean styled) voidsetWidth(float width) voidsetWorldTransform(ReadOnlyTransform transform) Sets the world transform.voidupdateWorldBound(boolean recurse) updateWorldBoundmerges the bounds of all the children maintained by this node.Methods inherited from class com.ardor3d.scenegraph.Node
acceptVisitor, detachAllChildren, detachChild, detachChildAt, detachChildNamed, getChild, getChild, getChildIndex, getChildren, getClassTag, getNumberOfChildren, hasChild, makeCopy, makeInstanced, propagateDirtyDown, read, sortLights, swapChildren, updateChildren, updateWorldRenderStates, updateWorldTransform, writeMethods inherited from class com.ardor3d.scenegraph.Spatial
addController, addTranslation, addTranslation, applyWorldRenderStates, clearControllers, clearDirty, clearDirty, clearRenderState, getController, getControllerCount, getControllers, getCurrentRenderDelegate, getLastFrustumIntersection, getListener, getLocalLastFrustumIntersection, getLocalRenderState, getLocalRenderStates, getName, getParent, getParentHintable, getRenderDelegate, getRotation, getScale, getSceneHints, getTransform, getTranslation, getUserData, getWorldBound, getWorldRotation, getWorldScale, getWorldTransform, getWorldTranslation, hasAncestor, isDirty, localToWorld, markDirty, markDirty, onDraw, propagateBoundToRoot, propagateDirtyUp, propagateStatesFromRoot, propageEventUp, removeController, removeController, removeFromParent, setLastFrustumIntersection, setListener, setName, setParent, setRenderDelegate, setRenderState, setRotation, setRotation, setScale, setScale, setScale, setTransform, setTranslation, setTranslation, setUserData, setWorldRotation, setWorldRotation, setWorldScale, setWorldScale, setWorldScale, setWorldTranslation, setWorldTranslation, toString, updateControllers, updateGeometricState, updateGeometricState, updateWorldRenderStates, worldToLocal
-
Field Details
-
_plainText
-
_parsedStyles
-
_width
protected float _width -
_height
protected float _height -
data
-
_styled
protected boolean _styled
-
-
Constructor Details
-
RenderedText
public RenderedText()
-
-
Method Details
-
getText
-
setPlainText
-
getPlainText
-
setHeight
public void setHeight(float height) -
getHeight
public float getHeight() -
setWidth
public void setWidth(float width) -
getWidth
public float getWidth() -
getParsedStyleSpans
-
setParsedStyleSpans
-
attachChild
Description copied from class:NodeattachChildattaches a child to this node. This node becomes the child's parent. The current number of children maintained is returned.
If the child already had a parent it is detached from that former parent.- Overrides:
attachChildin classNode- Parameters:
child- the child to attach to this node.- Returns:
- the number of children maintained by this node.
-
attachChildAt
Description copied from class:NodeattachChildAtattaches a child to this node at an index. This node becomes the child's parent. The current number of children maintained is returned.
If the child already had a parent it is detached from that former parent.- Overrides:
attachChildAtin classNode- Parameters:
child- the child to attach to this node.index- the index of the child to be attached.- Returns:
- the number of children maintained by this node.
-
draw
Description copied from class:Nodedrawcalls the onDraw method for each child maintained by this node. -
updateWorldBound
public void updateWorldBound(boolean recurse) Description copied from class:NodeupdateWorldBoundmerges the bounds of all the children maintained by this node. This will allow for faster culling operations.- Overrides:
updateWorldBoundin classNode- Parameters:
recurse- true to recurse down the scenegraph tree- See Also:
-
render
Description copied from interface:RenderableRender the object using the supplied renderer instance.- Specified by:
renderin interfaceRenderable- Parameters:
renderer- the renderer
-
setWorldTransform
Description copied from class:SpatialSets the world transform.- Overrides:
setWorldTransformin classSpatial- Parameters:
transform- the new world transform
-
getData
-
findCaretTranslation
-
findCaretPosition
public int findCaretPosition(int x, int y) -
getLineHeight
public int getLineHeight(int caretPosition) -
setStyled
public void setStyled(boolean styled) -
isStyled
public boolean isStyled()
-