MCPcopy
hub / github.com/ciromattia/kcc / addMessage

Method addMessage

kindlecomicconverter/KCC_gui.py:985–1000  ·  view source on GitHub ↗
(self, message, icon, replace=False)

Source from the content-addressed store, hash-verified

983 return s.get_data()
984
985 def addMessage(self, message, icon, replace=False):
986 if icon != '':
987 icon = getattr(self.icons, icon)
988 item = QListWidgetItem(icon, ' ' + self.stripTags(message))
989 else:
990 item = QListWidgetItem(' ' + self.stripTags(message))
991 if replace:
992 GUI.jobList.takeItem(GUI.jobList.count() - 1)
993 # Due to lack of HTML support in QListWidgetItem we overlay text field with QLabel
994 # We still fill original text field with transparent content to trigger creation of horizontal scrollbar
995 item.setForeground(QColor('transparent'))
996 label = QLabel(message)
997 label.setOpenExternalLinks(True)
998 GUI.jobList.addItem(item)
999 GUI.jobList.setItemWidget(item, label)
1000 GUI.jobList.scrollToBottom()
1001
1002 def showDialog(self, message, kind):
1003 if kind == 'error':

Callers 13

selectFileMetaEditorMethod · 0.95
togglewebtoonBoxMethod · 0.95
togglequalityBoxMethod · 0.95
toggleImageFormatBoxMethod · 0.95
changeDeviceMethod · 0.95
changeFormatMethod · 0.95
convertStartMethod · 0.95
saveSettingsMethod · 0.95
handleMessageMethod · 0.95
detectKindleGenMethod · 0.95

Calls 1

stripTagsMethod · 0.95

Tested by

no test coverage detected