[சனி நவம்பர் 08, 2025] Visuwesh wrote:

> To make C-c C-x C-l format the LaTeX result, I need to force the
> :results to be raw.  This introduces a world of pain since I now have to
> manually kill the old output before I can re-eval the source block.  As
> an example, try C-c C-x C-l when the point is on
>
>     : $$x + 1$$
>
> Nothing happens here.  With :results raw, there is no colon in the front
> so I can preview the output.
>
> Note that I'm using the LaTeX preview rewrite branch, things might be
> different in the master branch.

Never mind about this, I found a solution.  Abiding by :results latex
has the same problem since C-c C-x C-l does not preview #+BEGIN_EXPORT
latex #+END_EXPORT blocks.  But looking at org-babel-result-end, I see
that latex-environment element types are recognised, so I am instead
wrapping the LaTeX in the equation* environment (or should this be
displaymath?). With this, I still need to force the results to be raw
though.

Similarly, I could either wrap other language output in a src block, or
just let Org insert a colon before the results.

Reply via email to