1 /////////////////////////////////////////////////////////////////////////////
3 // Purpose: SWIG definitions of MORE window classes
9 // Copyright: (c) 1998 by Total Control Software
10 // Licence: wxWindows license
11 /////////////////////////////////////////////////////////////////////////////
17 #include <wx/notebook.h>
18 #include <wx/splitter.h>
19 #include <wx/imaglist.h>
21 #include <wx/taskbar.h>
25 //----------------------------------------------------------------------
28 // Put some wx default wxChar* values into wxStrings.
29 DECLARE_DEF_STRING(NOTEBOOK_NAME);
30 DECLARE_DEF_STRING(PanelNameStr);
31 DECLARE_DEF_STRING(ControlNameStr);
33 static const wxChar* wxSplitterNameStr = wxT("splitter");
34 DECLARE_DEF_STRING(SplitterNameStr);
35 static const wxString wxPyEmptyString(wxT(""));
38 //----------------------------------------------------------------------
41 %include my_typemaps.i
43 // Import some definitions of other classes, etc.
51 %pragma(python) code = "import wx"
53 //---------------------------------------------------------------------------
56 // notebook control event types
57 wxEVT_COMMAND_NOTEBOOK_PAGE_CHANGED,
58 wxEVT_COMMAND_NOTEBOOK_PAGE_CHANGING,
69 wxNB_HITTEST_NOWHERE = 1, // not on tab
70 wxNB_HITTEST_ONICON = 2, // on icon
71 wxNB_HITTEST_ONLABEL = 4, // on label
72 wxNB_HITTEST_ONITEM = wxNB_HITTEST_ONICON | wxNB_HITTEST_ONLABEL,
77 class wxNotebookEvent : public wxNotifyEvent {
79 wxNotebookEvent(wxEventType commandType = wxEVT_NULL, int id = 0,
80 int sel = -1, int oldSel = -1);
83 int GetOldSelection();
84 void SetOldSelection(int page);
85 void SetSelection(int page);
90 class wxNotebook : public wxControl {
92 wxNotebook(wxWindow *parent,
94 const wxPoint& pos = wxDefaultPosition,
95 const wxSize& size = wxDefaultSize,
97 const wxString& name = wxPyNOTEBOOK_NAME);
98 %name(wxPreNotebook)wxNotebook();
100 bool Create(wxWindow *parent,
102 const wxPoint& pos = wxDefaultPosition,
103 const wxSize& size = wxDefaultSize,
105 const wxString& name = wxPyNOTEBOOK_NAME);
107 %pragma(python) addtomethod = "__init__:self._setOORInfo(self)"
108 %pragma(python) addtomethod = "wxPreNotebook:val._setOORInfo(val)"
111 // get number of pages in the dialog
112 int GetPageCount() const;
114 // get the panel which represents the given page
115 wxWindow *GetPage(int page);
117 // get the currently selected page
118 int GetSelection() const;
120 // set/get the title of a page
121 bool SetPageText(int page, const wxString& text);
122 wxString GetPageText(int page) const;
124 // image list stuff: each page may have an image associated with it (all
125 // images belong to the same image list)
126 void SetImageList(wxImageList* imageList);
128 // as SetImageList() but the notebook will take ownership of the image list
129 void AssignImageList(wxImageList* imageList);
130 %pragma(python) addtomethod = "AssignImageList:_args[0].thisown = 0"
132 // get pointer (may be NULL) to the associated image list
133 wxImageList* GetImageList() const;
135 // sets/returns item's image index in the current image list
136 int GetPageImage(int page) const;
137 bool SetPageImage(int page, int nImage);
139 // get the number of rows for a control with wxNB_MULTILINE style (not all
140 // versions support it - they will always return 1 then)
141 int GetRowCount() const;
143 // set the size (the same for all pages)
144 void SetPageSize(const wxSize& size);
146 // set the padding between tabs (in pixels)
147 void SetPadding(const wxSize& padding);
149 // set the size of the tabs for wxNB_FIXEDWIDTH controls
150 void SetTabSize(const wxSize& sz);
152 // calculate the size of the notebook from the size of its page
153 wxSize CalcSizeFromPage(const wxSize& sizePage) const;
156 // remove one page from the notebook and delete it
157 bool DeletePage(int page);
159 // remove one page from the notebook, without deleting it
160 bool RemovePage(int page);
162 // remove all pages and delete them
163 bool DeleteAllPages();
165 // adds a new page to the notebook (it will be deleted by the notebook,
166 // don't delete it yourself) and make it the current one if select
167 bool AddPage(wxWindow *page,
168 const wxString& text,
172 // the same as AddPage(), but adds the page at the specified position
173 bool InsertPage(int index,
175 const wxString& text,
179 // set the currently selected page, return the index of the previously
180 // selected one (or -1 on error)
182 // NB: this function will _not_ generate wxEVT_NOTEBOOK_PAGE_xxx events
183 int SetSelection(int page);
185 // hit test, returns which tab is hit and, optionally, where (icon, label)
186 // (not implemented on all platforms)
187 int HitTest(const wxPoint& pt, long* OUTPUT);
189 // cycle thru the tabs
190 void AdvanceSelection(bool forward = TRUE);
194 //---------------------------------------------------------------------------
198 /* splitter window events */
199 wxEVT_COMMAND_SPLITTER_SASH_POS_CHANGING,
200 wxEVT_COMMAND_SPLITTER_SASH_POS_CHANGED,
201 wxEVT_COMMAND_SPLITTER_UNSPLIT,
202 wxEVT_COMMAND_SPLITTER_DOUBLECLICKED,
207 wxSPLIT_DRAG_DRAGGING,
208 wxSPLIT_DRAG_LEFT_DOWN,
225 class wxSplitterEvent : public wxNotifyEvent {
227 wxSplitterEvent(wxEventType type = wxEVT_NULL,
228 wxSplitterWindow *splitter = NULL);
230 int GetSashPosition();
233 wxWindow* GetWindowBeingRemoved();
234 void SetSashPosition(int pos);
240 class wxSplitterWindow : public wxWindow {
242 wxSplitterWindow(wxWindow* parent, wxWindowID id,
243 const wxPoint& point = wxDefaultPosition,
244 const wxSize& size = wxDefaultSize,
245 long style=wxSP_3D|wxCLIP_CHILDREN,
246 const wxString& name = wxPySplitterNameStr);
247 %name(wxPreSplitterWindow)wxSplitterWindow();
249 bool Create(wxWindow* parent, wxWindowID id,
250 const wxPoint& point = wxDefaultPosition,
251 const wxSize& size = wxDefaultSize,
252 long style=wxSP_3D|wxCLIP_CHILDREN,
253 const wxString& name = wxPySplitterNameStr);
255 %pragma(python) addtomethod = "__init__:self._setOORInfo(self)"
256 %pragma(python) addtomethod = "wxPreSplitterWindow:val._setOORInfo(val)"
258 // Gets the only or left/top pane
259 wxWindow *GetWindow1();
261 // Gets the right/bottom pane
262 wxWindow *GetWindow2();
264 // Sets the split mode
265 void SetSplitMode(int mode);
267 // Gets the split mode
270 // Initialize with one window
271 void Initialize(wxWindow *window);
273 // Associates the given window with window 2, drawing the appropriate sash
274 // and changing the split mode.
275 // Does nothing and returns FALSE if the window is already split.
276 // A sashPosition of 0 means choose a default sash position,
277 // negative sashPosition specifies the size of right/lower pane as it's
278 // absolute value rather than the size of left/upper pane.
279 virtual bool SplitVertically(wxWindow *window1,
281 int sashPosition = 0);
282 virtual bool SplitHorizontally(wxWindow *window1,
284 int sashPosition = 0);
286 // Removes the specified (or second) window from the view
287 // Doesn't actually delete the window.
288 bool Unsplit(wxWindow *toRemove = NULL);
290 // Replaces one of the windows with another one (neither old nor new
291 // parameter should be NULL)
292 bool ReplaceWindow(wxWindow *winOld, wxWindow *winNew);
294 // Is the window split?
297 // Sets the sash size
298 void SetSashSize(int width);
300 // Sets the border size
301 void SetBorderSize(int width);
303 // Gets the sash size
306 // Gets the border size
309 // Set the sash position
310 void SetSashPosition(int position, bool redraw = TRUE);
312 // Gets the sash position
313 int GetSashPosition();
315 // If this is zero, we can remove panes by dragging the sash.
316 void SetMinimumPaneSize(int min);
317 int GetMinimumPaneSize();
319 // Resizes subwindows
320 virtual void SizeWindows();
322 void SetNeedUpdating(bool needUpdating) { m_needUpdating = needUpdating; }
323 bool GetNeedUpdating() const { return m_needUpdating ; }
327 //---------------------------------------------------------------------------
329 // TODO: This should be usable on wxGTK now too...
334 wxEVT_TASKBAR_LEFT_DOWN,
335 wxEVT_TASKBAR_LEFT_UP,
336 wxEVT_TASKBAR_RIGHT_DOWN,
337 wxEVT_TASKBAR_RIGHT_UP,
338 wxEVT_TASKBAR_LEFT_DCLICK,
339 wxEVT_TASKBAR_RIGHT_DCLICK
343 class wxTaskBarIconEvent : public wxEvent
346 wxTaskBarIconEvent(wxEventType evtType, wxTaskBarIcon *tbIcon);
350 class wxTaskBarIcon : public wxEvtHandler {
355 //%pragma(python) addtomethod = "__init__:self._setOORInfo(self)"
357 // We still use the magic methods here since that is the way it is documented...
358 %pragma(python) addtomethod = "__init__:wx._checkForCallback(self, 'OnMouseMove', wxEVT_TASKBAR_MOVE)"
359 %pragma(python) addtomethod = "__init__:wx._checkForCallback(self, 'OnLButtonDown', wxEVT_TASKBAR_LEFT_DOWN)"
360 %pragma(python) addtomethod = "__init__:wx._checkForCallback(self, 'OnLButtonUp', wxEVT_TASKBAR_LEFT_UP)"
361 %pragma(python) addtomethod = "__init__:wx._checkForCallback(self, 'OnRButtonDown', wxEVT_TASKBAR_RIGHT_DOWN)"
362 %pragma(python) addtomethod = "__init__:wx._checkForCallback(self, 'OnRButtonUp', wxEVT_TASKBAR_RIGHT_UP)"
363 %pragma(python) addtomethod = "__init__:wx._checkForCallback(self, 'OnLButtonDClick',wxEVT_TASKBAR_LEFT_DCLICK)"
364 %pragma(python) addtomethod = "__init__:wx._checkForCallback(self, 'OnRButtonDClick',wxEVT_TASKBAR_RIGHT_DCLICK)"
366 bool SetIcon(const wxIcon& icon, const wxString& tooltip = wxPyEmptyString);
367 bool RemoveIcon(void);
368 bool PopupMenu(wxMenu *menu);
369 bool IsIconInstalled();
375 %pragma(python) code = "
376 def EVT_TASKBAR_MOVE(win, func):
377 win.Connect(-1, -1, wxEVT_TASKBAR_MOVE, func)
379 def EVT_TASKBAR_LEFT_DOWN(win, func):
380 win.Connect(-1, -1, wxEVT_TASKBAR_LEFT_DOWN, func)
382 def EVT_TASKBAR_LEFT_UP(win, func):
383 win.Connect(-1, -1, wxEVT_TASKBAR_LEFT_UP, func)
385 def EVT_TASKBAR_RIGHT_DOWN(win, func):
386 win.Connect(-1, -1, wxEVT_TASKBAR_RIGHT_DOWN, func)
388 def EVT_TASKBAR_RIGHT_UP(win, func):
389 win.Connect(-1, -1, wxEVT_TASKBAR_RIGHT_UP, func)
391 def EVT_TASKBAR_LEFT_DCLICK(win, func):
392 win.Connect(-1, -1, wxEVT_TASKBAR_LEFT_DCLICK, func)
394 def EVT_TASKBAR_RIGHT_DCLICK(win, func):
395 win.Connect(-1, -1, wxEVT_TASKBAR_RIGHT_DCLICK, func)
401 //---------------------------------------------------------------------------
402 //---------------------------------------------------------------------------
403 // wxPyWindow derives from wxWindow and adds support for overriding many of
404 // the virtual methods in Python derived classes.
406 // Which (any?) of these should be done also???
420 // GetClientAreaOrigin
423 // SetBackgroundColour
427 // SetForegroundColour
429 // SetVirtualSizeHints
433 %{ // C++ version of Python aware wxWindow
434 class wxPyWindow : public wxWindow
436 DECLARE_DYNAMIC_CLASS(wxPyWindow)
438 wxPyWindow() : wxWindow() {}
439 wxPyWindow(wxWindow* parent, const wxWindowID id,
440 const wxPoint& pos = wxDefaultPosition,
441 const wxSize& size = wxDefaultSize,
443 const wxString& name = wxPyPanelNameStr)
444 : wxWindow(parent, id, pos, size, style, name) {}
447 DEC_PYCALLBACK_VOID_INT4(DoMoveWindow);
448 DEC_PYCALLBACK_VOID_INT5(DoSetSize);
449 DEC_PYCALLBACK_VOID_INTINT(DoSetClientSize);
450 DEC_PYCALLBACK_VOID_INTINT(DoSetVirtualSize);
452 DEC_PYCALLBACK_VOID_INTPINTP_const(DoGetSize);
453 DEC_PYCALLBACK_VOID_INTPINTP_const(DoGetClientSize);
454 DEC_PYCALLBACK_VOID_INTPINTP_const(DoGetPosition);
456 DEC_PYCALLBACK_SIZE_const(DoGetVirtualSize);
457 DEC_PYCALLBACK_SIZE_const(DoGetBestSize);
459 DEC_PYCALLBACK__(InitDialog);
460 DEC_PYCALLBACK_BOOL_(TransferDataFromWindow);
461 DEC_PYCALLBACK_BOOL_(TransferDataToWindow);
462 DEC_PYCALLBACK_BOOL_(Validate);
464 DEC_PYCALLBACK_BOOL_const(AcceptsFocus);
465 DEC_PYCALLBACK_BOOL_const(AcceptsFocusFromKeyboard);
466 DEC_PYCALLBACK_SIZE_const(GetMaxSize);
468 DEC_PYCALLBACK_VOID_WXWINBASE(AddChild);
469 DEC_PYCALLBACK_VOID_WXWINBASE(RemoveChild);
474 IMPLEMENT_DYNAMIC_CLASS(wxPyWindow, wxWindow);
476 IMP_PYCALLBACK_VOID_INT4(wxPyWindow, wxWindow, DoMoveWindow);
477 IMP_PYCALLBACK_VOID_INT5(wxPyWindow, wxWindow, DoSetSize);
478 IMP_PYCALLBACK_VOID_INTINT(wxPyWindow, wxWindow, DoSetClientSize);
479 IMP_PYCALLBACK_VOID_INTINT(wxPyWindow, wxWindow, DoSetVirtualSize);
481 IMP_PYCALLBACK_VOID_INTPINTP_const(wxPyWindow, wxWindow, DoGetSize);
482 IMP_PYCALLBACK_VOID_INTPINTP_const(wxPyWindow, wxWindow, DoGetClientSize);
483 IMP_PYCALLBACK_VOID_INTPINTP_const(wxPyWindow, wxWindow, DoGetPosition);
485 IMP_PYCALLBACK_SIZE_const(wxPyWindow, wxWindow, DoGetVirtualSize);
486 IMP_PYCALLBACK_SIZE_const(wxPyWindow, wxWindow, DoGetBestSize);
488 IMP_PYCALLBACK__(wxPyWindow, wxWindow, InitDialog);
489 IMP_PYCALLBACK_BOOL_(wxPyWindow, wxWindow, TransferDataFromWindow);
490 IMP_PYCALLBACK_BOOL_(wxPyWindow, wxWindow, TransferDataToWindow);
491 IMP_PYCALLBACK_BOOL_(wxPyWindow, wxWindow, Validate);
493 IMP_PYCALLBACK_BOOL_const(wxPyWindow, wxWindow, AcceptsFocus);
494 IMP_PYCALLBACK_BOOL_const(wxPyWindow, wxWindow, AcceptsFocusFromKeyboard);
495 IMP_PYCALLBACK_SIZE_const(wxPyWindow, wxWindow, GetMaxSize);
497 IMP_PYCALLBACK_VOID_WXWINBASE(wxPyWindow, wxWindow, AddChild);
498 IMP_PYCALLBACK_VOID_WXWINBASE(wxPyWindow, wxWindow, RemoveChild);
502 // And now the one for SWIG to see
503 class wxPyWindow : public wxWindow
506 wxPyWindow(wxWindow* parent, const wxWindowID id,
507 const wxPoint& pos = wxDefaultPosition,
508 const wxSize& size = wxDefaultSize,
510 const wxString& name = wxPyPanelNameStr);
512 void _setCallbackInfo(PyObject* self, PyObject* _class);
513 %pragma(python) addtomethod = "__init__:self._setCallbackInfo(self, wxPyWindow)"
514 %pragma(python) addtomethod = "__init__:self._setOORInfo(self)"
517 void base_DoMoveWindow(int x, int y, int width, int height);
518 void base_DoSetSize(int x, int y, int width, int height,
519 int sizeFlags = wxSIZE_AUTO);
520 void base_DoSetClientSize(int width, int height);
521 void base_DoSetVirtualSize( int x, int y );
523 void base_DoGetSize( int *OUTPUT, int *OUTPUT ) const;
524 void base_DoGetClientSize( int *OUTPUT, int *OUTPUT ) const;
525 void base_DoGetPosition( int *OUTPUT, int *OUTPUT ) const;
527 wxSize base_DoGetVirtualSize() const;
528 wxSize base_DoGetBestSize() const;
530 void base_InitDialog();
531 bool base_TransferDataToWindow();
532 bool base_TransferDataFromWindow();
533 bool base_Validate();
535 bool base_AcceptsFocus() const;
536 bool base_AcceptsFocusFromKeyboard() const;
537 wxSize base_GetMaxSize() const;
539 void base_AddChild(wxWindow* child);
540 void base_RemoveChild(wxWindow* child);
543 //---------------------------------------------------------------------------
544 // Do the same thing for wxControl
547 %{ // C++ version of Python aware wxControl
548 class wxPyControl : public wxControl
550 DECLARE_DYNAMIC_CLASS(wxPyControl)
552 wxPyControl() : wxControl() {}
553 wxPyControl(wxWindow* parent, const wxWindowID id,
554 const wxPoint& pos = wxDefaultPosition,
555 const wxSize& size = wxDefaultSize,
557 const wxValidator& validator=wxDefaultValidator,
558 const wxString& name = wxPyControlNameStr)
559 : wxControl(parent, id, pos, size, style, validator, name) {}
562 DEC_PYCALLBACK_VOID_INT4(DoMoveWindow);
563 DEC_PYCALLBACK_VOID_INT5(DoSetSize);
564 DEC_PYCALLBACK_VOID_INTINT(DoSetClientSize);
565 DEC_PYCALLBACK_VOID_INTINT(DoSetVirtualSize);
567 DEC_PYCALLBACK_VOID_INTPINTP_const(DoGetSize);
568 DEC_PYCALLBACK_VOID_INTPINTP_const(DoGetClientSize);
569 DEC_PYCALLBACK_VOID_INTPINTP_const(DoGetPosition);
571 DEC_PYCALLBACK_SIZE_const(DoGetVirtualSize);
572 DEC_PYCALLBACK_SIZE_const(DoGetBestSize);
574 DEC_PYCALLBACK__(InitDialog);
575 DEC_PYCALLBACK_BOOL_(TransferDataFromWindow);
576 DEC_PYCALLBACK_BOOL_(TransferDataToWindow);
577 DEC_PYCALLBACK_BOOL_(Validate);
579 DEC_PYCALLBACK_BOOL_const(AcceptsFocus);
580 DEC_PYCALLBACK_BOOL_const(AcceptsFocusFromKeyboard);
581 DEC_PYCALLBACK_SIZE_const(GetMaxSize);
583 DEC_PYCALLBACK_VOID_WXWINBASE(AddChild);
584 DEC_PYCALLBACK_VOID_WXWINBASE(RemoveChild);
589 IMPLEMENT_DYNAMIC_CLASS(wxPyControl, wxControl);
591 IMP_PYCALLBACK_VOID_INT4(wxPyControl, wxControl, DoMoveWindow);
592 IMP_PYCALLBACK_VOID_INT5(wxPyControl, wxControl, DoSetSize);
593 IMP_PYCALLBACK_VOID_INTINT(wxPyControl, wxControl, DoSetClientSize);
594 IMP_PYCALLBACK_VOID_INTINT(wxPyControl, wxControl, DoSetVirtualSize);
596 IMP_PYCALLBACK_VOID_INTPINTP_const(wxPyControl, wxControl, DoGetSize);
597 IMP_PYCALLBACK_VOID_INTPINTP_const(wxPyControl, wxControl, DoGetClientSize);
598 IMP_PYCALLBACK_VOID_INTPINTP_const(wxPyControl, wxControl, DoGetPosition);
600 IMP_PYCALLBACK_SIZE_const(wxPyControl, wxControl, DoGetVirtualSize);
601 IMP_PYCALLBACK_SIZE_const(wxPyControl, wxControl, DoGetBestSize);
603 IMP_PYCALLBACK__(wxPyControl, wxControl, InitDialog);
604 IMP_PYCALLBACK_BOOL_(wxPyControl, wxControl, TransferDataFromWindow);
605 IMP_PYCALLBACK_BOOL_(wxPyControl, wxControl, TransferDataToWindow);
606 IMP_PYCALLBACK_BOOL_(wxPyControl, wxControl, Validate);
608 IMP_PYCALLBACK_BOOL_const(wxPyControl, wxControl, AcceptsFocus);
609 IMP_PYCALLBACK_BOOL_const(wxPyControl, wxControl, AcceptsFocusFromKeyboard);
610 IMP_PYCALLBACK_SIZE_const(wxPyControl, wxControl, GetMaxSize);
612 IMP_PYCALLBACK_VOID_WXWINBASE(wxPyControl, wxControl, AddChild);
613 IMP_PYCALLBACK_VOID_WXWINBASE(wxPyControl, wxControl, RemoveChild);
617 // And now the one for SWIG to see
618 class wxPyControl : public wxControl
621 wxPyControl(wxWindow* parent, const wxWindowID id,
622 const wxPoint& pos = wxDefaultPosition,
623 const wxSize& size = wxDefaultSize,
625 const wxValidator& validator=wxDefaultValidator,
626 const wxString& name = wxPyControlNameStr);
628 void _setCallbackInfo(PyObject* self, PyObject* _class);
629 %pragma(python) addtomethod = "__init__:self._setCallbackInfo(self, wxPyControl)"
630 %pragma(python) addtomethod = "__init__:self._setOORInfo(self)"
633 void base_DoMoveWindow(int x, int y, int width, int height);
634 void base_DoSetSize(int x, int y, int width, int height,
635 int sizeFlags = wxSIZE_AUTO);
636 void base_DoSetClientSize(int width, int height);
637 void base_DoSetVirtualSize( int x, int y );
639 void base_DoGetSize( int *OUTPUT, int *OUTPUT ) const;
640 void base_DoGetClientSize( int *OUTPUT, int *OUTPUT ) const;
641 void base_DoGetPosition( int *OUTPUT, int *OUTPUT ) const;
643 wxSize base_DoGetVirtualSize() const;
644 wxSize base_DoGetBestSize() const;
646 void base_InitDialog();
647 bool base_TransferDataToWindow();
648 bool base_TransferDataFromWindow();
649 bool base_Validate();
651 bool base_AcceptsFocus() const;
652 bool base_AcceptsFocusFromKeyboard() const;
653 wxSize base_GetMaxSize() const;
655 void base_AddChild(wxWindow* child);
656 void base_RemoveChild(wxWindow* child);
659 //---------------------------------------------------------------------------
662 %{ // C++ version of Python aware wxPanel
663 class wxPyPanel : public wxPanel
665 DECLARE_DYNAMIC_CLASS(wxPyPanel)
667 wxPyPanel() : wxPanel() {}
668 wxPyPanel(wxWindow* parent, const wxWindowID id,
669 const wxPoint& pos = wxDefaultPosition,
670 const wxSize& size = wxDefaultSize,
672 const wxString& name = wxPyPanelNameStr)
673 : wxPanel(parent, id, pos, size, style, name) {}
676 DEC_PYCALLBACK_VOID_INT4(DoMoveWindow);
677 DEC_PYCALLBACK_VOID_INT5(DoSetSize);
678 DEC_PYCALLBACK_VOID_INTINT(DoSetClientSize);
679 DEC_PYCALLBACK_VOID_INTINT(DoSetVirtualSize);
681 DEC_PYCALLBACK_VOID_INTPINTP_const(DoGetSize);
682 DEC_PYCALLBACK_VOID_INTPINTP_const(DoGetClientSize);
683 DEC_PYCALLBACK_VOID_INTPINTP_const(DoGetPosition);
685 DEC_PYCALLBACK_SIZE_const(DoGetVirtualSize);
686 DEC_PYCALLBACK_SIZE_const(DoGetBestSize);
688 DEC_PYCALLBACK__(InitDialog);
689 DEC_PYCALLBACK_BOOL_(TransferDataFromWindow);
690 DEC_PYCALLBACK_BOOL_(TransferDataToWindow);
691 DEC_PYCALLBACK_BOOL_(Validate);
693 DEC_PYCALLBACK_BOOL_const(AcceptsFocus);
694 DEC_PYCALLBACK_BOOL_const(AcceptsFocusFromKeyboard);
695 DEC_PYCALLBACK_SIZE_const(GetMaxSize);
697 DEC_PYCALLBACK_VOID_WXWINBASE(AddChild);
698 DEC_PYCALLBACK_VOID_WXWINBASE(RemoveChild);
703 IMPLEMENT_DYNAMIC_CLASS(wxPyPanel, wxPanel);
705 IMP_PYCALLBACK_VOID_INT4(wxPyPanel, wxPanel, DoMoveWindow);
706 IMP_PYCALLBACK_VOID_INT5(wxPyPanel, wxPanel, DoSetSize);
707 IMP_PYCALLBACK_VOID_INTINT(wxPyPanel, wxPanel, DoSetClientSize);
708 IMP_PYCALLBACK_VOID_INTINT(wxPyPanel, wxPanel, DoSetVirtualSize);
710 IMP_PYCALLBACK_VOID_INTPINTP_const(wxPyPanel, wxPanel, DoGetSize);
711 IMP_PYCALLBACK_VOID_INTPINTP_const(wxPyPanel, wxPanel, DoGetClientSize);
712 IMP_PYCALLBACK_VOID_INTPINTP_const(wxPyPanel, wxPanel, DoGetPosition);
714 IMP_PYCALLBACK_SIZE_const(wxPyPanel, wxPanel, DoGetVirtualSize);
715 IMP_PYCALLBACK_SIZE_const(wxPyPanel, wxPanel, DoGetBestSize);
717 IMP_PYCALLBACK__(wxPyPanel, wxPanel, InitDialog);
718 IMP_PYCALLBACK_BOOL_(wxPyPanel, wxPanel, TransferDataFromWindow);
719 IMP_PYCALLBACK_BOOL_(wxPyPanel, wxPanel, TransferDataToWindow);
720 IMP_PYCALLBACK_BOOL_(wxPyPanel, wxPanel, Validate);
722 IMP_PYCALLBACK_BOOL_const(wxPyPanel, wxPanel, AcceptsFocus);
723 IMP_PYCALLBACK_BOOL_const(wxPyPanel, wxPanel, AcceptsFocusFromKeyboard);
724 IMP_PYCALLBACK_SIZE_const(wxPyPanel, wxPanel, GetMaxSize);
726 IMP_PYCALLBACK_VOID_WXWINBASE(wxPyPanel, wxPanel, AddChild);
727 IMP_PYCALLBACK_VOID_WXWINBASE(wxPyPanel, wxPanel, RemoveChild);
731 // And now the one for SWIG to see
732 class wxPyPanel : public wxPanel
735 wxPyPanel(wxWindow* parent, const wxWindowID id,
736 const wxPoint& pos = wxDefaultPosition,
737 const wxSize& size = wxDefaultSize,
739 const wxString& name = wxPyPanelNameStr);
741 void _setCallbackInfo(PyObject* self, PyObject* _class);
742 %pragma(python) addtomethod = "__init__:self._setCallbackInfo(self, wxPyPanel)"
743 %pragma(python) addtomethod = "__init__:self._setOORInfo(self)"
746 void base_DoMoveWindow(int x, int y, int width, int height);
747 void base_DoSetSize(int x, int y, int width, int height,
748 int sizeFlags = wxSIZE_AUTO);
749 void base_DoSetClientSize(int width, int height);
750 void base_DoSetVirtualSize( int x, int y );
752 void base_DoGetSize( int *OUTPUT, int *OUTPUT ) const;
753 void base_DoGetClientSize( int *OUTPUT, int *OUTPUT ) const;
754 void base_DoGetPosition( int *OUTPUT, int *OUTPUT ) const;
756 wxSize base_DoGetVirtualSize() const;
757 wxSize base_DoGetBestSize() const;
759 void base_InitDialog();
760 bool base_TransferDataToWindow();
761 bool base_TransferDataFromWindow();
762 bool base_Validate();
764 bool base_AcceptsFocus() const;
765 bool base_AcceptsFocusFromKeyboard() const;
766 wxSize base_GetMaxSize() const;
768 void base_AddChild(wxWindow* child);
769 void base_RemoveChild(wxWindow* child);
773 //---------------------------------------------------------------------------