[Tex/LaTex] IguanaTeX in Powerpoint: problem computing bounding box

ghostscriptiguanatexluatex

This question is essentially an exact duplicate of this one, which alas went unanswered. I am using IguanaTeX to format LaTeX in PowerPoint (not something I’ve ever done before), and obtain the following error:

Error while using GhostScript to compute the bounding box. Is your path correct?

After a bit of Googling, I find that this error appears in the source code on line 337. There, the error comes up if GhostScript couldn’t execute or if a .bbx file doesn’t exist in the temporary path. My temporary path is C:\Temp\, so I went to have a look and I found a .bbx file with contents

'C:\Program' is not recognized as an internal or external command,
operable program or batch file.

Does anyone know how to fix this problem?

P.S. — The information asked for in the comments of the aforementioned post is, in my case:

  • LuaTeX: This is LuaTeX, Version 1.10.0 (MiKTeX 2.9.7140 64-bit),
  • DVIpng: This is dvipng 1.16 [MiKTeX 2.9.7140 64-bit],
  • GhostScript path: D:\MyName\Programs\MiKTeX 2.9\miktex\bin\x64\, which includes the .exe files gsbj, gsdj, gsdj500, gsf2pk, gslj, gslp.

Edit: The command in the source code that is to be executed is

cmd /C "C:\Program Files (x86)\gs\gs9.15\bin\gswin32c.exe" -q -dBATCH -dNOPAUSE -sDEVICE=bbox IguanaTex_tmp.pdf 2 > IguanaTex_tmp.bbx

However, "C:\Program Files (x86)\gs\gs9.15\bin\gswin32c.exe" is not a valid path — the closest equivalent I can find is "C:\Program Files\gs\gs9.20\bin\gswin32c.exe".

Best Answer

It turns out IguanaTeX has a tab called “Main settings” in its PowerPoint interface, and it sufficed to specify the correct path there.

Related Question