Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Title centering creates blank page #32

Open
dragonattheend opened this issue Dec 2, 2021 · 0 comments
Open

Title centering creates blank page #32

dragonattheend opened this issue Dec 2, 2021 · 0 comments

Comments

@dragonattheend
Copy link

I want to have the title, author and affiliation centered in article rmarkdown, which relies on svm-latex-ms.tex

I changed this part of the template (\raggedright to \center and changes to author related parts)

\makeatletter
\def\@maketitle{%
  \newpage
%  \null
%  \vskip 2em%
%  \begin{center}%
  \let \footnote \thanks
    {\fontsize{18}{20}\selectfont\raggedright  \setlength{\parindent}{0pt} \@title \par}%
}
%\fi
\makeatother

I'm using this RMarkdown template https://github.com/svmiller/svm-r-markdown-templates/blob/master/article-example/svm-rmarkdown-article-example.Rmd

It has https://github.com/svmiller/svm-r-markdown-templates/blob/master/svm-latex-ms.tex as template

I want to have the title, author and affiliation centered.

I changed this part of the template (\raggedright to \center and changes to author related parts)

\makeatletter
\def@maketitle{%
\newpage
% \null
% \vskip 2em%
% \begin{center}%
\let \footnote \thanks
{\fontsize{18}{20}\selectfont\raggedright \setlength{\parindent}{0pt} @title \par}%
}
%\fi
\makeatother

to

\makeatletter
\def\@maketitle{%
  \newpage
%  \null
%  \vskip 2em%
%  \begin{center}%
  \let \footnote \thanks
    {\fontsize{18}{20}\selectfont\center  \setlength{\parindent}{0pt} \@title \par}%
}
%\fi
\makeatother

And this part

{% \usefont{T1}{pnc}{m}{n}
\setlength{\parindent}{0pt}
\thispagestyle{plain}
{\fontsize{18}{20}\selectfont\raggedright 
\maketitle  % title \par  

}

{
   \vskip 13.5pt\relax \normalsize\fontsize{11}{12} 
$if(anonymous)$\hfill $else$$for(author)$\textbf{\authorfont $author.name$} \hskip 15pt \emph{\small $author.affiliation$}  $sep$ \par $endfor$ $endif$

}

}

to

{% \usefont{T1}{pnc}{m}{n}
\setlength{\parindent}{0pt}
\thispagestyle{plain}
{\fontsize{18}{20}\selectfont\center
\maketitle  % title \par

}

{
   \vskip 13.5pt\relax \normalsize\fontsize{11}{12}
$if(anonymous)$\hfill $else$$for(author)$\center\textbf{\authorfont $author.name$} \emph{\center\small $author.affiliation$}  $sep$ \par $endfor$ $endif$

}

}

This somehow creates a blank first page in the output.

My goal is to have the title, author, affiliation and abstract vertically centered separately on my first page.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant