-# 11/22/2003 - Jeff Grimmett (grimmtooth@softhome.net)
-#
-# o Updated for wx namespace
-#
import string
import wx
-
#----------------------------------------------------------------------
ALPHA_ONLY = 1
fgs.Add(wx.TextCtrl(self, -1, "", validator = TextObjectValidator()))
- buttons = wx.BoxSizer(wx.HORIZONTAL)
- b = wx.Button(self, wx.ID_OK, "Okay")
+ buttons = wx.StdDialogButtonSizer() #wx.BoxSizer(wx.HORIZONTAL)
+ b = wx.Button(self, wx.ID_OK, "OK")
b.SetDefault()
- buttons.Add(b, 0, wx.ALL, 10)
- buttons.Add(wx.Button(self, wx.ID_CANCEL, "Cancel"), 0, wx.ALL, 10)
+ buttons.AddButton(b)
+ buttons.AddButton(wx.Button(self, wx.ID_CANCEL, "Cancel"))
+ buttons.Realize()
border = wx.BoxSizer(wx.VERTICAL)
border.Add(fgs, 1, wx.GROW|wx.ALL, 25)
overview = """\
<html>
<body>
-wxValidator is the base class for a family of validator classes that mediate
+wx.Validator is the base class for a family of validator classes that mediate
between a class of control, and application data.
<p>A validator has three major roles:
if __name__ == '__main__':
import sys,os
import run
- run.main(['', os.path.basename(sys.argv[0])])
+ run.main(['', os.path.basename(sys.argv[0])] + sys.argv[1:])