This works in a web browser so may work as a template for calibre.
You need to extend the
ronu list as far as needed, and set
romp to the number of roman numeral pages at the start of the book.
Code:
<p id="pagenum" style="text-align:center;"></p>
<script>
var ronu = [ "-", "i", "ii", "iii", "iv", "v", "vi", "vii", "viii" ]
var valu = ""
var romp = 6
if (_PAGENUM_ > romp)
valu = _PAGENUM_ - romp
else
valu = ronu[_PAGENUM_]
document.getElementById("pagenum").innerHTML = valu
</script>
If you make
ronu as big as you think you'll ever need, (e.g. 20 roman numerals), then you just need to change
romp for each book.