I have created a GUI application using pywebview in python and want to change application icon shown in menu bar, By default it is shown as python icon in windows. I am new to this library and want to change default icon to custom icon so is there any way to do this?
Asked
Active
Viewed 1,197 times
3
-
Here's the related issue on GitHub https://github.com/r0x0r/pywebview/issues/185 (I see the OP already commented there) – finnmglas May 24 '21 at 15:28
-
Is there any work around for this? at least in windows machine it is not looking good in windows not usable for making enterprise product if we can't remove icon – Rukamesh Kumar May 26 '21 at 14:15
1 Answers
0
In the PyWebView framework if you are using the QT web engine as GUI then you have to add a window icon manually in the site packages "\Python39\Lib\site-packages\webview\platforms\qt.py" file. Simply paste the code given below into class BrowserView Class Decorator init().
class BrowserView(QMainWindow): def __init__(self, window): from PyQt5 import QtGui self.setWindowIcon(QtGui.QIcon('icon.ico'))

shivjeet bhullar
- 1
- 3