Revision: 7928
          http://matplotlib.svn.sourceforge.net/matplotlib/?rev=7928&view=rev
Author:   mdboom
Date:     2009-11-03 20:55:47 +0000 (Tue, 03 Nov 2009)

Log Message:
-----------
[2889193] Rasterized output offset in pdf and ps

Modified Paths:
--------------
    branches/v0_99_maint/lib/matplotlib/backends/backend_mixed.py

Modified: branches/v0_99_maint/lib/matplotlib/backends/backend_mixed.py
===================================================================
--- branches/v0_99_maint/lib/matplotlib/backends/backend_mixed.py       
2009-11-03 20:51:55 UTC (rev 7927)
+++ branches/v0_99_maint/lib/matplotlib/backends/backend_mixed.py       
2009-11-03 20:55:47 UTC (rev 7928)
@@ -14,7 +14,7 @@
                  raster_renderer_class=None,
                  bbox_inches_restore=None):
         """
-        figure: The figure instance. 
+        figure: The figure instance.
 
         width: The width of the canvas in logical units
 
@@ -49,7 +49,7 @@
         self.figure=figure
 
         self._bbox_inches_restore = bbox_inches_restore
-        
+
         self._set_current_renderer(vector_renderer)
 
     _methods = """
@@ -88,8 +88,8 @@
                                                mode="png")
 
             self._bbox_inches_restore = r
-            
-        
+
+
         if self._rasterizing == 0:
             self._raster_renderer = self._raster_renderer_class(
                 self._width*self.dpi, self._height*self.dpi, self.dpi)
@@ -117,9 +117,10 @@
                 image = frombuffer(buffer, w, h, True)
                 image.is_grayscale = False
                 image.flipud_out()
-                self._renderer.draw_image(int(float(l)/self.dpi*72.),
-                                          int((float(height) - b - 
h)/self.dpi*72.),
-                                          image, None)
+                self._renderer.draw_image(
+                    float(l)/self.dpi*72.,
+                    (float(height) - b - h)/self.dpi*72.,
+                    image, None)
             self._raster_renderer = None
             self._rasterizing = False
 


This was sent by the SourceForge.net collaborative development platform, the 
world's largest Open Source development site.

------------------------------------------------------------------------------
Come build with us! The BlackBerry(R) Developer Conference in SF, CA
is the only developer event you need to attend this year. Jumpstart your
developing skills, take BlackBerry mobile applications to market and stay 
ahead of the curve. Join us from November 9 - 12, 2009. Register now!
http://p.sf.net/sfu/devconference
_______________________________________________
Matplotlib-checkins mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/matplotlib-checkins

Reply via email to