]>
git.saurik.com Git - wxWidgets.git/blob - include/wx/motif/dcclient.h
ed895a982b29618fafa51572ff76277533f155fc
1 /////////////////////////////////////////////////////////////////////////////
3 // Purpose: wxClientDC, wxPaintDC and wxWindowDC classes
4 // Author: Julian Smart
8 // Copyright: (c) Julian Smart
9 // Licence: wxWindows licence
10 /////////////////////////////////////////////////////////////////////////////
12 #ifndef _WX_DCCLIENT_H_
13 #define _WX_DCCLIENT_H_
16 #pragma interface "dcclient.h"
21 //-----------------------------------------------------------------------------
23 //-----------------------------------------------------------------------------
25 class WXDLLEXPORT wxPaintDC
;
26 class WXDLLEXPORT wxWindow
;
28 // Under Windows, wxClientDC, wxPaintDC and wxWindowDC are implemented differently.
29 // On many platforms, however, they will be the same.
31 typedef wxPaintDC wxClientDC
;
32 typedef wxPaintDC wxWindowDC
;
34 //-----------------------------------------------------------------------------
36 //-----------------------------------------------------------------------------
38 class WXDLLEXPORT wxPaintDC
: public wxDC
40 DECLARE_DYNAMIC_CLASS(wxPaintDC
)
45 wxPaintDC( wxWindow
*win
);
49 virtual void FloodFill( long x1
, long y1
, wxColour
* col
, int style
=wxFLOOD_SURFACE
);
50 virtual bool GetPixel( long x1
, long y1
, wxColour
*col
) const;
52 virtual void DrawLine( long x1
, long y1
, long x2
, long y2
);
53 virtual void CrossHair( long x
, long y
);
54 virtual void DrawArc( long x1
, long y1
, long x2
, long y2
, long xc
, long yc
);
55 virtual void DrawEllipticArc( long x
, long y
, long width
, long height
, double sa
, double ea
);
56 virtual void DrawPoint( long x
, long y
);
58 virtual void DrawLines( int n
, wxPoint points
[], long xoffset
= 0, long yoffset
= 0 );
59 virtual void DrawLines( wxList
*points
, long xoffset
= 0, long yoffset
= 0 );
60 virtual void DrawPolygon( int n
, wxPoint points
[], long xoffset
= 0, long yoffset
= 0,
61 int fillStyle
=wxODDEVEN_RULE
);
62 virtual void DrawPolygon( wxList
*lines
, long xoffset
= 0, long yoffset
= 0,
63 int fillStyle
=wxODDEVEN_RULE
);
65 virtual void DrawRectangle( long x
, long y
, long width
, long height
);
66 virtual void DrawRoundedRectangle( long x
, long y
, long width
, long height
, double radius
= 20.0 );
67 virtual void DrawEllipse( long x
, long y
, long width
, long height
);
69 virtual bool CanDrawBitmap(void) const;
70 virtual void DrawIcon( const wxIcon
&icon
, long x
, long y
, bool useMask
=FALSE
);
71 virtual bool Blit( long xdest
, long ydest
, long width
, long height
,
72 wxDC
*source
, long xsrc
, long ysrc
, int logical_func
= wxCOPY
, bool useMask
=FALSE
);
74 virtual void DrawText( const wxString
&text
, long x
, long y
, bool use16
= FALSE
);
75 virtual bool CanGetTextExtent(void) const;
76 virtual void GetTextExtent( const wxString
&string
, long *width
, long *height
,
77 long *descent
= NULL
, long *externalLeading
= NULL
,
78 wxFont
*theFont
= NULL
, bool use16
= FALSE
);
79 virtual long GetCharWidth(void);
80 virtual long GetCharHeight(void);
82 virtual void Clear(void);
84 virtual void SetFont( const wxFont
&font
);
85 virtual void SetPen( const wxPen
&pen
);
86 virtual void SetBrush( const wxBrush
&brush
);
87 virtual void SetBackground( const wxBrush
&brush
);
88 virtual void SetLogicalFunction( int function
);
89 virtual void SetTextForeground( const wxColour
&col
);
90 virtual void SetTextBackground( const wxColour
&col
);
91 virtual void SetBackgroundMode( int mode
);
92 virtual void SetPalette( const wxPalette
& palette
);
94 virtual void SetClippingRegion( long x
, long y
, long width
, long height
);
95 virtual void DestroyClippingRegion(void);
97 virtual void DrawOpenSpline( wxList
*points
);