]>
git.saurik.com Git - wxWidgets.git/blob - include/wx/gtk1/pen.h
ccb83697037a7b1c3338f627f0312d428fbc1bef
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 #if defined(__WXGTK127__) || defined(__WXGTK20__)
26 typedef gint8 wxGTKDash
;
28 typedef gchar wxGTKDash
;
31 //-----------------------------------------------------------------------------
33 //-----------------------------------------------------------------------------
35 class WXDLLIMPEXP_CORE wxPen
: public wxGDIObject
40 wxPen( const wxColour
&colour
, int width
= 1, int style
= wxSOLID
);
43 wxPen( const wxPen
& pen
)
46 wxPen
& operator = ( const wxPen
& pen
) { Ref(pen
); return *this; }
48 bool Ok() const { return m_refData
!= NULL
; }
50 bool operator == ( const wxPen
& pen
) const;
51 bool operator != (const wxPen
& pen
) const { return !(*this == pen
); }
53 void SetColour( const wxColour
&colour
);
54 void SetColour( int red
, int green
, int blue
);
55 void SetCap( int capStyle
);
56 void SetJoin( int joinStyle
);
57 void SetStyle( int style
);
58 void SetWidth( int width
);
59 void SetDashes( int number_of_dashes
, const wxDash
*dash
);
61 wxColour
&GetColour() const;
66 int GetDashes(wxDash
**ptr
) const;
67 int GetDashCount() const;
68 wxDash
* GetDash() const;
72 virtual wxObjectRefData
*CreateRefData() const;
73 virtual wxObjectRefData
*CloneRefData(const wxObjectRefData
*data
) const;
75 DECLARE_DYNAMIC_CLASS(wxPen
)