EVT_MENU_HIGHLIGHT Problems

What I am trying to do is get menu's on multiple panels to all show
their help messages on the same status bar. The problem I have is that
EVT_MENU_HIGHLIGHT(self,id,func), EVT_MENU_HIGHLIGHT_ALL(self,self.func)
don't appear to do anything. I saw somewhere that this macro wasn't
implemented but I think that document was dated. I also tried to use
the frame.OnMenuHighlight method and it doesn't exist. If I use
frame.CreateStatusBar() I can get the help text from the menu bar to go
to the status bar but I cant figure out where this event is getting
handled. I've tried overloading OnMenuHighlight but that doesn't get
activated and the help text still makes it to the status bar. Any help
would be greatly appreciated.
Sam

Sam Hendley wrote:

What I am trying to do is get menu's on multiple panels to all show
their help messages on the same status bar. The problem I have is that
EVT_MENU_HIGHLIGHT(self,id,func), EVT_MENU_HIGHLIGHT_ALL(self,self.func)
don't appear to do anything.

What's your platform and version?

I saw somewhere that this macro wasn't

implemented but I think that document was dated. I also tried to use
the frame.OnMenuHighlight method and it doesn't exist. If I use
frame.CreateStatusBar() I can get the help text from the menu bar to go
to the status bar but I cant figure out where this event is getting
handled. I've tried overloading OnMenuHighlight but that doesn't get
activated and the help text still makes it to the status bar. Any help
would be greatly appreciated.

This works for me, where self is the wxFrame:

         EVT_MENU_HIGHLIGHT_ALL(self, self.OnMenuHighlight)

     ...

     def OnMenuHighlight(self, event):
         # Show how to get menu item imfo from this event handler
         id = event.GetMenuId()
         item = self.GetMenuBar().FindItemById(id)
         text = item.GetText()
         help = item.GetHelp()
         print text, help

ยทยทยท

--
Robin Dunn
Software Craftsman
http://wxPython.org Java give you jitters? Relax with wxPython!