def blit(self, bbox=None): if DEBUG: print 'FigureCanvasGTKAgg.blit' if DEBUG: print 'FigureCanvasGTKAgg.blit', self._pixmap agg_to_gtk_drawable(self._pixmap, self.renderer._renderer, bbox) x, y, w, h = self.allocation self.window.draw_drawable(self.style.fg_gc[self.state], self._pixmap, 0, 0, 0, 0, w, h) if DEBUG: print 'FigureCanvasGTKAgg.done'
def blit(self, bbox=None): if DEBUG: print 'FigureCanvasGTKAgg.blit' if DEBUG: print 'FigureCanvasGTKAgg.blit', self._pixmap agg_to_gtk_drawable(self._pixmap, self.renderer._renderer, bbox) x, y, w, h = self.allocation self.window.draw_drawable (self.style.fg_gc[self.state], self._pixmap, 0, 0, 0, 0, w, h) if DEBUG: print 'FigureCanvasGTKAgg.done'
def _render_figure(self, width, height): """Render the figure to a gdk.Pixmap, used by expose_event(). """ if DEBUG: print 'FigureCanvasGTKAgg._render_figure' create_pixmap = False if width > self._pixmap_width: # increase the pixmap in 10%+ (rather than 1 pixel) steps self._pixmap_width = max(int(self._pixmap_width * 1.1), width) create_pixmap = True if height > self._pixmap_height: self._pixmap_height = max(int(self._pixmap_height * 1.1), height) create_pixmap = True if create_pixmap: if DEBUG: print 'FigureCanvasGTK._render_figure new pixmap' self._pixmap = gtk.gdk.Pixmap(self.window, self._pixmap_width, self._pixmap_height) FigureCanvasAgg.draw(self) agg_to_gtk_drawable(self._pixmap, self.renderer._renderer)
def blit(self): agg_to_gtk_drawable(self._pixmap, self.renderer._renderer) self.window.set_back_pixmap(self._pixmap, False) self.window.clear() # draw pixmap as the gdk.Window's bg self._draw_pixmap = False
def blit(self): if self.window is None: return agg_to_gtk_drawable(self.window, self.renderer._renderer)
def blit(self, bbox=None): agg_to_gtk_drawable(self._pixmap, self.renderer._renderer, bbox) x, y, w, h = self.allocation self.window.draw_drawable (self.style.fg_gc[self.state], self._pixmap, x, y, x, y, w, h)
def _render_figure(self, pixmap, width, height): FigureCanvasAgg.draw(self) agg_to_gtk_drawable(pixmap, self.renderer._renderer, None)
def blit(self, bbox=None): agg_to_gtk_drawable(self._pixmap, self.renderer._renderer, bbox) x, y, w, h = self.allocation self.window.draw_drawable(self.style.fg_gc[self.state], self._pixmap, x, y, x, y, w, h)