Hi Aurélien,

you can also set the "xticklabel" with \pgflotsset in the preamble, 
which will probably solve your problem.

The changes introduced by \pgfplotsset remain in effect until a) the 
next \end{....} statement, the next curly end brace '}' or until you 
redefine them. Consequently,

\pgfplotsset{
   xticklabel={$\mathsf{\pgfmathprintnumber{\tick}}$}
}

will be a document-wide configuration for x tick labels. It might be 
useful to distinguish between logarithmic axes or normal ones. This can 
be realized by means of

\pgfplotsset{
   every loglog axis/.append style={
     xticklabel=...
   },
   every linear axis/.append style={
    xticklabel=something different
   },
}
(I hope the names are spelled correctly, consider the manual if the 
statements have no effect).

The simplest would be to use
\pgfplotsset{
   every axis/.style={font=...}
}
but unfortunately, this does not always affect the math mode in LaTeX 
(but you probably knew that) :-/

I hope this helps.

Best regards

Christian

Am 03.09.2010 16:13, schrieb aurelien coillet:
> Hi there,
>
> For my thesis I would like to type the figures with a sans-serif font
> (and the rest is serif, of course). For the moment, I use
> \pgfplotset{/tikz/font={\sffamily}} in the preamble for the legend and
> axis labels (which is nice and elegant),
> and \begin{axis}[xticklabel={$\mathsf{\pgfmathprintnumber{\tick}}$},
> ...] for the ticks, which is cumbersome, inefficient (since I have to do
> that for every plot) and inelegant.
> I was not able to find a simpler way to do that in the manual; maybe
> someone here has an idea...
>
> Thanks!
>
> Aurélien
>
>
>
> ------------------------------------------------------------------------------
> This SF.net Dev2Dev email is sponsored by:
>
> Show off your parallel programming skills.
> Enter the Intel(R) Threading Challenge 2010.
> http://p.sf.net/sfu/intel-thread-sfd
>
>
>
> _______________________________________________
> Pgfplots-features mailing list
> [email protected]
> https://lists.sourceforge.net/lists/listinfo/pgfplots-features


------------------------------------------------------------------------------
This SF.net Dev2Dev email is sponsored by:

Show off your parallel programming skills.
Enter the Intel(R) Threading Challenge 2010.
http://p.sf.net/sfu/intel-thread-sfd
_______________________________________________
Pgfplots-features mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/pgfplots-features

Reply via email to