]>
Commit | Line | Data |
---|---|---|
c801d85f KB |
1 | ///////////////////////////////////////////////////////////////////////////// |
2 | // Name: panelg.h | |
3 | // Purpose: wxPanel: similar to wxWindows but is coloured as for a dialog | |
4 | // Author: Julian Smart | |
5 | // Modified by: | |
6 | // Created: 01/02/97 | |
7 | // RCS-ID: $Id$ | |
8 | // Copyright: (c) | |
9 | // Licence: wxWindows licence | |
10 | ///////////////////////////////////////////////////////////////////////////// | |
11 | ||
12 | #ifndef __PANELH_G__ | |
13 | #define __PANELH_G__ | |
14 | ||
15 | #ifdef __GNUG__ | |
16 | #pragma interface "panelg.h" | |
17 | #endif | |
18 | ||
19 | #include "wx/window.h" | |
20 | ||
21 | WXDLLEXPORT_DATA(extern const char*) wxPanelNameStr; | |
22 | ||
b292e2f5 | 23 | |
c801d85f KB |
24 | class WXDLLEXPORT wxPanel: public wxWindow |
25 | { | |
c801d85f | 26 | public: |
e163f7bb | 27 | wxPanel(); |
c801d85f | 28 | |
e163f7bb VZ |
29 | // Old-style constructor (no default values for coordinates to avoid ambiguity |
30 | // with the new one) | |
c801d85f | 31 | inline wxPanel(wxWindow *parent, |
e163f7bb VZ |
32 | int x, int y, int width, int height, |
33 | long style = wxTAB_TRAVERSAL | wxNO_BORDER, | |
34 | const wxString& name = wxPanelNameStr) | |
c801d85f KB |
35 | { |
36 | Create(parent, -1, wxPoint(x, y), wxSize(width, height), style, name); | |
37 | } | |
38 | ||
39 | // Constructor | |
e163f7bb VZ |
40 | inline wxPanel(wxWindow *parent, wxWindowID id = -1, |
41 | const wxPoint& pos = wxDefaultPosition, | |
42 | const wxSize& size = wxDefaultSize, | |
43 | long style = wxTAB_TRAVERSAL | wxNO_BORDER, | |
44 | const wxString& name = wxPanelNameStr) | |
c801d85f KB |
45 | { |
46 | Create(parent, id, pos, size, style, name); | |
47 | } | |
48 | ||
debe6624 | 49 | bool Create(wxWindow *parent, wxWindowID id, |
e163f7bb VZ |
50 | const wxPoint& pos = wxDefaultPosition, |
51 | const wxSize& size = wxDefaultSize, | |
52 | long style = wxTAB_TRAVERSAL | wxNO_BORDER, | |
53 | const wxString& name = wxPanelNameStr); | |
c801d85f KB |
54 | |
55 | // Sends an OnInitDialog event, which in turns transfers data to | |
56 | // to the dialog via validators. | |
e163f7bb | 57 | virtual void InitDialog(); |
c801d85f | 58 | |
e163f7bb | 59 | // Responds to colour changes |
c801d85f | 60 | void OnSysColourChanged(wxSysColourChangedEvent& event); |
b292e2f5 | 61 | |
e163f7bb VZ |
62 | // Process a keyboard navigation message (Tab traversal) |
63 | void OnNavigationKey(wxNavigationKeyEvent& event); | |
58614078 | 64 | |
c801d85f | 65 | |
e163f7bb | 66 | DECLARE_DYNAMIC_CLASS(wxPanel) |
c801d85f KB |
67 | DECLARE_EVENT_TABLE() |
68 | }; | |
69 | ||
70 | #endif | |
71 | // __PANELH_G__ |