1

I am preparing a manuscript in LaTex using TextMaker (5.04) or Overleaf. The pdf output created by the two compilers was the same until a few days ago when I upload Latex 2021 to use the last version of siunitx. Now the pdf created by Textmaker is 43 pages, while overleaf (Tex Live 2020) is 39 pages. The same is true when I compile the eLife template provide by overleaf (Tex Live 2019); from 12 pages, it is now 15 pages with TexMaker (Tex Live 2021). link to Life Template from overleaf So I cannot compile with overleaf because I cannot handle the last version of siunitx and the output from Textmaker is totally out in terms of page.

I tried the \normalsize after \begin{document}, but this did not work.

the first page is the pdf output from the eLife template from overleaf (compile with Tex Live 2019) and the second from Tex Maker (compile with Tex Live 2021) The first page is shortened from 41 lines to 38 lines

overleaf- Tex Live 2019 Tex Maker- Tex Live 2021

4
  • 3
    well the output is not generally larger. It must be something specific in your document. You will have to show a small example. May 31 at 20:45
  • 2
    In case you are using NeurIPS, see tex.stackexchange.com/q/598567/2388 May 31 at 20:49
  • 1
    It appears that elife.cls is based on extarticle.cls, but in texlive 2021, extarticle loads size10.clo rather than size9.clo for the 9pt option. That looks like a bug to me. Anyway the new version uses a 10pt font, and the Overleaf version 9pt, which explains the size difference. Jun 1 at 13:33
  • As Pieter explains in his answer, it was a bug in babel, which as popped up after some changes in the LaTeX kernel. It should be fixed by now. Jun 4 at 16:04
5

EDIT: See solution 2 for the real cause, and solution.

The passing of options from one class to another one (that is used to implement the first class) seems to be slightly changed in the 2021 distribution.

The document class elife.cls uses the document class extarticle for its implementation, but it uses a method of passing its options, that isn't compatible with this new distribution. Therefore the 9pt option is not properly passed to extarticle, and then it uses the default 10pt.

SOLUTION 1:

Making this change to elife.cls solves this problem.

Replace these lines

\DeclareOption*{\PassOptionsToClass{\CurrentOption}{extarticle}}
\ExecuteOptions{}
\ProcessOptions\relax
\LoadClass{extarticle}

with

\ProcessOptions
\LoadClassWithOptions{extarticle}

NOTE: This will also pass other options, like lineno to extarticle, which will cause extarticle to complain about an unused global option. This in itself is harmless, but I think it indicates that something is wrong with the new code for \PassOptionsToClass. Anyway, consider the above a temporary solution.

SOLUTION 2

This is the better solution. I found that the babel package now ruins option processing. Therefore all option processing should be done before loading babel, and it is probably safest to do this before loading any package.

Move the piece of code in life.cls that starts with

\newif\if@reqslineno

and ends with

\LoadClass{extarticle}

immediately after

\ProvidesClass{elife}[2021/03/18, v1.9]

i.e. before any packages are loaded.

2
  • Dear Pieter, Thank you so much for your time and expertise. Your suggestion works perfectly and I got the correct size PDF for the manuscript.
    – stef
    Jun 1 at 15:12
  • Yes, solution two also works well with my manuscript. You save me yesterday, as I was in a rush to submit this paper on time. Thank you so much, and I'm sure your second solutuiobn will be very helpful for others.
    – stef
    Jun 2 at 17:13

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.