-};
-
-// ----------------------------------------------------------------------------
-// sizers
-// ----------------------------------------------------------------------------
-
-/*
-
-Algorithm:
-
- Each sizer has a Layout function.
-
- wxExpandSizer::Layout ; E.g. for resizeable windows
-
- - parent size must be known (i.e. called
- from OnSize or explicitly)
- - call Layout on each child to give it a chance to resize
- (e.g. child shrinks around its own children):
- stop when all children return TRUE, or no change
- - evaluate constraints on self to set size
-
- wxShrinkSizer::Layout ; E.g. fit-to-contents windows
- ; Perhaps 2 rowcols, one above other.
-
- - call Layout on each child to give it a chance to resize
- (e.g. child shrinks around its own children):
- stop when each returns TRUE, or no change
- - fit around children
- (what if some want to be centred? E.g. OK/Cancel rowcol.
- - done by centring e.g. bottom sizer w.r.t. top sizer.
- (sibling relationship only))
- - evaluate own constraints (e.g. may be below another window)
- - IF parent is a real window (remember: a real window can
- have only one child sizer, although a sizer can have several child
- (real) windows), then resize this parent WITHOUT invoking Layout
- again.
- Frame and dialog box OnSizes can check if the sizer is a shrink
- sizer; if not, can call layout. Maybe have virtual bool AutoSizeLayout()
- to determine this.
-
-How to relayout if a child sizer/window changes? Need to go all the way
-to the top of the hierarchy and call Layout() again.
-
- wxRowColSizer::Layout
-
- - Similar to wxShrinkSizer only instead of shrinking to fit
- contents, more sophisticated layout of contents, and THEN
- shrinking (possibly).
- - Do the same parent window check/setsize as for wxShrinkSizer.
-
-*/
-
-class WXDLLEXPORT wxSizer : public wxWindow
-{
- DECLARE_DYNAMIC_CLASS(wxSizer)
-
-protected:
- wxSizerBehaviour sizerBehaviour;
- int borderX;
- int borderY;
- int sizerWidth;
- int sizerHeight;
- int sizerX;
- int sizerY;
-
-public:
- wxSizer();
- wxSizer(wxWindowBase *parent, wxSizerBehaviour behav = wxSizerNone);
- ~wxSizer();
-
- bool Create(wxWindowBase *parent, wxSizerBehaviour behav = wxSizerNone);
-
- virtual void DoGetSize(int *w, int *h) const;
- virtual void DoGetClientSize(int *w, int *h) const { GetSize(w, h); }
- virtual void DoGetPosition(int *x, int *y) const;
-
- void SizerSetSize(int x, int y, int w, int h) { SetSize(x, y, w, h); }
- void SizerMove(int x, int y) { Move(x, y); }