I am unable to get sans-serif tick labels with matplotlib 0.87.5 in tex
text mode. I tried with some hints from the list archive but had no success.
So I had a look at the tex-files which are created to render the tick labels,
which look like this:

\documentclass{article}
\usepackage{type1cm}
\renewcommand{\rmdefault}{pnc}
\usepackage{helvet}
\usepackage{courier}
\usepackage{textcomp}
\usepackage[papersize={72in,72in}, body={70in,70in}, 
            margin={1in,1in}]{geometry}
\pagestyle{empty}
\begin{document}
\fontsize{16.000000}{20.000000}{\sffamily $80$}
\end{document}

According to the psnfss doc, the package helvet does not affect the font in
math mode. So I don't see why a tick label '$80$' should be rendered in
sans-serif. I experimented with texmanager.py and added a
\usepackage{cmbright}, which introduces sans-serif fonts in math mode,
and was able to display sans-serif tick labels on screen but the ps-backend
failed with a segfault(!).

I simply added an element to the font_info dict in texmanager.py:

   'cmbright' : ('cmbr',  r'\usepackage{cmbright}'),

and added 'CMBright' to the list of sans-serif fonts in my .matplotlibrc

It would be nice if some tex-expert could have a look at this or tell me what
I could do to get sans-serif tick labels.

Christian



-------------------------------------------------------------------------
Take Surveys. Earn Cash. Influence the Future of IT
Join SourceForge.net's Techsay panel and you'll get the chance to share your
opinions on IT & business topics through brief surveys - and earn cash
http://www.techsay.com/default.php?page=join.php&p=sourceforge&CID=DEVDEV
_______________________________________________
Matplotlib-users mailing list
Matplotlib-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/matplotlib-users

Reply via email to