Skip to content
Snippets Groups Projects
Commit b1e3a59a authored by Marco Biasini's avatar Marco Biasini
Browse files

display correct version number in "About" dialog

The version number is now directly based on ost.VERSION. Also, while I'm in there, make the link to the openstructure.org website clickable.
parent eecdd445
No related branches found
No related tags found
No related merge requests found
......@@ -6,6 +6,15 @@ from ost import gui
LOGO_PATH = os.path.join(ost.GetSharedDataPath(), "gui", "images", "logo-small.png")
SPLASH_TEXT=""""Welcome to <b>Openstructure</b>!<br/><br/>
You are running version %s<br /><br />If you are new to OpenStructure, we
invite you to run the demos from the examples directory. Scripts can be
displayed by right clicking on the file and selecting 'Show source'.<br/><br/>
Feel free visit our website at:<br />
<a href='http://www.openstructure.org'>http://www.openstructure.org</a>
""" % ost.VERSION
class SplashDialog(QtGui.QDialog):
def __init__(self, parent=None):
QtGui.QDialog.__init__(self, parent)
......@@ -15,9 +24,10 @@ class SplashDialog(QtGui.QDialog):
self.pix_map = QtGui.QPixmap(LOGO_PATH);
imageLabel.setPixmap(self.pix_map);
layout.addWidget(imageLabel)
self.label = QtGui.QTextEdit()
self.label = QtGui.QTextBrowser()
self.label.setReadOnly(True)
self.label.setHtml("Welcome to <b>Openstructure</b>!<br /><br />You are running version 1.0.0a<br /><br />If you are new to OpenStructure, we invite you to run the demos from the examples directory. Scripts can be displayed by right clicking on the file and selecting 'Show source'.<br /><br />Feel free visit our website at:<br /> http://www.openstructure.org")
self.label.setOpenExternalLinks(True)
self.label.setHtml(SPLASH_TEXT)
layout.addWidget(self.label)
def _InitSplash():
......@@ -25,3 +35,6 @@ def _InitSplash():
splash.exec_()
#QtCore.QTimer.singleShot(30000, splash.close);
__all__=('SplashDialog',)
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment