Forum dedicated to drawing translation issues.

Moderator: David A. Giesselman

#60701 by Mark F. Madura
Fri Jun 14, 2013 10:33 am
Mike Smith was asking us about MText formatting and if it was possible to adjust the aspect to create wider text.

Though it's not readily apparent, it is possible to use RTF (Rich Text Formatting) codes to customize the display of individual characters or words in MText entities.

After you've placed the text. Use the MText Entity Properties Editor and select Format RTF... to bring up a text editing dialog.

Enter the formatting codes as shown below to modify text. (I've also attached a sample drawing you can download.)

Note: These same formatting codes are also supported by AutoCAD's MText entity.

Code: Select allCode:       | Purpose:                                              | Example:
\0...\o     | Turns overline on/off                                 | {\ODataCAD\o}
\L...\l     | Turns underline on/off                                | {\LDataCAD\l}
\~          | Inserts nonbreaking space                             | {DataCAD\~LT}
\\          | Inserts backslash                                     | {\\DataCAD}
\{...\}     | Inserts opening and closing brace                     | {\{DataCAD\}}
\Cvalue;    | Changes to the specified color                        | {\C2;DataCAD}
\File name; | Changes to the specified font file                    | {\Ftimes; DataCAD}
\Hvalue;    | Changes to the text height in drawing units           | {\H2;DataCAD}
\Hvaluex;   | Changes text height to multiple of current height     | {\H3x;DataCAD}
\S...^...;  | Stacks subsequent text at the \, #, or ^ symbol       | {1.000\S+0.010^-0.000;}
\Tvalue;    | Adjusts the space between characters (.75 to 4 times) | {\T2;DataCAD}
\Qangle;    | Changes obliquing angle                               | {\Q20;DataCAD}
\Wvalue;    | Changes width factor                                  | {\W2;DataCAD}
\Avalue;    | Sets the alignment (0=bottom,1=center, 2=top)         | {\A1;1 \S1/2;}
\P          | Ends paragraph                                        | \PDataCAD

Select Format RTF... from the MText Entity Properties Dialog.
RTF_Editor.png (29.57 KiB) Viewed 7663 times

RTF Formatting Sample Output
RTF.jpg (143.59 KiB) Viewed 7663 times
Sample DataCAD drawing with RTF-formatted MText example.
(8.46 KiB) Downloaded 448 times

Who is online

Users browsing this forum: No registered users and 2 guests

About DataCAD Forum

The DataCAD Forum is a FREE online community we provide to enhance your experience with DataCAD.

We hope you'll visit often to get answers, share ideas, and interact with other DataCAD users around the world.


Software for AEC Professionals Since 1984