]> git.saurik.com Git - wxWidgets.git/blob - docs/latex/wx/menuevt.tex
docs corrections and docs for Chris' wxImage::SaveFile(filename_only) patch
[wxWidgets.git] / docs / latex / wx / menuevt.tex
1 \section{\class{wxMenuEvent}}\label{wxmenuevent}
2
3 This class is used for a variety of menu-related events. Note that
4 these do not include menu command events.
5
6 \wxheading{Derived from}
7
8 \helpref{wxEvent}{wxevent}\\
9 \helpref{wxObject}{wxobject}
10
11 \wxheading{Include files}
12
13 <wx/event.h>
14
15 \wxheading{Event table macros}
16
17 To process a menu event, use these event handler macros to direct input to member
18 functions that take a wxMenuEvent argument.
19
20 \twocolwidtha{7cm}
21 \begin{twocollist}\itemsep=0pt
22 \twocolitem{{\bf EVT\_MENU\_OPEN(func)}}{A menu is about to be opened.}
23 \twocolitem{{\bf EVT\_MENU\_CLOSE(func)}}{A menu has been just closed.}
24 \twocolitem{{\bf EVT\_MENU\_HIGHLIGHT(id, func)}}{The menu item with the
25 speicifed id has been highlighted: used to show help prompts in the status bar
26 by \helpref{wxFrame}{wxframe}}
27 \twocolitem{{\bf EVT\_MENU\_HIGHLIGHT\_ALL(func)}}{A menu item has been
28 highlighted, i.e. the currently selected menu item has changed.}
29 \end{twocollist}%
30
31 \wxheading{See also}
32
33 \helpref{Command events}{wxcommandevent},\\
34 \helpref{Event handling overview}{eventhandlingoverview}
35
36 \latexignore{\rtfignore{\wxheading{Members}}}
37
38 \membersection{wxMenuEvent::wxMenuEvent}
39
40 \func{}{wxMenuEvent}{\param{WXTYPE }{id = 0}, \param{int }{id = 0}, \param{wxDC* }{dc = NULL}}
41
42 Constructor.
43
44 \membersection{wxMenuEvent::m\_menuId}
45
46 \member{int}{m\_menuId}
47
48 The relevant menu identifier.
49
50 \membersection{wxMenuEvent::GetMenuId}\label{wxmenueventgetmenuid}
51
52 \constfunc{int}{GetMenuId}{\void}
53
54 Returns the menu identifier associated with the event. This method should be
55 only used with the {\tt HIGHLIGHT} events.
56
57 \membersection{wxMenuEvent::IsPopup}\label{wxmenueventispopup}
58
59 \constfunc{bool}{IsPopup}{\void}
60
61 Returns {\tt TRUE} if the menu which is being opened or closed is a popup menu,
62 {\tt FALSE} if it is a normal one.
63
64 This method should be only used with the {\tt OPEN} and {\tt CLOSE} events.
65
66