On Thu, Mar 25, 2010 at 9:31 AM, <GadgetSt...@live.co.uk> wrote:
> --------------------------------------------------
> From: "Andrea Gavana" <andrea.gav...@gmail.com>
> Sent: Thursday, March 25, 2010 8:21 AM
> To: <wxpython-users@googlegroups.com>
> Subject: Re: [wxPython-users] size of split page in AUINotebook?
>> Hi Che,
>> On 25 March 2010 03:13, C M wrote:
>>> (Python 2.5, wx.Pythin 2.8.10, WinXP and Linux)
>>> I am using the (wxWidgets derived, not AGW for now) AUINotebook and
>>> simply want to .Split() a page down to the bottom half of the
>>> notebook. When I call this:
>>> self.nb.Split(1, wx.BOTTOM)
>>> It splits, but the bottom page is about 1/5th the height of the top
>>> page. I'd like them to be roughly equal--or even have control over
>>> the exact page height. How can I do that? (Or why might it be
>>> splitting things this unevenly?)
>>> I've made a sample app with just bare panels, but it doesn't reproduce
>>> my problem--there .Split() does in fact split them 50/50.
>> That shouldn't really happens, as the C++ code explicitely set the
>> AUINotebook to split 50/50 *IF* there are only 2 TabCtrls (i.e., it is
>> the first time you split the AuiNotebook). Other than that, the only
>> reason why this might happen depends on the best size the 2 panes
>> report to have, but I am just guessing here without a sample
>> reproducing the issue...
> Just a guess but I have seen similar effects when the panel within the frame
> was longer than the frame, the panel - in this case the notebook is split
> 50-50 but as only 60% is visible the visible portion of it appears to be
> split 50-10 or 1/6th of the way up. Could this be the problem? If it is
> then there might be a missing call to Fit() that is the problem.
> Gadget/Steve
>> Andrea.
Thanks, Andrea and Gadget/Steve...but unfortunately for now I'm just
stuck. I tried simplifying things in my app by having it add blank
panels as notebook pages, and adjusting sizes or providing (-1,-1) as
sizes, and calling Layout() and Fit() somewhat indiscriminately, but I
guess there too many sizers-within-sizers in the frame for me to
easily figure out what's going on.
For now, I'm trying just using two AUINotebooks, one above the other,
though I'm not sure I'll remain satisfied with that, since users ought
to be able to choose how to display or not display these pages.
Thanks for the info, though.
Che