]>
git.saurik.com Git - wxWidgets.git/blob - include/wx/gtk1/frame.h
1 /////////////////////////////////////////////////////////////////////////////
2 // Name: wx/gtk/frame.h
4 // Author: Robert Roebling
6 // Copyright: (c) 1998 Robert Roebling, Julian Smart
7 // Licence: wxWindows licence
8 /////////////////////////////////////////////////////////////////////////////
14 #if defined(__GNUG__) && !defined(NO_GCC_PRAGMA)
15 #pragma interface "frame.h"
18 //-----------------------------------------------------------------------------
20 //-----------------------------------------------------------------------------
22 class wxMDIChildFrame
;
23 class wxMDIClientWindow
;
29 //-----------------------------------------------------------------------------
31 //-----------------------------------------------------------------------------
33 class wxFrame
: public wxFrameBase
38 wxFrame(wxWindow
*parent
,
40 const wxString
& title
,
41 const wxPoint
& pos
= wxDefaultPosition
,
42 const wxSize
& size
= wxDefaultSize
,
43 long style
= wxDEFAULT_FRAME_STYLE
,
44 const wxString
& name
= wxFrameNameStr
)
48 Create(parent
, id
, title
, pos
, size
, style
, name
);
51 bool Create(wxWindow
*parent
,
53 const wxString
& title
,
54 const wxPoint
& pos
= wxDefaultPosition
,
55 const wxSize
& size
= wxDefaultSize
,
56 long style
= wxDEFAULT_FRAME_STYLE
,
57 const wxString
& name
= wxFrameNameStr
);
62 virtual void PositionStatusBar();
64 virtual wxStatusBar
* CreateStatusBar(int number
= 1,
65 long style
= wxST_SIZEGRIP
|wxFULL_REPAINT_ON_RESIZE
,
67 const wxString
& name
= wxStatusLineNameStr
);
69 void SetStatusBar(wxStatusBar
*statbar
);
70 #endif // wxUSE_STATUSBAR
73 virtual wxToolBar
* CreateToolBar(long style
= -1,
75 const wxString
& name
= wxToolBarNameStr
);
76 void SetToolBar(wxToolBar
*toolbar
);
77 #endif // wxUSE_TOOLBAR
79 wxPoint
GetClientAreaOrigin() const { return wxPoint(0, 0); }
81 // implementation from now on
82 // --------------------------
85 virtual void GtkOnSize( int x
, int y
, int width
, int height
);
86 virtual void OnInternalIdle();
88 bool m_menuBarDetached
;
90 bool m_toolBarDetached
;
93 // common part of all ctors
96 // override wxWindow methods to take into account tool/menu/statusbars
97 virtual void DoSetClientSize(int width
, int height
);
98 virtual void DoGetClientSize( int *width
, int *height
) const;
100 #if wxUSE_MENUS_NATIVE
102 virtual void DetachMenuBar();
103 virtual void AttachMenuBar(wxMenuBar
*menubar
);
106 // Menu size is dynamic now, call this whenever it might change.
107 void UpdateMenuBarSize();
109 #endif // wxUSE_MENUS_NATIVE
111 DECLARE_DYNAMIC_CLASS(wxFrame
)
114 #endif // __GTKFRAMEH__