#include "wx/dcclient.h"
#include "wx/dcmemory.h"
#include "wx/region.h"
+#include "wx/window.h"
#include <math.h>
//-----------------------------------------------------------------------------
#include <wx/mac/uma.h>
-wxWindowDC::wxWindowDC(void)
+wxWindowDC::wxWindowDC()
{
}
-wxWindowDC::wxWindowDC(wxWindow *the_canvas)
+wxWindowDC::wxWindowDC(wxWindow *the_canvas)
{
WindowRef windowref ;
wxWindow* rootwindow ;
the_canvas->MacGetPortParams(&m_macLocalOrigin, &m_macClipRect , &windowref , &rootwindow );
m_macPort = UMAGetWindowPort( windowref ) ;
+ m_minY = m_minX = 0;
+ wxSize size = the_canvas->GetSize() ;
+ m_maxX = size.x ;
+ m_maxY = size.y ;
+
MacSetupPort() ;
m_ok = TRUE ;
}
-wxWindowDC::~wxWindowDC(void)
+wxWindowDC::~wxWindowDC()
{
}
* wxClientDC
*/
-wxClientDC::wxClientDC(void)
+wxClientDC::wxClientDC()
{
}
window->MacGetPortClientParams(&m_macLocalOrigin, &m_macClipRect , &windowref , &rootwindow );
m_macPort = UMAGetWindowPort( windowref ) ;
MacSetupPort() ;
+ m_minY = m_minX = 0;
+ wxSize size = window->GetSize() ;
+ m_maxX = size.x ;
+ m_maxY = size.y ;
m_ok = TRUE ;
SetBackground(wxBrush(window->GetBackgroundColour(), wxSOLID));
SetFont( window->GetFont() ) ;
}
-wxClientDC::~wxClientDC(void)
+wxClientDC::~wxClientDC()
{
}
* wxPaintDC
*/
-wxPaintDC::wxPaintDC(void)
+wxPaintDC::wxPaintDC()
{
}
m_macPort = UMAGetWindowPort( windowref ) ;
MacSetupPort() ;
m_ok = TRUE ;
- long x , y ,w , h ;
+ wxCoord x , y ,w , h ;
window->GetUpdateRegion().GetBox( x , y , w , h ) ;
+ m_minY = m_minX = 0;
+ wxSize size = window->GetSize() ;
+ m_maxX = size.x ;
+ m_maxY = size.y ;
SetClippingRegion( x , y , w , h ) ;
SetBackground(wxBrush(window->GetBackgroundColour(), wxSOLID));
SetFont(window->GetFont() ) ;