How to change background color in dialogs?
Jerry LeVan
jerry.levan at gmail.com
Thu May 3 10:17:55 PDT 2007
Hi,
I can't seem to find the magic to change the background color
in a dialog...
Here is a fragment that does not work:
class LoginDialog(wx.Dialog):
def __init__(self, data):
wx.Dialog.__init__(self, None, -1, "Postgresql Login Dialog")
res=self.SetBackgroundColour("blue")
if res :
print "changed "+str(res)
self.Refresh()
And later I have
app = wx.PySimpleApp()
data = { "user" : "levan", "port" : "5432" }
dlg = LoginDialog(data)
dlg.ShowModal()
dlg.Destroy()
Is it possible to set the background to a non default color? ( on my
mac it is always white ;(
Python 2.5.1 / wxPython 2.8.3 / MacOSX 10.4.9
Thanks,
Jerry
More information about the wxpython-users
mailing list