示例#1
0
 def build_panels(self, build_spec):
   panels = OrderedDict()
   for panel_name in self._build_spec['widgets'].keys():
     panel = ConfigPanel(self, widgets=self._build_spec['widgets'][panel_name], opt_cols=self._build_spec['num_optional_cols'], title=panel_name.upper())
     panels[panel_name] = panel
     panel.Hide()
   return panels
示例#2
0
  def __init__(self, *args, **kwargs):
    self._build_spec = kwargs.pop('build_spec')
    super(FlatLayout, self).__init__(*args, **kwargs)
    self.SetDoubleBuffered(True)

    self.main_content = ConfigPanel(self, widgets=self._build_spec['widgets'], opt_cols=self._build_spec['num_optional_cols'])

    sizer = wx.BoxSizer(wx.HORIZONTAL)
    sizer.Add(self.main_content, 3, wx.EXPAND)
    self.SetSizer(sizer)
示例#3
0
    def __init__(self, *args, **kwargs):
        super(FlatLayout, self).__init__(*args, **kwargs)
        self.SetDoubleBuffered(True)

        self.main_content = ConfigPanel(self, opt_cols=3)

        sizer = wx.BoxSizer(wx.HORIZONTAL)
        sizer.Add(self.main_content, 3, wx.EXPAND)
        self.SetSizer(sizer)
示例#4
0
    def __init__(self, *args, **kwargs):
        super(ColumnLayout, self).__init__(*args, **kwargs)
        self.SetDoubleBuffered(True)

        self.sidebar = Sidebar(self)
        self.main_content = ConfigPanel(self, opt_cols=2)

        sizer = wx.BoxSizer(wx.HORIZONTAL)
        sizer.Add(self.sidebar, 1, wx.EXPAND)
        sizer.Add(wx_util.vertical_rule(self), 0, wx.EXPAND)
        sizer.Add(self.main_content, 3, wx.EXPAND)
        self.SetSizer(sizer)