]>
Commit | Line | Data |
---|---|---|
42e69d6b VZ |
1 | \section{\class{wxSplitterEvent}}\label{wxsplitterevent} |
2 | ||
65e78240 VZ |
3 | This class represents the events generated by a splitter control. Also there is |
4 | only one event class, the data associated to the different events is not the | |
5 | same and so not all accessor functions may be called for each event. The | |
2edb0bde | 6 | documentation mentions the kind of event(s) for which the given accessor |
255d88eb UB |
7 | function makes sense: calling it for other types of events will result |
8 | in assert failure (in debug mode) and will return meaningless results. | |
42e69d6b VZ |
9 | |
10 | \wxheading{Derived from} | |
11 | ||
3e58dcb9 | 12 | \helpref{wxNotifyEvent}{wxnotifyevent}\\ |
42e69d6b VZ |
13 | \helpref{wxCommandEvent}{wxcommandevent}\\ |
14 | \helpref{wxEvent}{wxevent}\\ | |
42e69d6b VZ |
15 | \helpref{wxObject}{wxobject} |
16 | ||
17 | \wxheading{Include files} | |
18 | ||
19 | <wx/splitter.h> | |
20 | ||
a7af285d VZ |
21 | \wxheading{Library} |
22 | ||
23 | \helpref{wxCore}{librarieslist} | |
24 | ||
42e69d6b VZ |
25 | \wxheading{Event table macros} |
26 | ||
27 | To process a splitter event, use these event handler macros to direct input to member | |
28 | functions that take a wxSplitterEvent argument. | |
29 | ||
65e78240 | 30 | \twocolwidtha{10cm} |
42e69d6b | 31 | \begin{twocollist}\itemsep=0pt |
255d88eb | 32 | \twocolitem{{\bf EVT\_SPLITTER\_SASH\_POS\_CHANGING(id, func)}}{The sash |
3e58dcb9 VZ |
33 | position is in the process of being changed. You may prevent this change |
34 | from happening by calling \helpref{Veto}{wxnotifyeventveto} or you may also | |
35 | modify the position of the tracking bar to properly reflect the position that | |
36 | would be set if the drag were to be completed at this point. Processes a | |
37 | wxEVT\_COMMAND\_SPLITTER\_SASH\_POS\_CHANGING event.} | |
65e78240 | 38 | \twocolitem{{\bf EVT\_SPLITTER\_SASH\_POS\_CHANGED(id, func)}}{The sash |
9ec0e7da VZ |
39 | position was changed. This event is generated after the user releases the mouse |
40 | after dragging the splitter. | |
255d88eb | 41 | Processes a wxEVT\_COMMAND\_SPLITTER\_SASH\_POS\_CHANGED event.} |
65e78240 | 42 | \twocolitem{{\bf EVT\_SPLITTER\_UNSPLIT(id, func)}}{The splitter has been just |
3e58dcb9 VZ |
43 | unsplit. Processes a wxEVT\_COMMAND\_SPLITTER\_UNSPLIT event. This event can't |
44 | be vetoed.} | |
552861bf | 45 | \twocolitem{{\bf EVT\_SPLITTER\_DCLICK(id, func)}}{The sash was double |
65e78240 | 46 | clicked. The default behaviour is to unsplit the window when this happens |
3e58dcb9 VZ |
47 | (unless the minimum pane size has been set to a value greater than zero). This |
48 | won't happen if you veto this event. Processes a | |
49 | wxEVT\_COMMAND\_SPLITTER\_DOUBLECLICKED event.} | |
42e69d6b VZ |
50 | \end{twocollist}% |
51 | ||
52 | \wxheading{See also} | |
53 | ||
e4bbf3c2 UB |
54 | \helpref{wxSplitterWindow}{wxsplitterwindow},\rtfsp |
55 | \helpref{Event handling overview}{eventhandlingoverview} | |
42e69d6b | 56 | |
255d88eb | 57 | |
42e69d6b VZ |
58 | \latexignore{\rtfignore{\wxheading{Members}}} |
59 | ||
255d88eb | 60 | |
42e69d6b VZ |
61 | \membersection{wxSplitterEvent::wxSplitterEvent}\label{wxsplittereventconstr} |
62 | ||
63 | \func{}{wxSplitterEvent}{\param{wxEventType}{ eventType = wxEVT\_NULL}, | |
64 | \param{wxSplitterWindow *}{ splitter = NULL}} | |
65 | ||
fc2171bd | 66 | Constructor. Used internally by wxWidgets only. |
42e69d6b | 67 | |
255d88eb | 68 | |
65e78240 | 69 | \membersection{wxSplitterEvent::GetSashPosition}\label{wxsplittereventgetsashposition} |
e4bbf3c2 | 70 | |
65e78240 | 71 | \constfunc{int}{GetSashPosition}{\void} |
e4bbf3c2 | 72 | |
65e78240 | 73 | Returns the new sash position. |
e4bbf3c2 UB |
74 | |
75 | May only be called while processing | |
255d88eb | 76 | wxEVT\_COMMAND\_SPLITTER\_SASH\_POS\_CHANGING and |
e4bbf3c2 UB |
77 | wxEVT\_COMMAND\_SPLITTER\_SASH\_POS\_CHANGED events. |
78 | ||
e4bbf3c2 | 79 | |
65e78240 | 80 | \membersection{wxSplitterEvent::GetX}\label{wxsplittereventgetx} |
e4bbf3c2 | 81 | |
65e78240 | 82 | \constfunc{int}{GetX}{\void} |
e4bbf3c2 | 83 | |
65e78240 | 84 | Returns the x coordinate of the double-click point. |
e4bbf3c2 UB |
85 | |
86 | May only be called while processing | |
65e78240 | 87 | wxEVT\_COMMAND\_SPLITTER\_DOUBLECLICKED events. |
e4bbf3c2 UB |
88 | |
89 | ||
65e78240 | 90 | \membersection{wxSplitterEvent::GetY}\label{wxsplittereventgety} |
e4bbf3c2 | 91 | |
65e78240 | 92 | \constfunc{int}{GetY}{\void} |
e4bbf3c2 | 93 | |
65e78240 | 94 | Returns the y coordinate of the double-click point. |
e4bbf3c2 UB |
95 | |
96 | May only be called while processing | |
65e78240 | 97 | wxEVT\_COMMAND\_SPLITTER\_DOUBLECLICKED events. |
e4bbf3c2 | 98 | |
65e78240 | 99 | \membersection{wxSplitterEvent::GetWindowBeingRemoved}\label{wxsplittereventgetwindowbeingremoved} |
e4bbf3c2 | 100 | |
65e78240 | 101 | \constfunc{wxWindow*}{GetWindowBeingRemoved}{\void} |
e4bbf3c2 | 102 | |
65e78240 VZ |
103 | Returns a pointer to the window being removed when a splitter window |
104 | is unsplit. | |
e4bbf3c2 UB |
105 | |
106 | May only be called while processing | |
65e78240 | 107 | wxEVT\_COMMAND\_SPLITTER\_UNSPLIT events. |
e4bbf3c2 UB |
108 | |
109 | ||
65e78240 | 110 | \membersection{wxSplitterEvent::SetSashPosition}\label{wxsplittereventsetsashposition} |
e4bbf3c2 | 111 | |
07d09af8 | 112 | \func{void}{SetSashPosition}{\param{int}{ pos}} |
e4bbf3c2 | 113 | |
255d88eb | 114 | In the case of wxEVT\_COMMAND\_SPLITTER\_SASH\_POS\_CHANGED events, |
43e8916f | 115 | sets the new sash position. In the case of |
255d88eb UB |
116 | wxEVT\_COMMAND\_SPLITTER\_SASH\_POS\_CHANGING events, sets the new |
117 | tracking bar position so visual feedback during dragging will | |
118 | represent that change that will actually take place. Set to -1 from | |
119 | the event handler code to prevent repositioning. | |
e4bbf3c2 UB |
120 | |
121 | May only be called while processing | |
255d88eb | 122 | wxEVT\_COMMAND\_SPLITTER\_SASH\_POS\_CHANGING and |
65e78240 | 123 | wxEVT\_COMMAND\_SPLITTER\_SASH\_POS\_CHANGED events. |
e4bbf3c2 | 124 | |
f6bcfd97 | 125 | \wxheading{Parameters} |
e4bbf3c2 | 126 | |
65e78240 | 127 | \docparam{pos}{New sash position.} |
255d88eb | 128 |