]>
Commit | Line | Data |
---|---|---|
56873923 VZ |
1 | /////////////////////////////////////////////////////////////////////////////// |
2 | // Name: wx/msw/headercol.h | |
3 | // Purpose: wxHeaderColumn implementation for MSW | |
4 | // Author: Vadim Zeitlin | |
5 | // Created: 2008-12-02 | |
6 | // RCS-ID: $Id$ | |
7 | // Copyright: (c) 2008 Vadim Zeitlin <vadim@wxwidgets.org> | |
8 | // Licence: wxWindows licence | |
9 | /////////////////////////////////////////////////////////////////////////////// | |
10 | ||
11 | #ifndef _WX_MSW_HEADERCOL_H_ | |
12 | #define _WX_MSW_HEADERCOL_H_ | |
13 | ||
14 | struct wxHDITEM; | |
15 | ||
16 | // ---------------------------------------------------------------------------- | |
17 | // wxHeaderColumn | |
18 | // ---------------------------------------------------------------------------- | |
19 | ||
20 | class WXDLLIMPEXP_CORE wxHeaderColumn : public wxHeaderColumnBase | |
21 | { | |
22 | public: | |
23 | // ctors and dtor | |
24 | wxHeaderColumn(const wxString& title, | |
25 | int width = wxCOL_WIDTH_DEFAULT, | |
26 | wxAlignment align = wxALIGN_NOT, | |
27 | int flags = wxCOL_DEFAULT_FLAGS); | |
28 | wxHeaderColumn(const wxBitmap &bitmap, | |
29 | int width = wxCOL_WIDTH_DEFAULT, | |
30 | wxAlignment align = wxALIGN_CENTER, | |
31 | int flags = wxCOL_DEFAULT_FLAGS); | |
32 | ||
33 | virtual ~wxHeaderColumn(); | |
34 | ||
35 | // implement base class pure virtuals | |
36 | virtual void SetTitle(const wxString& title); | |
37 | virtual wxString GetTitle() const; | |
38 | ||
39 | virtual void SetBitmap(const wxBitmap& bitmap); | |
40 | wxBitmap GetBitmap() const; | |
41 | ||
42 | virtual void SetWidth(int width); | |
43 | virtual int GetWidth() const; | |
44 | ||
45 | virtual void SetMinWidth(int minWidth); | |
46 | virtual int GetMinWidth() const; | |
47 | ||
48 | virtual void SetAlignment(wxAlignment align); | |
49 | virtual wxAlignment GetAlignment() const; | |
50 | ||
51 | virtual void SetClientData(wxUIntPtr data); | |
52 | virtual wxUIntPtr GetClientData() const; | |
53 | ||
54 | virtual void SetFlags(int flags); | |
55 | virtual int GetFlags() const; | |
56 | ||
57 | ||
58 | virtual void SetSortOrder(bool ascending); | |
59 | virtual bool IsSortOrderAscending() const; | |
60 | ||
61 | ||
62 | // MSW-specific implementation helpers | |
63 | wxHDITEM& GetHDI(); | |
64 | const wxHDITEM& GetHDI() const | |
65 | { | |
66 | return const_cast<wxHeaderColumn *>(this)->GetHDI(); | |
67 | } | |
68 | ||
69 | private: | |
70 | // initialize m_impl | |
71 | void Init(); | |
72 | ||
73 | struct wxMSWHeaderColumnImpl *m_impl; | |
74 | }; | |
75 | ||
76 | #endif // _WX_MSW_HEADERCOL_H_ | |
77 |