Re: [Matplotlib-users] family=sans-serif not taking effect? why?

2007-01-08 Thread Glen W. Mabey
On Fri, Jan 05, 2007 at 10:30:50PM -0500, [EMAIL PROTECTED] wrote:
 does fontweight = ... work for you?  I couldn't get that one to work

I sure can't see any difference in the tick labels, at least (didn't try
it for manually-instantiated text).

But what I wonder is whether there is some issue here similar to how the
tick labels don't take the default font.size value ...

Glen


-
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.phpp=sourceforgeCID=DEVDEV
___
Matplotlib-users mailing list
Matplotlib-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/matplotlib-users


Re: [Matplotlib-users] family=sans-serif not taking effect? why?

2007-01-05 Thread Glen W. Mabey
On Fri, Jan 05, 2007 at 12:21:04PM -0500, [EMAIL PROTECTED] wrote:
 In my code I did family=sans-serif but it didn't seem to have
 any effect.  Any ideas?

I was struggling with this myself this week.  Do:

import matplotlib.font_manager
fm = matplotlib.font_manager.FontManager()

If fm.ttfdict doesn't list a bunch of TrueType fonts that you think
should be listed, delete ~/.matplotlib/ttffont.cache , which will cause
it to be rebuilt the next time you import matplotlib.

Then try:

import matplotlib.text
t = matplotlib.text.Text( 'alskdjfalksdj' )
t.get_fontname()
p = t.get_font_properties()
p.get_name()

If this last statement returns the first element of 
matplotlib.rcParams[ 'font.sans-serif' ]
then I would think that everything is working like it ought to.

If you get something like 'vera' at some point, then the absolute-last
fallback font is being used (fm.defaultFont).

Contrary to the comments in the default matplotlibrc, it seems that
font.size does not set the fontsize for axis labels and ticks; you have
to set [xy]tick.labelsize and axes.labelsize explicitly.  But I haven't
had a chance to look into that ... yet.

hope that helps.

Glen



-
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.phpp=sourceforgeCID=DEVDEV
___
Matplotlib-users mailing list
Matplotlib-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/matplotlib-users


Re: [Matplotlib-users] family=sans-serif not taking effect? why?

2007-01-05 Thread chris
On Fri, Jan 05, 2007 at 04:23:53PM -0600, Glen W. Mabey wrote:
 Contrary to the comments in the default matplotlibrc, it seems that
 font.size does not set the fontsize for axis labels and ticks; you have
 to set [xy]tick.labelsize and axes.labelsize explicitly.  But I haven't
 had a chance to look into that ... yet.

does fontweight = ... work for you?  I couldn't get that one to work

cs

-
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.phpp=sourceforgeCID=DEVDEV
___
Matplotlib-users mailing list
Matplotlib-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/matplotlib-users