]>
git.saurik.com Git - wxWidgets.git/blob - include/wx/gtk1/notebook.h
1 /////////////////////////////////////////////////////////////////////////////
3 // Purpose: wxTabCtrl class
4 // Author: Robert Roebling
7 // Copyright: (c) Julian Smart and Markus Holzem
8 // Licence: wxWindows license
9 /////////////////////////////////////////////////////////////////////////////
15 #pragma interface "notebook.h"
19 #include "wx/object.h"
20 #include "wx/string.h"
21 #include "wx/control.h"
23 //-----------------------------------------------------------------------------
25 //-----------------------------------------------------------------------------
32 //-----------------------------------------------------------------------------
34 //-----------------------------------------------------------------------------
37 //-----------------------------------------------------------------------------
39 //-----------------------------------------------------------------------------
41 class wxNotebook
: public wxControl
43 DECLARE_DYNAMIC_CLASS(wxNotebook
)
48 wxNotebook( wxWindow
*parent
, const wxWindowID id
,
49 const wxPoint
& pos
= wxDefaultPosition
, const wxSize
& size
= wxDefaultSize
,
50 const long style
= 0, const wxString
& name
= "notebook" );
52 bool Create(wxWindow
*parent
, const wxWindowID id
,
53 const wxPoint
& pos
= wxDefaultPosition
, const wxSize
& size
= wxDefaultSize
,
54 const long style
= 0, const wxString
& name
= "notebook" );
55 int GetSelection(void) const;
56 wxImageList
* GetImageList(void) const;
57 int GetPageCount(void) const;
58 int GetRowCount(void) const;
59 wxString
GetPageText( const int page
) const;
60 int GetPageImage( const int page
) const;
61 void* GetPageData( const int page
) const;
62 int SetSelection( const int page
);
63 void SetImageList( wxImageList
* imageList
);
64 bool SetPageText( const int page
, const wxString
& text
);
65 bool SetPageImage( const int oage
, const int image
);
66 bool SetPageData( const int page
, void* data
);
67 void SetPageSize( const wxSize
& size
);
68 void SetPadding( const wxSize
& padding
);
69 bool DeleteAllPages(void);
70 bool DeletePage( const int page
);
71 wxPanel
*CreatePage( const int page
, const wxString
& text
, const int imageId
= -1, void* data
= NULL
);
72 wxPanel
*GetPanel( const int page
);
74 // overriden to do nothing
75 virtual void AddChild( wxWindow
*win
);
79 wxImageList
* m_imageList
;
86 //-----------------------------------------------------------------------------
88 //-----------------------------------------------------------------------------
90 class wxTabEvent
: public wxCommandEvent
92 DECLARE_DYNAMIC_CLASS(wxTabEvent
)
96 wxTabEvent( WXTYPE commandType
= 0, int id
= 0 );
99 typedef void (wxEvtHandler::*wxTabEventFunction
)(wxTabEvent
&);
101 #define EVT_TAB_SEL_CHANGED(id, fn) { wxEVT_COMMAND_TAB_SEL_CHANGED, \
102 id, -1, (wxObjectEventFunction) (wxEventFunction) (wxTabEventFunction) & fn, NULL },
103 #define EVT_TAB_SEL_CHANGING(id, fn) { wxEVT_COMMAND_TAB_SEL_CHANGING, \
104 id, -1, (wxObjectEventFunction) (wxEventFunction) (wxTabEventFunction) & fn, NULL },