Commit 195d6200 authored by sumpfralle's avatar sumpfralle

r561@erker: lars | 2010-02-02 05:35:26 +0100

 make the PyGTK interface the default
 add a switch for the SimpleGui


git-svn-id: https://pycam.svn.sourceforge.net/svnroot/pycam/trunk@84 bbaffbd6-741e-11dd-a85d-61de82d9cad9
parent 10027286
...@@ -3,6 +3,7 @@ ...@@ -3,6 +3,7 @@
from optparse import OptionParser from optparse import OptionParser
from pycam.Gui.SimpleGui import SimpleGui from pycam.Gui.SimpleGui import SimpleGui
from pycam.Gui.Project import ProjectGui
from pycam.Importers.TestModel import TestModel from pycam.Importers.TestModel import TestModel
# check if we were started as a separate program # check if we were started as a separate program
...@@ -14,6 +15,9 @@ if __name__ == "__main__": ...@@ -14,6 +15,9 @@ if __name__ == "__main__":
parser.add_option("", "--gui", dest="display", parser.add_option("", "--gui", dest="display",
action="store_true", default=False, action="store_true", default=False,
help="don't create the outputfile on the fly - just preset the output filename and show the GUI") help="don't create the outputfile on the fly - just preset the output filename and show the GUI")
parser.add_option("", "--simple-gui", dest="simple_gui",
action="store_true", default=False,
help="use the obsolete old GUI (Tcl/Tk)")
(options, args) = parser.parse_args() (options, args) = parser.parse_args()
if len(args) > 0: if len(args) > 0:
...@@ -23,7 +27,10 @@ if __name__ == "__main__": ...@@ -23,7 +27,10 @@ if __name__ == "__main__":
if len(args) > 2: if len(args) > 2:
parser.error("too many arguments given (%d instead of %d)" % (len(args), 2)) parser.error("too many arguments given (%d instead of %d)" % (len(args), 2))
if options.simple_gui:
gui = SimpleGui() gui = SimpleGui()
else:
gui = ProjectGui()
if not inputfile: if not inputfile:
gui.model = TestModel() gui.model = TestModel()
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment