Class DxfMLeader
- Namespace
- GeometryHelper.Dxf
- Assembly
- GeometryHelper.dll
A MULTILEADER of a DXF file, as AutoCAD's MLeader: words of an MTEXT or a block (its content) with leaders that
point from it, each leader a dogleg and one or more leader lines, drawn by its multileader style with the properties it
overrides.
public sealed class DxfMLeader : DxfEntity
- Inheritance
-
DxfMLeader
- Inherited Members
Remarks
The file holds a MULTILEADER as AutoCAD keeps one: its own properties, then its context data (groups 300 to 301) with the content, the plane and the leaders (302 to 303), each with its lines (304 to 305). A MULTILEADER of the words "Line one" held at (800, 0, 0) with one leader whose line runs from (780, -10, 0) to its dogleg at (790, -1.25, 0) has ContentType MTextContent, LeaderCount 1, LeaderLineCount 1, and its line 0 has VerticesCount(int) 2: GetFirstVertex(int) (780, -10, 0) where its arrow is, and GetLastVertex(int) (790, -1.25, 0), the point of its leader the dogleg starts at, which every line of the leader ends at.
Leaders and lines are named by their indices, as AutoCAD names them (90 of a leader, 91 of a line), not by their place. A property set writes the MULTILEADER's own group and the one of its context data AutoCAD keeps with it, and sets its bit of the overrides of the style (group 90), as AutoCAD sets it for a property given a value of its own. A property given the value it has sets its bit all the same and changes nothing else, as AutoCAD 2021 sets it (ArrowSize is written anew too, and a dogleg's length lands the leaders anew, DoglegLength); the colour of the words, the content, the block, the direction of the attachment, the annotation scale, the places and the style change nothing. The sizes (TextHeight, LandingGap, ArrowSize, DoglegLength and BlockScale) are read and set unscaled, as AutoCAD 2021's API reads and sets them, and drawn times the Scale. What AutoCAD works out when it draws the MULTILEADER (where the leaders meet the words, the box of the words, the breaks) is not worked out here: the library writes the data AutoCAD draws it from. Where AutoCAD 2021 moves the words or block, or lands a leader anew, when a property is set, so that each leader still meets the content (the gap, the doglegs, the height, the scale, an attachment, the words given anew, a leader's last vertex), the library moves them as AutoCAD does where that needs no font: words met on their left, by AutoCAD's rules of the lines of words, and a move of words met on their right that keeps them as wide; what AutoCAD lands as far right as its font makes the words wide is left as it was, but where the drawing's FontSearchPath measures the words (one line in an SHX or TrueType font), which are then met on their right, lower where their ink reaches below their baseline, and kept readable when mirrored, as AutoCAD 2021 does it (check F1b). Words mirrored across their plane, which then run against its x axis and say so (294 of 1), are moved by the same edits, as AutoCAD 2021 moves them, held at their right, where their width is needed only where the fonts measure them (check D38).
GetGeometry() gives the lines of its leaders, as DxfReader reads a MULTILEADER, so that IntersectWith(DxfEntity, DxfIntersect) meets it on them: for each leader line a GeoPolyline3 from its first vertex, where its arrow points, through its vertices and the last point of its leader to the end of the dogleg, a vertex on the one before it left out, along the path Explode() draws with the line and its dogleg; splined, a GeoSpline3 fitted through those points, leaving along the first segment and reaching along the dogleg. Both start at the arrow's point, where Explode() starts its line at the back of the arrow, and the spline of a line splined of its own runs on through the dogleg, where the spline exploded ends at the dogleg's start, so that the two part near the arrow and near the words; a multileader whose leader lines are all splined has no dogleg drawn, and its splines run to the end the dogleg would have, exploded too. The line above is met by the line y = -3 from (780, -3, 0) to (795, -3, 0) at (788, -3, 0), on its way up to the dogleg. Its words or block, its arrowheads and the lines AutoCAD draws under the words are not among them, and invisible lines give none.
Constructors
- DxfMLeader()
Initializes a MULTILEADER of no content and no leaders, its plane the floor, as AutoCAD's
new MLeader(), on layer 0 in no file, its content type the words (172 of 2) though it holds none, as AutoCAD 2021 makes one (check D38b): added to a drawing, it takes the drawing's multileader style (CMLEADERSTYLE, else Standard), with the style's linetype of the leader lines (341) and its arrow block (342) where it names them, as AutoCAD 2021 writes them, and the text style Standard. Give it leaders with AddLeaderLine(GeoPoint3) and words with MText.
Properties
- ArrowSize
Gets or sets the size of the arrows, as AutoCAD's
ArrowSize: unscaled, as AutoCAD 2021's API reads it, the size the arrows are drawn with (140 of the context data) over the Scale, else the MULTILEADER's own (42); 4 where the record gives neither. Set, the size is written in 42 and, times the Scale, in 140; Scale and TransformBy(GeoTransform3) scale 140 alone, as AutoCAD 2021 scales it, so that a MULTILEADER of arrows 4 scaled by 2 by TransformBy(GeoTransform3) reads 8, its 42 still 4, until the size is set again. A leader line of no size of its own reads 42 (GetArrowSize(int)), as AutoCAD 2021 reads it.
- ArrowSymbol
Gets or sets the block drawn as the arrows (group 342), as AutoCAD's
ArrowSymbolIdgives its id; null for AutoCAD's closed filled arrow, which needs no block.
- BlockColor
Gets or sets the colour of the block (group 93, and 93 of the context data), as AutoCAD's
BlockColor; BYBLOCK where the record gives none.
- BlockConnectionType
Gets or sets where the leaders meet the block (group 176), as AutoCAD's
BlockConnectionType; at its box where the record gives none.
- BlockContent
Gets or sets the block the leaders point to (group 344, and 341 of the context data), as AutoCAD's
BlockContentIdgives its id; null where the MULTILEADER points to none, or to a block the drawing has none of.
- BlockPosition
Gets or sets where the block is placed (group 15 of the block of the context data), as AutoCAD's
BlockPosition, in the world; the base point of the content (10 of the context data) where the MULTILEADER holds no block. Set, the base point of the content and the point each leader's dogleg starts at (10 of the context data and of each leader) move with the block, and the block's matrix (its groups 47) is left as it is, as AutoCAD 2021 moves and leaves them: the box of lines from (-10, -5) to (20, 15) moved from (100, 50, 0) to (130, 60, 0) moves a dogleg from (82, 55, 0) to (112, 65, 0), the leader lines' own vertices staying; the matrix is written anew where BlockScale or BlockRotation is set.
- BlockRotation
Gets or sets how far the block is turned, as AutoCAD's
BlockRotation, in radians: the MULTILEADER's own (43), as AutoCAD 2021's API reads it, else as the block is drawn, group 46 of the block of the context data; nought where the record gives neither. A block turned a quarter by TransformBy(GeoTransform3) is drawn turned a quarter and reads nought, as AutoCAD reads it.
- BlockScale
Gets or sets how the block is scaled along its axes, as AutoCAD's
BlockScale: unscaled, as AutoCAD 2021's API reads it, the MULTILEADER's own (group 10), else the scale the block is drawn with (16 of the block of the context data) over the Scale; 1 each way where the record gives neither. A block drawn 2 at a scale of 2 reads 1.
- ContentType
Gets or sets what the leaders point to (group 172), as AutoCAD's
ContentType; MTextContent where the record gives none, and for a new MULTILEADER, which holds no words yet (HasContent() false), as AutoCAD 2021 reads a new one (check D38b).
- DoglegLength
Gets or sets how long the doglegs are, as AutoCAD's
DoglegLength: unscaled, as AutoCAD 2021's API reads it, the length the first leader's dogleg is drawn (its 40) over the Scale, else, where the MULTILEADER has no leader or its first meets the words at their top or bottom, its own (group 41, unscaled); 8 where the record gives none. Doglegs drawn 16 by TransformBy(GeoTransform3) by 2, 41 still 8, read 16; the first leader given 15 by SetDoglegLength(int, double) reads 15.
- EnableAnnotationScale
Gets or sets whether the MULTILEADER is scaled by the annotation scale (group 293), as AutoCAD's
EnableAnnotationScale.
- EnableDogleg
Gets or sets whether the leaders have doglegs (group 291), as AutoCAD's
EnableDogleg, as the record says it. A multileader whose leader lines are splined (LeaderLineType) draws none whatever this says, as AutoCAD 2021 draws none, its ownEnableDoglegreading false for it.
- EnableFrameText
Gets or sets whether a frame is drawn round the words (group 292), as AutoCAD's
EnableFrameText.
- EnableLanding
Gets or sets whether the leaders end in a landing, a dogleg and gap (group 290), as AutoCAD's
EnableLanding.
- ExtendLeaderToText
Gets or sets whether the leaders run on to the words (group 295, from R2013), as AutoCAD's
ExtendLeaderToText: true for a multileader made in code and added to a drawing of R2013 or later, of words, a block or none, as AutoCAD 2021 makes every new one (check D38).
- GeometricExtents
Gets the box the MULTILEADER fills, as AutoCAD 2021's
GeometricExtents: the vertices of every leader line (the point its dogleg starts at among them) and the point of its words or block, and the parts Explode() draws it with, its words, block and arrowheads, the words with the landing gap more beyond them on the side away from their leader. A multileader from (0, 0) to a landing at (100, -1.25), words "TEXT" 2.5 high at its right in the font txt.shx and arrowheads of 0.18, fills (0, -2.5) to (109.71, 0.03): the words 9.17 wide and the gap of 0.09 counted, and the arrowhead's corners 0.03 above its line. Words that no font of the drawing measures, or a multileader that Explode() cannot draw, add nothing: the box is then that of the points alone.
- LandingGap
Gets or sets the gap between the landing and the words, as AutoCAD's
LandingGap: unscaled, as AutoCAD 2021's API reads it, the gap drawn (group 145 of the context data) over the Scale; 2 where the record gives none. A gap drawn 4 at a scale of 2 reads 2.
- LeaderCount
Gets how many leaders the MULTILEADER has, as AutoCAD's
LeaderCount.
- LeaderLineColor
Gets or sets the colour of the leader lines (group 91), as AutoCAD's
LeaderLineColor; BYBLOCK where the record gives none.
- LeaderLineCount
Gets how many leader lines the MULTILEADER has, those of every leader, as AutoCAD's
LeaderLineCount.
- LeaderLineType
Gets or sets how the leader lines are drawn (group 170), as AutoCAD's
LeaderLineType; straight where the record gives none.
- LeaderLineWeight
Gets or sets the lineweight of the leader lines (group 171), as AutoCAD's
LeaderLineWeight; BYBLOCK where the record gives none.
- MLeaderStyle
Gets or sets the multileader style (group 340), as AutoCAD's
MLeaderStylegives its id: by its name in the drawing's dictionary ACAD_MLEADERSTYLE; null where the handle names none of it.
- MText
Gets or sets the words, as AutoCAD's
MText: a DxfMText in no file of the MTEXT of the context data, its words (304), place (12), direction (13), height (the context's 41), width (43), spacing of its lines (45 and 170), the point it is held by (171, at the top on the left, middle or right) and, in a drawing, its text style (340), by name; null where the MULTILEADER holds no words.
- Normal
Gets the normal of the plane of the MULTILEADER, as AutoCAD's
Normal: the x axis of its context's plane (111) crossed with its y axis (112), of unit length, turned over where the context says so (297).
- Scale
Gets or sets the scale of the MULTILEADER (group 45 from R2007, and 40 of the context data), as AutoCAD's
Scale; 1 where the record gives none.
- TextAlignmentType
Gets or sets how the words are lined up (group 175, 176 of the context data, and 171 of its MTEXT), as AutoCAD's
TextAlignmentType: read from the context data, as AutoCAD 2021 reads it (check D38b), else from 175; on the left where the record gives neither. Words lined up on the left and mirrored across the YZ plane, which the mirror lines up the other way (176 of 2), read on the right; lined up on the right and mirrored so, on the left.
- TextAngleType
Gets or sets how the words are turned (group 174), as AutoCAD's
TextAngleType; level where the record gives none.
- TextAttachmentDirection
Gets or sets which sides of the words the leaders meet (group 271, and 271 of each leader, from R2010), as AutoCAD's
TextAttachmentDirection; the left and the right where the record gives none.
- TextAttachmentType
Gets or sets where the leaders on the left meet the words (group 173, and 174 of the context data), as AutoCAD's
TextAttachmentType; the right (95, and 175 of the context data) is left as it is, as AutoCAD 2021 leaves it.
- TextColor
Gets or sets the colour of the words (group 92, and 90 of the context's MTEXT), as AutoCAD's
TextColor; BYBLOCK where the record gives none.
- TextHeight
Gets or sets how high the letters are, as AutoCAD's
TextHeight: unscaled, as AutoCAD 2021's API reads it, the height drawn (group 41 of the context data) over the Scale; 4 where the record gives none. Words drawn 8 high at a scale of 2 read 4, and MText gives them 8 high, as drawn.
- TextLocation
Gets or sets where the words are held (group 12 of the context's MTEXT), as AutoCAD's
TextLocation, in the world; the base point of the content (10 of the context data) where the MULTILEADER holds no words.
Methods
- AddFirstVertex(int, GeoPoint3)
Puts a vertex in before the first of a leader line, where its arrow goes, as AutoCAD's
AddFirstVertex. On a line of a leader of no landing yet (AddLeader()), the vertex becomes the leader's landing, as AutoCAD 2021 takes it, the line of one vertex and the content left where it is: (-20, 80, 0) given so, then the last vertex set to (40, 70, 0), moves words at (100, 50, 0) by (60, -10, 0), to (160, 40, 0).
- AddLastVertex(int, GeoPoint3)
Adds a vertex after the last of a leader line, as AutoCAD's
AddLastVertex: it becomes the end of the leader's landing (GetLastVertex(int)), the old one a vertex of the line, and every line of the leader ends at it. On a line of a leader of no landing yet it becomes the landing, as AddFirstVertex(int, GeoPoint3) says.
- AddLeader()
Adds a leader of no lines, as AutoCAD's
AddLeader: its index (90) one above every leader's, its dogleg along the x axis of the plane, as long as DoglegLength times the Scale, written as ezdxf writes a leader, and of no landing yet (290 of nought), as AutoCAD 2021 writes it: it draws no dogleg, a line added to it has no vertex, and the first vertex given a line of it (AddFirstVertex(int, GeoPoint3) or AddLastVertex(int, GeoPoint3)) becomes its landing, the content left where it is, unless SetDogleg(int, GeoVector3) lands it first. Words at (100, 50, 0) given a leader whose line is given (-20, 80, 0) are met there, the line of one vertex, its dogleg drawn from (-20, 80, 0) to (-12, 80, 0).
- AddLeaderLine(GeoPoint3)
Adds a leader line from a point, as AutoCAD's
AddLeaderLineof a point: the point its first vertex, where its arrow is, the line added to the first leader whose dogleg runs from the point's side towards the content. Where none does and the point is on the left of words held at their top left and met on their sides, along the plane, the line is added to a new leader landed as AutoCAD 2021 lands it: its dogleg along the x axis of the plane, as long as DoglegLength times the Scale, ending the LandingGap short of the words' left edge, as far below their top as the attachment of the left side (TextAttachmentType) says: nought at the top of the top line, half the height of the words at its middle, all of it at its bottom and a fifth more under it; the middle of the words, the middle of the bottom line, its bottom and a fifth more under it as the lines of the words stand, each 5/3 of their height times their spacing below the one above, the lines counted by their breaks (\P), as words that do not wrap. Words "ABC" 4 high held at (100, 50, 0), met at the middle of their top line with a gap of 2 and a dogleg of 8, are met by a leader from (0, 0, 0) whose dogleg runs from (90, 48, 0) to (98, 48, 0); three lines met at their middle, from (90, 41.33, 0). A block is met on the side of its box the point is on (its middle along x), with no gap, its dogleg ending where the block's shapes meet the line along x through the middle of its box (connected at its extents) or through its position (at its base), the outermost such point on that side, else that point of the line; the box is the block's own, of the shapes the library reads, carried as the block is drawn and boxed in the plane: the box of lines from (-10, -5) to (20, 15) placed at (100, 50, 0) is met from (0, 0, 0) by a dogleg from (82, 55, 0) to (90, 55, 0), and from (250, 0, 0) by one from (128, 55, 0) to (120, 55, 0). Elsewhere, the line goes to the first leader, one made at the base point of the content where there is none, its dogleg ending there for a point on its left, as AutoCAD 2021 lands a leader it adds (check D38b), and starting there for one on its right: on the right of the words, which AutoCAD lands as far right as its font makes them wide; for words turned off the plane, held at their top centre or right where no font measures them, or met at their top or bottom. A MULTILEADER of no content has its first line landed at the point, its dogleg towards the base point, the line of that one vertex, as AutoCAD 2021 lands it (check D38b): from (30, 40, 0), a dogleg from there along -x; a line after it goes to that leader. Words held at their top centre or right are met from their edges where the fonts measure them (check D38b). Where the drawing's FontSearchPath measures the words (one line in an SHX or TrueType font), a point at their middle or right of it is met on their right, as AutoCAD 2021 lands it (check F1b): the dogleg against x, ending the gap past their ink, "ABC" of txt.shx 4 high at (100, 50, 0), 10.67 wide, met from (250, 0, 0) by a dogleg from (120.67, 48, 0) to (112.67, 48, 0), and from (108, 0, 0) too, while (103, 0, 0) is met on the left; words whose ink reaches below their baseline are as high as their height and that depth together, "Ag" met 2.67 below its top at the middle of its top line. A leader of no landing yet (AddLeader()) is passed over, as AutoCAD 2021 passes it. Words a leader meets on a side of attachment 8 are underlined (SetTextAttachmentType(DxfTextAttachmentType, DxfLeaderDirectionType)). Words mirrored across their plane, which run against its x axis (294 of 1), held at their right, are met as AutoCAD 2021 meets them where the fonts measure them (check D38): "ABC" of txt.shx held at (110.67, 50, 0) facing down, met from (250, 100, 0) by a dogleg from (120.67, 48, 0). The line has no colour of its own (no 92), as AutoCAD 2021 writes one.
- AddLeaderLine(int)
Adds a leader line of no vertices to a leader, as AutoCAD's
AddLeaderLineof a leader: its index (91) one above every line's, of no colour of its own (no 92), drawn in LeaderLineColor, as AutoCAD 2021 writes one (check D38). Its arrow goes at a vertex put in by AddFirstVertex(int, GeoPoint3).
- Explode()
Gets the entities the multileader breaks into, as AutoCAD 2021's
Explodegives them from its context data: its content first, an MTEXT of its words (MText, as wide as the context data says, which the scale has scaled already, as AutoCAD 2021 writes it, in its text style and colour) or an INSERT of its block (BlockContent at BlockPosition, scaled, turned and coloured so, its attributes given the values the multileader holds), either in the multileader's own linetype and lineweight, as AutoCAD 2021 gives them; then, leader by leader, its dogleg, a LINE from the last point of the leader along its direction, of no length where the dogleg has none, as AutoCAD 2021 draws it, where the multileader has one, its leader lines are not splined and the leader runs left or right of the words, a leader of no line giving its dogleg alone and one of no landing yet (AddLeader()) nothing, as AutoCAD 2021 draws them; then line by line, unless the line is invisible, an LWPOLYLINE through the vertices to the last point of the leader, and the arrowhead at the first vertex. A splined line is one SPLINE fitted through the same points, leaving along its first segment and reaching along its dogleg, its knots the lengths of the chords, as AutoCAD's. Without a dogleg, a line on the left or right of the words runs on to the end the dogleg would have; so does every line of a multileader whose leader lines are splined (LeaderLineType), which AutoCAD 2021 draws with no dogleg: two lines splined from (0, 0) and (0, 100) to a dogleg from (90, 48) to (98, 48) give two SPLINEs fitted from the backs of their arrows to (98, 48) and no LINE. The arrowhead is drawn where the first segment is more than twice as long as the arrow, as AutoCAD draws it: an INSERT of the line's or the multileader's arrow block, turned to point away from the line, by an angle from nought to a whole turn, and scaled to the arrow's size, or AutoCAD's closed filled arrow as a SOLID a third as wide as long, its corners the one on the right of the line, the tip and the one on its left; the line then starts at the back of the arrow. Each part is on the multileader's layer, and a colour of BYBLOCK, as the style Standard gives the words and the lines, is the multileader's own colour, as AutoCAD 2021 gives it; the arrowhead has the multileader's own linetype, and the SOLID its own lineweight, the INSERT the lineweight of its line, as AutoCAD 2021 gives them: a multileader of lineweight 0.30 and linetype Continuous of its own, its leader lines 0.50, gives a SOLID of 0.30 or an INSERT of 0.50, both Continuous. A line is drawn with the type, colour, linetype, lineweight and arrow size of its own where its flags (93) say it has them, BYBLOCK among them, and its colour where it has no flags and its colour is not BYBLOCK, as ezdxf writes one; else with the multileader's (GetLeaderLineType(int), GetLeaderLineColor(int), GetLeaderLineWeight(int)): a line splined of its own is one SPLINE among the straight lines of the others, one invisible of its own gives nothing, and a line of arrows 2 of its own under arrows 4 starts 2 from its tip; a size of its own is unscaled, as the multileader's own (42), and drawn times the scale of the context data, 4 at a scale of 2, where a line of none is drawn with the size of the context data (140). The words on the right of two leader lines with a dogleg of 8 give an MTEXT, the dogleg's LINE, and for each line an LWPOLYLINE and a SOLID. A multileader scaled to nothing gives nothing. The lines AutoCAD draws under or over the words, as long as the words are wide, are AutoCAD's to work out from its fonts, and are not among them. A copy in no file, made by Clone(), finds the blocks, the linetype and the text style its record names in the drawing it was copied from, as a dimension's copy finds its block, and gives what the original gives, the values of its attributes among it; where that drawing has erased a block it names since, it is refused, rather than drawn without it.
- ExplodeBroken()
Gets the entities the multileader breaks into, as Explode() gives them, but with each leader line cut at its breaks (GetBreaks(int)), as AutoCAD draws a multileader that DIMBREAK has broken: AutoCAD 2021's
Explodegives the lines whole. A line from (0, 0, 0) to (100, 0, 0) broken from 40 to 50 gives two polylines, from the back of its arrow to 40 and from 50 to the end. A line splined, and the arrows, doglegs and words, are as Explode() gives them.
- GetArrowSize(int)
Gets the size of a leader line's arrow, as AutoCAD's
GetArrowSizeof a line: its own (group 40 of the line) where it overrides the multileader's (bit 16 of its 93), else the multileader's own size (its 42), as AutoCAD 2021 reads it; unscaled, the arrow drawn times the Scale. A multileader of arrows 4 scaled by 2 by TransformBy(GeoTransform3) reads 4 here, its ArrowSize 8.
- GetBlockAttribute(DxfAttributeDefinition)
Gets the value of an attribute of the block, as AutoCAD's
GetBlockAttribute: an ATTRIB in no file of the tag of the attribute's definition and the value the MULTILEADER gives it (group 302 after the 330 of the definition's handle); the definition's own value where the MULTILEADER gives none.
- GetBreaks(int)
Gets the breaks of a leader line, as AutoCAD 2021's DIMBREAK keeps them in the line (90, 11 and 12 of its LEADER_LINE): for each the segment of the line it is in and where it starts and ends, in the order the record has them. A line no DIMBREAK has touched has none.
- GetDogleg(int)
Gets the direction of a leader's dogleg (groups 11, 21 and 31 of the leader), as AutoCAD's
GetDogleg, in the world.
- GetDoglegLength(int)
Gets how long a leader's dogleg is, as AutoCAD's
GetDoglegLength: its length as drawn (group 40 of the leader, 1 where the leader gives none, as ezdxf reads one) over the Scale, as AutoCAD 2021 gives it, 8 for a dogleg drawn 16 at a scale of 2; nought for a leader that meets the words at their top or bottom, which has none.
- GetFirstVertex(int)
Gets the first vertex of a leader line, where its arrow is, as AutoCAD's
GetFirstVertex.
- GetLastVertex(int)
Gets the last vertex of a leader line, as AutoCAD's
GetLastVertex: the point of its leader the dogleg starts at (10 of the leader); where the leader meets the words on their left or right and its dogleg is not drawn (no EnableDogleg, or its leader lines splined), the end the dogleg would have, which the line runs on to, as AutoCAD 2021 gives it: a line from (0, 0, 0) whose leader's dogleg of 8 starts at (90, 48, 0) ends at (98, 48, 0) once the dogleg is taken away.
- GetLeaderIndex(int)
Gets the index of the leader a line is of, as AutoCAD's
GetLeaderIndex.
- GetLeaderIndexes()
Gets the indices of the leaders (90 of each), in their order, as AutoCAD's
GetLeaderIndexes.
- GetLeaderLineColor(int)
Gets the colour of a leader line, as AutoCAD's
GetLeaderLineColor: its own (group 92 of the line) where it overrides the multileader's (bit 2 of its 93), BYBLOCK where it does so with no 92, or where the line has no flags and its colour is not BYBLOCK, as ezdxf writes and Explode() draws such a line; else BYBLOCK, as AutoCAD 2021 reads a line of no colour of its own whatever the LeaderLineColor it is drawn in (check D38b): a new line of a multileader of green lines reads BYBLOCK, and is drawn green.
- GetLeaderLineIndexes(int)
Gets the indices of the lines of a leader (91 of each), in their order, as AutoCAD's
GetLeaderLineIndexes.
- GetLeaderLineType(int)
Gets how a leader line is drawn, as AutoCAD's
GetLeaderLineType: its own type (group 170 of the line) where it overrides the multileader's (bit 1 of its 93), else LeaderLineType.
- GetLeaderLineWeight(int)
Gets the lineweight of a leader line, as AutoCAD's
GetLeaderLineWeight: its own (group 171 of the line) where it overrides the multileader's (bit 8 of its 93), else LeaderLineWeight.
- GetOverridedMLeaderStyle(DxfMLeaderStyle)
Gives a style made in code the values the multileader is drawn with, as AutoCAD's
getOverridedMLeaderStyle, named here as the library names its members: those of its multileader style (MLeaderStyle), and in place of each it overrides (a bit of its 90) its own, as ezdxf'sMLeaderStyleOverridereads them. A multileader of the style Standard, its words 2.5 high of its own, gives TextHeight 2.5 and the style's arrows, 4 long. An override is the value the multileader's group gives, the style's kept where the multileader has no group of it, but for the arrows: a multileader of AutoCAD's closed filled arrow gives a style of no arrow block. Each is read as the multileader writes it, asMLeaderStyleOverridereads it: the height of the words (bit 16) and the landing gap (bit 5) from the context data, scaled (its 41 and 145, as drawn, which TextHeight and LandingGap read over the scale); the size of the arrows (bit 9) from the multileader's own 42, unscaled, as the style holds it; the length of the doglegs (bit 7) from its own 41, unscaled too, as AutoCAD 2021 writes it. A multileader of scale 2 with words 8 high, arrows 4 and doglegs 8 of its own, drawn 16, gives a style of words 8 high, arrows 4 and doglegs 8, whose scale is the multileader's 2 where it overrides that too (bit 24).
- GetPlane()
Gets the plane of the MULTILEADER, as AutoCAD's
GetPlane: through the origin of its context's plane (110), of its Normal.
- GetTextAttachmentType(DxfLeaderDirectionType)
Gets where the leaders of a side meet the words, as AutoCAD's
GetTextAttachmentType: the left (group 173), the right (95), the top (273) or the bottom (272), the last two from R2010.
- GetVertex(int, int)
Gets a vertex of a leader line, as AutoCAD's
GetVertex, in the world: the last the end of its leader's landing, as GetLastVertex(int) gives it.
- HasContent()
Gets whether the MULTILEADER holds the content its type says, as AutoCAD's
HasContent: words or a block in its context data.
- MoveMLeader(GeoVector3, DxfMoveType)
Moves the MULTILEADER or a part of it along a vector, as AutoCAD's
MoveMLeader: everything, as TransformBy(GeoTransform3) by the move does; everything but the first vertex of each leader line, where its arrow is; or the content and the doglegs, the points they start at with them, the leader lines' own vertices staying.
- RemoveFirstVertex(int)
Takes the first vertex of a leader line out, as AutoCAD's
RemoveFirstVertex, down to one, the point its leader's dogleg starts at, as AutoCAD 2021 takes it: the line from (0, 0, 0) to the words "ABC" at (100, 50, 0) is left the one vertex (90, 48, 0), written as a line of no vertex of its own, and drawn as its dogleg alone, from (90, 48, 0) to (98, 48, 0), with no arrow. A line keeps that vertex, which AutoCAD 2021 crashed taking out of a drawing it had read.
- RemoveLastVertex(int)
Takes the last vertex of a leader line out, as AutoCAD's
RemoveLastVertex, down to one: the vertex before it becomes the point the leader's dogleg starts at, as it stands, the content left where it is, as AutoCAD 2021 makes it. The line from (0, 0, 0) to the words "ABC" at (100, 50, 0) is landed at (0, 0, 0), its dogleg drawn to (8, 0, 0); with no dogleg drawn (EnableDogleg) the dogleg starts at (0, 0, 0) all the same, and the vertex reads (8, 0, 0), the end the dogleg would have, as GetLastVertex(int) reads it. A line keeps one vertex, as RemoveFirstVertex(int) says; and the last vertex of a leader of more lines than one, the landing they all end at, is not taken out, as AutoCAD 2021 refuses it.
- RemoveLeader(int)
Takes a leader out with its lines, as AutoCAD's
RemoveLeader; the arrows of its lines (94 and 345) with them.
- RemoveLeaderLine(int)
Takes a leader line out, as AutoCAD's
RemoveLeaderLine; its arrow (94 and 345) with it, its leader kept.
- SetArrowSize(int, double)
Gives a leader line's arrow a size of its own, as AutoCAD's
SetArrowSizeof a line: its group 40 written and bit 16 of its flags (93) set, from R2010; a line of a multileader of arrows 4 long given 2.5 reads 2.5, the others 4. The size is unscaled, as ArrowSize is: Explode() draws it times the Scale, a line given 4.5 on a multileader of scale 2 drawn 9. The size the arrow has already is written and flagged all the same, as AutoCAD 2021 writes it, from R2010.
- SetBlockAttribute(DxfAttributeDefinition, DxfAttributeReference)
Gives an attribute of the block a value, as AutoCAD's
SetBlockAttribute: the 302 of the definition's entry written, or an entry made after the others (its handle 330, index 177, width 44 of 1 and value 302), as ezdxf writes one, from R2007.
- SetBreaks(int, IEnumerable<DxfLeaderBreak>)
Sets the breaks of a leader line, in place of those it has, as AutoCAD 2021 writes them: grouped by segment, the segments in order, after the line's vertices. Explode() gives the line whole, as AutoCAD's does; ExplodeBroken() gives it cut at the breaks, as AutoCAD draws it. A line of one segment, from (0, 0, 0) to (100, 0, 0), given a break from (39.9375, 0, 0) to (40.0625, 0, 0) is drawn in two, to 39.9375 and from 40.0625.
- SetDogleg(int, GeoVector3)
Gives a leader's dogleg its direction, as AutoCAD's
SetDogleg. A leader of no landing yet (AddLeader()), or one whose dogleg is turned to another direction, is landed on the side of the content its dogleg now runs from, where the library can tell where it meets the content, as AutoCAD 2021 lands it: along x on the left of the words, on either side of a block; on the right of the words, which AutoCAD lands by their font's width, it keeps its point, but where the drawing's FontSearchPath measures them, where it is landed as far right as they are wide. The box of lines from (-10, -5) to (20, 15) at (100, 50, 0) is met against x from (128, 55, 0), where a leader just added lands, and where its leader from the left lands once turned; a vertex then given a line of it goes before the landing.
- SetDoglegLength(int, double)
Gives a leader's dogleg its length, as AutoCAD's
SetDoglegLength: drawn times the Scale (group 40 of the leader), as AutoCAD 2021 writes it, 2 for 1 at a scale of 2, and the bit of the overrides of the doglegs (7) set, the length it has too. The content or the leader moves as DoglegLength says: the content, where the leader is the only one of its side and none meets the content on the other; else the leader's start alone, as AutoCAD 2021 moves it: of two leaders landed at (150, 38, 0) on the left of words at (160, 40, 0), the second given 15 starts at (143, 38, 0), the words and the first staying.
- SetFirstVertex(int, GeoPoint3)
Moves the first vertex of a leader line, as AutoCAD's
SetFirstVertex, as SetVertex(int, int, GeoPoint3) moves one.
- SetFromStyle()
Gives the multileader the values of its multileader style and takes away its overrides of it, as AutoCAD's
SetFromStyle: the style's scale first, then its look of the leader lines, the landing, the dogleg, the arrows, the words and the block, each written by the property of its name (Scale, LeaderLineType ... BlockConnectionType) in the multileader and its context data, its linetype (341) and text style (343, and 340 of its words) by the style's handles; then its overrides (90) set to nought. A multileader of the style Standard, its words 2.5 high of its own, has words 4 high, as the style. The sizes, unscaled in the style, are scaled once by the scale the multileader then has: the height of the words, the landing gap and the size of the arrows of the context data (41, 145 and 140) and each leader's length of the dogleg (40) are the style's times the scale, and the multileader's own size of the arrows (42) and length of the doglegs (41) the style's, unscaled, as AutoCAD 2021 writes them; Standard scaled 2 gives words 8 high, a gap of 4, arrows 8 drawn (42 of 4) and doglegs 16 drawn (41 of 8). A value the style gives that the multileader cannot take keeps the multileader's own and its bit: a content (172) or a block (344) it does not hold, a size or a type out of AutoCAD's range, a linetype or a text style the style names none of or one its drawing has not, an arrow block or a block a copy in no drawing cannot be given (it keeps its own arrow, and takes the rest), and the attachments of the top and bottom and their direction in a file older than R2010; so do the bits of no property the library writes (18, 26 and 30). What it cannot take is judged before anything is written, so that nothing is left half set. The overrides of each leader line (its 93) are the multileader's own, not the style's, and stay. The words, the block and the landings stay where they are, the properties written here not moving them as they do when set one by one: how AutoCAD 2021 moves them when a style is taken has not been read.
- SetLastVertex(int, GeoPoint3)
Moves the last vertex of a leader line, as AutoCAD's
SetLastVertex: the point of its leader the dogleg starts at, or, where the dogleg is not drawn, that point so that the end the dogleg would have is there (GetLastVertex(int)): (98, 48, 0) set to (50, 60, 0) puts the dogleg's start at (42, 60, 0), as AutoCAD 2021 puts it. The words or block and the other landings move with it, as SetVertex(int, int, GeoPoint3) says; AddLastVertex(int, GeoPoint3) moves neither, as AutoCAD's.
- SetLeaderLineColor(int, DxfColor)
Gives a leader line a colour of its own, as AutoCAD's
SetLeaderLineColor: its group 92 written and bit 2 of its flags (93) set, from R2010; Explode() draws the line in it. BYBLOCK sets the flag and writes no 92, as AutoCAD 2021 writes it (check D38b). The colour the line is drawn in already is written and flagged all the same, as AutoCAD 2021 flags it.
- SetLeaderLineType(int, DxfLeaderType)
Gives a leader line a type of its own, as AutoCAD's
SetLeaderLineType: its group 170 written and bit 1 of its flags (93) set, as the DXF reference and the ODA's specification of DWG place them after its index (91), from R2010. The type the line is drawn with already is written and flagged all the same, as AutoCAD 2021 flags it, from R2010.
- SetLeaderLineWeight(int, DxfLineWeight)
Gives a leader line a lineweight of its own, as AutoCAD's
SetLeaderLineWeight: its group 171 written and bit 8 of its flags (93) set, from R2010. The lineweight the line is drawn with already is written and flagged all the same, as AutoCAD 2021 flags it.
- SetPlane(GeoPlane3)
Puts the multileader in a plane, as AutoCAD's
SetPlane: the plane of its context data the one given, its origin (110) the plane's and its x axis (111) the one it had laid in the plane, the x axis of the plane's own system where it stood along the normal, its y axis (112) across them, or as it was where it lies in the plane already, on the side the x axis keeps, so that Normal is the plane's whichever way 297 turns it; every point moved straight onto the plane (the base point of its content, the place of its words and block, the last point of each leader, the vertices of its lines and the points of their breaks); and every direction laid in it (the words' direction and turn, the block's turn and matrix, the doglegs), the normals of its words and block the plane's, or the other way where they faced away from its plane before, as the words of a mirrored multileader (297 of 1, its words of normal -z over a plane of +z) are read from behind it. The multileader of the floor whose words are at (800, 0, 0) put in the plane z = 5 has its words at (800, 0, 5) and its leaders' vertices 5 up; put in a plane x = 0 its words go to (0, 0, 0). A point and a direction in the plane already keep their numbers, of whatever length, and axes that lean to each other, as a shear leaves them, keep theirs, so that the multileader put in its own plane changes nothing.
- SetTextAttachmentType(DxfTextAttachmentType, DxfLeaderDirectionType)
Sets where the leaders of a side meet the words, as AutoCAD's
SetTextAttachmentType: the MULTILEADER's group of the side and that of its context data, and the side's bit of the overrides. Where leaders meet the words on that side, the words or the landings move as AutoCAD 2021 moves them, the words running along the plane: the left set, the words move up by as much more as the left is met below their top, the leaders on the right with them; the right set, the words move so where no leader meets them on the left, else the leaders on the right are landed lower by as much. Three lines at (100, 50, 0) met on both sides at the middle of their top line, the left set to the bottom of the bottom line, stand at (100, 65.33, 0), the dogleg on their right from (120.67, 63.33, 0). Attachment 8, the underline of every line, underlines the words where a leader meets them on its side, as AutoCAD writes it: "ABC" becomes\LABC, words that begin with\Lor have no letters left; set away from it,\Lis taken off the words again.
- SetVertex(int, int, GeoPoint3)
Moves a vertex of a leader line, as AutoCAD's
SetVertex: one of its own; the last, the end of its leader's landing (GetLastVertex(int)), which moves the end of every line of the leader with it, and, for a leader on a side of the content, the words or block and the landings of the other leaders on a side by as much, as AutoCAD 2021 moves them: words "ABC" at (100, 50, 0) met from (90, 48, 0), the last vertex set to (50, 60, 0), stand at (60, 62, 0).
- VerticesCount(int)
Gets how many vertices a leader line has, as AutoCAD's
VerticesCount: its own (10 of the line), then the end of its leader's landing (GetLastVertex(int)), which every line of the leader ends at; its own alone where the leader has no landing yet (AddLeader()), none for a line just added to it, as AutoCAD 2021 counts them.