I am just played around with wxGLCanvas. It doesn't seem to be
possible to display OGL content on a Panel!? What I want is to mix
wxGLCanvas, Panels, Buttons and Grid in one single Frame. Is that
possible?
On the other hand I found out a way to do just that. But it seems to
be not the correct way and I would like ask if it is okay to do so.
At first I generate an Canvas inside a frame and draw some GL stuff.
AFTER I showed the frame, I add a panel and increase the dimension of
the frame. The panel gets visible, and the Canvas still gets updated.
Any comments appreciated.
Lucian
Here is the code:
...
frame=wxFrame(pos = wxPoint(100, 100), size = wxSize(400, 400) ,....)
canvas=CubeCanvas(frame) #taken from the wxGLCanvas Demo
I have a wxCheckBoxList where I dynamically add/remove items. I wan't to
keep it sorted, but I found out that style=wxLB_SORT made it misbehave (as
previously reported in this list). Now I sort things manually as items are
Append()ed, and I'd like to be able to Check(1|0) items without actually
emitting an EVT_CHECKLISTBOX, just like you can SetValue in wxCheckBoxes.
I am just played around with wxGLCanvas. It doesn't seem to be
possible to display OGL content on a Panel!? What I want is to mix
wxGLCanvas, Panels, Buttons and Grid in one single Frame. Is that
possible?
Yep. Make a panel as the child of the frame, and the canvas buttons, grid,
etc. as children of the panel.
···
--
Robin Dunn
Software Craftsman
robin@AllDunn.com Java give you jitters? http://wxPython.org Relax with wxPython!
I have a wxCheckBoxList where I dynamically add/remove items. I wan't to
keep it sorted, but I found out that style=wxLB_SORT made it misbehave (as
previously reported in this list). Now I sort things manually as items are
Append()ed, and I'd like to be able to Check(1|0) items without actually
emitting an EVT_CHECKLISTBOX, just like you can SetValue in wxCheckBoxes.
How do I do that?
If it's sending an event when you call Check, then please enter a bug report
about it. In the meantime you can get around it by setting a flag before
calling Check and checking the flag in your event handler.
···
--
Robin Dunn
Software Craftsman
robin@AllDunn.com Java give you jitters? http://wxPython.org Relax with wxPython!
Yeah, but the problem is, that if I am put GLCanvas and a panel inside
a frame and show the frame afterwards, the GL content will not be
vissible.
···
I am just played around with wxGLCanvas. It doesn't seem to be
possible to display OGL content on a Panel!? What I want is to mix
wxGLCanvas, Panels, Buttons and Grid in one single Frame. Is that
possible?
Yep. Make a panel as the child of the frame, and the canvas buttons, grid,
etc. as children of the panel.
--
Robin Dunn
Software Craftsman
robin@AllDunn.com Java give you jitters? http://wxPython.org Relax with wxPython!