After using RemovePage in a wxNotebook the page gets removed but
the tab stays. I've noticed this in my app and other people's (Pysoulseek for example).
Is there something I can do to fix this? I get this in wxPython 2.4.0.2 and 2.4.0.7, wxGTK version.
If I manually resize the window with the mouse it disappears.
Sample code? Does it still happen with 2.4.1.2?
Yes, I just tried 2.4.1.2, so I think its something I'm (not?) doing.
I simply call self.nb.RemovePage(self.nb.GetSelection())
I'm not sure if I need to do anything else. I tried .Refresh() on self (the panel) and
self.nb, but neither helped.
Try changing the selection to another page first.
I tried. No luck using 2.4.1.2 using this code:
p = self.nb.GetSelection()
self.nb.SetSelection(p - 1)
self.nb.RemovePage(p)
After using RemovePage in a wxNotebook the page gets removed but
the tab stays. I've noticed this in my app and other people's (Pysoulseek for example).
Is there something I can do to fix this? I get this in wxPython 2.4.0.2 and 2.4.0.7, wxGTK version.
If I manually resize the window with the mouse it disappears.
Sample code? Does it still happen with 2.4.1.2?
Yes, I just tried 2.4.1.2, so I think its something I'm (not?) doing.
I simply call self.nb.RemovePage(self.nb.GetSelection())
I'm not sure if I need to do anything else. I tried .Refresh() on self (the panel) and
self.nb, but neither helped.
Try changing the selection to another page first.
I tried. No luck using 2.4.1.2 using this code:
p = self.nb.GetSelection()
self.nb.SetSelection(p - 1)
self.nb.RemovePage(p)
The demo removes pages when switching between the samples but I've never seen this problem there. Perhaps something on your machine you are using could be causing this problem? (Some rogue libraries, the gtk theme, etc.) Try removing your ~/.gtkrc* files and see if that makes a difference.
···
--
Robin Dunn
Software Craftsman http://wxPython.org Java give you jitters? Relax with wxPython!