printrun-src/printrun/gui/widgets.py

changeset 48
3c27b4ee6fec
parent 46
cce0af6351f0
equal deleted inserted replaced
47:dcc64b767b64 48:3c27b4ee6fec
1 # FILE MODIFIED BY NEOSOFT - MALTE DI DONATO
2 # Add Lasercut settings panel
3
1 # This file is part of the Printrun suite. 4 # This file is part of the Printrun suite.
2 # 5 #
3 # Printrun is free software: you can redistribute it and/or modify 6 # Printrun is free software: you can redistribute it and/or modify
4 # it under the terms of the GNU General Public License as published by 7 # it under the terms of the GNU General Public License as published by
5 # the Free Software Foundation, either version 3 of the License, or 8 # the Free Software Foundation, either version 3 of the License, or
118 121
119 SETTINGS_GROUPS = {"Printer": _("Printer settings"), 122 SETTINGS_GROUPS = {"Printer": _("Printer settings"),
120 "UI": _("User interface"), 123 "UI": _("User interface"),
121 "Viewer": _("Viewer"), 124 "Viewer": _("Viewer"),
122 "Colors": _("Colors"), 125 "Colors": _("Colors"),
123 "External": _("External commands")} 126 "External": _("External commands"),
127 "Laser": "Lasercut options"}
124 128
125 class PronterOptionsDialog(wx.Dialog): 129 class PronterOptionsDialog(wx.Dialog):
126 """Options editor""" 130 """Options editor"""
127 def __init__(self, pronterface): 131 def __init__(self, pronterface):
128 wx.Dialog.__init__(self, parent = None, title = _("Edit settings"), 132 wx.Dialog.__init__(self, parent = None, title = _("Edit settings"),
132 sbox = wx.StaticBoxSizer(header, wx.VERTICAL) 136 sbox = wx.StaticBoxSizer(header, wx.VERTICAL)
133 self.notebook = notebook = wx.Notebook(panel) 137 self.notebook = notebook = wx.Notebook(panel)
134 all_settings = pronterface.settings._all_settings() 138 all_settings = pronterface.settings._all_settings()
135 group_list = [] 139 group_list = []
136 groups = {} 140 groups = {}
137 for group in ["Printer", "UI", "Viewer", "Colors", "External"]: 141 for group in ["Printer", "UI", "Viewer", "Colors", "External", "Laser"]:
138 group_list.append(group) 142 group_list.append(group)
139 groups[group] = [] 143 groups[group] = []
140 for setting in all_settings: 144 for setting in all_settings:
141 if setting.group not in group_list: 145 if setting.group not in group_list:
142 group_list.append(setting.group) 146 group_list.append(setting.group)

mercurial