Objects
objects/ mleader/ style
#include "dxfio/objects/mleader/style.hpp"In DxfIO::Objects::Mleader
struct LeaderLEADER
How the leader lines of a multileader style are drawn.
| Field | Type and default | Meaning |
|---|---|---|
Order | int | Which end of a leader is drawn first: 0 the head, 1 the tail. Group 172. |
Points | int{2} | The most points a leader line has. Group 90. |
First | double | The angle the first segment snaps to; 0 for any. Group 40. |
Second | double | The angle the second segment snaps to; 0 for any. Group 41. |
Type | int{1} | The kind of line: 0 invisible, 1 straight, 2 spline. Group 173. |
Color | int{PackedByblock} | The color of the lines, packed into one integer as AutoCAD does. Group 91. |
Linetype | Handle | The linetype of the lines. Group 340. |
Lineweight | int{Lineweights::Byblock} | The lineweight in hundredths of a millimeter, or -1 ByLayer, -2 ByBlock, -3 the default. Group 92. |
Landing | bool{true} | Whether the leader lands on the content. Group 290. |
Gap | double{Margin} | The gap between the landing and the content. Group 42. |
Dogleg | bool{true} | Whether the leader ends in a horizontal dogleg. Group 291. |
Length | double{Reach} | The length of the dogleg. Group 43. |
Arrow | Handle | The block record of the arrowhead; none for the closed filled arrow. Group 341. |
Size | double{Mleader::Size} | The size of the arrowhead. Group 44. |
struct TextTEXT
How the text of a multileader style is drawn.
| Field | Type and default | Meaning |
|---|---|---|
Content | std::string | The text a new multileader starts with. Group 300. |
Style | Handle | The text style. Group 342. |
Left | int{1} | Where a leader from the left meets the text, such as 1 at the middle of its top line. Group 174. |
Right | int{1} | Where a leader from the right meets the text, as Left. Group 178. |
Angle | int{1} | How the text is turned: 0 along the leader, 1 horizontal, 2 along the leader but never upside down. Group 175. |
Alignment | int | How the lines of the text are aligned: 0 left, 1 center, 2 right. Group 176. |
Color | int{PackedByblock} | The color of the text, packed into one integer as AutoCAD does. Group 93. |
Height | double{Size} | The height of the text. Group 45. |
Frame | bool | Whether the text is framed. Group 292. |
Flush | bool | Whether the text is always aligned left. Group 297. |
Space | double{Size} | The space between the text and its alignment. Group 46. |
Direction | int | Which way leaders meet the text: 0 from the sides, 1 from above or below. Group 271, from R2010. |
Bottom | int{Centered} | Where a leader from below meets the text. Group 272, from R2010. |
Top | int{Centered} | Where a leader from above meets the text. Group 273, from R2010. |
struct Block
How the block of a multileader style is drawn, when its content is a block.
| Field | Type and default | Meaning |
|---|---|---|
Record | Handle | The block record of the content. Group 343. |
Color | int{PackedByblock} | The color of the block, packed into one integer as AutoCAD does. Group 94. |
Scale | Vector{.X = 1, .Y = 1, .Z = 1} | The scale of the block along X, Y and Z. Groups 47, 49, 140. |
Scaled | bool{true} | Whether Scale applies. Group 293. |
Rotation | double | The rotation of the block. Group 141. |
Rotated | bool{true} | Whether Rotation applies. Group 294. |
Connection | int | Where the leader meets the block: 0 its extents, 1 its insertion point. Group 177. |
struct MLeaderStyleMLEADERSTYLE
An MLEADERSTYLE: how a multileader draws its leader lines and its text or block, named by its entry in the multileader style dictionary.
| Field | Type and default | Meaning |
|---|---|---|
Base | DxfIO::Base | The handle, owner, reactors and extended data. |
Revision | int{2} | A version number, 2 as AutoCAD writes it. Group 179, from R2010. |
Content | int{2} | The content at the end of the leader: 0 none, 1 a block, 2 text, 3 a tolerance. Group 170. |
Order | int{1} | What is drawn first: 0 the content, 1 the leader. Group 171. |
Description | std::string | The style's description. Group 3. |
Leader | Boxed<Mleader::Leader> | How the leader lines are drawn, kept on the heap as the text and block are, so every object stays small. |
Text | Boxed<Mleader::Text> | How the text is drawn. |
Block | Boxed<Mleader::Block> | How the block is drawn. |
Scale | double{1} | The factor the whole multileader is scaled by. Group 142. |
Overwrite | bool | Whether a property of the style was overridden. Group 295. |
Annotative | bool | Whether the style is annotative. Group 296. |
Breaks | double{Mleader::Breaking} | The gap left where a leader is broken. Group 143. |
Spare | int | A value AutoCAD writes with no published meaning, usually 0. Group 298, from R2013. |
Constants
PackedByblock | int = -1056964608 | ByBlock as a packed color, AutoCAD's color in one integer: the color method 0xC1 in the top byte and nothing below it. Not Colors::Byblock, the index 0 of group 62. |
Margin | double = 2 | The landing gap of a new multileader style. |
Reach | double = 8 | The dogleg length of a new multileader style. |
Size | double = 4 | The arrow size and text height of a new multileader style. |
Breaking | double = 3.75 | The break gap of a new multileader style. |
Centered | int = 9 | A text attachment above or below: centered on the text. |