[wxPython-users] Printing and Toolbar status

Christopher Barker Chris.Barker at noaa.gov
Mon Jul 17 22:03:03 PDT 2006



Saketh Bhamidipati wrote:
> Second, the toolbar problem:
> 
> I want the toolbar in my application to be optional through the main 
> menu and a right-click popup menu, so the following situation is what I 
> want, not what I have already written. Under 'Edit-Preferences' there is 
> a submenu with the checkable option "Toolbar" that toggles a flag 
> self.toolbarOn. If the option is checked, then the toolbar is displayed; 

>         # TODO: Make toolbar optional
>         if self.toolbarOn:
>             self.toolbar = toolbar = self.CreateToolBar()

You may need to manage the toolbar yourself, rather than using 
wx.Frame.CreateToolBar(). Read this to see how:

http://wiki.wxpython.org/index.cgi/WorkingWithToolBars

Note that that is old style code! Don't copy that style! Myabe you could 
clean it up as your contribution....

-Chris




More information about the wxpython-users mailing list