Skip to content
This repository has been archived by the owner on Jan 3, 2018. It is now read-only.

Figure numbering for figure captions #138

Closed
zmughal opened this issue Jan 22, 2015 · 3 comments
Closed

Figure numbering for figure captions #138

zmughal opened this issue Jan 22, 2015 · 3 comments

Comments

@zmughal
Copy link

zmughal commented Jan 22, 2015

Since Pandoc can generate figure captions for images, it would be nice to be able to use figure numbering to refer to figures from the text (Figure 1, Figure 2, etc.). Currently, the figure captions can be escaped by using the <backslash><white-space> syntax.

This is currently not possible directly in Pandoc, but there are some solutions discussed by @r-gaia-cs that involve CSS or Pandoc filters.

(issue also filed at swcarpentry/python-novice-inflammation#20)

@rgaiacs
Copy link
Contributor

rgaiacs commented Jan 22, 2015

Since Pandoc can generate figure captions for images, it would be nice to be able to use figure numbering to refer to figures from the text (Figure 1, Figure 2, etc.).

There is two problems here: (1) automatic numbering of figures and (2) link to figures from the text.

Automatic Numbering of Figures

This one is "easy" and we have a few options:

Link to Figures From the Text

Use CSS is impossible (at least for now) and write our own Pandoc filters is a very bad move. We will need to be involved with this discussion.

@aaren
Copy link
Contributor

aaren commented Feb 11, 2015

@r-gaia-cs the active pandoc issue for this is jgm/pandoc#813 and it has seen some recent activity.

As for filters, I wrote one (in python) that does automatic markdown figure numbering / linking:

https://github.com/aaren/pandoc-reference-filter

@gvwilson
Copy link
Contributor

No longer relying on Pandoc.

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

4 participants