MCPcopy Create free account
hub / github.com/PyQt5/PyQtClient / StyleWindow

Class StyleWindow

Test/BaseApplyStyle.py:19–30  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

17
18
19class StyleWindow(QWidget):
20
21 def __init__(self, *args, **kwargs):
22 super(StyleWindow, self).__init__(*args, **kwargs)
23 layout = QVBoxLayout(self)
24 self.editStyle = QPlainTextEdit(self)
25 layout.addWidget(self.editStyle)
26 layout.addWidget(QPushButton('Apply', self, clicked=self.onApply))
27 self.editStyle.setPlainText(QApplication.instance().styleSheet())
28
29 def onApply(self):
30 QApplication.instance().setStyleSheet(self.editStyle.toPlainText())
31
32
33if __name__ == '__main__':

Callers 2

TestSkinDialog.pyFile · 0.90
BaseApplyStyle.pyFile · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected