1998-05-20 10:25:30 -04:00
|
|
|
\section{\class{wxScrollEvent}}\label{wxscrollevent}
|
|
|
|
|
1999-07-26 10:28:25 -04:00
|
|
|
A scroll event holds information about events sent from stand-alone scrollbars,
|
|
|
|
spin-buttons and sliders - starting from wxWindows 2.1, scrolled windows send the
|
|
|
|
\helpref{wxScrollWinEvent}{wxscrollwinevent} which does not derive from
|
|
|
|
wxCommandEvent, but from wxEvent directly.
|
1998-05-20 10:25:30 -04:00
|
|
|
|
|
|
|
\wxheading{Derived from}
|
|
|
|
|
|
|
|
\helpref{wxCommandEvent}{wxcommandevent}\\
|
|
|
|
\helpref{wxEvent}{wxevent}\\
|
|
|
|
\helpref{wxObject}{wxobject}
|
|
|
|
|
1999-02-15 15:41:29 -05:00
|
|
|
\wxheading{Include files}
|
|
|
|
|
|
|
|
<wx/event.h>
|
|
|
|
|
1998-05-20 10:25:30 -04:00
|
|
|
\wxheading{Event table macros}
|
|
|
|
|
|
|
|
To process a scroll event, use these event handler macros to direct input to member
|
|
|
|
functions that take a wxScrollEvent argument. You can use EVT\_COMMAND\_SCROLL... macros
|
|
|
|
with window IDs for when intercepting scroll events from controls, or EVT\_SCROLL... macros
|
|
|
|
without window IDs for intercepting scroll events from the receiving window.
|
|
|
|
|
|
|
|
\twocolwidtha{7cm}
|
|
|
|
\begin{twocollist}\itemsep=0pt
|
|
|
|
\twocolitem{{\bf EVT\_SCROLL(func)}}{Process all scroll events.}
|
|
|
|
\twocolitem{{\bf EVT\_SCROLL\_TOP(func)}}{Process wxEVT\_SCROLL\_TOP scroll-to-top events.}
|
|
|
|
\twocolitem{{\bf EVT\_SCROLL\_BOTTOM(func)}}{Process wxEVT\_SCROLL\_TOP scroll-to-bottom events.}
|
|
|
|
\twocolitem{{\bf EVT\_SCROLL\_LINEUP(func)}}{Process wxEVT\_SCROLL\_LINEUP line up events.}
|
|
|
|
\twocolitem{{\bf EVT\_SCROLL\_LINEDOWN(func)}}{Process wxEVT\_SCROLL\_LINEDOWN line down events.}
|
|
|
|
\twocolitem{{\bf EVT\_SCROLL\_PAGEUP(func)}}{Process wxEVT\_SCROLL\_PAGEUP page up events.}
|
|
|
|
\twocolitem{{\bf EVT\_SCROLL\_PAGEDOWN(func)}}{Process wxEVT\_SCROLL\_PAGEDOWN page down events.}
|
|
|
|
\twocolitem{{\bf EVT\_SCROLL\_THUMBTRACK(func)}}{Process wxEVT\_SCROLL\_THUMBTRACK thumbtrack events (frequent events
|
|
|
|
sent as the user drags the thumtrack).}
|
2000-02-15 04:37:39 -05:00
|
|
|
\twocolitem{{\bf EVT\_SCROLL\_THUMBRELEASE(func)}}{Process wxEVT\_SCROLL\_THUMBRELEASE thumb release events.}
|
1998-05-20 10:25:30 -04:00
|
|
|
\twocolitem{{\bf EVT\_COMMAND\_SCROLL(id, func)}}{Process all scroll events.}
|
|
|
|
\twocolitem{{\bf EVT\_COMMAND\_SCROLL\_TOP(id, func)}}{Process wxEVT\_SCROLL\_TOP scroll-to-top events.}
|
|
|
|
\twocolitem{{\bf EVT\_COMMAND\_SCROLL\_BOTTOM(id, func)}}{Process wxEVT\_SCROLL\_TOP scroll-to-bottom events.}
|
|
|
|
\twocolitem{{\bf EVT\_COMMAND\_SCROLL\_LINEUP(id, func)}}{Process wxEVT\_SCROLL\_LINEUP line up events.}
|
|
|
|
\twocolitem{{\bf EVT\_COMMAND\_SCROLL\_LINEDOWN(id, func)}}{Process wxEVT\_SCROLL\_LINEDOWN line down events.}
|
|
|
|
\twocolitem{{\bf EVT\_COMMAND\_SCROLL\_PAGEUP(id, func)}}{Process wxEVT\_SCROLL\_PAGEUP page up events.}
|
|
|
|
\twocolitem{{\bf EVT\_COMMAND\_SCROLL\_PAGEDOWN(id, func)}}{Process wxEVT\_SCROLL\_PAGEDOWN page down events.}
|
|
|
|
\twocolitem{{\bf EVT\_COMMAND\_SCROLL\_THUMBTRACK(id, func)}}{Process wxEVT\_SCROLL\_THUMBTRACK thumbtrack events (frequent events
|
|
|
|
sent as the user drags the thumtrack).}
|
|
|
|
\end{twocollist}%
|
|
|
|
|
|
|
|
\wxheading{Remarks}
|
|
|
|
|
|
|
|
Note that unless specifying a scroll control identifier, you will need to test for scrollbar
|
|
|
|
orientation with \helpref{wxScrollEvent::GetOrientation}{wxscrolleventgetorientation}, since
|
|
|
|
horizontal and vertical scroll events are processed using the same event handler.
|
|
|
|
|
|
|
|
\wxheading{See also}
|
|
|
|
|
1999-07-26 10:28:25 -04:00
|
|
|
\helpref{wxScrollBar}{wxscrollbar}, \helpref{wxSlider}{wxslider}, \helpref{wxSpinButton}{wxspinbutton}, \\
|
|
|
|
\helpref{wxScrollWinEvent}{wxscrollwinevent}, \helpref{Event handling overview}{eventhandlingoverview}
|
1998-05-20 10:25:30 -04:00
|
|
|
|
|
|
|
\latexignore{\rtfignore{\wxheading{Members}}}
|
|
|
|
|
|
|
|
\membersection{wxScrollEvent::wxScrollEvent}
|
|
|
|
|
|
|
|
\func{}{wxScrollEvent}{\param{WXTYPE }{commandType = 0}, \param{int }{id = 0}, \param{int}{ pos = 0},
|
|
|
|
\rtfsp\param{int}{ orientation = 0}}
|
|
|
|
|
|
|
|
Constructor.
|
|
|
|
|
|
|
|
\membersection{wxScrollEvent::GetOrientation}\label{wxscrolleventgetorientation}
|
|
|
|
|
|
|
|
\constfunc{int}{GetOrientation}{\void}
|
|
|
|
|
|
|
|
Returns wxHORIZONTAL or wxVERTICAL, depending on the orientation of the scrollbar.
|
|
|
|
|
|
|
|
\membersection{wxScrollEvent::GetPosition}\label{wxscrolleventgetposition}
|
|
|
|
|
|
|
|
\constfunc{int}{GetPosition}{\void}
|
|
|
|
|
|
|
|
Returns the position of the scrollbar.
|
|
|
|
|