You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Notice the SoftBreak elements generated for the second and third figures. As far as I can tell, this depends on the order of the label control sequence inside the figure environment.
reacted with thumbs up emoji reacted with thumbs down emoji reacted with laugh emoji reacted with hooray emoji reacted with confused emoji reacted with heart emoji reacted with rocket emoji reacted with eyes emoji
-
General considerations
Current nested figures handling.
This is for pandoc 2.14.0.2
The current pandoc version can already handle nested figures in some way. Considering the input:
fig.tex
It produces:
This is, all figures get flattened into a sequence.
This means that:
subfigure
environment is already handled by pandoc.subfigure
environment doesn't mean requiring thesubcaption
LaTeX package.One issue with figures in general
Currently pandoc has issues with the parsing of figures in general. That is not necessarily nested. This is illustrated in the following example:
fig-simple.tex
All those figures render the same with
pdflatex
. So, one would expect all figures to produce the same AST but the actual output is:Notice the
SoftBreak
elements generated for the second and third figures. As far as I can tell, this depends on the order of the label control sequence inside thefigure
environment.New native figures & LaTeX
I've repurposed the
native_figure
extensions to work with LaTex.Some issues
I have similar issues as before though. For example,
fig-simple.tex
generates:Which in html translates to:
Notice the
<span>
in for the third figure.Nested figures
For the nested figure case (
fig.tex
), I get:For HTML output this becomes:
Closing
Any idea about what's happening with the reader is wellcome. As usual, the code can be found here
Beta Was this translation helpful? Give feedback.
All reactions