简体   繁体   中英

Hide application icon from taskbar using pyqt5

I am creating desktop application using python pyqt5. i want hide my application icon from taskbar i am using following code to hide application.

def __init__(self):
   super(MainWindow, self).__init__()
   self.setWindowFlags(QtCore.Qt.Tool) 

but after this i am facing application not responding issue.any one have idea how can we hide application icon?

Thanks in advance.

In Windows, if you write your app in a .pyw file, no window will open, so you won't get any app icon in taskbar either.

In MacOS you have to use a plist: QT/C++ on MAC - How do I hide my dock icon?

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM