1

Attempting to add a header and footer to the IEEEtran conference paper (the 2 column one). At present I'm able to get the footer that I want on all the pages, as my conference requires me to.

However I'm trying to get 3 lines on the first page header. This seems to "squish" the footers on all the pages. I believe that if I change the margin geometries, this will apply to all the pages, but I only want a large header for the first page and the rest to have standard (not large) margins.

\documentclass[conference]{IEEEtran}

\usepackage{amsmath} % for equation labelling
\usepackage[font=footnotesize, labelfont=bf]{caption} % make captions smaller text and make them BOLD 
\usepackage[usenames,dvipsnames]{color} 
\usepackage{enumerate} % to create fancy enumerated lists
\usepackage{fancyhdr} % for headers on each page (and customization of them)
\usepackage{float} % for allowing "floating" of figures
% \usepackage[top=1 in, bottom=1 in, left=1 in, right=1 in]{geometry} % edit individual margins
\usepackage{graphicx} % for figures in general
\usepackage{hyperref} % for "clickable" links to figures/refs/(etc.)
\usepackage{lastpage} % for page __ of __
\usepackage{multicol} % for multiple column environments (mostly used with equations)
\usepackage{mdwlist}  % tighter packed bulleted lists
\usepackage[sort&compress,numbers]{natbib} % for getting rid of extra space in references section 
\usepackage{setspace} % for line spacing between lines and also for bibliography
\usepackage{siunitx} % for scientific units (add [scientific-notation=true] for scientific notation always)
\usepackage{tabularx} % to try and get variable-spacing columns




\newcommand*\titleheader[1]{\gdef\@titleheader{#1}}


% ####################### Header and Footer Stuff
\renewcommand{\headrulewidth}{0pt}
\pagestyle{fancy}
{
\cfoot{\thepage}
\rfoot{Copyright \textcopyright \vspace{1em} 2018}
}
%
\fancypagestyle{firstpage} %{style}
{
    \fancyhead[R]{\textbf{line 1 \\
        line2 \\
        line3}}
}




\graphicspath{{./img/}}


\hypersetup
{
    colorlinks = true,
    citecolor = black,
    linkcolor = blue, % link colour for figure, equation, + table refs
    urlcolor = blue, 
}




\begin{document}


\title{\Large\textbf{title title title}}


\author
{
    \IEEEauthorblockN{author}
    \IEEEauthorblockA{\textit{some place} \\
    %\textit{name of organization (of Aff.)}\\
    stuff \\
    stuff2}

    \and

    \IEEEauthorblockN{author}
    \IEEEauthorblockA{\textit{some place} \\
    %\textit{name of organization (of Aff.)}\\
    stuff \\
    stuff2}
}
\maketitle

\thispagestyle{firstpage}

\begin{abstract}
    \normalfont
    To be written
\end{abstract}

\begin{IEEEkeywords}
    %\normalfont
    \textit{keyword1; keyword2; keyword3}
\end{IEEEkeywords}


\section{Introduction}

main body here



\end{document}

Any ideas?

2
  • please provide small but complete document, that we can test your/ours ideas how to accomplish this ... help us to help you :-). welcome to tex.se!
    – Zarko
    Feb 13, 2018 at 12:02
  • Added more of document. Hope this helps...
    – bsquared
    Feb 13, 2018 at 13:30

1 Answer 1

0

edit: to code are added comments for clarifying meaning of code

a solution can be

...
\begin{document}
\pagestyle{fancy}
\maketitle
\thispagestyle{firstpage}
...

complete minimal working example without special bothering with the article space issues and without complete header/footer formatting:

\documentclass[conference]{IEEEtran}
\addtolength\headheight{ 2\baselineskip}% make space for your multi line header
\addtolength\headheight{-2\baselineskip}% you need to reduce text height 
                                                                 % for the same amount as you increase 
                                                                 % header height

\usepackage{fancyhdr} % for headers on each page (and customization of them)
\renewcommand{\headrulewidth}{1pt}% change to your desired width (0pt?)
\pagestyle{fancy}
{
\renewcommand{\headrulewidth}{2pt}
\cfoot{% here you can define font size in cfoot
  \thepage}
\rfoot{% here you can define font size in rfoot
    Copyright \textcopyright\ 2018}% corrected your code
\rhead{\bfseries\footnotesize % <--- here is defined font size in rhead
    line 1 \\
    line 2 \\
    line 3}
}
\fancypagestyle{firstpage}
{
\renewcommand{\headrulewidth}{2pt}
\cfoot{\thepage}
\rfoot{Copyright \textcopyright\ 2018}% corrected your code
\rhead{\bfseries\color{red}\large
    line 1 \\
    line 2 \\
    line 3}
}

\title{\Large\textbf{title title title}}
\author{
    \IEEEauthorblockN{author}
    \IEEEauthorblockA{\textit{some place} \\
    %\textit{name of organization (of Aff.)}\\
    stuff \\
    stuff2}
    \and
    \IEEEauthorblockN{author}
    \IEEEauthorblockA{\textit{some place} \\
    %\textit{name of organization (of Aff.)}\\
    stuff \\
    stuff2}
        }

\usepackage{xcolor}
\usepackage{lipsum}

\begin{document}
\pagestyle{fancy}
\maketitle
\thispagestyle{firstpage}

\begin{abstract}
    \normalfont
    To be written
\end{abstract}

%\begin{IEEEkeywords}
    %\normalfont
%    \textit{keyword1; keyword2; keyword3}
%\end{IEEEkeywords}


\section{Introduction}
\lipsum
\lipsum
\lipsum
\end{document}

the first page:

enter image description here

and others pages:

enter image description here

addendum: your observation in comment is not accurate. see, what you will obtained using the following definition of fancy and firstpage page styles definition:

\pagestyle{fancy}
{
\renewcommand{\headrulewidth}{2pt}
\cfoot{\thepage}
\rfoot{Copyright \textcopyright \vspace{1em} 2018}
\rhead{\bfseries\tiny
    line 1 \\
    line 2 \\
    line 3}
}
\fancypagestyle{firstpage}
{
\renewcommand{\headrulewidth}{2pt}
\cfoot{\thepage}
\rfoot{Copyright \textcopyright \vspace{1em} 2018}
\rhead{\bfseries\color{red}\Huge
    line 1 \\
    line 2 \\
    line 3}
}

hopefully now difference (with this extreme difference of font sizes) is clearly evident :-)

note: desire font size is left to you. my intention was only to show a way (method) how to solve your problem. all details of header design i left to you. so you should change color, rule, font size and other content of headers as you like to have.

10
  • This header looks to be the same size on both the first page and all other pages. Is this the case?
    – bsquared
    Feb 13, 2018 at 15:55
  • no, it is not the case. and they are different size (large and footnotesize), even more, larger is emphasized in red color :-) (both images have the same size)
    – Zarko
    Feb 13, 2018 at 16:05
  • Thank you for your continued help :). Unfortunately this still has the issue of "squishing" the footer. See image: imagebin.ca/v/3ra9Tk8YLT9k
    – bsquared
    Feb 13, 2018 at 16:22
  • @bsquared, but your question is about header only. the footer i left as you define it. if you like to change font size in footers too, than do this on the same way as i done for headers.
    – Zarko
    Feb 13, 2018 at 16:28
  • Maybe I'm not understanding how to edit the header without touching the footer height. It seems that the footer height keeps getting affected as the header height is changed. Maybe a textbox could be used instead (less desirable but I'll use it if I have to)
    – bsquared
    Feb 13, 2018 at 16:28

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .