TextString Class
A single line of text, all with the same font, styles (underline, bold, italic), and size. This class also holds the origin and direction for the text. A paragraph is composed of one or more instances of TextStrings.
Methods
| Name | Description | |
|---|---|---|
| constructor(props: TextStringProps): TextString | ||
| toJSON(): TextStringProps | ||
| transformInPlace(transform: Transform): boolean |
Properties
| Name | Type | Description | |
|---|---|---|---|
| bold | boolean | undefined | bold text. | |
| font | number | FontId for this TextString. | |
| height | number | ||
| italic | boolean | undefined | italic text. | |
| origin Readonly | Point3d | position relative to element's placement | |
| rotation Readonly | YawPitchRollAngles | Rotation relative to element's placement | |
| text | string | Text string | |
| underline | boolean | undefined | underline text. | |
| width Accessor ReadOnly | number | ||
| widthFactor | number | undefined |
Defined in
Last Updated: 29 October, 2025
Found something wrong, missing, or unclear on this page? Raise an issue in our repo.