]> git.saurik.com Git - wxWidgets.git/blob - include/wx/gtk/pen.h
enabling alpha on msw colour
[wxWidgets.git] / include / wx / gtk / pen.h
1 /////////////////////////////////////////////////////////////////////////////
2 // Name: wx/gtk/pen.h
3 // Purpose:
4 // Author: Robert Roebling
5 // Id: $Id$
6 // Copyright: (c) 1998 Robert Roebling
7 // Licence: wxWindows licence
8 /////////////////////////////////////////////////////////////////////////////
9
10 #ifndef _WX_GTK_PEN_H_
11 #define _WX_GTK_PEN_H_
12
13 #include "wx/gdiobj.h"
14 #include "wx/gdicmn.h"
15
16 typedef gint8 wxGTKDash;
17
18 //-----------------------------------------------------------------------------
19 // wxPen
20 //-----------------------------------------------------------------------------
21
22 class WXDLLIMPEXP_CORE wxPen: public wxGDIObject
23 {
24 public:
25 wxPen() { }
26
27 wxPen( const wxColour &colour, int width = 1, int style = wxSOLID );
28 virtual ~wxPen();
29
30 bool Ok() const { return m_refData != NULL; }
31
32 bool operator == ( const wxPen& pen ) const;
33 bool operator != (const wxPen& pen) const { return !(*this == pen); }
34
35 void SetColour( const wxColour &colour );
36 void SetColour( unsigned char red, unsigned char green, unsigned char blue );
37 void SetCap( int capStyle );
38 void SetJoin( int joinStyle );
39 void SetStyle( int style );
40 void SetWidth( int width );
41 void SetDashes( int number_of_dashes, const wxDash *dash );
42
43 wxColour &GetColour() const;
44 int GetCap() const;
45 int GetJoin() const;
46 int GetStyle() const;
47 int GetWidth() const;
48 int GetDashes(wxDash **ptr) const;
49 int GetDashCount() const;
50 wxDash* GetDash() const;
51
52 protected:
53 // ref counting code
54 virtual wxObjectRefData *CreateRefData() const;
55 virtual wxObjectRefData *CloneRefData(const wxObjectRefData *data) const;
56
57 DECLARE_DYNAMIC_CLASS(wxPen)
58 };
59
60 #endif // _WX_GTK_PEN_H_