Hi All,
I have just committed some fairly large changes to the AGW library,
and I hope I am going to explain myself clearly enough about what I
have done.
First of all, I would like to apologize to those (3 or 4) wxPython
users/developers who are actually using AGW. If you update your copy
of AGW from SVN, you will be forced to make (relatively small) changes
to your applications.
As you may know, for some widgets in AGW (most notably CustomTreeCtrl,
AuiNotebook, HyperTreeList, FlatNotebook, UltimateListCtrl), the
AGW-specific window style conflicted with the underlying wx.Window
window styles (one mention is in bug #11861 at the tracker:
http://trac.wxwidgets.org/ticket/11861). So, my approach has been the
following:
1) For all the AGW widgets in which the "style" keyword used mixed
wx.Window styles and AGW styles, I have added a new keyword for their
constructor (termed "agwStyle"). So, if you were using CustomTreeCtrl
like this before:
class CustomTreeCtrl(CT.CustomTreeCtrl):
def __init__(self, parent, id=wx.ID_ANY, pos=wx.DefaultPosition,
size=wx.DefaultSize,
style=wx.SUNKEN_BORDER | CT.TR_HAS_BUTTONS
> CT.TR_HAS_VARIABLE_ROW_HEIGHT):
CT.CustomTreeCtrl.__init__(self, parent, id, pos, size, style)
Now you should construct it like this:
class CustomTreeCtrl(CT.CustomTreeCtrl):
def __init__(self, parent, id=wx.ID_ANY, pos=wx.DefaultPosition,
size=wx.DefaultSize,
style=wx.SUNKEN_BORDER,
agwStyle=CT.TR_HAS_BUTTONS | CT.TR_HAS_VARIABLE_ROW_HEIGHT):
CT.CustomTreeCtrl.__init__(self, parent, id, pos, size, style, agwStyle)
Which means, the "style" keyword is now reserved for the underlying
wx.Window only and it's left untouched by AGW.
2) As the constructors have been modified, methods like HasFlag,
SetWindowStyle, SetWindowStyleFlag, GetWindowStyle, GetWindowStyleFlag
and so on do *not* return the AGW style anymore. For these modified
widgets, you should use:
- SetAGWWindowStyleFlag;
- GetAGWWindowStyleFlag;
- HasAGWFlag (this method is not present everywhere)
3) There are no more "extra styles" in UltimateListCtrl (everything is
clamped inside the "agwStyle" keyword);
4) There are no more limitations on the number of styles a widget can
have (this is a positive outcome).
The AGW widgets affected by these changes are:
- AdvancedSplash
- AUI
- ButtonPanel
- CubeColourDialog
- CustomTreeCtrl
- FlatNotebook
- FloatSpin
- FourWaySplitter
- GenericMessageDialog
- HyperTreeList
- KnobCtrl
- LabelBook
- MultiDirDialog
- PeakMeter
- PyProgress
- RibbonBar
- SpeedMeter
- UltimateListCtrl
In the meanwhile, I believe I have managed to fix tickets #11825
(AuiNotebook), #11861 (FlatNotebook), #11953 (AuiNotebook), #11954
(HyperTreeList).
The updated documentation for AGW is here:
http://xoomer.virgilio.it/infinity77/AGW_Docs/index.html
If you encounter any issue/problem, please let me know. I have tested
the changes quite a bit but it was a huge commit and something may
have slipped in.
Sorry for the disruption, happy wxPython hacking.
Andrea.
"Imagination Is The Only Weapon In The War Against Reality."
http://xoomer.alice.it/infinity77/
==> Never *EVER* use RemovalGroup for your house removal. You'll
regret it forever.
http://thedoomedcity.blogspot.com/2010/03/removal-group-nightmare.html <==
···
--
To unsubscribe, send email to wxPython-users+unsubscribe@googlegroups.com
or visit http://groups.google.com/group/wxPython-users?hl=en