Text (single-line) Home

Text conveys important information in your drawing. You use text for title blocks, to label parts of the drawing, to give specifications, or to make annotations. New text entities are created with the current Text style.

To add a text into a drawing use the following functions:

Function Meaning
lcBlockAddText By text and position
lcBlockAddText2 By text, position, alignment, height, width scale, rotation, oblique
lcBlockAddText3 By text and start-end position

A text has properties and functions derived from base class and the following specific properties:

Property Type Access Meaning
LC_PROP_ENT_...    Base class properties
RW Handle to Text style
Name of Text style
LC_PROP_TEXT_STR string RW Text content (See formatting codes)
LC_PROP_TEXT_LEN int R Number of characters in the text string
LC_PROP_TEXT_ALIGN int RW Alignment type
LC_PROP_TEXT_X float RW Insertion point X
LC_PROP_TEXT_Y float RW Insertion point Y
LC_PROP_TEXT_H float RW Height. If 0 - LC_PROP_TSTYLE_HEIGHT value will be used
LC_PROP_TEXT_WSCALE float RW Width factor (horisontal scale). If 0 - LC_PROP_TSTYLE_WSCALE value will be used
LC_PROP_TEXT_ANGLE float RW Rotation angle
LC_PROP_TEXT_OBLIQUE float RW Oblique angle. If 0 - LC_PROP_TSTYLE_OBLIQUE value will be used
LC_PROP_TEXT_CHARSPACE float RW Relative distance between characters (0.0 - 3.0)
LC_PROP_TEXT_WRECT float R Width of a text bounding rectange
LC_PROP_TEXT_X0 float R X coordinate of left-bottom corner
LC_PROP_TEXT_Y0 float R Y coordinate of left-bottom corner
LC_PROP_TEXT_XFIT float RW X coordinate of end point for alignment LC_TA_ALIGNED or LC_TA_FIT
LC_PROP_TEXT_YFIT float RW Y coordinate of end point for alignment LC_TA_ALIGNED or LC_TA_FIT
LC_PROP_TEXT_UPDOWN bool RW "Upside-down text" flag
LC_PROP_TEXT_BACKWARD bool RW "Backward text" flag


0 - insertion point (the grip's position depends on text alignment)
1 - rotation
2, 4, 6, 8 - text size (height)
3, 7 - width scale (height is not changed)
5, 9 - height and width scale (text width is not changed)

For alignment types LC_TA_ALIGNED and LC_TA_FIT :

0 - start point (= insertion point)
1 - end point

See also

   Code sample,   Multiline text,   Arc text,   Retrieve objects