]> git.saurik.com Git - wxWidgets.git/blobdiff - src/gtk1/dcclient.cpp
Some OS/2 customization to make a more presentable statusbar.
[wxWidgets.git] / src / gtk1 / dcclient.cpp
index 0cad4913f8f4ddfcc1dc3d43f3576fd44c579550..588fbb5501ddae3a84d37644a09eea86600fdc0e 100644 (file)
 #pragma implementation "dcclient.h"
 #endif
 
+#ifdef __VMS
+#define XCopyPlane XCOPYPLANE
+#endif
+
 #include "wx/dcclient.h"
 #include "wx/dcmemory.h"
 #include "wx/image.h"
@@ -389,6 +393,13 @@ void wxWindowDC::SetUpDC()
     }
 }
 
+void wxWindowDC::DoGetSize( int* width, int* height ) const
+{
+    wxCHECK_RET( m_owner, _T("GetSize() doesn't work without window") );
+
+    m_owner->GetSize(width, height);
+}
+
 void wxWindowDC::DoFloodFill( wxCoord WXUNUSED(x), wxCoord WXUNUSED(y),
                            const wxColour &WXUNUSED(col), int WXUNUSED(style) )
 {
@@ -522,7 +533,12 @@ void wxWindowDC::DoDrawArc( wxCoord x1, wxCoord y1, wxCoord x2, wxCoord y2,
         }
 
         if (m_pen.GetStyle() != wxTRANSPARENT)
+        {
             gdk_draw_arc( m_window, m_penGC, FALSE, xxc-r, yyc-r, 2*r,2*r, alpha1, alpha2 );
+
+            gdk_draw_line( m_window, m_penGC, xx1, yy1, xxc, yyc );
+            gdk_draw_line( m_window, m_penGC, xxc, yyc, xx2, yy2 );
+        }
     }
 
     CalcBoundingBox (x1, y1);
@@ -545,7 +561,7 @@ void wxWindowDC::DoDrawEllipticArc( wxCoord x, wxCoord y, wxCoord width, wxCoord
     if (m_window)
     {
         wxCoord start = wxCoord(sa * 64.0);
-        wxCoord end = wxCoord(ea * 64.0);
+        wxCoord end = wxCoord((ea-sa) * 64.0);
 
         if (m_brush.GetStyle() != wxTRANSPARENT)
         {
@@ -2208,20 +2224,15 @@ void wxWindowDC::DoDrawSpline( wxList *points )
 // wxPaintDC
 //-----------------------------------------------------------------------------
 
-IMPLEMENT_DYNAMIC_CLASS(wxPaintDC,wxWindowDC)
-
-wxPaintDC::wxPaintDC()
-  : wxWindowDC()
-{
-}
+IMPLEMENT_DYNAMIC_CLASS(wxPaintDC, wxClientDC)
 
 wxPaintDC::wxPaintDC( wxWindow *win )
-  : wxWindowDC( win )
+         : wxClientDC( win )
 {
 #if USE_PAINT_REGION
     if (!win->m_clipPaintRegion)
         return;
-        
+
     m_paintClippingRegion = win->GetUpdateRegion();
     GdkRegion *region = m_paintClippingRegion.GetRegion();
     if ( region )
@@ -2240,16 +2251,18 @@ wxPaintDC::wxPaintDC( wxWindow *win )
 // wxClientDC
 //-----------------------------------------------------------------------------
 
-IMPLEMENT_DYNAMIC_CLASS(wxClientDC,wxWindowDC)
+IMPLEMENT_DYNAMIC_CLASS(wxClientDC, wxWindowDC)
 
-wxClientDC::wxClientDC()
-  : wxWindowDC()
+wxClientDC::wxClientDC( wxWindow *win )
+          : wxWindowDC( win )
 {
 }
 
-wxClientDC::wxClientDC( wxWindow *win )
-  : wxWindowDC( win )
+void wxClientDC::DoGetSize(int *width, int *height) const
 {
+    wxCHECK_RET( m_owner, _T("GetSize() doesn't work without window") );
+
+    m_owner->GetClientSize( width, height );
 }
 
 // ----------------------------------------------------------------------------