wxPython and wxFlexGridSizer problem

Jeff Shannon jeff at ccvcorp.com
Tue Mar 26 14:47:41 EST 2002


Cliff Wells wrote:

> Also, I notice that your calls to gridSizer.Add are incorrect.  The second
> argument is supposed to be a boolean flag indicating whether the widget
> should be expanded in the sizer's primary direction (in the case of a
> wxFlexGridSizer, I'm not sure what that means, but you still need the
> argument, at least as a placeholder).  The wxALL and wxALIGN_* flags should
> be the third argument.

Oooh, I missed that, the first time through.  Actually, though, the second
argument isn't a boolean, though, it's an integer, which represents the
weighting given to that item when expanded.  (If you add item 1 with weight 2,
item 2 with weight 0, and item 3 with weight 1, then any expanded space will be
split up, with 2/3 of it going to item 1 and 1/3 going to item 3...)

Jeff Shannon
Technician/Programmer
Credit International





More information about the Python-list mailing list