pyqt从URL设置QIcon()pixmap应用图标

img = QImage()
res= requests.get('https://xxx/logo.ico').content
img.loadFromData(res)
self.setWindowIcon(QIcon(QPixmap(img)))

猜你喜欢

转载自blog.csdn.net/m0_38124502/article/details/124494768