blob: e723680a427c433b197de89c1c6e1e2577a37b05 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
|
from PyQt5 import QtWidgets
import subprocess
import os
class UserManual(QtWidgets.QWidget):
"""
This class opens User-Manual page in new tab of web browser
when help button is clicked.
"""
def __init__(self):
QtWidgets.QWidget.__init__(self)
self.vlayout = QtWidgets.QVBoxLayout()
manual = 'library/browser/User-Manual/eSim_Manual_2.1.pdf'
if os.name == 'nt':
os.startfile(os.path.realpath(manual))
else:
manual_path = '../../' + manual
subprocess.Popen(
['xdg-open', os.path.realpath(manual_path)], shell=False
)
self.setLayout(self.vlayout)
self.show()
|