On 12/05/07, Jouni K. Seppänen <[EMAIL PROTECTED]> wrote: > J Oishi <[EMAIL PROTECTED]> writes: > > > I have an interesting problem using fonts in matplotlib on OS X 10.4. > > When I use a font other than the Bitstream Vera provided with MPL > > 0.90.0, I cannot create readable eps files. > > FWIW, I have the same problem: eps files produced on OS X are huge, > and somehow broken. My guess is that the fonts that come with OS X > have some advanced features, which should somehow be stripped out when > embedding into an eps file.
Yes, this is the problem. matplotlib needs straight truetype fonts (ttf) , not the more sophisticated opentype fonts and font suitcases that come with macosX. Most fonts in standard Apple places: /Users/agn/Library/Fonts/ /Library/Fonts/ /System/Library/Fonts/ are .dfont or .otf etc... these don't work. Except e.g. sans serif InaiMathi fantasy Chalkboard which are straight .ttf, so do work. If you have e.g. Gerben Wierda's latex installation gwtex, or probably also the mactex distribution, this comes wilth various ttf versions of the system fonts. E.g I have the old gwtex based on tetex which comes with gillsans [in light heavy etc..],hoefler ( a very nice serif font),helveticaneue,lucidagrande,optima,verdana,didot and futura. In my distribution these fonts are in /usr/local/teTeX/share/texmf.gwtex/fonts/truetype/gtamacfont if you want to use fonts like this, you either have to modify the search path in font_manager.py to include the directories *directly* containiong the .ttf files, or symlink the .ttf files into the matplotlib directory holding vera.ttf etc... /Library/Frameworks/Python.framework/Versions/2.4/lib/python2.4/site-packages/matplotlib/mpl-data/fonts/ttf I believe you can make your own .ttf files from any standard Mac .otf or .dfont using Fondu [ http://fondu.sourceforge.net/] -- again included in Wierda's teX installations. HTH. George Nurser. ------------------------------------------------------------------------- This SF.net email is sponsored by DB2 Express Download DB2 Express C - the FREE version of DB2 express and take control of your XML. No limits. Just data. Click to get it now. http://sourceforge.net/powerbar/db2/ _______________________________________________ Matplotlib-users mailing list Matplotlib-users@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/matplotlib-users