Mtext for MoxyDraw

Creates a multi-line text.


position X
position Y
line spc factor
back color

position X:

Sets the position point X.

position Y:

Sets the position point Y.


Sets the text height.


Optional. Leader text. If omitted, well, there will be no text. Here are some codes:

%%c = Displays the diameter character (Ø).

%%d = Displays the degree character (°).

%%p = Displays the tolerance character, plus-minus (±).

Here are some switches that can be used with dimension text or MTEXT in general:

\L = Starts the underline; \l = Stops the underline. Ex.: {\Lthis is underlined} or \Lthis is underlined\l

\O = Starts the overstrike; \o = Stops the overstrike. Ex.: {\Othis is overstriked} or \Othis is overstriked\o

\K = Starts the strike-through; \k = Stops the strike-through. Ex.: {\Kthis is strike-through} or \Kthis is strike-through\k

\P = New paragraph (new line)

\Q = Obliquing text by angle. Ex.: {\Q30This text is oblique} or \Q30;This one is oblique too

\H = Text height. Ex.: {\H3xThis is 3 times bigger} or \H0.5x;This text is half size

\W = Text width. Ex.: {\W0.5This text is half width} or \W2;This text is twice as wide

\f = Font selection. Ex.: {{\ftimes New Roman|b1|i1;This is Times New Roman} or \fscripts;This is Scripts. Where b is for bold (0 or 1), i is for italic (0 or 1).

\S = Stacking, fractions. Ex.: {\Sa^b;} or {\Sa/b;} or {\Sa#b;}

\T = Spacing between characters. Ex.: {\T1.5this text has 1.5x space between char} or \T3this one has 3x space between char

\~ = Non-wrapping space, hard space.

\ = Escape character. Ex.: \\ = "\", \{ = "{"

Color switches:

\C1 = Text color changes to red. Ex.: {\C1this text is red} or \C1this text is red or \C1; this text is red

\C2 = Text color changes to yellow. Ex.: {\C2this text is yellow} or \C2this text is yellow or \C2; this text is yellow

\C3 = Text color changes to green. Ex.: {\C3this text is green} or \C3this text is green or \C3; this text is green

\C4 = Text color changes to cyan. Ex.: {\C4this text is cyan} or \C4this text is cyan or \C4; this text is cyan

\C5 = Text color changes to blue. Ex.: {\C5this text is blue} or \C5this text is blue or \C5; this text is blue

\C6 = Text color changes to magenta. Ex.: {\C6this text is magenta} or \C6this text is magenta or \C6; this text is magenta

\C7 = Text color changes to white. Ex.: {\C7this text is white} or \C7this text is white or \C7; this text is white

ALL colors can be produced with the \C switch. Look at the below notes for an hint on to get the needed color code.

List example: {\fSymbol|b0|i0;·} item1\P{\fSymbol|b0|i0;·} item2

Simpler list example: 1. item1\P2. item2


• { } Braces - Defines the text area influenced by the code.

• Codes and braces can be nested up to 8 levels deep.

• Many codes can be placed together. Ex.: \L\C1\H2x\T2\fscripts;Your text here

Note that the best way to find the good code for you is to do a Mtext and manipulate its format. Once done, look at the generated code in the AutoCAD properties under text contents. But note that some of the codes from AutoCAD properties may not work...


Optional. Sets the rotation angle. Angles are in degrees and counter-clock wise. If omitted, it will be set to 0.



Optional. Sets text justification. If omitted, it will be set to topLeft. Here are all available justification codes:

topLeft = Top Left (standard)

topCenter = Top Center

topRight = Top Right

middleLeft = Middle Left

middleCenter = Middle Center

middleRight = Middle Right

bottomLeft = Bottom Left

bottomCenter = Bottom Center

bottomRight = Bottom Right


Optional. Sets text width. If omitted, it will be set to 0.

line spc factor:

Optional. Sets line spacing factor. If omitted, it will be set to 1.

back color:

Optional. Fills the background with chosen color. If set to 0 or omitted, Mtext background color will be transparent (background mask will be set to false).

Color can be either an index number (from 1 to 255), its English name (black, blue, cyan, green, magenta, red, white or yellow) or an RGB color (ex: 101,135,77).