def __init__(self, parent, title='Select new connection type'): WizardPageSimple.__init__(self, parent) self.sizer = wx.BoxSizer(wx.VERTICAL) self.SetSizer(self.sizer) titleText = wx.StaticText(self, -1, title) fs = self.GetFont().GetPointSize() bf = wx.Font(fs + 4, wx.SWISS, wx.NORMAL, wx.BOLD) nf = wx.Font(fs + 2, wx.SWISS, wx.NORMAL, wx.NORMAL) titleText.SetFont(bf) #################################################################### ''' Header section ''' self.tree = DatabaseNavigationTree(self) self.filter = wx.SearchCtrl(self, style=wx.TE_PROCESS_ENTER) self.filter.SetDescriptiveText("Type filter database name") self.filter.ShowCancelButton(True) self.filter.Bind(wx.EVT_TEXT, self.RecreateTree) self.filter.Bind(wx.EVT_SEARCHCTRL_CANCEL_BTN, lambda e: self.filter.SetValue('')) self.filter.Bind(wx.EVT_TEXT_ENTER, self.OnSearch) self.RecreateTree() #################################################################### self.sizer.Add(titleText, 0, wx.ALIGN_CENTRE | wx.ALL, 5) self.sizer.Add(wx.StaticLine(self, -1), 0, wx.EXPAND | wx.ALL, 5) self.sizer.Add(self.filter, 0, wx.EXPAND | wx.ALL) self.sizer.Add(self.tree, 1, wx.EXPAND | wx.ALL)
def __init__(self, parent, title): WizardPageSimple.__init__(self, parent) self.sizer = wx.BoxSizer(wx.VERTICAL) self.SetSizer(self.sizer) titleText = wx.StaticText(self, -1, title) titleText.SetFont(wx.Font(12, wx.SWISS, wx.NORMAL, wx.BOLD)) self.sizer.Add(titleText, 0, wx.ALIGN_CENTRE | wx.ALL, 5) self.sizer.Add(wx.StaticLine(self, -1), 0, wx.EXPAND | wx.ALL, 5)
def __init__(self, parent, title='define title'): WizardPageSimple.__init__(self, parent) self.sizer = wx.BoxSizer(wx.VERTICAL) self.SetSizer(self.sizer) titleText = wx.StaticText(self, -1, title) fs = self.GetFont().GetPointSize() bf = wx.Font(fs + 4, wx.SWISS, wx.NORMAL, wx.BOLD) nf = wx.Font(fs + 2, wx.SWISS, wx.NORMAL, wx.NORMAL) titleText.SetFont(bf) self.sizer.Add(titleText, 0, wx.ALIGN_CENTRE | wx.ALL, 5) self.sizer.Add(wx.StaticLine(self, -1), 0, wx.EXPAND | wx.ALL, 5) #################################################################### self.panel = wx.Panel(self, -1) vbox1 = wx.BoxSizer(wx.VERTICAL) hbox1 = wx.BoxSizer(wx.HORIZONTAL) hbox3 = wx.BoxSizer(wx.HORIZONTAL) connectionNameLabel = wx.StaticText(self.panel, -1, "Connection name : ") self.connectionNameTextCtrl = wx.TextCtrl(self.panel, size=(300, -1)) dbFileNameLabel = wx.StaticText(self.panel, -1, "Database File name : ") self.dbFileNameTextCtrl = wx.TextCtrl(self.panel, size=(300, -1)) self.connectionNameTextCtrl.Bind(wx.EVT_TEXT, self.onConnectionName) hbox1.Add(connectionNameLabel) hbox1.Add(self.connectionNameTextCtrl, 0, wx.EXPAND | wx.ALIGN_LEFT | wx.ALL, 1) hbox3.Add(dbFileNameLabel) hbox3.Add(self.dbFileNameTextCtrl, 0, wx.EXPAND | wx.ALIGN_LEFT | wx.ALL, 1) import wx.lib.filebrowsebutton as filebrowse self.dbb = filebrowse.DirBrowseButton(self.panel, -1, size=(450, -1), changeCallback=self.dbbCallback, startDirectory=wx.GetHomeDir()) self.dbb.SetValue(wx.GetHomeDir(), self.dbbCallback) # self.markFile = brows.FileBrowseButton(self.panel, labelText="File path :", fileMode=wx.FD_OPEN, size=(400, 30), toolTip='Type database filename or click browse to choose file') # self.markFile.Bind(wx.EVT_TEXT, self.onMarkFile) hbox2 = wx.BoxSizer(wx.HORIZONTAL) hbox2.Add(self.dbb) vbox1.Add(hbox1) vbox1.Add(hbox2) vbox1.Add(hbox3) self.panel.SetSizer(vbox1) self.sizer.Add(self.panel, 0, wx.ALL, 5)
def __init__(self, parent, lp, title): WizardPageSimple.__init__(self, parent) self.sizer = make_page_title(self, title) self.lp = lp
def __init__(self, parent, title): WizardPageSimple.__init__(self, parent) self.sizer = makePageTitle(self, title)
def __init__(self,parent,lp,title): WizardPageSimple.__init__(self, parent) self.sizer = make_page_title(self, title) self.lp = lp