[PyQt] removing a menu from the menubar

Ziegler Stefan Stefan.Ziegler at bd.so.ch
Fri Dec 28 17:14:25 GMT 2007


Hi
I began to write some python plugins for QGIS. During the initialisation
of the plugin I add a menu with:
 
self.fileMenu =
self.iface.getMainWindow().menuBar().addMenu("&DM01-Verifikation")
self.fileMenu.addAction(self.action1)
self.fileMenu.addAction(self.action2)
 
But how do I unload/remove it from the menubar? I tried:
 
self.fileMenu.close()
 
But that's not working... 
 
Thanks for any help.
Stefan

 

 

Mit freundlichem Gruss 
Stefan Ziegler 
Leiter Aufsicht 

Kanton Solothurn 
Bau- und Justizdepartement 
Amt für Geoinformation 
Rötistrasse 4 
4501 Solothurn 
Telefon 032 627 75 96 
Telefax 032 627 75 98 
stefan.ziegler at bd.so.ch 
http://www.so.ch 

 

-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://www.riverbankcomputing.com/pipermail/pyqt/attachments/20071228/d56611aa/attachment.html


More information about the PyQt mailing list