Skip to content

\Romannum breaks with recent latex core #46

@tomh-overleaf

Description

@tomh-overleaf

Hi! It seems that a recent change to textcasing in LaTeX broke \Romannum from the romannum package.

MnWE:

\listfiles
\documentclass{article}
\usepackage{romannum}
\begin{document}
Hello! \Romannum{6}
\end{document}

Listfiles:

 *File List*
 article.cls    2021/10/04 v1.4n Standard LaTeX document class
  size10.clo    2021/10/04 v1.4n Standard LaTeX file (size option)
romannum.sty    2009/09/03 v1.0b roman numerals
stdclsdv.sty    2009/09/04 v1.1a Sectional divisions
l3backend-pdftex.def    2022-07-01 L3 backend support: PDF output (pdfTeX)
 ***********

Investigation

Unterminated \romannumeral in \romannum.

Solution

Add a space after \romannumeral #1 and \romannumeral -#1:

\newcommand{\romannum}[1]{%
  \ifnum#1<1
    \ifnum#1=0
      o%
    \else
      -\romannumeral -#1 %
    \fi
  \else
    \romannumeral #1 %
  \fi}

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions