Skip to content

Commit

Permalink
Integrated fix for arXiv's requirements into class file
Browse files Browse the repository at this point in the history
  • Loading branch information
sieversMartin committed Nov 25, 2023
1 parent 35be547 commit fb8afda
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 3 deletions.
2 changes: 1 addition & 1 deletion lni.cls
Original file line number Diff line number Diff line change
Expand Up @@ -16,6 +16,7 @@
\ProvidesClass{lni}
[2023/11/06 v1.8BETA Official class for submissions to the ``Lecture Notes
in Informatics'']
\RequirePackage{iftex}\ifluatex\else\pdfoutput=1\fi%
\def\@clearglobaloption#1{%
\def\@tempa{#1}%
\def\@tempb{\@gobble}%
Expand Down Expand Up @@ -84,7 +85,6 @@
\ExecuteOptions{utf8,norunningheads}
\DeclareOption*{\PassOptionsToClass{\CurrentOption}{article}}
\ProcessOptions\relax
\RequirePackage{iftex}
\PassOptionsToPackage{fleqn}{amsmath}
\LoadClass[10pt,twoside,a4paper]{article}
\ifPDFTeX
Expand Down
6 changes: 4 additions & 2 deletions lni.dtx
Original file line number Diff line number Diff line change
Expand Up @@ -724,6 +724,10 @@ This work consists of the file lni.dtx
% \begin{macrocode}
%<*class>
% \end{macrocode}
% We have to make sure, that pdf is always written (arXiv's requirements)
% \begin{macrocode}
\RequirePackage{iftex}\ifluatex\else\pdfoutput=1\fi%
% \end{macrocode}
% \begin{macrocode}
\def\@clearglobaloption#1{%
\def\@tempa{#1}%
Expand Down Expand Up @@ -794,8 +798,6 @@ This work consists of the file lni.dtx
\ExecuteOptions{utf8,norunningheads}
\DeclareOption*{\PassOptionsToClass{\CurrentOption}{article}}
\ProcessOptions\relax
%
\RequirePackage{iftex}
% \end{macrocode}
% \changes{v1.8}{2023/11/06}{Fix option handling for \opt{fleqn}}
% \begin{macrocode}
Expand Down

3 comments on commit fb8afda

@koppor
Copy link
Member

@koppor koppor commented on fb8afda Nov 26, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It is strange that this works. According to https://info.arxiv.org/help/submit_tex.html, \pdfoutput=1 needs to be in the first five (5) lines in the .tex file:

arXiv fully supports and automatically recognizes PDFLaTeX. You can ensure pdflatex processing by setting the flag \pdfoutput=1 within the first 5 lines of the preamble of the main .tex file. You should not need any other special flag.

Refs #81

@sieversMartin
Copy link
Member Author

@sieversMartin sieversMartin commented on fb8afda Nov 26, 2023

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Well, I called latex lni-paper-example.tex once with the lines in the class file, once without. pdfTeX switched to pdf output in the first case while it kept DVI mode in the second.

@sieversMartin
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I guess arXiv's solution is meant for any kind of classes used. So a normal user has of course to add the lines to the tex file.

Please sign in to comment.