eric7/eric7.py

branch
eric7
changeset 8728
62b44a7c0a3a
parent 8705
327e596607f8
child 8729
226da2e26a84
equal deleted inserted replaced
8727:e2f8a0fbf738 8728:62b44a7c0a3a
264 "disable the given plug-in (may be repeated)"), 264 "disable the given plug-in (may be repeated)"),
265 ("--plugin=plugin-file", 265 ("--plugin=plugin-file",
266 "load the given plugin file (plugin development)"), 266 "load the given plugin file (plugin development)"),
267 ("--settings=settingsDir", 267 ("--settings=settingsDir",
268 "use the given directory to store the settings files"), 268 "use the given directory to store the settings files"),
269 ("--small-screen",
270 "adjust the interface for screens smaller than FHD"),
269 ("--start-file", "load the most recently opened file"), 271 ("--start-file", "load the most recently opened file"),
270 ("--start-multi", "load the most recently opened multi-project"), 272 ("--start-multi", "load the most recently opened multi-project"),
271 ("--start-project", "load the most recently opened project"), 273 ("--start-project", "load the most recently opened project"),
272 ("--start-session", "load the global session file"), 274 ("--start-session", "load the global session file"),
273 ("--", 275 ("--",
338 pluginFile = None 340 pluginFile = None
339 noopen = False 341 noopen = False
340 nocrash = False 342 nocrash = False
341 disablecrash = False 343 disablecrash = False
342 disabledPlugins = [] 344 disabledPlugins = []
345 smallScreen = False
343 if "--no-open" in sys.argv and sys.argv.index("--no-open") < ddindex: 346 if "--no-open" in sys.argv and sys.argv.index("--no-open") < ddindex:
344 sys.argv.remove("--no-open") 347 sys.argv.remove("--no-open")
345 ddindex -= 1 348 ddindex -= 1
346 noopen = True 349 noopen = True
347 if "--no-crash" in sys.argv and sys.argv.index("--no-crash") < ddindex: 350 if "--no-crash" in sys.argv and sys.argv.index("--no-crash") < ddindex:
353 sys.argv.index("--disable-crash") < ddindex 356 sys.argv.index("--disable-crash") < ddindex
354 ): 357 ):
355 sys.argv.remove("--disable-crash") 358 sys.argv.remove("--disable-crash")
356 ddindex -= 1 359 ddindex -= 1
357 disablecrash = True 360 disablecrash = True
361 if "--small-screen" in sys.argv:
362 sys.argv.remove("--small-screen")
363 ddindex -= 1
364 smallScreen = True
358 for arg in sys.argv[:]: 365 for arg in sys.argv[:]:
359 if ( 366 if (
360 arg.startswith("--disable-plugin=") and 367 arg.startswith("--disable-plugin=") and
361 sys.argv.index(arg) < ddindex 368 sys.argv.index(arg) < ddindex
362 ): 369 ):
399 from UI.UserInterface import UserInterface 406 from UI.UserInterface import UserInterface
400 407
401 splash.showMessage( 408 splash.showMessage(
402 QCoreApplication.translate("eric7", "Generating Main Window...")) 409 QCoreApplication.translate("eric7", "Generating Main Window..."))
403 mainWindow = UserInterface(app, loc, splash, pluginFile, disabledPlugins, 410 mainWindow = UserInterface(app, loc, splash, pluginFile, disabledPlugins,
404 noopen, nocrash, disablecrash, restartArgs, 411 noopen, nocrash, disablecrash, smallScreen,
405 originalPathString) 412 restartArgs, originalPathString)
406 app.lastWindowClosed.connect(app.quit) 413 app.lastWindowClosed.connect(app.quit)
407 mainWindow.show() 414 mainWindow.show()
408 415
409 QTimer.singleShot(0, uiStartUp) 416 QTimer.singleShot(0, uiStartUp)
410 417

eric ide

mercurial