|
From: Darren D. <dd...@co...> - 2007-05-17 14:24:15
|
On Thursday 17 May 2007 10:08:06 am Alexander Schmolck wrote:
> "George Nurser" <gn...@go...> writes:
> > I didn't realize that!
> > Apologies for being ignorant here.
>
> No worries, here's a concrete example for selecting Helvetica (and
> commented out, Palatino) as default fonts:
>
> from matplotlib.pylab import *
> from numpy import *
> #rc('font',**dict(family='serif',serif='Palatino'))
> rc('font',**{'family':'sans-serif','sans-serif':'Helvetica'})
> rc('text', usetex=True)
>
> Note that I've had problems with font-changes being ignored by latex in
> some version of matplotlib, but not the latest 0.9 -- if in doubt
> ``rm -r ~/.matplotlib/*cache`` and see whether that fixes things.
You should also make your rc changes before importing pylab. That might be
considered a bug, and would take some work to fix.
> I've added these two things to
>
> <http://www.scipy.org/Cookbook/Matplotlib/UsingTex>
>
> Hope that's OK, otherwise please revert.
Would you mind changing it to use the rcParams dict instead of the rc
function? It is clearer that way.
Darren
|