Tabstops render as squares

Hello,

I was trying to render a pdf document with some data
aligned by tabstops.
But Matplotlib renders the tabs as squares,
at first I thought it is related to the pdf, but it
also happens with titles or labels.

I know it does not make much sense there, but
this is as far as I could break it down.

···

-----------
import matplotlib
from pylab import *

#matplotlib.rcParams['pdf.fonttype'] = 42 #42 #TTF 42, 3 ?

matplotlib.rcParams['ps.useafm'] = True
matplotlib.rcParams['pdf.use14corefonts'] = True

#this seems to work, but only on my simple example
#it throws a lot of latex errors with my original code.
#matplotlib.rcParams['text.usetex'] = True

figure(figsize=(3,3))
title('Page' + '\t' + 'One')
show()
------------

And ideas how to solve this?

Joe

Joe <solarjoe at posteo.org> writes:

I was trying to render a pdf document with some data
aligned by tabstops.

I don't think there is any support for that kind of text layout.
The closest feature is probably pyplot.table:

https://matplotlib.org/api/_as_gen/matplotlib.pyplot.table.html
http://matplotlib.org/examples/pylab_examples/table_demo.html

Another possibility is to use a monospaced font and align with spaces
(possibly using str.expandtabs to generate the spaces):

https://stackoverflow.com/a/30111217/26575

···

--
Jouni K. Sepp?nen
http://www.iki.fi/jks