From: Peter W. <pw...@go...> - 2012-08-08 10:59:07
|
Peter Würtz wrote: > > > David Trémouilles wrote: >> >> Is there any reason that the generated figure could not be used with >> pdflatex ? >> > > The PGF pictures should work with pdflatex, xelatex and lualatex alike. > Xelatex (or lualatex) must be installed though because I use it for > obtaining the font metrics when the figure is created. In principle I > could use pdflatex for this as well, I just saw no reason to use it > anymore when I learned about the newer implementations. > Ok, the latest commit now allows you to rely on pdflatex only. Xelatex is still the default, but you can change that using the rc parameters: matplotlib.rcParams.update({ "font.family": "serif", "pgf.texsystem": "pdflatex", "pgf.preamble": [r"\usepackage{siunitx}", r"\usepackage{somefontpackage}"], }) System fonts specified in the rc parameters will be ignored since pdflatex cannot use them. Font metrics will be obtained from a pdflatex process. If you save the figure as pdf, pdflatex will be used to compile the figure. Hope this helps. -- View this message in context: http://old.nabble.com/Asking-for-code-review%3A-Xelatex---PGF-backend-tp34263853p34271056.html Sent from the matplotlib - devel mailing list archive at Nabble.com. |