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
|
Insert
======
.. module:: ezdxf.entities
:noindex:
The INSERT entity (`DXF Reference`_) represents a block reference with optional
attached attributes as (:class:`Attrib`) entities.
======================== ==========================================
Subclass of :class:`ezdxf.entities.DXFGraphic`
DXF type ``'INSERT'``
Factory function :meth:`ezdxf.layouts.BaseLayout.add_blockref`
Inherited DXF attributes :ref:`Common graphical DXF attributes`
======================== ==========================================
.. seealso::
:ref:`tut_blocks`
.. warning::
Do not instantiate entity classes by yourself - always use the provided factory functions!
.. class:: Insert
.. attribute:: dxf.name
BLOCK name (str)
.. attribute:: dxf.insert
Insertion location of the BLOCK base point as (2D/3D Point in :ref:`OCS`)
.. attribute:: dxf.xscale
Scale factor for x direction (float)
.. attribute:: dxf.yscale
Scale factor for y direction (float)
Not all CAD applications support non-uniform scaling (e.g. LibreCAD).
.. attribute:: dxf.zscale
Scale factor for z direction (float)
Not all CAD applications support non-uniform scaling (e.g. LibreCAD).
.. attribute:: dxf.rotation
Rotation angle in degrees (float)
.. attribute:: dxf.row_count
Count of repeated insertions in row direction, MINSERT entity if > 1 (int)
.. attribute:: dxf.row_spacing
Distance between two insert points (MINSERT) in row direction (float)
.. attribute:: dxf.column_count
Count of repeated insertions in column direction, MINSERT entity if > 1 (int)
.. attribute:: dxf.column_spacing
Distance between two insert points (MINSERT) in column direction (float)
.. attribute:: attribs
A list of all attached :class:`Attrib` entities.
.. autoattribute:: has_scaling
.. autoattribute:: has_uniform_scaling
.. autoattribute:: mcount
.. automethod:: set_scale
.. automethod:: block
.. automethod:: place
.. automethod:: grid
.. automethod:: has_attrib
.. automethod:: get_attrib
.. automethod:: get_attrib_text
.. automethod:: add_attrib
.. automethod:: add_auto_attribs
.. automethod:: delete_attrib
.. automethod:: delete_all_attribs
.. automethod:: transform
.. automethod:: translate
.. automethod:: virtual_entities
.. automethod:: multi_insert
.. automethod:: explode
.. automethod:: ucs
.. automethod:: matrix44
.. automethod:: reset_transformation
.. _DXF Reference: http://help.autodesk.com/view/OARX/2018/ENU/?guid=GUID-28FA4CFB-9D5E-4880-9F11-36C97578252F
|