Skip to content

Commit a8a4c9d

Browse files
author
volayaf
committedApr 23, 2012
added #5460
git-svn-id: http://sextante.googlecode.com/svn/trunk/soft/bindings/qgis-plugin@143 881b9c09-3ef8-f3c2-ec3d-21d735c97f4d
1 parent 732709c commit a8a4c9d

File tree

1 file changed

+15
-3
lines changed

1 file changed

+15
-3
lines changed
 

‎src/sextante/gui/HTMLViewerDialog.py

Lines changed: 15 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -13,15 +13,27 @@ def __init__(self, filename):
1313
def setupUi(self):
1414
self.resize(600, 500)
1515
self.webView = QtWebKit.QWebView()
16-
self.setWindowTitle("")
16+
self.setWindowTitle("Help")
17+
self.closeButton = QtGui.QPushButton()
18+
self.closeButton.setText("Close")
19+
self.closeButton.setMaximumWidth(150)
1720
self.horizontalLayout= QtGui.QHBoxLayout()
1821
self.horizontalLayout.setSpacing(2)
1922
self.horizontalLayout.setMargin(0)
20-
self.horizontalLayout.addWidget(self.webView)
21-
self.setLayout(self.horizontalLayout)
23+
self.horizontalLayout.addStretch(1000)
24+
self.horizontalLayout.addWidget(self.closeButton)
25+
self.verticalLayout= QtGui.QVBoxLayout()
26+
self.verticalLayout.setSpacing(2)
27+
self.verticalLayout.setMargin(0)
28+
self.verticalLayout.addWidget(self.webView)
29+
self.verticalLayout.addLayout(self.horizontalLayout)
30+
self.setLayout(self.verticalLayout)
31+
QObject.connect(self.closeButton, QtCore.SIGNAL("clicked()"), self.closeWindow)
2232
try:
2333
url = QtCore.QUrl(self.filename)
2434
self.webView.load(url)
2535
except:
2636
pass
2737

38+
def closeWindow(self):
39+
self.close()

0 commit comments

Comments
 (0)
Please sign in to comment.