1//---------------------------------------------------------------------------
2// This file is generated by wxPython's SIP generator.  Do not edit by hand.
3//
4// Copyright: (c) 2018 by Total Control Software
5// License:   wxWindows License
6//
7// This file will be included by _core.sip
8//
9//---------------------------------------------------------------------------
10
11//---------------------------------------------------------------------------
12
13const int wxFRAME_NO_TASKBAR;
14const int wxFRAME_TOOL_WINDOW;
15const int wxFRAME_FLOAT_ON_PARENT;
16class wxFrame : wxTopLevelWindow
17{
18    %Docstring
19        Frame()
20        Frame(parent, id=ID_ANY, title=EmptyString, pos=DefaultPosition, size=DefaultSize, style=DEFAULT_FRAME_STYLE, name=FrameNameStr)
21
22        A frame is a window whose size and position can (usually) be changed
23        by the user.
24    %End
25    %TypeHeaderCode
26        #include <wx/frame.h>
27    %End
28
29public:
30    wxFrame();
31    %PreMethodCode
32        if (!wxPyCheckForApp()) return NULL;
33    %End
34
35    wxFrame(
36        wxWindow * parent,
37        wxWindowID id = wxID_ANY,
38        const wxString & title = wxEmptyString,
39        const wxPoint & pos = wxDefaultPosition,
40        const wxSize & size = wxDefaultSize,
41        long style = wxDEFAULT_FRAME_STYLE,
42        const wxString & name = wxFrameNameStr
43    )   /Transfer/;
44    %PreMethodCode
45        if (!wxPyCheckForApp()) return NULL;
46    %End
47
48    ~wxFrame();
49
50    void Centre(
51        int direction = wxBOTH
52    );
53    %Docstring
54        Centre(direction=BOTH)
55
56        Centres the frame on the display.
57    %End
58
59    bool Create(
60        wxWindow * parent,
61        wxWindowID id = wxID_ANY,
62        const wxString & title = wxEmptyString,
63        const wxPoint & pos = wxDefaultPosition,
64        const wxSize & size = wxDefaultSize,
65        long style = wxDEFAULT_FRAME_STYLE,
66        const wxString & name = wxFrameNameStr
67    )   /TransferThis/;
68    %Docstring
69        Create(parent, id=ID_ANY, title=EmptyString, pos=DefaultPosition, size=DefaultSize, style=DEFAULT_FRAME_STYLE, name=FrameNameStr) -> bool
70
71        Used in two-step frame construction.
72    %End
73
74    wxStatusBar * CreateStatusBar(
75        int number = 1,
76        long style = wxSTB_DEFAULT_STYLE,
77        wxWindowID id = 0,
78        const wxString & name = wxStatusBarNameStr
79    );
80    %Docstring
81        CreateStatusBar(number=1, style=STB_DEFAULT_STYLE, id=0, name=StatusBarNameStr) -> StatusBar
82
83        Creates a status bar at the bottom of the frame.
84    %End
85
86    wxToolBar * CreateToolBar(
87        long style = wxTB_DEFAULT_STYLE,
88        wxWindowID id = wxID_ANY,
89        const wxString & name = wxToolBarNameStr
90    );
91    %Docstring
92        CreateToolBar(style=TB_DEFAULT_STYLE, id=ID_ANY, name=ToolBarNameStr) -> ToolBar
93
94        Creates a toolbar at the top or left of the frame.
95    %End
96
97    virtual
98    wxPoint GetClientAreaOrigin() const;
99    %Docstring
100        GetClientAreaOrigin() -> Point
101
102        Returns the origin of the frame client area (in client coordinates).
103    %End
104
105    wxMenuBar * GetMenuBar() const;
106    %Docstring
107        GetMenuBar() -> MenuBar
108
109        Returns a pointer to the menubar currently associated with the frame
110        (if any).
111    %End
112
113    wxStatusBar * GetStatusBar() const;
114    %Docstring
115        GetStatusBar() -> StatusBar
116
117        Returns a pointer to the status bar currently associated with the
118        frame (if any).
119    %End
120
121    int GetStatusBarPane() const;
122    %Docstring
123        GetStatusBarPane() -> int
124
125        Returns the status bar pane used to display menu and toolbar help.
126    %End
127
128    wxToolBar * GetToolBar() const;
129    %Docstring
130        GetToolBar() -> ToolBar
131
132        Returns a pointer to the toolbar currently associated with the frame
133        (if any).
134    %End
135
136    virtual
137    wxStatusBar * OnCreateStatusBar(
138        int number,
139        long style,
140        wxWindowID id,
141        const wxString & name
142    );
143    %Docstring
144        OnCreateStatusBar(number, style, id, name) -> StatusBar
145
146        Virtual function called when a status bar is requested by
147        CreateStatusBar().
148    %End
149
150    virtual
151    wxToolBar * OnCreateToolBar(
152        long style,
153        wxWindowID id,
154        const wxString & name
155    );
156    %Docstring
157        OnCreateToolBar(style, id, name) -> ToolBar
158
159        Virtual function called when a toolbar is requested by
160        CreateToolBar().
161    %End
162
163    bool ProcessCommand(
164        int id
165    );
166    %Docstring
167        ProcessCommand(id) -> bool
168
169        Simulate a menu command.
170    %End
171
172    void SetMenuBar(
173        wxMenuBar * menuBar   /Transfer/
174    );
175    %Docstring
176        SetMenuBar(menuBar)
177
178        Tells the frame to show the given menu bar.
179    %End
180
181    void SetStatusBar(
182        wxStatusBar * statusBar
183    );
184    %Docstring
185        SetStatusBar(statusBar)
186
187        Associates a status bar with the frame.
188    %End
189
190    void SetStatusBarPane(
191        int n
192    );
193    %Docstring
194        SetStatusBarPane(n)
195
196        Set the status bar pane used to display menu and toolbar help.
197    %End
198
199    void SetStatusText(
200        const wxString & text,
201        int number = 0
202    );
203    %Docstring
204        SetStatusText(text, number=0)
205
206        Sets the status bar text and redraws the status bar.
207    %End
208
209    void SetStatusWidths(
210        const wxArrayInt& widths
211    );
212    %Docstring
213        SetStatusWidths(widths)
214
215        Sets the widths of the fields in the status bar.
216    %End
217    %MethodCode
218        PyErr_Clear();
219        Py_BEGIN_ALLOW_THREADS
220        _wxFrame_SetStatusWidths(sipCpp, widths);
221        Py_END_ALLOW_THREADS
222        if (PyErr_Occurred()) sipIsErr = 1;
223    %End
224    %TypeCode
225    void _wxFrame_SetStatusWidths(wxFrame* self, const wxArrayInt* widths)
226    {
227        const int* ptr = &widths->front();
228        self->SetStatusWidths(widths->size(), ptr);
229    }
230    %End
231
232    void SetToolBar(
233        wxToolBar * toolBar
234    );
235    %Docstring
236        SetToolBar(toolBar)
237
238        Associates a toolbar with the frame.
239    %End
240
241    void PushStatusText(
242        const wxString & text,
243        int number = 0
244    );
245    %Docstring
246        PushStatusText(text, number=0)
247    %End
248
249    void PopStatusText(
250        int number = 0
251    );
252    %Docstring
253        PopStatusText(number=0)
254    %End
255
256    %Property(name=MenuBar, get=GetMenuBar, set=SetMenuBar)
257    %Property(name=StatusBar, get=GetStatusBar, set=SetStatusBar)
258    %Property(name=StatusBarPane, get=GetStatusBarPane, set=SetStatusBarPane)
259    %Property(name=ToolBar, get=GetToolBar, set=SetToolBar)
260    public:
261    virtual bool Validate();
262    virtual bool TransferDataToWindow();
263    virtual bool TransferDataFromWindow();
264    virtual void InitDialog();
265    virtual bool AcceptsFocus() const;
266    virtual bool AcceptsFocusRecursively() const;
267    virtual bool AcceptsFocusFromKeyboard() const;
268    virtual void AddChild( wxWindowBase *child );
269    virtual void RemoveChild( wxWindowBase *child );
270    virtual void InheritAttributes();
271    virtual bool ShouldInheritColours() const;
272    virtual void OnInternalIdle();
273    virtual wxWindow *GetMainWindowOfCompositeControl();
274    virtual bool InformFirstDirection(int direction, int size, int availableOtherDir);
275    virtual void SetCanFocus(bool canFocus);
276    virtual bool Destroy();
277    virtual void SetValidator( const wxValidator &validator );
278    virtual wxValidator* GetValidator();
279
280
281    protected:
282    virtual bool ProcessEvent(wxEvent & event);
283    virtual void DoEnable(bool enable);
284    virtual void DoGetPosition(int *x, int *y) const;
285    virtual void DoGetSize(int *width, int *height) const;
286    virtual void DoGetClientSize(int *width, int *height) const;
287    virtual wxSize DoGetBestSize() const;
288    virtual wxSize DoGetBestClientSize() const;
289    virtual void DoSetSize(int x, int y, int width, int height, int sizeFlags);
290    virtual void DoSetClientSize(int width, int height);
291    virtual void DoSetSizeHints( int minW, int minH, int maxW, int maxH, int incW, int incH );
292    virtual wxSize DoGetBorderSize() const;
293    virtual void DoMoveWindow(int x, int y, int width, int height);
294    virtual void DoSetWindowVariant( wxWindowVariant variant);
295    virtual wxBorder GetDefaultBorder() const;
296    virtual wxBorder GetDefaultBorderForControl() const;
297    virtual void DoFreeze();
298    virtual void DoThaw();
299    virtual bool HasTransparentBackground();
300    virtual bool TryBefore(wxEvent& event);
301    virtual bool TryAfter(wxEvent& event);
302
303
304    public:
305
306
307    static
308    wxVisualAttributes GetClassDefaultAttributes(
309        wxWindowVariant variant = wxWINDOW_VARIANT_NORMAL
310    );
311    %Docstring
312        GetClassDefaultAttributes(variant=WINDOW_VARIANT_NORMAL) -> VisualAttributes
313    %End
314    %PreMethodCode
315        if (!wxPyCheckForApp()) return NULL;
316    %End
317
318};  // end of class wxFrame
319
320
321
322//---------------------------------------------------------------------------
323
324