Arch: Ability to add windows presets
This commit is contained in:
@@ -784,6 +784,15 @@ class _CommandWindow:
|
||||
self.librarypresets.append([wtype+" - "+subtype+" - "+os.path.splitext(subfile)[0],os.path.join(subdir,subfile)])
|
||||
else:
|
||||
librarypath = None
|
||||
# check for existing presets
|
||||
presetdir = os.path.join(FreeCAD.getUserAppDataDir(),"Arch")
|
||||
for tp in ["Windows","Doors"]:
|
||||
wdir = os.path.join(presetdir,tp)
|
||||
if os.path.exists(wdir):
|
||||
for wfile in os.listdir(wdir):
|
||||
if wfile.lower().endswith(".fcstd"):
|
||||
self.librarypresets.append([tp[:-1]+" - "+wfile[:-6],wfile])
|
||||
|
||||
|
||||
# presets box
|
||||
labelp = QtGui.QLabel(translate("Arch","Preset"))
|
||||
|
||||
Reference in New Issue
Block a user