]> git.saurik.com Git - wxWidgets.git/blame - docs/latex/wx/scrolevt.inc
fixed syntax errors (incorrect use of _)
[wxWidgets.git] / docs / latex / wx / scrolevt.inc
CommitLineData
dd56228c
VZ
1\wxheading{Event table macros}
2
3To process a scroll event, use these event handler macros to direct input to
4member functions that take a wxScrollEvent argument. You can use
5{\tt EVT\_COMMAND\_SCROLL...} macros with window IDs for when intercepting
6scroll events from controls, or {\tt EVT\_SCROLL...} macros without window IDs
cbc85508 7for intercepting scroll events from the receiving window -- except for this,
2b5f62a0 8the macros behave exactly the same.
dd56228c 9
2b5f62a0 10\twocolwidtha{9cm}
dd56228c
VZ
11\begin{twocollist}\itemsep=0pt
12\twocolitem{{\bf EVT\_SCROLL(func)}}{Process all scroll events.}
15c8d3b6 13\twocolitem{{\bf EVT\_SCROLL\_TOP(func)}}{Process wxEVT\_SCROLL\_TOP scroll-to-top events (minimum position).}
e6d5afb5 14\twocolitem{{\bf EVT\_SCROLL\_BOTTOM(func)}}{Process wxEVT\_SCROLL\_BOTTOM scroll-to-bottom events (maximum position).}
dd56228c
VZ
15\twocolitem{{\bf EVT\_SCROLL\_LINEUP(func)}}{Process wxEVT\_SCROLL\_LINEUP line up events.}
16\twocolitem{{\bf EVT\_SCROLL\_LINEDOWN(func)}}{Process wxEVT\_SCROLL\_LINEDOWN line down events.}
17\twocolitem{{\bf EVT\_SCROLL\_PAGEUP(func)}}{Process wxEVT\_SCROLL\_PAGEUP page up events.}
18\twocolitem{{\bf EVT\_SCROLL\_PAGEDOWN(func)}}{Process wxEVT\_SCROLL\_PAGEDOWN page down events.}
19\twocolitem{{\bf EVT\_SCROLL\_THUMBTRACK(func)}}{Process wxEVT\_SCROLL\_THUMBTRACK thumbtrack events (frequent events
20sent as the user drags the thumbtrack).}
21\twocolitem{{\bf EVT\_SCROLL\_THUMBRELEASE(func)}}{Process wxEVT\_SCROLL\_THUMBRELEASE thumb release events.}
cbc85508 22\twocolitem{{\bf EVT\_SCROLL\_CHANGED(func)}}{Process wxEVT\_SCROLL\_CHANGED end of scrolling events (MSW only).}
dd56228c
VZ
23\twocolitem{{\bf EVT\_COMMAND\_SCROLL(id, func)}}{Process all scroll events.}
24\twocolitem{{\bf EVT\_COMMAND\_SCROLL\_TOP(id, func)}}{Process wxEVT\_SCROLL\_TOP scroll-to-top events (minimum position).}
e6d5afb5 25\twocolitem{{\bf EVT\_COMMAND\_SCROLL\_BOTTOM(id, func)}}{Process wxEVT\_SCROLL\_BOTTOM scroll-to-bottom events (maximum position).}
dd56228c
VZ
26\twocolitem{{\bf EVT\_COMMAND\_SCROLL\_LINEUP(id, func)}}{Process wxEVT\_SCROLL\_LINEUP line up events.}
27\twocolitem{{\bf EVT\_COMMAND\_SCROLL\_LINEDOWN(id, func)}}{Process wxEVT\_SCROLL\_LINEDOWN line down events.}
28\twocolitem{{\bf EVT\_COMMAND\_SCROLL\_PAGEUP(id, func)}}{Process wxEVT\_SCROLL\_PAGEUP page up events.}
29\twocolitem{{\bf EVT\_COMMAND\_SCROLL\_PAGEDOWN(id, func)}}{Process wxEVT\_SCROLL\_PAGEDOWN page down events.}
30\twocolitem{{\bf EVT\_COMMAND\_SCROLL\_THUMBTRACK(id, func)}}{Process wxEVT\_SCROLL\_THUMBTRACK thumbtrack events (frequent events
31sent as the user drags the thumbtrack).}
32\twocolitem{{\bf EVT\_COMMAND\_SCROLL\_THUMBRELEASE(func)}}{Process wxEVT\_SCROLL\_THUMBRELEASE thumb release events.}
cbc85508 33\twocolitem{{\bf EVT\_COMMAND\_SCROLL\_CHANGED(func)}}{Process wxEVT\_SCROLL\_CHANGED end of scrolling events (MSW only).}
dd56228c
VZ
34\end{twocollist}%
35
36
2b5f62a0 37
cbc85508 38\wxheading{The difference between {\tt EVT\_SCROLL\_THUMBRELEASE} and {\tt EVT\_SCROLL\_CHANGED}}
2b5f62a0
VZ
39
40The {\tt EVT\_SCROLL\_THUMBRELEASE} event is only emitted when actually dragging
41the thumb using the mouse and releasing it (This {\tt EVT\_SCROLL\_THUMBRELEASE}
cbc85508 42event is also followed by an {\tt EVT\_SCROLL\_CHANGED} event).
2b5f62a0 43
cbc85508 44The {\tt EVT\_SCROLL\_CHANGED} event also occurs when using the keyboard to
2b5f62a0
VZ
45change the thumb position, and when clicking next to the thumb (In all these
46cases the {\tt EVT\_SCROLL\_THUMBRELEASE} event does not happen).
47
cbc85508 48In short, the {\tt EVT\_SCROLL\_CHANGED} event is triggered when scrolling/
3c96417a
VZ
49moving has finished independently of the way it had started. Please see the
50widgets sample ("Slider" page) to see the difference between {\tt
51EVT\_SCROLL\_THUMBRELEASE} and {\tt EVT\_SCROLL\_CHANGED} in action.
2b5f62a0 52