Jörgen Stenarson <[EMAIL PROTECTED]> writes:

> Saving a semilogy plot using the [pdf] backend the exponents come
> out wrong.

This seems to have something to do with the caching in
Text._get_layout_super(). The first script below works right, the
second has the exponents all wrong.

------------------------------------------------------------------------
#!/usr/bin/env python

import matplotlib
matplotlib.use('pdf')
from matplotlib import pylab

pylab.plot([0.001, 1, 10, 100, 1000])
pylab.gca().set_yscale('log')
pylab.savefig('foo1.pdf')
------------------------------------------------------------------------
#!/usr/bin/env python

import matplotlib
matplotlib.use('agg')
from matplotlib import pylab

pylab.plot([0.001, 1, 10, 100, 1000])
pylab.gca().set_yscale('log')
pylab.savefig('foo2.pdf')
------------------------------------------------------------------------

For some reason this doesn't happen with the eps backend, even though
it has flipy() == False, like pdf and unlike agg. Is there something
the pdf backend should do to reset the state of other objects when
switching to pdf from another backend?

> Looking at the source for the pdf-backend I also saw that it contains
> a mix of space and tabs for indentation.

Fixed in svn.

-- 
Jouni K. Seppänen
http://www.iki.fi/jks


-------------------------------------------------------------------------
Using Tomcat but need to do more? Need to support web services, security?
Get stuff done quickly with pre-integrated technology to make your job easier.
Download IBM WebSphere Application Server v.1.0.1 based on Apache Geronimo
http://sel.as-us.falkag.net/sel?cmd=lnk&kid=120709&bid=263057&dat=121642
_______________________________________________
Matplotlib-devel mailing list
Matplotlib-devel@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/matplotlib-devel

Reply via email to