22 import Globals |
22 import Globals |
23 configDir = arg.replace("--config=", "") |
23 configDir = arg.replace("--config=", "") |
24 Globals.setConfigDir(configDir) |
24 Globals.setConfigDir(configDir) |
25 sys.argv.remove(arg) |
25 sys.argv.remove(arg) |
26 elif arg.startswith("--settings="): |
26 elif arg.startswith("--settings="): |
27 from PyQt5.QtCore import QSettings |
27 from PyQt6.QtCore import QSettings |
28 settingsDir = os.path.expanduser(arg.replace("--settings=", "")) |
28 settingsDir = os.path.expanduser(arg.replace("--settings=", "")) |
29 if not os.path.isdir(settingsDir): |
29 if not os.path.isdir(settingsDir): |
30 os.makedirs(settingsDir) |
30 os.makedirs(settingsDir) |
31 QSettings.setPath( |
31 QSettings.setPath( |
32 QSettings.Format.IniFormat, QSettings.Scope.UserScope, settingsDir) |
32 QSettings.Format.IniFormat, QSettings.Scope.UserScope, settingsDir) |
53 |
53 |
54 def main(): |
54 def main(): |
55 """ |
55 """ |
56 Main entry point into the application. |
56 Main entry point into the application. |
57 """ |
57 """ |
58 from PyQt5.QtGui import QGuiApplication |
58 from PyQt6.QtGui import QGuiApplication |
59 QGuiApplication.setDesktopFileName("eric7_editor.desktop") |
59 QGuiApplication.setDesktopFileName("eric7_editor.desktop") |
60 |
60 |
61 options = [ |
61 options = [ |
62 ("--config=configDir", |
62 ("--config=configDir", |
63 "use the given directory as the one containing the config files"), |
63 "use the given directory as the one containing the config files"), |