mirror of
https://github.com/saitohirga/WSJT-X.git
synced 2025-05-24 10:22:26 -04:00
Moved example in a subdirectory
This commit is contained in:
parent
3210eb38bb
commit
6e06a97570
12
example.py → example/example.py
Normal file → Executable file
12
example.py → example/example.py
Normal file → Executable file
@ -1,9 +1,14 @@
|
|||||||
|
#!/usr/bin/env python
|
||||||
|
import os
|
||||||
|
from os.path import abspath, dirname
|
||||||
|
|
||||||
import sys
|
import sys
|
||||||
|
sys.path.insert(0, abspath(dirname(abspath(__file__)) + '/../..'))
|
||||||
|
|
||||||
from PySide import QtGui
|
from PySide import QtGui
|
||||||
|
import QDarkStyleSheet
|
||||||
import example_ui
|
import example_ui
|
||||||
|
|
||||||
# import the style resources
|
|
||||||
import style_pyside_rc
|
|
||||||
|
|
||||||
|
|
||||||
# create the application and the main window
|
# create the application and the main window
|
||||||
@ -15,8 +20,7 @@ ui = example_ui.Ui_MainWindow()
|
|||||||
ui.setupUi(window)
|
ui.setupUi(window)
|
||||||
|
|
||||||
# setup stylesheet
|
# setup stylesheet
|
||||||
with open("style.qss", 'r') as stylesheet:
|
app.setStyleSheet(QDarkStyleSheet.load_stylesheet(pyside=True))
|
||||||
app.setStyleSheet(stylesheet.read())
|
|
||||||
|
|
||||||
# run
|
# run
|
||||||
window.show()
|
window.show()
|
Loading…
x
Reference in New Issue
Block a user