[wxPython] The display of wxFrame and Grid collapsed & error message displayed

# Create a Notebook
        self.nb = wxNotebook(splitter2, -1, style=wxCLIP_CHILDREN)
        
        # Set up a wxHtmlWindow on the Overview Notebook page
        # we put it in a panel first because there seems to be a
        # refresh bug of some sort (wxGTK) when it is directly in
        # the notebook...
        if 0: # the old way
            self.ovr = wxHtmlWindow(self.nb, -1, size=(400, 400))
            self.nb.AddPage(self.ovr, "Overview")

        else: # hopefully I can remove this hacky code soon, see bug #216861
            self.ovr = AtGrid.BomGrid(self.nb) ---(1)
            self.nb.AddPage(self.ovr, "Overview") ---(2)

            #def OnOvrSize(evt, ovr=self.ovr):
            # ovr.SetSize(evt.GetSize())

            #EVT_SIZE(self.ovr, OnOvrSize)
            #EVT_ERASE_BACKGROUND(self.ovr, EmptyHandler)

16:50:36: Debug: ..\msw\dc.cpp(291): 'CreateRectRgn' failed with error 0x00000000

I've tried to add the "Simple grid" instead of wxHtmlWindows in the demo's main.py.
But the display of wxFrame and Grid is collapsed.
And the message is displayed.

How should I do the size control event of grid?

Thanks

I've tried to add the "Simple grid" instead of wxHtmlWindows in the demo's

main.py.

But the display of wxFrame and Grid is collapsed.

I don't know what you mean by this statement.

And the message is displayed.

How should I do the size control event of grid?

Is BomGrid derived from wxGrid or wxFrame? If wxFrame then you can see now
why you can't put wxFrames in a notebook page. If it is derived from
wxGrid, then you shouln't need to resize it at all as the notebook will
resize its immediate children automatically.

···

--
Robin Dunn
Software Craftsman
robin@AllDunn.com Java give you jitters?
http://wxPython.org Relax with wxPython!

I'm sorry it's insufficient to explain my question.

I'm modifying the main.py to study the wxPython.
So the base code is the main.py of wxpython's demo folder.
The sent codes is a part of it.
As I'm said, the original demo displayes the htmlwindows in the rightside view.
Instead of rightside view's htmlwindows I've tried to display the simplegrid.
It's no problem to display, but the wxframe is been resized with mouse manually.
The Grid is happended the abnormal display.
And the error message is displayed in the lower right window of wxframe and the left upper side of
windows 2000.

···

----- Original Message -----
From: "Robin Dunn" <robin@alldunn.com>
To: <wxpython-users@lists.wxwindows.org>
Sent: Friday, July 27, 2001 7:40 AM
Subject: Re: [wxPython] The display of wxFrame and Grid collapsed & error message displayed

> I've tried to add the "Simple grid" instead of wxHtmlWindows in the demo's
main.py.
> But the display of wxFrame and Grid is collapsed.

I don't know what you mean by this statement.

> And the message is displayed.
>
> How should I do the size control event of grid?

Is BomGrid derived from wxGrid or wxFrame? If wxFrame then you can see now
why you can't put wxFrames in a notebook page. If it is derived from
wxGrid, then you shouln't need to resize it at all as the notebook will
resize its immediate children automatically.

--
Robin Dunn
Software Craftsman
robin@AllDunn.com Java give you jitters?
http://wxPython.org Relax with wxPython!

_______________________________________________
wxpython-users mailing list
wxpython-users@lists.wxwindows.org
http://lists.wxwindows.org/mailman/listinfo/wxpython-users