Define a single Graphics Display Kit text string
group TextAttribs {
int align_horiz;
int align_vert;
int drop_shadow;
int background;
int bounds;
int underline;
int lead_line;
int radial;
int do_offset;
float offset[3];
};
group Stroke
TextAttribs {
int font_type;
int style;
int plane;
int orient;
int path
int space_mode;
float spacing;
float angle;
float height;
int expansion;
float width;
};
TextAttribs Text_NoXform {
string str;
int nspace;
float position[nspace];
int stroke = 0;
StrokeTextAttribs StrokeTextAttribs;
};
Text_NoXform+Xform Text; {
float+write min_vec[nspace];
float+write max_vec[nspace};
};
These templates define a Graphics Display Kit text string. TextAttribs and StrokeTextAttribs define the set of attributes that apply to text that is rendered in the Graphics Display Kit. Text_NoXform adds the string and the position of the string. Text adds a transformation and extents vectors. Text is what is normally instanced and used as the data that is connected to a Graphics Display Kit object to be rendered.
A string. Contains the string to be rendered.
This parameter controls the horizontal alignment of the text string.
|
|
|
This parameter controls the vertical alignment of the text string.
|
|
|
This parameter is a boolean that controls if a drop shadow is rendered: 0 means no; 1 means yes.
This parameter is a boolean that controls if a background is rendered with the view's background color: 0 means no; 1 means yes.
This parameter is a boolean that controls if a bounding box is rendered around the text string: 0 means no; 1 means yes.
This parameter is a boolean that controls if the text string is underlined: 0 means no; 1 means yes.
This parameter is a boolean that controls if a line is rendered from the text position to the position where the text is actually rendered: 0 means no; 1 means yes. The position that the text is rendered at is the text position plus the offset if it is enabled.
This parameter is a boolean that causes automatic text alignment and offset away from the center of the view: 0 means no; 1 means yes.
If radial is set, the align_horiz parameter is overriden. Alignment then works in the following manner. If the text X position is to the left of center, the text string is right aligned. If the text X position is to the right of center, the text string is left aligned.
The offset is used when the do_offset parameter is set but it is used in a different manner. The radius of the offset is used to position the text away from the center. In the upper right quadrant, this is towards the upper right. In the lower right quadrant, this is towards the lower right. In the upper left quadrant, this is towards the upper left. In the lower left quadrant, this is towards the lower left.
This parameter is a boolean that controls if the offset is to be added to the text position prior to rendering: 0 means no; 1 means yes.
This parameter is an NDC offset that is added to the text position prior to rendering. The do_offset parameter controls whether the offset is used.
This parameter controls the dimensionality of the text position. Valid values are 2 or 3.
This parameter is a vector of length nspace that contains the position at which to render the text string.
Parameters
(for stroke text only)
This controls the type of font displayed. Possible options are:
Used in conjunction with the orient and angle subobjects, this parameter specifies the transformation for the character string. Valid values are:
|
|
|
Used in conjunction with the plane and angle subobjects, specifies the transformation for the character string. Valid values are:
|
|
|
This parameter specifies the angle of rotation on the specified plane for arbitrary orientation. Valid values are between -180.00 and 180.00.
This parameter specifies the direction of the text path. Valid values are:
|
|
|
This parameter specifies fixed or proportional spacing. Valid values are 0 for fixed spacing and 1 for proportional spacing. Default character spacing is set to 0.0.
This parameter modifies the default character spacing. Specifying a value greater than 0.0 increases the spacing between characters.
This parameter specifies the height of the character; the default character height is 1.0. It is used as a scale factor for both the height and width of the character.
This parameter specifies the width of the character. The default value is 1.0. Values less than 1.0 will make the characters narrower; values greater than 1.0 make the characters wider.
A DefaultXform. The transformation to be applied to the text position.
Libraries.Visualization.Geometries.TextString
Libraries.Visualization.Geometries.TextString3D