Supposing I have a document structure like:
* Heading 1
** Heading a
** Heading b
** Heading c
*** Heading i
*** Heading ii
When I do, say, M-xorg-export-as-html-and-open
, I'd get HTML that shows things as:
1 Heading 1
1.1 Heading a
1.2 Heading b
1.3 Heading c
1.3.1 Heading i
1.3.2 Heading ii
I'd like this to instead be:
1 Heading 1
1.a Heading a
1.b Heading b
1.c Heading c
1.c.i Heading i
1.c.ii Heading ii
Or even something fancier like:
§ 1 Heading 1
§ 1(A) Heading a
§ 1(B) Heading b
§ 1(C) Heading c
§ 1(C)(i) Heading i
§ 1(C)(ii) Heading ii
Is there some way to do this? I found org-export-number-to-roman
in the source, but it's not clear to me whether or where it gets called, and I don't see an org-export-number-to-letter
or similar.
Is there some configuration value that I'm missing, or perhaps a hook that I could create that might be called like (org-get-outline-numbering-string 1 3 2)
that I could set up to return an arbitrary string of my design such as 1.c.ii
or 1(C)(ii)
, which would then get used, creating HTML such as the following?
<h4 id="sec-1-3-2"><span class="section-number-4">1.c.ii</span> Heading ii</h4>
I'm open to writing some elisp, but I'm not sure where to start.
<span>
tags and transmogrify them. :)