notes about sizer changes
git-svn-id: https://svn.wxwidgets.org/svn/wx/wxWidgets/trunk@26663 c3d73ce0-8a6f-49c7-b76d-6d57e0e08775
This commit is contained in:
@@ -1,6 +1,17 @@
|
|||||||
Recent Changes for wxPython
|
Recent Changes for wxPython
|
||||||
=====================================================================
|
=====================================================================
|
||||||
|
|
||||||
|
2.5.1.6
|
||||||
|
-------
|
||||||
|
|
||||||
|
wx.ADJUST_MINSIZE is now the default behaviour for window items in
|
||||||
|
sizers. This means that the item's GetAdjustedBestSize will be called
|
||||||
|
when calculating layout and the return value from that will be used
|
||||||
|
for the minimum size. Added wx.FIXED_SIZE flag for when you would
|
||||||
|
like the old behavior but you should only need it when your desired
|
||||||
|
size is smaller than the item's GetBestSize()
|
||||||
|
|
||||||
|
|
||||||
2.5.1.5
|
2.5.1.5
|
||||||
-------
|
-------
|
||||||
|
|
||||||
|
@@ -347,13 +347,17 @@ Then you can just simplify it like this::
|
|||||||
dc.DrawRectangle(p, s)
|
dc.DrawRectangle(p, s)
|
||||||
|
|
||||||
Now before you start yelling and screaming at me for breaking all your
|
Now before you start yelling and screaming at me for breaking all your
|
||||||
code, take note that up above I said, "...using the new wx namespace..."
|
code, take note that up above I said, "...using the new wx
|
||||||
That's because if you are still importing from wxPython.wx then there
|
namespace..." That's because if you are still importing from
|
||||||
are some classes defined there with Draw and etc. methods that have
|
wxPython.wx then there are some classes defined there with Draw and
|
||||||
2.4 compatible signatures. However if/when the old wxPython.wx
|
etc. methods that have 2.4 compatible signatures. Unfortunately there
|
||||||
namespace is removed then these classes will be removed too so you
|
is one exception to this behaviour. If a DC is returned from a
|
||||||
should plan on migrating to the new namespace and new DC Draw methods
|
function or method then an instance of the new class (with the new
|
||||||
before that time.
|
methods described above) will be returned instead of the compatibility
|
||||||
|
class. If/When the old wxPython.wx namespace is removed then these
|
||||||
|
compatibility classes will be removed too so you should plan on
|
||||||
|
migrating to the new namespace and new DC Draw methods before that
|
||||||
|
time.
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
@@ -432,6 +436,11 @@ then you will need to use the ``proportion`` name instead of ``option``.
|
|||||||
|
|
||||||
When adding a spacer to a sizer you now need to use a wx.Size or a
|
When adding a spacer to a sizer you now need to use a wx.Size or a
|
||||||
2-integer sequence instead of separate width and height parameters.
|
2-integer sequence instead of separate width and height parameters.
|
||||||
|
This allows for more consistency in how you add the various types of
|
||||||
|
items to a sizer. The first parameter defines the item (instead of
|
||||||
|
the possibily first two, depending on if you are doing a spacer or
|
||||||
|
not,) and that item can either be a window, a sizer or a spacer (which
|
||||||
|
can be a sequence or a wx.Size.)
|
||||||
|
|
||||||
The wx.GridBagSizer class (very similar to the RowColSizer in the
|
The wx.GridBagSizer class (very similar to the RowColSizer in the
|
||||||
library) has been added to C++ and wrapped for wxPython. It can also
|
library) has been added to C++ and wrapped for wxPython. It can also
|
||||||
@@ -441,6 +450,14 @@ You should not use AddWindow, AddSizer, AddSpacer (and similar for
|
|||||||
Insert, Prepend, and etc.) methods any longer. Just use Add and the
|
Insert, Prepend, and etc.) methods any longer. Just use Add and the
|
||||||
wrappers will figure out what to do.
|
wrappers will figure out what to do.
|
||||||
|
|
||||||
|
**[Changed in 2.5.1.6]** wx.ADJUST_MINSIZE is now the default
|
||||||
|
behaviour for window items in sizers. This means that the item's
|
||||||
|
GetAdjustedBestSize will be called when calculating layout and the
|
||||||
|
return value from that will be used for the minimum size. Added
|
||||||
|
wx.FIXED_SIZE flag for when you would like the old behavior but you
|
||||||
|
should only need it when your desired size is smaller than the item's
|
||||||
|
GetBestSize().
|
||||||
|
|
||||||
|
|
||||||
PlatformInfo
|
PlatformInfo
|
||||||
------------
|
------------
|
||||||
|
Reference in New Issue
Block a user