Nicolas Goaziou <[email protected]> writes: > Eric Schulte <[email protected]> writes: > >> Sure. I have added a function to org-export-filter-parse-tree-functions >> which replaces a custom keyword with either a latex-fragment or an HTML >> link wrapped in a paragraph depending on the export backend. The latex >> fragment basically has the following content, >> >> "\\begin{figure} >> \\centering >> \\input{%s} >> \\caption[%s]{\\label{%s}%s} >> \\end{figure}\n\n" >> >> and I assign it a :name property to match the label in the above. I >> then have links elsewhere in the file which reference this label. > > I still do not get it. Could you show your (possibly simplified) filter > function? >
Attached
tikz-figure-keywords.el
Description: application/emacs-lisp
>
> Also, what code do you want ox-latex to generate?
>
So something like the following
#+name: technique-overview
#+Caption[Overview of Technique]: Text.
#+TIKZ_FIGURE: technique-overview
Lorem ipsum dolor sit amet Figure [[technique-overview]] posuere.
results in something like the following for latex export
\begin{figure}
\centering
\input{technique-overview}
\caption[Overview of Technique]{\label{technique-overview}Text.}
\end{figure}
Lorem ipsum dolor sit amet Figure \ref{technique-overview} posuere.
Thanks,
Eric
>
> Note that #+NAME is internal Org syntax. It cannot possibly be
> compatible with random raw LaTeX code. IOW, even if you can write raw
> LaTeX in an Org buffer, it doesn't mean that Org will understand the
> LaTeX code you wrote.
>
>
> Regards,
--
Eric Schulte
https://cs.unm.edu/~eschulte
PGP: 0x614CA05D (see https://u.fsf.org/yw)
