A wxScrolledWindow will normally scroll itself and therefore its child windows as well. It
might however be desired to scroll a different window than itself: e.g. when designing a
A wxScrolledWindow will normally scroll itself and therefore its child windows as well. It
might however be desired to scroll a different window than itself: e.g. when designing a
(usually grey) label area will scroll very differently. For this special purpose, you can
call \helpref{SetTargetWindow}{wxscrolledwindowsettargetwindow} which means that pressing
the scrollbars will scroll a different window.
Note that the underlying system knows nothing about scrolling coordinates, so that all system
(usually grey) label area will scroll very differently. For this special purpose, you can
call \helpref{SetTargetWindow}{wxscrolledwindowsettargetwindow} which means that pressing
the scrollbars will scroll a different window.
Note that the underlying system knows nothing about scrolling coordinates, so that all system
are relative to the "physical" origin of the scrolled window. If the user insert a child window at
position (10,10) and scrolls the window down 100 pixels (moving the child window out of the visible
area), the child window will report a position of (10,-90).
are relative to the "physical" origin of the scrolled window. If the user insert a child window at
position (10,10) and scrolls the window down 100 pixels (moving the child window out of the visible
area), the child window will report a position of (10,-90).
Translates the logical coordinates to the device ones. For example, if a window is
scrolled 10 pixels to the bottom, the device coordinates of the origin are (0, 0)
(as always), but the logical coordinates are (0, 10) and so the call to
Translates the logical coordinates to the device ones. For example, if a window is
scrolled 10 pixels to the bottom, the device coordinates of the origin are (0, 0)
(as always), but the logical coordinates are (0, 10) and so the call to
-CalcScrolledPosition(0, 0, \&xx, \&yy) will return 10 in yy.
+CalcScrolledPosition(0, 10, \&xx, \&yy) will return 0 in yy.
+\pythonnote{The wxPython version of this methods accepts only two
+parameters and returns xx and yy as a tuple of values.}
+
+\perlnote{In wxPerl this method takes two parameters and returns a
+2-element list {\tt ( xx, yy )}.}
+
\membersection{wxScrolledWindow::CalcUnscrolledPosition}\label{wxscrolledwindowcalcunscrolledposition}
\constfunc{void}{CalcUnscrolledPosition}{
\membersection{wxScrolledWindow::CalcUnscrolledPosition}\label{wxscrolledwindowcalcunscrolledposition}
\constfunc{void}{CalcUnscrolledPosition}{
Translates the device coordinates to the logical ones. For example, if a window is
scrolled 10 pixels to the bottom, the device coordinates of the origin are (0, 0)
(as always), but the logical coordinates are (0, 10) and so the call to
Translates the device coordinates to the logical ones. For example, if a window is
scrolled 10 pixels to the bottom, the device coordinates of the origin are (0, 0)
(as always), but the logical coordinates are (0, 10) and so the call to
-CalcUnscrolledPosition(0, 10, \&xx, \&yy) will return 0 in yy.
+CalcUnscrolledPosition(0, 0, \&xx, \&yy) will return 10 in yy.
+\pythonnote{The wxPython version of this methods accepts only two
+parameters and returns xx and yy as a tuple of values.}
+
+\perlnote{In wxPerl this method takes two parameters and returns a
+2-element list {\tt ( xx, yy )}.}
+
\membersection{wxScrolledWindow::Create}\label{wxscrolledwindowcreate}
\func{bool}{Create}{\param{wxWindow*}{ parent}, \param{wxWindowID }{id = -1},\rtfsp
\membersection{wxScrolledWindow::Create}\label{wxscrolledwindowcreate}
\func{bool}{Create}{\param{wxWindow*}{ parent}, \param{wxWindowID }{id = -1},\rtfsp
\helpref{wxScrolledWindow::SetScrollbars}{wxscrolledwindowsetscrollbars},\rtfsp
\helpref{wxScrolledWindow::GetVirtualSize}{wxscrolledwindowgetvirtualsize}
\helpref{wxScrolledWindow::SetScrollbars}{wxscrolledwindowsetscrollbars},\rtfsp
\helpref{wxScrolledWindow::GetVirtualSize}{wxscrolledwindowgetvirtualsize}
+\pythonnote{The wxPython version of this methods accepts no
+parameters and returns a tuple of values for xUnit and yUnit.}
+
+\perlnote{In wxPerl this method takes no parameters and returns a
+2-element list {\tt ( xUnit, yUnit )}.}
+
\membersection{wxScrolledWindow::GetVirtualSize}\label{wxscrolledwindowgetvirtualsize}
\constfunc{void}{GetVirtualSize}{\param{int* }{x}, \param{int* }{y}}
\membersection{wxScrolledWindow::GetVirtualSize}\label{wxscrolledwindowgetvirtualsize}
\constfunc{void}{GetVirtualSize}{\param{int* }{x}, \param{int* }{y}}
\helpref{wxScrolledWindow::SetScrollbars}{wxscrolledwindowsetscrollbars},\rtfsp
\helpref{wxScrolledWindow::GetScrollPixelsPerUnit}{wxscrolledwindowgetscrollpixelsperunit}
\helpref{wxScrolledWindow::SetScrollbars}{wxscrolledwindowsetscrollbars},\rtfsp
\helpref{wxScrolledWindow::GetScrollPixelsPerUnit}{wxscrolledwindowgetscrollpixelsperunit}
+\pythonnote{The wxPython version of this methods accepts no
+parameters and returns a tuple of values for x and y.}
+
+\perlnote{In wxPerl this method takes no parameters and returns a
+2-element list {\tt ( x, y )}.}
+
\membersection{wxScrolledWindow::IsRetained}\label{wxscrolledwindowisretained}
\constfunc{bool}{IsRetained}{\void}
\membersection{wxScrolledWindow::IsRetained}\label{wxscrolledwindowisretained}
\constfunc{bool}{IsRetained}{\void}
\func{virtual void}{OnDraw}{\param{wxDC\& }{dc}}
Called by the default paint event handler to allow the application to define
\func{virtual void}{OnDraw}{\param{wxDC\& }{dc}}
Called by the default paint event handler to allow the application to define
\helpref{wxScrolledWindow::PrepareDC}{wxscrolledwindowpreparedc}.
Instead of overriding this function you may also just process the paint event
\helpref{wxScrolledWindow::PrepareDC}{wxscrolledwindowpreparedc}.
Instead of overriding this function you may also just process the paint event
\func{void}{SetScrollbars}{\param{int}{ pixelsPerUnitX}, \param{int}{ pixelsPerUnitY},\rtfsp
\param{int}{ noUnitsX}, \param{int}{ noUnitsY},\rtfsp
\func{void}{SetScrollbars}{\param{int}{ pixelsPerUnitX}, \param{int}{ pixelsPerUnitY},\rtfsp
\param{int}{ noUnitsX}, \param{int}{ noUnitsY},\rtfsp
-\param{int }{xPos = 0}, \param{int}{ yPos = 0}}
+\param{int }{xPos = 0}, \param{int}{ yPos = 0},\rtfsp
+\param{bool }{noRefresh = FALSE}}
Call this function to tell wxScrolledWindow to perform the actually scrolling on
a different window (not on itself).
Call this function to tell wxScrolledWindow to perform the actually scrolling on
a different window (not on itself).
+\pythonnote{The wxPython version of this methods accepts no
+parameters and returns a tuple of values for x and y.}
+
+\perlnote{In wxPerl this method takes no parameters and returns a
+2-element list {\tt ( x, y )}.}
+