如何自定义字符串WM_NAME和程序WM_CLASS,PyQt4如图所示xprop?
考虑例如:
from PyQt4 import QtGui, QtCore
import sys
if __name__ == '__main__':
app = QtGui.QApplication(sys.argv)
app.setStyle("plastique")
listView = QtGui.QListView()
listView.show()
combobox = QtGui.QComboBox()
combobox.show()
sys.exit(app.exec_())
如果我通过运行此(文件称为xprop_test.py)并为 ListView 或 ComboBoxpython xprop_test.py调用 linux 工具,它会显示xprop
WM_NAME(STRING) = "xprop_test.py"
和
WM_CLASS(STRING) = "xprop_test.py", "Xprop_test.py"
如何将字符串设置WM_NAME为WM_CLASS另一个自定义值(不同于文件名)?
如何为整个程序设置它?如何为每个单独的 GUI 元素调整它?