Package org.jzy3d.plot3d.text.drawable
Class DrawableTextWrapper
java.lang.Object
org.jzy3d.plot3d.primitives.Drawable
org.jzy3d.plot3d.text.drawable.DrawableTextWrapper
- All Implemented Interfaces:
IGLRenderer,ISortableDraw
- Direct Known Subclasses:
DrawableText,DrawableTextBillboard
A
DrawableTextWrapper wraps any text rendered by an ITextRenderer into an
Drawable, meaning it can be injected in the scene graph, and be transformed.- Author:
- Martin Pernollet
-
Field Summary
FieldsModifier and TypeFieldDescriptionprotected AxisLayoutprotected Colorprotected Fontprotected booleanprotected Horizontalprotected Pointprotected booleanprotected Coord3dprotected ITextRendererprotected floatprotected Coord3dprotected Coord2dprotected Stringprotected VerticalFields inherited from class org.jzy3d.plot3d.primitives.Drawable
bbox, boundingBoxColor, boundingBoxDisplayed, displayed, hasListeners, legend, legendDisplayed, listeners, spaceTransformer, transform, transformBefore -
Constructor Summary
ConstructorsConstructorDescriptionDrawableTextWrapper(String txt, Coord3d position, Color color, ITextRenderer renderer) DrawableTextWrapper(ITextRenderer renderer) -
Method Summary
Modifier and TypeMethodDescriptionvoidapplyGeometryTransform(Transform transform) voidvoidCall OpenGL2 routines for rendering the object.flipHorizontalAlignIfEnabled(IPainter painter) Return the BoundingBox of this object.getPoint()floatgetText()booleanbooleanvoidsetAxisLayout(AxisLayout axisLayout) The axis layout acts as main font provider, to allow all text renderer to use the same current font than the one selected for axis and colorbar texts.voidvoidsetDefaultFont(Font defaultFont) voidsetFlipHorizontalAlignWithViewpoint(boolean flipHorizontalAlignWithViewpoint) voidsetHalign(Horizontal halign) voidsetPointDisplayed(boolean pointDisplayed) voidsetPosition(Coord3d position) voidsetRotation(float rotation) voidsetSceneOffset(Coord3d sceneOffset) voidsetScreenOffset(Coord2d screenOffset) voidvoidtoString()voidMethods inherited from class org.jzy3d.plot3d.primitives.Drawable
addDrawableListener, asWireframeable, dispose, doDrawBoundsIfDisplayed, doTransform, fireDrawableChanged, fireDrawableChanged, getBarycentre, getBoundingBoxColor, getDistance, getLegend, getLongestDistance, getShortestDistance, getSpaceTransformer, getTransform, getTransformBefore, hasLegend, isBoundingBoxDisplayed, isDisplayed, isLegendDisplayed, removeDrawableListener, setBoundingBoxColor, setBoundingBoxDisplayed, setDisplayed, setLegend, setLegendDisplayed, setSpaceTransformer, setTransform, setTransformBefore, toString
-
Field Details
-
txt
-
position
-
halign
-
valign
-
color
-
screenOffset
-
sceneOffset
-
rotation
protected float rotation -
renderer
-
axisLayout
-
defaultFont
-
pointDisplayed
protected boolean pointDisplayed -
point
-
flipHorizontalAlignWithViewpoint
protected boolean flipHorizontalAlignWithViewpoint
-
-
Constructor Details
-
DrawableTextWrapper
-
DrawableTextWrapper
-
-
Method Details
-
draw
Description copied from class:DrawableCall OpenGL2 routines for rendering the object.- Specified by:
drawin interfaceIGLRenderer- Specified by:
drawin classDrawable
-
flipHorizontalAlignIfEnabled
-
getBounds
Description copied from class:DrawableReturn the BoundingBox of this object. -
configure
-
getText
-
setText
-
setPosition
-
getPosition
-
setColor
-
isFlipHorizontalAlignWithViewpoint
public boolean isFlipHorizontalAlignWithViewpoint() -
setFlipHorizontalAlignWithViewpoint
public void setFlipHorizontalAlignWithViewpoint(boolean flipHorizontalAlignWithViewpoint) -
getHalign
-
setHalign
-
getValign
-
setValign
-
getScreenOffset
-
setScreenOffset
-
getSceneOffset
-
setSceneOffset
-
getRotation
public float getRotation() -
setRotation
public void setRotation(float rotation) -
getAxisLayout
-
setAxisLayout
The axis layout acts as main font provider, to allow all text renderer to use the same current font than the one selected for axis and colorbar texts. To for this drawable text to use a given font, set this to null and configuresetDefaultFont(Font) -
getDefaultFont
-
setDefaultFont
-
getPoint
-
isPointDisplayed
public boolean isPointDisplayed() -
setPointDisplayed
public void setPointDisplayed(boolean pointDisplayed) -
toString
-
applyGeometryTransform
- Specified by:
applyGeometryTransformin classDrawable
-
updateBounds
public void updateBounds()- Specified by:
updateBoundsin classDrawable
-