]>
git.saurik.com Git - wxWidgets.git/blob - include/wx/gtk1/dcclient.h
1 /////////////////////////////////////////////////////////////////////////////
4 // Author: Robert Roebling
7 // Copyright: (c) 1998 Robert Roebling, Julian Smart and Markus Holzem
8 // Licence: wxWindows licence
9 /////////////////////////////////////////////////////////////////////////////
12 #ifndef __GTKDCCLIENTH__
13 #define __GTKDCCLIENTH__
20 #include "wx/window.h"
22 //-----------------------------------------------------------------------------
24 //-----------------------------------------------------------------------------
27 typedef wxPaintDC wxClientDC
;
28 typedef wxPaintDC wxWindowDC
;
30 //-----------------------------------------------------------------------------
32 //-----------------------------------------------------------------------------
34 class wxPaintDC
: public wxDC
36 DECLARE_DYNAMIC_CLASS(wxPaintDC
)
41 wxPaintDC( wxWindow
*win
);
45 virtual void FloodFill( long x1
, long y1
, wxColour
*col
, int style
=wxFLOOD_SURFACE
);
46 virtual bool GetPixel( long x1
, long y1
, wxColour
*col
) const;
48 virtual void DrawLine( long x1
, long y1
, long x2
, long y2
);
49 virtual void CrossHair( long x
, long y
);
50 virtual void DrawArc( long x1
, long y1
, long x2
, long y2
, double xc
, double yc
);
51 virtual void DrawEllipticArc( long x
, long y
, long width
, long height
, double sa
, double ea
);
52 virtual void DrawPoint( long x
, long y
);
54 virtual void DrawLines( int n
, wxPoint points
[], long xoffset
= 0, long yoffset
= 0 );
55 virtual void DrawLines( wxList
*points
, long xoffset
= 0, long yoffset
= 0 );
56 virtual void DrawPolygon( int n
, wxPoint points
[], long xoffset
= 0, long yoffset
= 0,
57 int fillStyle
=wxODDEVEN_RULE
);
58 virtual void DrawPolygon( wxList
*lines
, long xoffset
= 0, long yoffset
= 0,
59 int fillStyle
=wxODDEVEN_RULE
);
61 virtual void DrawRectangle( long x
, long y
, long width
, long height
);
62 virtual void DrawRoundedRectangle( long x
, long y
, long width
, long height
, double radius
= 20.0 );
63 virtual void DrawEllipse( long x
, long y
, long width
, long height
);
65 virtual bool CanDrawBitmap(void) const;
66 virtual void DrawIcon( const wxIcon
&icon
, long x
, long y
, bool useMask
=FALSE
);
67 virtual bool Blit( long xdest
, long ydest
, long width
, long height
,
68 wxDC
*source
, long xsrc
, long ysrc
, int logical_func
= wxCOPY
, bool useMask
=FALSE
);
70 virtual void DrawText( const wxString
&text
, long x
, long y
, bool use16
= FALSE
);
71 virtual bool CanGetTextExtent(void) const;
72 virtual void GetTextExtent( const wxString
&string
, long *width
, long *height
,
73 long *descent
= NULL
, long *externalLeading
= NULL
,
74 wxFont
*theFont
= NULL
, bool use16
= FALSE
);
75 virtual long GetCharWidth(void);
76 virtual long GetCharHeight(void);
78 virtual void Clear(void);
80 virtual void SetFont( const wxFont
&font
);
81 virtual void SetPen( const wxPen
&pen
);
82 virtual void SetBrush( const wxBrush
&brush
);
83 virtual void SetBackground( const wxBrush
&brush
);
84 virtual void SetLogicalFunction( int function
);
85 virtual void SetTextForeground( const wxColour
&col
);
86 virtual void SetTextBackground( const wxColour
&col
);
87 virtual void SetBackgroundMode( int mode
);
88 virtual void SetPalette( const wxPalette
& palette
);
90 virtual void SetClippingRegion( long x
, long y
, long width
, long height
);
91 virtual void DestroyClippingRegion(void);
93 virtual void DrawOpenSpline( wxList
*points
);
95 public: // shouldn't be public
106 GdkWindow
*GetWindow(void);
109 #endif // __GTKDCCLIENTH__