LaTeXML
LaTeXML copied to clipboard
Fix authblk line breaks when font has been customized
Author lines typeset using the authblk
package can have an unexpected behavior when the \Authfont
has been set to a custom font size and a line break \authorcr
is used to separate authors.
Example document:
\documentclass{article}
\usepackage{authblk}
\renewcommand\Authfont{\Large}
\title{Use of authblk}
\author[1]{Alice}
\author[1]{Bob}
\author[1]{\authorcr Charlie} % \authorcr = line break
\author[1]{Dominik}
\affil[1]{Example University}
\begin{document}
\maketitle
\end{document}
LaTeXML | LaTeXML with this pull request | |
---|---|---|
<br class="ltx_break"><span class="ltx_text" style="font-size:144%;">Charlie</span> |
<br class="ltx_break">Charlie |
The reason for the difference is that the authblk
binding does not actually apply the \Authfont
to the author name text in its current version, except after \authorcr
.
https://github.com/brucemiller/LaTeXML/blob/f75b0c6b06ff9191178a008c62a95f2b9c1dd087/lib/LaTeXML/Package/authblk.sty.ltxml#L27
This pull request removes this:
https://github.com/brucemiller/LaTeXML/blob/ca7e2146e73b9e566b797992487cc8102f0fe14a/lib/LaTeXML/Package/authblk.sty.ltxml#L27
Example to make it clear that normally \Authfont
is ignored: let's set
\renewcommand\Authfont{\bfseries}
Then LaTeXML outputs the following:
LaTeXML with this pull request gives the same output as in the above table, right-most cell.