|Version 27 (modified by rjollos, 2 years ago) (diff)|
Add footnotes to wiki
Note: There is an open ticket for integrating this feature to the Trac core, t:#9037.
[[FootNote(This is a footnote)]]
Footnotes are numbered by the order in which they appear.
To create a reference to an existing footnote, pass the footnote number as the only argument to the macro:
In addition, identical footnotes are coalesced into one entry. The following will generate one footnote entry with two references:
Some text[[FootNote(A footnote)]] and some more text [[FootNote(A footnote)]]. [[FootNote]]
And finally, to display a list of foot-notes call the macro with no arguments:
Once a set of footnotes has been displayed, a complete new set of footnotes can be created. This allows multiple sets of footnotes per page.
If you have any issues, create a new ticket.
Download the zipped source from here.
Here are the footnotes assembled from this page.
Here is some wiki markup that will exercise all the functionality of the macro.
Testing out the !FootNoteMacro[[FootNote(Here is the first footnote)]]. This will be a good test to exercise all of its functionality[[FootNote(Here is the second footnote)]]. And now I'll add an identical footnote and refer to the first footnote again[[FootNote(Here is the second footnote)]][[FootNote(1)]]. [[FootNote]] Now that I've called the !FootNoteMacro to print all the footnotes [[FootNote(I did that in the paragraph above)]], I should be able to generate more footnotes[[FootNote(It would be really cool if this feature was integrated into the Trac core)]] and print just the one that have been generated since the start of the second paragraph. Just for good measure I'll try referring to some footnotes in the first paragraph again[[FootNote(1)]][[FootNote(Here is the second footnote)]]. [[FootNote]]
Screen capture of the output that is produced:
-  by rjollos on 2015-04-20 15:58:21
1.0.4: tag_svn_revision is not supported in setuptools ≥ 10.
-  by rjollos on 2014-08-14 20:47:15
1.04: PEP-0008 changes and moved COPYING file to proper location.
-  by rjollos on 2014-02-11 04:50:30
1.0.4: Attach footnotes to the context to avoid scoping issues when formatting the page. Fixes #9211.