OpenSCAD: allow to enable verbose output in preferences
This commit is contained in:
parent
35cc2879e5
commit
f3d66aa674
|
@ -36,7 +36,7 @@
|
|||
</widget>
|
||||
</item>
|
||||
<item>
|
||||
<widget class="Gui::PrefFileChooser" name="gui::preffilechooser" native="true">
|
||||
<widget class="Gui::PrefFileChooser" name="gui::preffilechooser">
|
||||
<property name="minimumSize">
|
||||
<size>
|
||||
<width>300</width>
|
||||
|
@ -65,6 +65,23 @@
|
|||
<string>OpenSCAD import</string>
|
||||
</property>
|
||||
<layout class="QVBoxLayout" name="verticalLayout">
|
||||
<item>
|
||||
<layout class="QHBoxLayout" name="horizontalLayout_4">
|
||||
<item>
|
||||
<widget class="Gui::PrefCheckBox" name="checkBox">
|
||||
<property name="text">
|
||||
<string>Print debug information in the Console</string>
|
||||
</property>
|
||||
<property name="prefEntry" stdset="0">
|
||||
<cstring>printVerbose</cstring>
|
||||
</property>
|
||||
<property name="prefPath" stdset="0">
|
||||
<cstring>Mod/OpenSCAD</cstring>
|
||||
</property>
|
||||
</widget>
|
||||
</item>
|
||||
</layout>
|
||||
</item>
|
||||
<item>
|
||||
<layout class="QHBoxLayout" name="horizontalLayout_5">
|
||||
<item>
|
||||
|
|
|
@ -49,6 +49,9 @@ import Part
|
|||
from OpenSCADFeatures import *
|
||||
from OpenSCADUtils import *
|
||||
|
||||
params = FreeCAD.ParamGet("User parameter:BaseApp/Preferences/Mod/OpenSCAD")
|
||||
printverbose = params.GetBool('printVerbose',False)
|
||||
|
||||
if open.__module__ == '__builtin__':
|
||||
pythonopen = open # to distinguish python built-in open function from the one declared here
|
||||
|
||||
|
@ -715,8 +718,8 @@ def processDXF(fname,layer):
|
|||
obj.Shape=face
|
||||
if printverbose: print "DXF Diagnostics"
|
||||
if printverbose: print obj.Shape.ShapeType
|
||||
if printverbose: print "Closed : "+str(f.isClosed())
|
||||
if printverbose: print f.check()
|
||||
if printverbose: print "Closed : "+str(obj.Shape.isClosed())
|
||||
if printverbose: print obj.Shape.check()
|
||||
if printverbose: print [w.isClosed() for w in obj.Shape.Wires]
|
||||
return(obj)
|
||||
|
||||
|
|
Loading…
Reference in New Issue
Block a user