summaryrefslogtreecommitdiff
path: root/contrib/QDarkStyleSheet/script/run_ui_css_edition.py
diff options
context:
space:
mode:
authorChristoph Berg <myon@debian.org>2025-01-09 22:12:06 +0100
committerChristoph Berg <myon@debian.org>2025-01-09 22:12:06 +0100
commit992d4b4b8d3f3a630a2cf00d593ee4ce4dfa7ce8 (patch)
treefbfdfe6bcb0a8a114be2480dac53d88c977e4869 /contrib/QDarkStyleSheet/script/run_ui_css_edition.py
parent4320ce238aae1fe87fc9f379cdd816e9317885fa (diff)
New upstream version 2.7.0~rc8+repackupstream/2.7.0_rc8+repack
Diffstat (limited to 'contrib/QDarkStyleSheet/script/run_ui_css_edition.py')
-rwxr-xr-xcontrib/QDarkStyleSheet/script/run_ui_css_edition.py104
1 files changed, 52 insertions, 52 deletions
diff --git a/contrib/QDarkStyleSheet/script/run_ui_css_edition.py b/contrib/QDarkStyleSheet/script/run_ui_css_edition.py
index 4b8c2576..754f46c8 100755
--- a/contrib/QDarkStyleSheet/script/run_ui_css_edition.py
+++ b/contrib/QDarkStyleSheet/script/run_ui_css_edition.py
@@ -1,52 +1,52 @@
-#!/usr/bin/env python3
-# -*- coding: utf-8 -*-
-"""Process qrc and ui files, then run example in while loop."""
-
-from __future__ import absolute_import, print_function
-
-import sys
-from subprocess import call
-
-
-def main():
- """Process qrc and ui files, then run example in while loop."""
- dark = None
- no_dark = None
-
- while True:
- try:
- dark.kill()
- except AttributeError:
- print('Dark not running!')
- except Exception:
- print('Dark still running!')
- else:
- print('Dark was killed!')
-
- try:
- no_dark.kill()
- except AttributeError:
- print('No Dark not running!')
- except Exception:
- print('No Dark still running!')
- else:
- print('No Dark was killed!')
-
- print(sys.argv)
-
- # process qrc files
- call(['python', 'process_qrc.py'])
- # process ui files
- call(['python', 'process_ui.py'])
- # open dark example
- dark = call(['python', '../example/example.py'] + sys.argv[1:])
- # open no dark example
- no_dark = call(['python', '../example/example.py', '--no_dark'] + sys.argv[1:])
-
- if dark or no_dark:
- print('Unf! It not worked! Please, check the error(s).')
- break
-
-
-if __name__ == "__main__":
- sys.exit(main())
+#!/usr/bin/env python3
+# -*- coding: utf-8 -*-
+"""Process qrc and ui files, then run example in while loop."""
+
+from __future__ import absolute_import, print_function
+
+import sys
+from subprocess import call
+
+
+def main():
+ """Process qrc and ui files, then run example in while loop."""
+ dark = None
+ no_dark = None
+
+ while True:
+ try:
+ dark.kill()
+ except AttributeError:
+ print('Dark not running!')
+ except Exception:
+ print('Dark still running!')
+ else:
+ print('Dark was killed!')
+
+ try:
+ no_dark.kill()
+ except AttributeError:
+ print('No Dark not running!')
+ except Exception:
+ print('No Dark still running!')
+ else:
+ print('No Dark was killed!')
+
+ print(sys.argv)
+
+ # process qrc files
+ call(['python', 'process_qrc.py'])
+ # process ui files
+ call(['python', 'process_ui.py'])
+ # open dark example
+ dark = call(['python', '../example/example.py'] + sys.argv[1:])
+ # open no dark example
+ no_dark = call(['python', '../example/example.py', '--no_dark'] + sys.argv[1:])
+
+ if dark or no_dark:
+ print('Unf! It not worked! Please, check the error(s).')
+ break
+
+
+if __name__ == "__main__":
+ sys.exit(main())