2

I am trying to fix an image in the top of a page, according with the margins definitions. It is the logo of a conference paper, so it has to be in the head of the first page. How can i do it? Thank you for your attention!

Nicolo

1
2

Respect to tcassanelli's answer, note that you can define more of one header style and change among them.

To make a new style:

\fancypagestyle{mystyle}{% 
  %definition here
 }

To use the above style only in the actual page:

\thispagestyle{mystyle}

But if you want only a logo in the first page, another option could be the wallpaper package. In this way the logo do not take space, so the position of any other object in the document remain unchanged. A minimal working example:

MWE

\documentclass[a4paper,latin]{article} 
\usepackage{wallpaper}
\usepackage{babel} 
\usepackage{lipsum} % dummy text
\title{Minimum exemplum laborandi}
\author{Franciscus Studiosum Somniantis} 

\begin{document}

\addtolength{\wpXoffset}{-7cm} 
\addtolength{\wpYoffset}{12cm} 
\ThisCenterWallPaper{.15}{logo}

\maketitle 

\section{Introductio} 
\lipsum[1]
\section{Materia et modos} 
\lipsum[2] 
\section{Consequitur} 
\lipsum[3]
\section{Disputatio} 
\lipsum[4] 
\end{document}
0

Have you tried Fancy package?

%%%%%%%%%%%%%%%%%%%%%%%%%%%
\usepackage{fancyhdr} % Custom headers and footers
\pagestyle{fancyplain} % Makes all pages in the document conform to the custom headers and footers
\fancyhead[L]{}%\leftmark
\fancyhead[R]{\includegraphics{image}}%You could place here the image. 
\fancyfoot[L]{} % Empty left footer
\fancyfoot[C]{} % Empty center footer
\fancyfoot[R]{\thepage} % Page numbering for right footer
%%%%%%%%%%%%%%%%%%%%%%%%%%%
4
  • Thank you for your help, but I need it just for the first page and without the black line under the image. – nicolo Mar 11 '14 at 12:46
  • Besides, the following text is overlying on the logo – nicolo Mar 11 '14 at 12:48
  • the back line is easily remove by \renewcommand{\headrulewidth}{0pt} – tcassanelli Mar 11 '14 at 12:48
  • or you could use \rhead{} for the next pages. – tcassanelli Mar 11 '14 at 12:51
0

With the following:

    \fancypagestyle{mystyle}{% 
    \thispagestyle{empty}
    \pagestyle{fancy} % Makes all pages in the document conform to the custom headers and                               footers
   \renewcommand{\headrulewidth}{0pt}
   \fancyhead[L]{}%\leftmark
   \fancyhead[R]{\includegraphics{logo}}%You could place here the image. 
   }

the head is fine, the problem is the bottom part of the text that doesn't respect the margins. I defined them in this way:

\usepackage{geometry}
\geometry{a4paper,top=2.5cm,bottom=2.5cm,left=2.5cm,right=2.5cm}
\setlength\parindent{1cm}

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.