Another set of fixes in DXF/DWG Importer
This commit is contained in:
parent
a5bf2e41c6
commit
2dd642795b
@ -89,7 +89,8 @@
|
||||
</param>
|
||||
<label appearance="header">ezdxf Entity Filter</label>
|
||||
<label>What entity types do you want to filter? Only the listed one's are possible at the moment.</label>
|
||||
<param name="allentities" type="bool" gui-text="Use all entities (override selection)">false</param>
|
||||
<param name="allentities" type="bool" gui-text="Keep all listed entity types (override filter selection)">false</param>
|
||||
<label>Or select the entity types you want to keep. Checked items will not be dropped while processing.</label>
|
||||
<hbox>
|
||||
<hbox>
|
||||
<label appearance="header">sk1 Supported</label>
|
||||
@ -123,16 +124,14 @@
|
||||
<param type="bool" gui-text="3DSOLID" name="THREE_DSOLID">true</param>
|
||||
<param type="bool" gui-text="ATTRIB" name="ATTRIB">true</param>
|
||||
<param type="bool" gui-text="BODY" name="BODY">true</param>
|
||||
<param type="bool" gui-text="DIMENSION" name="DIMENSION">true</param>
|
||||
<param type="bool" gui-text="ARC_DIMENSION" name="ARC_DIMENSION">true</param>
|
||||
<param type="bool" gui-text="HATCH" name="HATCH">true</param>
|
||||
<param type="bool" gui-text="IMAGE" name="IMAGE">true</param>
|
||||
<param type="bool" gui-text="INSERT" name="INSERT">true</param>
|
||||
<param type="bool" gui-text="LEADER" name="LEADER">true</param>
|
||||
<param type="bool" gui-text="MESH" name="MESH">true</param>
|
||||
</vbox>
|
||||
<separator/>
|
||||
<vbox>
|
||||
<param type="bool" gui-text="MESH" name="MESH">true</param>
|
||||
<param type="bool" gui-text="MTEXT" name="MTEXT">true</param>
|
||||
<param type="bool" gui-text="RAY" name="RAY">true</param>
|
||||
<param type="bool" gui-text="REGION" name="REGION">true</param>
|
||||
|
@ -95,12 +95,10 @@ class DXFDWGImport(inkex.Effect):
|
||||
self.arg_parser.add_argument("--THREE_DSOLID", type=inkex.Boolean, default=True) #3DSOLID
|
||||
self.arg_parser.add_argument("--ATTRIB", type=inkex.Boolean, default=True)
|
||||
self.arg_parser.add_argument("--BODY", type=inkex.Boolean, default=True)
|
||||
self.arg_parser.add_argument("--DIMENSION", type=inkex.Boolean, default=True)
|
||||
self.arg_parser.add_argument("--ARC_DIMENSION", type=inkex.Boolean, default=True)
|
||||
self.arg_parser.add_argument("--HATCH", type=inkex.Boolean, default=True)
|
||||
self.arg_parser.add_argument("--IMAGE", type=inkex.Boolean, default=True)
|
||||
self.arg_parser.add_argument("--INSERT", type=inkex.Boolean, default=True)
|
||||
self.arg_parser.add_argument("--LEADER", type=inkex.Boolean, default=True)
|
||||
self.arg_parser.add_argument("--MESH", type=inkex.Boolean, default=True)
|
||||
self.arg_parser.add_argument("--MTEXT", type=inkex.Boolean, default=True)
|
||||
self.arg_parser.add_argument("--RAY", type=inkex.Boolean, default=True)
|
||||
@ -155,12 +153,10 @@ class DXFDWGImport(inkex.Effect):
|
||||
if self.options.allentities or self.options.THREE_DSOLID: entityspace.append("3DSOLID")
|
||||
if self.options.allentities or self.options.ATTRIB: entityspace.append("ATTRIB")
|
||||
if self.options.allentities or self.options.BODY: entityspace.append("BODY")
|
||||
if self.options.allentities or self.options.DIMENSION: entityspace.append("DIMENSION")
|
||||
if self.options.allentities or self.options.ARC_DIMENSION: entityspace.append("ARC_DIMENSION")
|
||||
if self.options.allentities or self.options.HATCH: entityspace.append("HATCH")
|
||||
if self.options.allentities or self.options.IMAGE: entityspace.append("IMAGE")
|
||||
if self.options.allentities or self.options.INSERT: entityspace.append("INSERT")
|
||||
if self.options.allentities or self.options.LEADER: entityspace.append("LEADER")
|
||||
if self.options.allentities or self.options.MESH: entityspace.append("MESH")
|
||||
if self.options.allentities or self.options.MTEXT: entityspace.append("MTEXT")
|
||||
if self.options.allentities or self.options.RAY: entityspace.append("RAY")
|
||||
@ -281,9 +277,10 @@ class DXFDWGImport(inkex.Effect):
|
||||
# The auditor.errors attribute stores severe errors, which *may* raise exceptions when rendering.
|
||||
if len(auditor.errors) == 0:
|
||||
fig = plt.figure()
|
||||
ax = plt.axes([0., 0., 1., 1.], frameon=False, xticks=[], yticks=[])
|
||||
#ax.patches = []
|
||||
plt.axis('off')
|
||||
ax = plt.axes([0., 0., 1., 1.], xticks=[], yticks=[])
|
||||
#ax = plt.axes([0., 0., 1., 1.], frameon=False, xticks=[], yticks=[])
|
||||
ax.patches = []
|
||||
#plt.axis('off')
|
||||
plt.margins(0, 0)
|
||||
plt.gca().xaxis.set_major_locator(plt.NullLocator())
|
||||
plt.gca().yaxis.set_major_locator(plt.NullLocator())
|
||||
|
Reference in New Issue
Block a user