roman numerals for chapter numbers?

Is there a way to make the automatic chapter numbers Roman numerals instead of Arabic ones?

Hi,

I don't think that's possible after reading a related topic here

Roman numerals would not be able to cope with subsections, as you can't write something like 1.2.1 as roman numeral. Also, more theoretically, roman numerals only go up till about 4000, so you can't convert large numbers (though this would not be an issue in a book, as there are likely not that many chapters).

It seems the only solution is to build custom css, js or latex depending on the knitting, but that's too advanced for me :slight_smile: Maybe someone else knows how to do that.

PJ

It is a book, so actually we were planning on having web, ePub and PDF.

This topic was automatically closed 7 days after the last reply. New replies are no longer allowed.

I am not sure by default it can't be done, but by format we can suggest a solution.
For which output type are you looking this to ?

Let's not that this is maybe the easiest solution as you just need to find solution already existing for each output type.

I would say

I don't know of an easy solution right now. Maybe someone has already done it ?

2 Likes

So you are looking for this to use with bookdown, and to output to all format.

I don't think this is something offered by default within pandoc. I think you can achieve such multiformat transformation using pandoc lua filters.

Otherwise, you'll need to provide custom templates and formating for each kind of output.

I'll look into the lua filter option on my side as I am not sure if it is easy or not.

Thanks for the help. I’ll look into it more. This is a great start.

1 Like