]>
git.saurik.com Git - wxWidgets.git/blob - include/wx/gtk1/dcclient.h
1 /////////////////////////////////////////////////////////////////////////////
4 // Author: Robert Roebling
6 // Copyright: (c) 1998 Robert Roebling
7 // Licence: wxWindows licence
8 /////////////////////////////////////////////////////////////////////////////
11 #ifndef __GTKDCCLIENTH__
12 #define __GTKDCCLIENTH__
19 #include "wx/window.h"
21 //-----------------------------------------------------------------------------
23 //-----------------------------------------------------------------------------
29 //-----------------------------------------------------------------------------
31 //-----------------------------------------------------------------------------
33 class wxWindowDC
: public wxDC
35 DECLARE_DYNAMIC_CLASS(wxWindowDC
)
39 wxWindowDC( wxWindow
*win
);
43 virtual void FloodFill( long x1
, long y1
, wxColour
*col
, int style
=wxFLOOD_SURFACE
);
44 virtual bool GetPixel( long x1
, long y1
, wxColour
*col
) const;
46 virtual void DrawLine( long x1
, long y1
, long x2
, long y2
);
47 virtual void CrossHair( long x
, long y
);
48 virtual void DrawArc( long x1
, long y1
, long x2
, long y2
, double xc
, double yc
);
49 virtual void DrawEllipticArc( long x
, long y
, long width
, long height
, double sa
, double ea
);
50 virtual void DrawPoint( long x
, long y
);
52 virtual void DrawLines( int n
, wxPoint points
[], long xoffset
= 0, long yoffset
= 0 );
53 virtual void DrawLines( wxList
*points
, long xoffset
= 0, long yoffset
= 0 );
54 virtual void DrawPolygon( int n
, wxPoint points
[], long xoffset
= 0, long yoffset
= 0,
55 int fillStyle
=wxODDEVEN_RULE
);
56 virtual void DrawPolygon( wxList
*lines
, long xoffset
= 0, long yoffset
= 0,
57 int fillStyle
=wxODDEVEN_RULE
);
59 virtual void DrawRectangle( long x
, long y
, long width
, long height
);
60 virtual void DrawRoundedRectangle( long x
, long y
, long width
, long height
, double radius
= 20.0 );
61 virtual void DrawEllipse( long x
, long y
, long width
, long height
);
63 virtual bool CanDrawBitmap(void) const;
64 virtual void DrawIcon( const wxIcon
&icon
, long x
, long y
, bool useMask
=FALSE
);
65 virtual bool Blit( long xdest
, long ydest
, long width
, long height
,
66 wxDC
*source
, long xsrc
, long ysrc
, int logical_func
= wxCOPY
, bool useMask
=FALSE
);
68 virtual void DrawText( const wxString
&text
, long x
, long y
, bool use16
= FALSE
);
69 virtual bool CanGetTextExtent(void) const;
70 virtual void GetTextExtent( const wxString
&string
, long *width
, long *height
,
71 long *descent
= (long *) NULL
, long *externalLeading
= (long *) NULL
,
72 wxFont
*theFont
= (wxFont
*) NULL
, bool use16
= FALSE
);
73 virtual long GetCharWidth(void);
74 virtual long GetCharHeight(void);
76 virtual void Clear(void);
78 virtual void SetFont( const wxFont
&font
);
79 virtual void SetPen( const wxPen
&pen
);
80 virtual void SetBrush( const wxBrush
&brush
);
81 virtual void SetBackground( const wxBrush
&brush
);
82 virtual void SetLogicalFunction( int function
);
83 virtual void SetTextForeground( const wxColour
&col
);
84 virtual void SetTextBackground( const wxColour
&col
);
85 virtual void SetBackgroundMode( int mode
);
86 virtual void SetPalette( const wxPalette
& palette
);
88 virtual void SetClippingRegion( long x
, long y
, long width
, long height
);
89 virtual void DestroyClippingRegion(void);
91 virtual void DrawSpline( wxList
*points
);
105 GdkWindow
*GetWindow(void);
108 //-----------------------------------------------------------------------------
110 //-----------------------------------------------------------------------------
112 class wxPaintDC
: public wxWindowDC
114 DECLARE_DYNAMIC_CLASS(wxPaintDC
)
118 wxPaintDC( wxWindow
*win
);
121 //-----------------------------------------------------------------------------
123 //-----------------------------------------------------------------------------
125 class wxClientDC
: public wxWindowDC
127 DECLARE_DYNAMIC_CLASS(wxClientDC
)
131 wxClientDC( wxWindow
*win
);
135 #endif // __GTKDCCLIENTH__