]>
git.saurik.com Git - wxWidgets.git/blob - include/wx/x11/pen.h
1 /////////////////////////////////////////////////////////////////////////////
3 // Purpose: wxPen class
4 // Author: Julian Smart
8 // Copyright: (c) Julian Smart
9 // Licence: wxWindows licence
10 /////////////////////////////////////////////////////////////////////////////
16 #pragma interface "pen.h"
19 #include "wx/gdiobj.h"
20 #include "wx/colour.h"
21 #include "wx/bitmap.h"
23 //-----------------------------------------------------------------------------
25 //-----------------------------------------------------------------------------
29 typedef char wxX11Dash
;
31 //-----------------------------------------------------------------------------
33 //-----------------------------------------------------------------------------
35 class wxPen
: public wxGDIObject
40 wxPen( const wxColour
&colour
, int width
, int style
);
43 wxPen( const wxPen
& pen
) { Ref(pen
); }
44 wxPen
& operator = ( const wxPen
& pen
) { Ref(pen
); return *this; }
46 bool Ok() const { return m_refData
!= NULL
; }
48 bool operator == ( const wxPen
& pen
) const;
49 bool operator != (const wxPen
& pen
) const { return !(*this == pen
); }
51 void SetColour( const wxColour
&colour
);
52 void SetColour( int red
, int green
, int blue
);
53 void SetCap( int capStyle
);
54 void SetJoin( int joinStyle
);
55 void SetStyle( int style
);
56 void SetWidth( int width
);
57 void SetDashes( int number_of_dashes
, const wxDash
*dash
);
59 wxColour
&GetColour() const;
64 int GetDashes(wxDash
**ptr
) const;
65 int GetDashCount() const;
66 wxDash
* GetDash() const;
70 virtual wxObjectRefData
*CreateRefData() const;
71 virtual wxObjectRefData
*CloneRefData(const wxObjectRefData
*data
) const;
73 DECLARE_DYNAMIC_CLASS(wxPen
)