[wxMac 2.8x] wxWindow::DoGetBestSize bug still not solved
H
H at h.com
Tue Apr 17 10:00:27 PDT 2007
In article <27lZ_.A.trO.0l6IGB at brage.sunsite.dk>,
vadim at wxwindows.org (Vadim Zeitlin) wrote:
> On Mon, 16 Apr 2007 18:39:50 +0200 H <H at h.com> wrote:
>
> H> > Sorry, I'm getting confusier and confusier. If GetSize() returns (0, 0)
> H> > for hidden windows it definitely isn't fine. So which one is it?
> H> >
> H> This behaviour sounds logical to me.
>
> It's definitely not meant to work like this and it doesn't in the other
> ports and unless I have Stefan's word to the contrary I'll continue to
> believe that it's not intended to work like this in wxMac neither.
>
> H> I think you mean the correct thing but described it incorrectly: "diff"
> H> is positive because GetClientSize() becomes negative. And therefore
> H> positive values are added to "best".
>
> Yes, sorry.
>
> H> That's how it works know!
>
> This is a bug.
>
> H> > Once again:
> H> >
> H> > 1. If GetSize() returns (0, 0) for a window with scrollbars this is a
> bug.
> H> > 2. Independently of this discussion, calling InvalidateBestSize() in
> H> > DoInsertItem() should help with wxTreebook problem
> H> >
> H> > Regards,
> H> > VZ
> H>
> H> Then, I have to find out why a window with scrollbars ever returns (0,
> H> 0) when calling GetSize().
>
> As I wrote, I suspect that it's just because scrollbars don't yet exist at
> this moment. Could you please try if (2) above helps?
>
> TIA,
> VZ
(2) does not help.
I put it here:
wxTreeItemId wxGenericTreeCtrl::DoInsertItem(const wxTreeItemId&
parentId,
size_t previous,
const wxString& text,
int image,
int selImage,
wxTreeItemData *data)
{
this->InvalidateBestSize();
wxGenericTreeItem *parent = (wxGenericTreeItem*) parentId.m_pItem;
Hartwig
More information about the wx-users
mailing list