]>
git.saurik.com Git - wxWidgets.git/blob - include/wx/generic/panelg.h
1 /////////////////////////////////////////////////////////////////////////////
3 // Purpose: wxPanel: similar to wxWindows but is coloured as for a dialog
4 // Author: Julian Smart
9 // Licence: wxWindows licence
10 /////////////////////////////////////////////////////////////////////////////
16 #pragma interface "panelg.h"
19 #include "wx/window.h"
21 WXDLLEXPORT_DATA(extern const char*) wxPanelNameStr
;
24 class WXDLLEXPORT wxPanel
: public wxWindow
29 // Old-style constructor (no default values for coordinates to avoid ambiguity
31 inline wxPanel(wxWindow
*parent
,
32 int x
, int y
, int width
, int height
,
33 long style
= wxTAB_TRAVERSAL
| wxNO_BORDER
,
34 const wxString
& name
= wxPanelNameStr
)
36 Create(parent
, -1, wxPoint(x
, y
), wxSize(width
, height
), style
, name
);
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
)
46 Create(parent
, id
, pos
, size
, style
, name
);
49 bool Create(wxWindow
*parent
, wxWindowID id
,
50 const wxPoint
& pos
= wxDefaultPosition
,
51 const wxSize
& size
= wxDefaultSize
,
52 long style
= wxTAB_TRAVERSAL
| wxNO_BORDER
,
53 const wxString
& name
= wxPanelNameStr
);
55 // Sends an OnInitDialog event, which in turns transfers data to
56 // to the dialog via validators.
57 virtual void InitDialog();
59 // overriden base class virtuals
60 virtual void SetFocus();
63 // Responds to colour changes
64 void OnSysColourChanged(wxSysColourChangedEvent
& event
);
65 // Process a keyboard navigation message (Tab traversal)
66 void OnNavigationKey(wxNavigationKeyEvent
& event
);
69 bool SetFocusToNextChild(wxNode
*nodeCurrent
= (wxNode
*) NULL
, bool bForward
= TRUE
);
71 DECLARE_DYNAMIC_CLASS(wxPanel
)