mirror of
https://github.com/Kilian/Trimage.git
synced 2026-01-26 10:08:40 -05:00
update docstrings
This commit is contained in:
parent
cbd4d76b6e
commit
022df47501
2 changed files with 4 additions and 0 deletions
|
|
@ -230,6 +230,7 @@ class StartQT4(QMainWindow):
|
||||||
return status
|
return status
|
||||||
|
|
||||||
def safe_call(self, command):
|
def safe_call(self, command):
|
||||||
|
""" cross-platform command-line check """
|
||||||
while True:
|
while True:
|
||||||
try:
|
try:
|
||||||
return call(command, shell=True, stdout=PIPE)
|
return call(command, shell=True, stdout=PIPE)
|
||||||
|
|
|
||||||
|
|
@ -28,10 +28,12 @@ class TrimageTableView(QTableView):
|
||||||
|
|
||||||
class Ui_trimage(object):
|
class Ui_trimage(object):
|
||||||
def get_image(self, image):
|
def get_image(self, image):
|
||||||
|
""" Get the correct link to the images used in the UI """
|
||||||
imagelink = path.join(path.dirname(path.dirname(path.realpath(__file__))), "trimage/" + image)
|
imagelink = path.join(path.dirname(path.dirname(path.realpath(__file__))), "trimage/" + image)
|
||||||
return imagelink
|
return imagelink
|
||||||
|
|
||||||
def setupUi(self, trimage):
|
def setupUi(self, trimage):
|
||||||
|
""" Setup the entire UI """
|
||||||
trimage.setObjectName("trimage")
|
trimage.setObjectName("trimage")
|
||||||
trimage.resize(600, 170)
|
trimage.resize(600, 170)
|
||||||
trimage.setWindowIcon(QIcon(self.get_image("pixmaps/trimage-icon.png")))
|
trimage.setWindowIcon(QIcon(self.get_image("pixmaps/trimage-icon.png")))
|
||||||
|
|
@ -137,6 +139,7 @@ class Ui_trimage(object):
|
||||||
QMetaObject.connectSlotsByName(trimage)
|
QMetaObject.connectSlotsByName(trimage)
|
||||||
|
|
||||||
def retranslateUi(self, trimage):
|
def retranslateUi(self, trimage):
|
||||||
|
""" Fill in the texts for all UI elements """
|
||||||
trimage.setWindowTitle(QApplication.translate("trimage",
|
trimage.setWindowTitle(QApplication.translate("trimage",
|
||||||
"Trimage image compressor", None, QApplication.UnicodeUTF8))
|
"Trimage image compressor", None, QApplication.UnicodeUTF8))
|
||||||
self.addfiles.setToolTip(QApplication.translate("trimage",
|
self.addfiles.setToolTip(QApplication.translate("trimage",
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue