]> git.saurik.com Git - wxWidgets.git/blob - wxPython/src/mdi.i
added wx/defs.h include to correct compilation issues under Mac OS X
[wxWidgets.git] / wxPython / src / mdi.i
1 /////////////////////////////////////////////////////////////////////////////
2 // Name: mdi.i
3 // Purpose: MDI related class definitions for wxPython
4 //
5 // Author: Robin Dunn
6 //
7 // Created: 5/26/98
8 // RCS-ID: $Id$
9 // Copyright: (c) 1998 by Total Control Software
10 // Licence: wxWindows license
11 /////////////////////////////////////////////////////////////////////////////
12
13
14 %module mdi
15
16 %{
17 #include "helpers.h"
18 %}
19
20 //----------------------------------------------------------------------
21
22 %include typemaps.i
23 %include my_typemaps.i
24
25 // Import some definitions of other classes, etc.
26 %import _defs.i
27 %import misc.i
28 %import windows.i
29 %import frames.i
30
31 %pragma(python) code = "import wx"
32
33 //----------------------------------------------------------------------
34
35 class wxMDIParentFrame : public wxFrame {
36 public:
37 wxMDIParentFrame(wxWindow *parent,
38 const wxWindowID id,
39 const wxString& title,
40 const wxPoint& pos = wxDefaultPosition,
41 const wxSize& size = wxDefaultSize,
42 long style = wxDEFAULT_FRAME_STYLE | wxVSCROLL | wxHSCROLL,
43 const char* name = "frame");
44 %name(wxPreMDIParentFrame)wxMDIParentFrame();
45
46 bool Create(wxWindow *parent,
47 const wxWindowID id,
48 const wxString& title,
49 const wxPoint& pos = wxDefaultPosition,
50 const wxSize& size = wxDefaultSize,
51 long style = wxDEFAULT_FRAME_STYLE | wxVSCROLL | wxHSCROLL,
52 const char* name = "frame");
53
54 void ActivateNext();
55 void ActivatePrevious();
56 void ArrangeIcons();
57 void Cascade();
58 wxMDIChildFrame* GetActiveChild();
59 wxMDIClientWindow* GetClientWindow();
60 wxWindow* GetToolBar();
61
62 // TODO: This isn't handled by the standard event-table system...
63 //wxMDIClientWindow* OnCreateClient();
64
65
66 #ifdef __WXMSW__
67 wxMenu* GetWindowMenu();
68 void SetWindowMenu(wxMenu* menu);
69 void SetToolBar(wxToolBar* toolbar);
70 #endif
71 void Tile();
72 };
73
74 //---------------------------------------------------------------------------
75
76 class wxMDIChildFrame : public wxFrame {
77 public:
78 wxMDIChildFrame(wxMDIParentFrame* parent,
79 const wxWindowID id,
80 const wxString& title,
81 const wxPoint& pos = wxDefaultPosition,
82 const wxSize& size = wxDefaultSize,
83 long style = wxDEFAULT_FRAME_STYLE,
84 const char* name = "frame");
85 %name(wxPreMDIChildFrame)wxMDIChildFrame();
86
87 bool Create(wxMDIParentFrame* parent,
88 const wxWindowID id,
89 const wxString& title,
90 const wxPoint& pos = wxDefaultPosition,
91 const wxSize& size = wxDefaultSize,
92 long style = wxDEFAULT_FRAME_STYLE,
93 const char* name = "frame");
94
95
96 void Activate();
97 void Maximize(bool maximize);
98 void Restore();
99
100 };
101
102
103 //---------------------------------------------------------------------------
104
105 class wxMDIClientWindow : public wxWindow {
106 public:
107 wxMDIClientWindow(wxMDIParentFrame* parent, long style = 0);
108 %name(wxPreMDIClientWindow)wxMDIClientWindow();
109
110 %pragma(python) addtomethod = "__init__:#wx._StdWindowCallbacks(self)"
111 %pragma(python) addtomethod = "__init__:#wx._StdOnScrollCallbacks(self)"
112
113 bool Create(wxMDIParentFrame* parent, long style = 0);
114
115 %pragma(python) addtomethod = "__init__:#wx._StdWindowCallbacks(self)"
116 %pragma(python) addtomethod = "__init__:#wx._StdOnScrollCallbacks(self)"
117 };
118
119 //---------------------------------------------------------------------------