def show_fullscreen_chart(chart, parent): """ :param chart: a chart container :return: the widget showing the chart, by default a LiteBoxView """ from matplotlib.figure import Figure from matplotlib.backends.backend_qt4agg import FigureCanvasQTAgg as FigureCanvas from camelot.view.controls.liteboxview import LiteBoxView from camelot.container.chartcontainer import structure_to_figure_container figure_container = structure_to_figure_container(chart) litebox = LiteBoxView(parent) fig = Figure(facecolor='#ffffff') canvas = FigureCanvas(fig) canvas.updateGeometry() figure_container.plot_on_figure(fig) proxy = QtGui.QGraphicsProxyWidget() proxy.setWidget(canvas) litebox.show_fullscreen_item(proxy) canvas.draw() return litebox
def show_fullscreen_chart(chart, parent): """ :param chart: a chart container :return: the widget showing the chart, by default a LiteBoxView """ from matplotlib.figure import Figure from matplotlib.backends.backend_qt4agg import FigureCanvasQTAgg as FigureCanvas from camelot.view.controls.liteboxview import LiteBoxView from camelot.container.chartcontainer import structure_to_figure_container figure_container = structure_to_figure_container( chart ) litebox = LiteBoxView(parent) fig = Figure(facecolor='#ffffff') canvas = FigureCanvas(fig) canvas.updateGeometry() figure_container.plot_on_figure(fig) proxy = QtGui.QGraphicsProxyWidget() proxy.setWidget(canvas) litebox.show_fullscreen_item(proxy) canvas.draw() return litebox
def gui_run(self, gui_context): from camelot.view.controls.liteboxview import LiteBoxView litebox = LiteBoxView(parent=gui_context.workspace) litebox.show_fullscreen_pixmap(self.pixmap.getQPixmap())
def gui_run( self, gui_context ): from camelot.view.controls.liteboxview import LiteBoxView litebox = LiteBoxView( parent = gui_context.workspace ) litebox.show_fullscreen_pixmap( self.pixmap.getQPixmap() )
def show_fullscreen(self, image): lite_box = LiteBoxView(self) lite_box.show_fullscreen_image(image)