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