]>
git.saurik.com Git - wxWidgets.git/blob - include/wx/gtk/pen.h
1 /////////////////////////////////////////////////////////////////////////////
4 // Author: Robert Roebling
6 // Copyright: (c) 1998 Robert Roebling
7 // Licence: wxWindows licence
8 /////////////////////////////////////////////////////////////////////////////
14 #include "wx/object.h"
15 #include "wx/string.h"
16 #include "wx/gdiobj.h"
17 #include "wx/gdicmn.h"
19 //-----------------------------------------------------------------------------
21 //-----------------------------------------------------------------------------
23 class WXDLLIMPEXP_CORE wxPen
;
25 typedef gint8 wxGTKDash
;
27 //-----------------------------------------------------------------------------
29 //-----------------------------------------------------------------------------
31 class WXDLLIMPEXP_CORE wxPen
: public wxGDIObject
36 wxPen( const wxColour
&colour
, int width
= 1, int style
= wxSOLID
);
39 bool Ok() const { return m_refData
!= NULL
; }
41 bool operator == ( const wxPen
& pen
) const;
42 bool operator != (const wxPen
& pen
) const { return !(*this == pen
); }
44 void SetColour( const wxColour
&colour
);
45 void SetColour( unsigned char red
, unsigned char green
, unsigned char blue
);
46 void SetCap( int capStyle
);
47 void SetJoin( int joinStyle
);
48 void SetStyle( int style
);
49 void SetWidth( int width
);
50 void SetDashes( int number_of_dashes
, const wxDash
*dash
);
52 wxColour
&GetColour() const;
57 int GetDashes(wxDash
**ptr
) const;
58 int GetDashCount() const;
59 wxDash
* GetDash() const;
63 virtual wxObjectRefData
*CreateRefData() const;
64 virtual wxObjectRefData
*CloneRefData(const wxObjectRefData
*data
) const;
66 DECLARE_DYNAMIC_CLASS(wxPen
)