1 #############################################################################
2 ## Name: XS/ScrolledWindow.xs
3 ## Purpose: XS for Wx::ScrolledWindow
4 ## Author: Mattia Barbon
7 ## RCS-ID: $Id: ScrolledWindow.xs 2285 2007-11-11 21:31:54Z mbarbon $
8 ## Copyright: (c) 2000-2003, 2005-2007 Mattia Barbon
9 ## Licence: This program is free software; you can redistribute it and/or
10 ## modify it under the same terms as Perl itself
11 #############################################################################
13 #include <wx/scrolwin.h>
15 #include "cpp/scrolledwindow.h"
17 MODULE=Wx PACKAGE=Wx::ScrolledWindow
23 MATCH_VOIDM_REDISP( newDefault )
24 MATCH_ANY_REDISP( newFull )
25 END_OVERLOAD( "Wx::ScrolledWindow::new" )
31 RETVAL = new wxPliScrolledWindow( CLASS );
32 wxPli_create_evthandler( aTHX_ RETVAL, CLASS );
36 newFull( CLASS, parent, id = wxID_ANY, pos = wxDefaultPosition, size = wxDefaultSize, style = wxHSCROLL|wxVSCROLL, name = wxPanelNameStr )
45 RETVAL = new wxPliScrolledWindow( CLASS, parent, id, pos, size, style,
51 wxScrolledWindow::Create( parent, id = wxID_ANY, pos = wxDefaultPosition, size = wxDefaultSize, style = wxHSCROLL|wxVSCROLL, name = wxPanelNameStr )
60 wxScrolledWindow::CalcScrolledPosition( x, y )
67 THIS->CalcScrolledPosition( x, y, &xx, &yy );
69 PUSHs( sv_2mortal( newSViv( xx ) ) );
70 PUSHs( sv_2mortal( newSViv( yy ) ) );
73 wxScrolledWindow::CalcUnscrolledPosition( x, y )
80 THIS->CalcUnscrolledPosition( x, y, &xx, &yy );
82 PUSHs( sv_2mortal( newSViv( xx ) ) );
83 PUSHs( sv_2mortal( newSViv( yy ) ) );
86 wxScrolledWindow::EnableScrolling( xScrolling, yScrolling )
91 wxScrolledWindow::GetScrollPixelsPerUnit()
96 THIS->GetScrollPixelsPerUnit( &xUnit, &yUnit );
98 PUSHs( sv_2mortal( newSViv( xUnit ) ) );
99 PUSHs( sv_2mortal( newSViv( yUnit ) ) );
102 wxScrolledWindow::GetVirtualSize()
107 THIS->GetVirtualSize( &x, &y );
109 PUSHs( sv_2mortal( newSViv( x ) ) );
110 PUSHs( sv_2mortal( newSViv( y ) ) );
113 wxScrolledWindow::IsRetained()
116 wxScrolledWindow::PrepareDC( dc )
119 THIS->PrepareDC( *dc );
122 wxScrolledWindow::DoPrepareDC( dc )
127 wxScrolledWindow::Scroll( x, y )
132 wxScrolledWindow::SetScrollbars( ppuX, ppuY, nX, nY, xPos = 0, yPos = 0, noRefresh = false )
142 wxScrolledWindow::SetScrollRate( xstep, ystep )
147 wxScrolledWindow::SetTargetWindow( window )
151 wxScrolledWindow::GetViewStart()
156 THIS->GetViewStart( &x, &y );
158 PUSHs( sv_2mortal( newSViv( x ) ) );
159 PUSHs( sv_2mortal( newSViv( y ) ) );