I'm afraid that, unfortunately, it won't be fixed soon (if ever, as far as I can tell). What "tight_layout" does is to adjust the *subplot parameters* of the figure so that the "subplots" fit in. Artists created with figtext command is not affected by the subplot parameters, i.e. there is not much thing we can do for these artists within the current implementation. It would be better if some warning is printed in such case (there are lots of cases that tight_layout will fail), but this is not currently done.
Depending on your need, you may leave out some area for figtext when you call "tight_layout". This is only supported for gridspec though. import matplotlib.pyplot as plt import matplotlib.gridspec as gridspec fig = plt.figure() gs1 = gridspec.GridSpec(2, 2) ax_list = [fig.add_subplot(ss) for ss in gs1] fig.text (02, 0, "test", horizontalalignment='left', verticalalignment='bottom', size=5) fig.text (0.5, 1, "01", horizontalalignment='left', verticalalignment='top', size='x-small') gs1.tight_layout(fig, rect=[0, 0.03, 1, 0.97]) # adjust rect parameter to make some room for figtext. Regards, -JJ On Wed, Mar 28, 2012 at 9:17 PM, Neal Becker <ndbeck...@gmail.com> wrote: > I just tried 1.1.1rc to see if it fixed the tight_layout for figtext. > > I have a semilogy plot, and add some lines of text on the bottom (and top): > > plt.figtext (0, 0, res['carriers'].values, horizontalalignment='left', > verticalalignment='bottom', size=5) > plt.figtext (0.5, 1, self.pageno, horizontalalignment='left', > verticalalignment='top', size='x-small') > ##plt.tight_layout(pad=1.0) > plt.tight_layout() > > The text on the bottom is overprinting the x axis - the same as happened with > the previous release. > > > ------------------------------------------------------------------------------ > This SF email is sponsosred by: > Try Windows Azure free for 90 days Click Here > http://p.sf.net/sfu/sfd2d-msazure > _______________________________________________ > Matplotlib-devel mailing list > Matplotlib-devel@lists.sourceforge.net > https://lists.sourceforge.net/lists/listinfo/matplotlib-devel ------------------------------------------------------------------------------ This SF email is sponsosred by: Try Windows Azure free for 90 days Click Here http://p.sf.net/sfu/sfd2d-msazure _______________________________________________ Matplotlib-devel mailing list Matplotlib-devel@lists.sourceforge.net https://lists.sourceforge.net/lists/listinfo/matplotlib-devel