I am using texlive on Windows Subsystem for Linux. I'm testing the quality of figures I can create using the python package matplotlib. One thing I'd like to be able to do is make the text in the figures match that of my documents/reports.

I am using TeX Gyre Pagella and TeX Gyre Pagella Math in my main document. I think, in order to tell matplotlib where to look for the font, I need to know where the files that define the font are.

I think the TeX fonts are packaged with my distribution (I don't ever remember installing them but they seem to just work when I compile my documents using LuaLatex), but I've not been able to dig them up.

Does anyone know where they are located?

  • Does kpsewhich t1qpl.fd or kpsewhich texgyrepagella-regular.otf work for you? If not,do a file search in Explorer.
    – Davislor
    Commented Jan 23, 2021 at 2:23
  • Also, in case anyone is interested, I found how to specify it for matplotlib from the solution here. Make sure to use the actual font name and not the file name when specifying the font.family (e.g. for I would do TeX Gyre Pagella and not texgyrepagella-regular)
    – Nukesub
    Commented Jan 23, 2021 at 3:17

1 Answer 1


The command to find files in your TeX distribution is kpsewhich. In this case you would want to run either kpsewhich t1qpl.fd or kpsewhich texgyrepagella-regular.otf.

If kpsewhich doesn’t work, you can try a file search in Explorer.

An alternative to find the full path of a font file that might be in either the TeX distribution or a system directory is luaotfload-tool or fc-list | grep. A way to find the filename of a font from its display name is fc-match or luaotfload-tool --find.

  • Thank you! kpsewhich texgyrepagella-regular.otf worked!
    – Nukesub
    Commented Jan 23, 2021 at 2:54

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .