1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271
|
MLeaderStyle
============
.. module:: ezdxf.entities
:noindex:
The MLEADERSTYLE entity (`DXF Reference`_) stores all attributes required to
create new :class:`MultiLeader` entities. The meaning of these attributes are
not really documented in the `DXF Reference`_.
The default style "Standard" always exist.
.. seealso::
- :class:`ezdxf.entities.MultiLeader`
- :class:`ezdxf.render.MultiLeaderBuilder`
- :ref:`tut_mleader`
Create a new :class:`MLeaderStyle`::
import ezdxf
doc = ezdxf.new()
new_style = doc.mleader_styles.new("NewStyle")
Duplicate an existing style::
duplicated_style = doc.mleader_styles.duplicate_entry("Standard", "DuplicatedStyle")
======================== =======================================================
Subclass of :class:`ezdxf.entities.DXFObject`
DXF type ``'MLEADERSTYLE'``
Factory function :meth:`ezdxf.document.Drawing.mleader_styles.new`
======================== =======================================================
.. class:: MLeaderStyle
.. attribute:: dxf.align_space
unknown meaning
.. attribute:: dxf.arrow_head_handle
handle of default arrow head, see also :mod:`ezdxf.render.arrows` module,
by default no handle is set, which mean default arrow "closed filled"
.. attribute:: dxf.arrow_head_size
default arrow head size in drawing units, default is 4.0
.. attribute:: dxf.block_color
default block color as ;term:`raw color` value, default is BY_BLOCK_RAW_VALUE
.. attribute:: dxf.block_connection_type
=== ================
0 center extents
1 insertion point
=== ================
.. attribute:: dxf.block_record_handle
handle to block record of the BLOCK content, not set by default
.. attribute:: dxf.block_rotation
default BLOCK rotation in radians, default is 0.0
.. attribute:: dxf.block_scale_x
default block x-axis scale factor, default is 1.0
.. attribute:: dxf.block_scale_y
default block y-axis scale factor, default is 1.0
.. attribute:: dxf.block_scale_z
default block z-axis scale factor, default is 1.0
.. attribute:: dxf.break_gap_size
default break gap size, default is 3.75
.. attribute:: dxf.char_height
default MTEXT char height, default is 4.0
.. attribute:: dxf.content_type
=== =========
0 none
1 BLOCK
2 MTEXT
3 TOLERANCE
=== =========
default is MTEXT (2)
.. attribute:: dxf.default_text_content
default MTEXT content as string, default is ""
.. attribute:: dxf.dogleg_length
default dogleg length, default is 8.0
.. attribute:: dxf.draw_leader_order_type
unknown meaning
.. attribute:: dxf.draw_mleader_order_type
unknown meaning
.. attribute:: dxf.first_segment_angle_constraint
angle of fist leader segment in radians, default is 0.0
.. attribute:: dxf.has_block_rotation
.. attribute:: dxf.has_block_scaling
.. attribute:: dxf.has_dogleg
default is 1
.. attribute:: dxf.has_landing
default is 1
.. attribute:: dxf.is_annotative
default is 0
.. attribute:: dxf.landing_gap_size
default landing gap size, default is 2.0
.. attribute:: dxf.leader_line_color
default leader line color as :term:`raw-color` value, default is
BY_BLOCK_RAW_VALUE
.. attribute:: dxf.leader_linetype_handle
handle of default leader linetype
.. attribute:: dxf.leader_lineweight
default leader lineweight, default is LINEWEIGHT_BYBLOCK
.. attribute:: dxf.leader_type
=== ====================
0 invisible
1 straight line leader
2 spline leader
=== ====================
default is 1
.. attribute:: dxf.max_leader_segments_points
max count of leader segments, default is 2
.. attribute:: dxf.name
MLEADERSTYLE name
.. attribute:: dxf.overwrite_property_value
unknown meaning
.. attribute:: dxf.scale
overall scaling factor, default is 1.0
.. attribute:: dxf.second_segment_angle_constraint
angle of fist leader segment in radians, default is 0.0
.. attribute:: dxf.text_align_always_left
use always left side to attach leaders, default is 0
.. attribute:: dxf.text_alignment_type
unknown meaning - its not the MTEXT attachment point!
.. attribute:: dxf.text_angle_type
=== =======================================================
0 text angle is equal to last leader line segment angle
1 text is horizontal
2 text angle is equal to last leader line segment angle, but potentially
rotated by 180 degrees so the right side is up for readability.
=== =======================================================
default is 1
.. attribute:: dxf.text_attachment_direction
defines whether the leaders attach to the left & right of the content
BLOCK/MTEXT or attach to the top & bottom:
=== =====================================
0 horizontal - left & right of content
1 vertical - top & bottom of content
=== =====================================
default is 0
.. attribute:: dxf.text_bottom_attachment_type
=== ===============================
9 center
10 overline and center
=== ===============================
default is 9
.. attribute:: dxf.text_color
default MTEXT color as :term:`raw-color` value, default is
BY_BLOCK_RAW_VALUE
.. attribute:: dxf.text_left_attachment_type
=== ========================================================
0 top of top MTEXT line
1 middle of top MTEXT line
2 middle of whole MTEXT
3 middle of bottom MTEXT line
4 bottom of bottom MTEXT line
5 bottom of bottom MTEXT line & underline bottom MTEXT line
6 bottom of top MTEXT line & underline top MTEXT line
7 bottom of top MTEXT line
8 bottom of top MTEXT line & underline all MTEXT lines
=== ========================================================
.. attribute:: dxf.text_right_attachment_type
=== ========================================================
0 top of top MTEXT line
1 middle of top MTEXT line
2 middle of whole MTEXT
3 middle of bottom MTEXT line
4 bottom of bottom MTEXT line
5 bottom of bottom MTEXT line & underline bottom MTEXT line
6 bottom of top MTEXT line & underline top MTEXT line
7 bottom of top MTEXT line
8 bottom of top MTEXT line & underline all MTEXT lines
=== ========================================================
.. attribute:: dxf.text_style_handle
handle of the default MTEXT text style, not set by default, which means
"Standard"
.. attribute:: dxf.text_top_attachment_type
=== ===============================
9 center
10 overline and center
=== ===============================
.. _DXF Reference: https://help.autodesk.com/view/OARX/2018/ENU/?guid=GUID-0E489B69-17A4-4439-8505-9DCE032100B4
|