Beispiel #1
0
    def createRescale(self):
        """
		Creates the GUI for controlling the rescaling
		"""
        box = wx.StaticBox(self, -1, "Preview selected mapping")
        previewBox = wx.StaticBoxSizer(box, wx.HORIZONTAL)
        self.preview = PreviewFrame(self,
                                    previewsize=(256, 256),
                                    scrollbars=False)

        previewBox.Add(self.preview)

        self.zslider = wx.Slider(self,
                                 value=1,
                                 minValue=1,
                                 maxValue=1,
                                 style=wx.SL_VERTICAL | wx.SL_LABELS
                                 | wx.SL_AUTOTICKS)
        self.zslider.SetHelpText(
            "Use this slider to select the displayed optical slice.")
        self.zslider.Bind(wx.EVT_SCROLL, self.onChangeZSlice)

        previewBox.Add(self.zslider, 1, wx.EXPAND)

        box = wx.StaticBox(self, -1, "Channel histograms")
        self.histogramSizer = wx.StaticBoxSizer(box, wx.HORIZONTAL)

        self.sizer.Add(previewBox, (0, 0), flag=wx.EXPAND | wx.ALL)
        self.sizer.Add(self.histogramSizer, (2, 0), flag=wx.EXPAND | wx.ALL)