コード例 #1
0
    def makeGaugePanel(self):
        """Make processing gauge."""

        panel = wx.Panel(self, -1)

        # make elements
        self.gauge = mwx.gauge(panel, -1)

        stop_butt = wx.BitmapButton(panel,
                                    -1,
                                    images.lib['stopper'],
                                    style=wx.BORDER_NONE)
        stop_butt.Bind(wx.EVT_BUTTON, self.onStop)

        # pack elements
        sizer = wx.BoxSizer(wx.HORIZONTAL)
        sizer.Add(self.gauge, 1, wx.ALIGN_CENTER_VERTICAL)
        sizer.AddSpacer(10)
        sizer.Add(stop_butt, 0, wx.ALIGN_CENTER_VERTICAL)

        # fit layout
        mainSizer = wx.BoxSizer(wx.VERTICAL)
        if wx.Platform == '__WXMAC__':
            mainSizer.Add(wx.StaticLine(panel), 0, wx.EXPAND | wx.TOP, -1)
        mainSizer.Add(sizer, 1, wx.EXPAND | wx.ALL, mwx.GAUGE_SPACE)
        panel.SetSizer(mainSizer)
        mainSizer.Fit(panel)

        return panel
コード例 #2
0
 def makeGaugePanel(self):
     """Make processing gauge."""
     
     panel = wx.Panel(self, -1)
     
     # make elements
     self.gauge = mwx.gauge(panel, -1)
     
     stop_butt = wx.BitmapButton(panel, -1, images.lib['stopper'], style=wx.BORDER_NONE)
     stop_butt.Bind(wx.EVT_BUTTON, self.onStop)
     
     # pack elements
     sizer = wx.BoxSizer(wx.HORIZONTAL)
     sizer.Add(self.gauge, 1, wx.ALIGN_CENTER_VERTICAL)
     sizer.AddSpacer(10)
     sizer.Add(stop_butt, 0, wx.ALIGN_CENTER_VERTICAL)
     
     # fit layout
     mainSizer = wx.BoxSizer(wx.VERTICAL)
     if wx.Platform == '__WXMAC__':
         mainSizer.Add(wx.StaticLine(panel), 0, wx.EXPAND|wx.TOP, -1)
     mainSizer.Add(sizer, 1, wx.EXPAND|wx.ALL, mwx.GAUGE_SPACE)
     panel.SetSizer(mainSizer)
     mainSizer.Fit(panel)
     
     return panel
コード例 #3
0
 def makeGaugePanel(self):
     """Make processing gauge."""
     
     panel = wx.Panel(self, -1)
     
     # make elements
     self.gauge = mwx.gauge(panel, -1)
     
     # pack elements
     mainSizer = wx.BoxSizer(wx.VERTICAL)
     mainSizer.Add(self.gauge, 0, wx.EXPAND|wx.LEFT|wx.RIGHT|wx.BOTTOM, mwx.GAUGE_SPACE)
     
     # fit layout
     mainSizer.Fit(panel)
     panel.SetSizer(mainSizer)
     
     return panel
コード例 #4
0
ファイル: panel_calibration.py プロジェクト: wwissdorf/mmass
    def makeGaugePanel(self):
        """Make processing gauge."""

        panel = wx.Panel(self, -1)

        # make elements
        self.gauge = mwx.gauge(panel, -1)

        # pack elements
        mainSizer = wx.BoxSizer(wx.VERTICAL)
        if wx.Platform == '__WXMAC__':
            mainSizer.Add(wx.StaticLine(panel), 0, wx.EXPAND | wx.TOP, -1)
        mainSizer.Add(self.gauge, 0, wx.EXPAND | wx.ALL, mwx.GAUGE_SPACE)

        # fit layout
        mainSizer.Fit(panel)
        panel.SetSizer(mainSizer)

        return panel
コード例 #5
0
    def makeGaugePanel(self):
        """Make processing gauge."""

        panel = wx.Panel(self, -1)

        # make elements
        self.gauge = mwx.gauge(panel, -1)

        # pack elements
        mainSizer = wx.BoxSizer(wx.VERTICAL)
        if wx.Platform == "__WXMAC__":
            mainSizer.Add(wx.StaticLine(panel), 0, wx.EXPAND | wx.TOP, -1)
        mainSizer.Add(self.gauge, 0, wx.EXPAND | wx.ALL, mwx.GAUGE_SPACE)

        # fit layout
        mainSizer.Fit(panel)
        panel.SetSizer(mainSizer)

        return panel
コード例 #6
0
    def makeGaugePanel(self):
        """Make processing gauge."""

        panel = wx.Panel(self, -1)

        # make elements
        self.gauge = mwx.gauge(panel, -1)

        # pack elements
        mainSizer = wx.BoxSizer(wx.VERTICAL)
        mainSizer.Add(self.gauge, 0,
                      wx.EXPAND | wx.LEFT | wx.RIGHT | wx.BOTTOM,
                      mwx.GAUGE_SPACE)

        # fit layout
        mainSizer.Fit(panel)
        panel.SetSizer(mainSizer)

        return panel