def __createPlot(self): plot = _RingPlot(parent=self._imageHolder) plot.setKeepDataAspectRatio(True) toolBar = self.__createPlotToolBar(plot) plot.addToolBar(toolBar) statusBar = self.__createPlotStatusBar(plot) plot.setStatusBar(statusBar) # FIXME Fix using silx 0.5 if "BackendMatplotlib" in plot._backend.__class__.__name__: # hide axes and viewbox rect plot._backend.ax.set_axis_off() plot._backend.ax2.set_axis_off() # remove external margins plot._backend.ax.set_position([0, 0, 1, 1]) plot._backend.ax2.set_position([0, 0, 1, 1]) colormap = { 'name': "inferno", 'normalization': 'log', 'autoscale': True, } plot.setDefaultColormap(colormap) return plot
def __createPlot(self, parent): plot = silx.gui.plot.PlotWidget(parent=parent) plot.setKeepDataAspectRatio(True) plot.setDataMargins(0.1, 0.1, 0.1, 0.1) plot.setGraphXLabel("X") plot.setGraphYLabel("Y") colormap = CalibrationContext.instance().getRawColormap() plot.setDefaultColormap(colormap) from silx.gui.plot import tools toolBar = tools.InteractiveModeToolBar(parent=self, plot=plot) plot.addToolBar(toolBar) toolBar = tools.ImageToolBar(parent=self, plot=plot) colormapDialog = CalibrationContext.instance().getColormapDialog() toolBar.getColormapAction().setColorDialog(colormapDialog) plot.addToolBar(toolBar) toolBar = qt.QToolBar(self) plot3dAction = qt.QAction(self) plot3dAction.setIcon(icons.getQIcon("pyfai:gui/icons/3d")) plot3dAction.setText("3D visualization") plot3dAction.setToolTip("Display a 3D visualization of the detector") plot3dAction.triggered.connect(self.__display3dDialog) toolBar.addAction(plot3dAction) plot.addToolBar(toolBar) return plot
def __createPlot(self): plot = _RingPlot(parent=self._imageHolder) plot.setKeepDataAspectRatio(True) self.__createPlotToolBar(plot) statusBar = self.__createPlotStatusBar(plot) self.__statusBar = statusBar plot.setStatusBar(statusBar) plot.setAxesDisplayed(False) colormap = CalibrationContext.instance().getRawColormap() plot.setDefaultColormap(colormap) return plot
def __createPlot(self, parent): plot = silx.gui.plot.PlotWidget(parent=parent) plot.setKeepDataAspectRatio(True) plot.setDataMargins(0.1, 0.1, 0.1, 0.1) plot.setGraphXLabel("Y") plot.setGraphYLabel("X") colormap = CalibrationContext.instance().getRawColormap() plot.setDefaultColormap(colormap) from silx.gui.plot import tools toolBar = tools.InteractiveModeToolBar(parent=self, plot=plot) plot.addToolBar(toolBar) toolBar = tools.ImageToolBar(parent=self, plot=plot) colormapDialog = CalibrationContext.instance().getColormapDialog() toolBar.getColormapAction().setColorDialog(colormapDialog) plot.addToolBar(toolBar) return plot
def __createPlot(self, parent): plot = silx.gui.plot.PlotWidget(parent=parent) plot.setKeepDataAspectRatio(True) plot.setDataMargins(0.1, 0.1, 0.1, 0.1) plot.setGraphXLabel("Y") plot.setGraphYLabel("X") plot.setAxesDisplayed(False) colormap = CalibrationContext.instance().getRawColormap() plot.setDefaultColormap(colormap) from silx.gui.plot import tools toolBar = tools.InteractiveModeToolBar(parent=self, plot=plot) plot.addToolBar(toolBar) toolBar = tools.ImageToolBar(parent=self, plot=plot) colormapDialog = CalibrationContext.instance().getColormapDialog() toolBar.getColormapAction().setColorDialog(colormapDialog) plot.addToolBar(toolBar) statusBar = self.__createPlotStatusBar(plot) plot.setStatusBar(statusBar) return plot