I spent some time today trying to get latex babel source blocks to work for me and discovered that calling `org-babel-execute:latex` ignores the :headers header if the output file is a png without setting imagemagick to t. It's easy to see this in the source code: the conditions mentioned above leads to calling org-create-formula-image without passing in the headers. I think this is a bug, although maybe I missed it somewhere in the documentation? Here's a MWE if you want it
#+header: :file "test.png" #+header: :headers '("\\def\\hello{hello}") #+begin_src latex :results output file link \hello #+end_src doesn't work, but #+header: :file "test.png" #+header: :imagemagick t #+header: :headers '("\\def\\hello{hello}") #+begin_src latex :results output file link \hello #+end_src does. However, this got me thinking that I wish executing latex blocks behaved a bit more like latex fragment previews. Particularly, the ability to customize `image-converter`. So, I'm thinking about adding a customization option that allows a user to use the image-converter portion of an existing org-preview-latex-process-alist entry (I guess the most obvious choice would be org-preview-latex-default-process). Although I guess I could just add a new variable like what we have with org-latex-pdf-process. Maybe that's better since we'd only be using one part of the latex-process-alist. What are people's thoughts on this?