Commit efa14b95 authored by Lars Bittrich's avatar Lars Bittrich

Implemented version string and displaying this version in window title.

parent 1fff5fef
......@@ -25,12 +25,13 @@ from .scalebar import ScaleBar
from .ramancom.ramancontrol import defaultPath
from .ramancom.ramanSwitch import RamanSwitch
from .analysis.colorlegend import ColorLegend
from gepard import __version__
class GEPARDMainWindow(QtWidgets.QMainWindow):
def __init__(self, logpath):
super(GEPARDMainWindow, self).__init__()
self.setWindowTitle("GEPARD " + __version__)
self.resize(900, 700)
self.view = SampleView(logpath)
......@@ -120,8 +121,16 @@ class GEPARDMainWindow(QtWidgets.QMainWindow):
def about(self):
devbranch = None
fname = os.path.join(os.path.split(__file__)[0],
os.path.join('.git', 'HEAD'))
if os.path.exists(fname):
with open(fname, 'r') as fp:
cont =
devbranch = cont.rsplit('/',maxsplit=1)[1]
QtWidgets.QMessageBox.about(self, 'GEPARD',
"Developed by Complex Fiber Structures GmbH on behalf of Leibniz-IPF Dresden")
'Gepard-Enabled PARticle Detection for Raman microscopes. \nVersion:' + \
__version__ + '' if devbranch is None else ('\nDevelopment branch: ' + devbranch))
def createActions(self):
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment