Esempio n. 1
0
    def __init__(self, parent, name, engineCallback=None):
        """"""
        SectionItem.__init__(self, parent, name, engineCallback)

        #-- Elements
        self.LDR0Button = wx.Button(self, label='LDR 0')
        self.LDR1Button = wx.Button(self, label='LDR 1')

        self.LDR0Label = wx.StaticText(self, label='0')
        self.LDR1Label = wx.StaticText(self, label='0')

        #-- Layout
        vbox =wx.BoxSizer(wx.VERTICAL)
        hbox = wx.BoxSizer(wx.HORIZONTAL)
        hbox.Add(self.LDR0Button, -1, wx.ALL^wx.LEFT^wx.BOTTOM|wx.EXPAND, 10)
        hbox.Add(self.LDR0Label, -1, wx.ALL^wx.BOTTOM|wx.EXPAND, 15)
        vbox.Add(hbox, 0, wx.ALL|wx.EXPAND, 0)
        hbox = wx.BoxSizer(wx.HORIZONTAL)
        hbox.Add(self.LDR1Button, -1, wx.ALL^wx.LEFT^wx.BOTTOM|wx.EXPAND, 10)
        hbox.Add(self.LDR1Label, -1, wx.ALL^wx.BOTTOM|wx.EXPAND, 15)
        vbox.Add(hbox, 0, wx.ALL|wx.EXPAND, 0)
        self.SetSizer(vbox)
        self.Layout()

        #-- Events
        self.LDR0Button.Bind(wx.EVT_BUTTON, self.onButton0Clicked)
        self.LDR1Button.Bind(wx.EVT_BUTTON, self.onButton1Clicked)
Esempio n. 2
0
    def __init__(self, parent, name, engineCallback=None):
        """"""
        SectionItem.__init__(self, parent, name, engineCallback)

        #-- Elements
        self.LDR0Button = wx.Button(self, label='LDR 0')
        self.LDR1Button = wx.Button(self, label='LDR 1')

        self.LDR0Label = wx.StaticText(self, label='0')
        self.LDR1Label = wx.StaticText(self, label='0')

        #-- Layout
        vbox = wx.BoxSizer(wx.VERTICAL)
        hbox = wx.BoxSizer(wx.HORIZONTAL)
        hbox.Add(self.LDR0Button, -1, wx.ALL ^ wx.LEFT ^ wx.BOTTOM | wx.EXPAND,
                 10)
        hbox.Add(self.LDR0Label, -1, wx.ALL ^ wx.BOTTOM | wx.EXPAND, 15)
        vbox.Add(hbox, 0, wx.ALL | wx.EXPAND, 0)
        hbox = wx.BoxSizer(wx.HORIZONTAL)
        hbox.Add(self.LDR1Button, -1, wx.ALL ^ wx.LEFT ^ wx.BOTTOM | wx.EXPAND,
                 10)
        hbox.Add(self.LDR1Label, -1, wx.ALL ^ wx.BOTTOM | wx.EXPAND, 15)
        vbox.Add(hbox, 0, wx.ALL | wx.EXPAND, 0)
        self.SetSizer(vbox)
        self.Layout()

        #-- Events
        self.LDR0Button.Bind(wx.EVT_BUTTON, self.onButton0Clicked)
        self.LDR1Button.Bind(wx.EVT_BUTTON, self.onButton1Clicked)
Esempio n. 3
0
    def __init__(self, parent, name, engineCallback=None):
        """"""
        SectionItem.__init__(self, parent, name, engineCallback)

        #-- Elements
        self.LDR0 = wx.Button(self, label='LDR 0')
        self.LDR1 = wx.Button(self, label='LDR 1')

        self.response = wx.TextCtrl(self,
                                    size=(10, 250),
                                    style=wx.TE_MULTILINE)

        #-- Layout
        vbox = wx.BoxSizer(wx.VERTICAL)
        hbox = wx.BoxSizer(wx.HORIZONTAL)
        hbox.Add(self.LDR0, 0, wx.ALL | wx.EXPAND, 12)
        hbox.Add(self.LDR1, 0, wx.ALL | wx.EXPAND, 12)
        vbox.Add(hbox, 0, wx.ALL | wx.EXPAND, 0)
        vbox.Add(self.response, 1, wx.ALL ^ wx.LEFT | wx.EXPAND, 12)
        self.SetSizer(vbox)
        self.Layout()

        #-- Events
        self.LDR0.Bind(wx.EVT_BUTTON, self.onButton0Clicked)
        self.LDR1.Bind(wx.EVT_BUTTON, self.onButton1Clicked)
Esempio n. 4
0
    def __init__(self, parent, name, engineCallback=None):
        """"""
        SectionItem.__init__(self, parent, name, engineCallback)

        #-- Elements
        self.request = wx.TextCtrl(self, size=(10,10))
        self.control = wx.Button(self, label=self.setting.getLabel())
        self.response = wx.TextCtrl(self, size=(10,250), style=wx.TE_MULTILINE)

        #-- Layout
        vbox =wx.BoxSizer(wx.VERTICAL)
        hbox = wx.BoxSizer(wx.HORIZONTAL)
        hbox.Add(self.request, 1, wx.ALL^wx.RIGHT^wx.LEFT|wx.EXPAND, 12)
        hbox.Add(self.control, 0, wx.ALL|wx.EXPAND, 12)
        vbox.Add(hbox, 0, wx.ALL|wx.EXPAND, 0)
        vbox.Add(self.response, 1, wx.ALL^wx.LEFT|wx.EXPAND, 12)
        self.SetSizer(vbox)
        self.Layout()

        #-- Events
        self.control.Bind(wx.EVT_BUTTON, self.onButtonClicked)
Esempio n. 5
0
    def __init__(self, parent, name, engineCallback=None):
        """"""
        SectionItem.__init__(self, parent, name, engineCallback)

        #-- Elements
        self.request = wx.TextCtrl(self, size=(10, 10))
        self.control = wx.Button(self, label=self.setting.getLabel())
        self.response = wx.TextCtrl(self,
                                    size=(10, 250),
                                    style=wx.TE_MULTILINE)

        #-- Layout
        vbox = wx.BoxSizer(wx.VERTICAL)
        hbox = wx.BoxSizer(wx.HORIZONTAL)
        hbox.Add(self.request, 1, wx.ALL ^ wx.RIGHT ^ wx.LEFT | wx.EXPAND, 12)
        hbox.Add(self.control, 0, wx.ALL | wx.EXPAND, 12)
        vbox.Add(hbox, 0, wx.ALL | wx.EXPAND, 0)
        vbox.Add(self.response, 1, wx.ALL ^ wx.LEFT | wx.EXPAND, 12)
        self.SetSizer(vbox)
        self.Layout()

        #-- Events
        self.control.Bind(wx.EVT_BUTTON, self.onButtonClicked)
Esempio n. 6
0
    def __init__(self, parent, name, engineCallback=None):
        """"""
        SectionItem.__init__(self, parent, name, engineCallback)

        #-- Elements
        self.LDR0 = wx.Button(self, label='LDR 0')
        self.LDR1 = wx.Button(self, label='LDR 1')

        self.response = wx.TextCtrl(self, size=(10,40), style=wx.TE_MULTILINE)

        #-- Layout
        vbox =wx.BoxSizer(wx.VERTICAL)
        hbox = wx.BoxSizer(wx.HORIZONTAL)
        hbox.Add(self.LDR0, -1, wx.ALIGN_CENTER, 12)
        hbox.Add(self.LDR1, -1, wx.ALIGN_CENTER, 12)
        vbox.Add(hbox, 0, wx.ALL|wx.EXPAND, 0)
        vbox.Add(self.response, 1, wx.EXPAND, 12)
        self.SetSizer(vbox)
        self.Layout()

        #-- Events
        self.LDR0.Bind(wx.EVT_BUTTON, self.onButton0Clicked)
        self.LDR1.Bind(wx.EVT_BUTTON, self.onButton1Clicked)