FAQ
Cliff Wells <LogiplexSoftware at earthlink.net> wrote in message news:<mailman.1042825960.12009.python-list at python.org>...
On Fri, 2003-01-17 at 09:33, Sean wrote:

Here is a sample program that creates a small frame and adds a toolbar
with 2 wxStaticText controls. Under both KDE and Gnome (on both
redhat 7.3 and 8.0) the static text will disappear anytime you resize
the frame. The only way to get it back is to give focus to another
window, and then focus to the frame.


from wxPython.wx import *

ID_ABOUT = 101
ID_EXIT = 102

class MyFrame(wxFrame):
def __init__(self, parent, ID, title):
wxFrame.__init__(self, parent, ID, title,
wxDefaultPosition, wxSize(400, 250))


self.toolBar =
self.CreateToolBar(wxTB_HORIZONTAL|wxTB_3DBUTTONS, NewId(), "ToolBar")

#add state combo boxs
id = NewId()
self.toolBar.AddControl(wxStaticText(self.toolBar, id, "Static
Text 1: "))

id = NewId()
self.toolBar.AddControl(wxStaticText(self.toolBar, id, "Static
Text 2: "))


self.toolBar.Realize()



class MyApp(wxApp):
def OnInit(self):
frame = MyFrame(NULL, -1, "Hello from wxPython")
frame.Show(true)
self.SetTopWindow(frame)
return true

app = MyApp(0)
app.MainLoop()
Hm. It seems to work fine for me on Redhat 8.0, using wxPython
2.3.4p2. What version of wxPython are you using?
I've been using both 2.3.2 and the new 2.4.0. I'll see about getting
2.3.4 on and testing that...

Search Discussions

Discussion Posts

Previous

Follow ups

Related Discussions

Discussion Navigation
viewthread | post
posts ‹ prev | 7 of 8 | next ›
Discussion Overview
grouppython-list @
categoriespython
postedJan 10, '03 at 9:18p
activeJan 21, '03 at 8:42p
posts8
users2
websitepython.org

2 users in discussion

Cliff Wells: 4 posts Sean: 4 posts

People

Translate

site design / logo © 2022 Grokbase