Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
S
su
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Deploy
Releases
Model registry
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
dmeiss2s
su
Commits
e54b9511
Commit
e54b9511
authored
9 years ago
by
Daniel Meißner
Committed by
Daniel Meißner
9 years ago
Browse files
Options
Downloads
Patches
Plain Diff
moved Su class into lib directory and added more data about SU
parent
2a85f50c
No related branches found
No related tags found
No related merge requests found
Changes
4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
lib/gui/gui.py
+6
-6
6 additions, 6 deletions
lib/gui/gui.py
lib/gui/su_mainwindow.ui
+1
-1
1 addition, 1 deletion
lib/gui/su_mainwindow.ui
lib/su.py
+38
-0
38 additions, 0 deletions
lib/su.py
su.py
+1
-14
1 addition, 14 deletions
su.py
with
46 additions
and
21 deletions
lib/gui/gui.py
+
6
−
6
View file @
e54b9511
...
...
@@ -9,7 +9,7 @@ import re
from
PyQt5
import
QtCore
,
QtGui
,
QtWidgets
,
uic
from
lib.hardware
import
Hardware
from
lib.
version
import
__version__
from
lib.
su
import
Su
class
SuGui
(
QtWidgets
.
QMainWindow
):
"""
...
...
@@ -24,6 +24,7 @@ class SuGui(QtWidgets.QMainWindow):
uic
.
loadUi
(
"
lib/gui/su_mainwindow.ui
"
,
self
)
self
.
show
()
# setting some defaults
self
.
setWindowTitle
(
Su
.
name_and_version
())
self
.
lineEdit_dump_file
.
setText
(
self
.
_get_default_dump_file_path
())
self
.
lineEdit_dump_file
.
setCursorPosition
(
0
)
self
.
refresh_hw_button
()
...
...
@@ -69,11 +70,10 @@ class SuGui(QtWidgets.QMainWindow):
"""
Show about widget.
"""
QtWidgets
.
QMessageBox
.
about
(
self
,
\
"
About
"
,
\
"
SU - Spectrum Usage v
"
+
__version__
+
"
\n\n
"
\
"
Contact: daniel.meissner@smail.inf.h-brs.de
\n
"
\
"
Source: https://git.fslab.de/dmeiss2s/su
"
)
QtWidgets
.
QMessageBox
.
about
(
self
,
"
About
"
,
\
Su
.
name_and_version
()
+
"
\n\n
"
\
"
Contact: daniel.meissner@smail.inf.h-brs.de
\n
"
\
"
Source: https://git.fslab.de/dmeiss2s/su
"
)
def
_get_default_dump_file_path
(
self
):
...
...
This diff is collapsed.
Click to expand it.
lib/gui/su_mainwindow.ui
+
1
−
1
View file @
e54b9511
...
...
@@ -11,7 +11,7 @@
</rect>
</property>
<property
name=
"windowTitle"
>
<string
>
SU - Spectrum Usage
</string
>
<string
/
>
</property>
<widget
class=
"QWidget"
name=
"centralWidget"
>
<widget
class=
"QPushButton"
name=
"button_start"
>
...
...
This diff is collapsed.
Click to expand it.
lib/su.py
0 → 100644
+
38
−
0
View file @
e54b9511
# -*- coding: utf-8 -*-
from
lib.version
import
__version__
class
Su
(
object
):
"""
Prgramm class to store some information about the programm.
"""
@staticmethod
def
version
():
"""
Get programm version in Semantic Versioning format.
"""
return
__version__
@staticmethod
def
name
():
"""
Programm name.
"""
return
"
Spectrum Usage
"
@staticmethod
def
short_name
():
"""
Short programm name.
"""
return
"
SU
"
@staticmethod
def
name_and_version
():
"""
Return handy string containing short name, name and version.
Example:
SU - Spectrum Usage v0.0.1
"""
return
Su
.
short_name
()
+
"
-
"
+
Su
.
name
()
+
"
v
"
+
Su
.
version
()
This diff is collapsed.
Click to expand it.
su.py
+
1
−
14
View file @
e54b9511
...
...
@@ -10,22 +10,9 @@ from PyQt5 import QtCore, QtGui, QtWidgets
import
lib.gui.gui
as
gui
from
lib.
version
import
__version__
from
lib.
su
import
Su
from
lib.dependencies
import
check_dependencies
class
Su
(
object
):
"""
"""
@staticmethod
def
version
():
return
__version__
@staticmethod
def
name
():
return
"
Spectrum Usage (su)
"
def
parse_arguments
():
parser
=
argparse
.
ArgumentParser
()
# verbose
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment