1
0
Fork 0
forked from josch/img2pdf

only run gui if requested with --gui even on windows (closes: #73)

This commit is contained in:
Johannes 'josch' Schauer 2020-04-23 07:09:13 +02:00
parent 0bbbc7a31a
commit 9449f96345
Signed by untrusted user: josch
GPG key ID: F2CBA5C78FBD83E1

View file

@ -3084,23 +3084,12 @@ Report bugs at https://gitlab.mister-muffin.de/josch/img2pdf/issues
version="%(prog)s " + __version__, version="%(prog)s " + __version__,
help="Prints version information and exits.", help="Prints version information and exits.",
) )
gui_group = parser.add_mutually_exclusive_group(required=False) parser.add_argument(
gui_group.add_argument(
"--gui", "--gui",
dest="gui", dest="gui",
action="store_true", action="store_true",
help="run tkinter gui (default on Windows)", help="run experimental tkinter gui",
) )
gui_group.add_argument(
"--nogui",
dest="gui",
action="store_false",
help="don't run tkinter gui (default elsewhere)",
)
if platform.system() == "Windows":
parser.set_defaults(gui=True)
else:
parser.set_defaults(gui=False)
outargs = parser.add_argument_group( outargs = parser.add_argument_group(
title="General output arguments", title="General output arguments",