table of contents
other sections
SoText3(3IV)() | SoText3(3IV)() |
NAME¶
SoText3 — 3D text shape nodeINHERITS FROM¶
SoBase > SoFieldContainer > SoNode > SoShape > SoText3SYNOPSIS¶
#include <Inventor/nodes/SoText3.h>enum Justification {
SoText3::LEFT Left edges of all strings are aligned
SoText3::RIGHT Right edges of all strings are aligned
SoText3::CENTER Centers of all strings are aligned
}
enum Part {
SoText3::FRONT Front faces of characters
SoText3::SIDES Extruded sides of characters
SoText3::BACK Back faces of characters
SoText3::ALL All parts
}
Fields from class SoText3:
SoMFString string
SoSFFloat spacing
SoSFBitMask parts
SoSFEnum justification
Methods from class SoText3:
SoText3()
static SoType getClassTypeId()
Methods from class SoNode:
void setOverride(SbBool state)
SbBool isOverride() const
SoNode * copy(SbBool copyConnections = FALSE) const
virtual SbBool affectsState() const
static SoNode * getByName(const SbName &name)
static int getByName(const SbName &name, SoNodeList &list)
Methods from class SoFieldContainer:
void setToDefaults()
SbBool hasDefaultValues() const
SbBool fieldsAreEqual(const SoFieldContainer *fc) const
void copyFieldValues(const SoFieldContainer *fc, SbBool copyConnections = FALSE)
SbBool set(const char *fieldDataString)
void get(SbString &fieldDataString)
virtual int getFields(SoFieldList &resultList) const
virtual SoField * getField(const SbName &fieldName) const
SbBool getFieldName(const SoField *field, SbName &fieldName) const
SbBool isNotifyEnabled() const
SbBool enableNotify(SbBool flag)
Methods from class SoBase:
void ref()
void unref() const
void unrefNoDelete() const
void touch()
virtual SoType getTypeId() const
SbBool isOfType(SoType type) const
virtual void setName(const SbName &name)
virtual SbName getName() const
DESCRIPTION¶
This node defines one or more strings of 3D text. In contrast with SoText2, 3D text can be rotated, scaled, lighted, and textured, just like all other 3D shapes. Each character in a 3D text string is created by extruding an outlined version of the character (in the current typeface) along the current profile, as defined by nodes derived from SoProfile. The default text profile, if none is specified, is a straight line segment one unit long.FIELDS¶
SoMFString string
The text string(s) to display. Each string will appear on its own line. The string(s) can be ascii or UTF-8.
SoSFFloat spacing
Defines the distance (in the negative y direction) between the base points of successive strings, measured with respect to the current font height. A value of 1 indicates single spacing, a value of 2 indicates double spacing, and so on.
SoSFBitMask parts
Which parts of text are visible. Note that, for speed, the default for this field is FRONT only.
SoSFEnum justification
Indicates placement and alignment of strings. With LEFT justification, the left edge of the first line is at the (transformed) origin, and all left edges are aligned. RIGHT justification is similar. CENTER justification places the center of the first string at the (transformed) origin, with the centers of all remaining strings aligned under it.
METHODS¶
SoText3()
Creates a 3D text node with default settings.
static SoType getClassTypeId()
Returns type identifier for this class.
ACTION BEHAVIOR¶
SoGLRenderActionDraws text based on the current font, profiles, transformation, drawing style, material, texture, complexity, and so on.
SoRayPickAction
Performs a pick on the text. The string index and character position are available from the SoTextDetail.
SoGetBoundingBoxAction
Computes the bounding box that encloses the text.
SoCallbackAction
If any triangle callbacks are registered with the action, they will be invoked for each successive triangle used to approximate the text geometry.
FILE FORMAT/DEFAULTS¶
Text3 {
string "" spacing 1 justification LEFT parts FRONT
}