3

I would like to have a different background (wallpaper) on the title page, all even and all odd pages in a latex article document.

This is what I have so far:

% Set document background
\ifthenelse{\boolean{branding}}{
    \leftwatermark{\ThisCenterWallPaper{1.0}{background_page_even.pdf}}
    \rightwatermark{\ThisCenterWallPaper{1.0}{background_page_odd.pdf}}
}{}

I am using this snippet to set a different wallpaper on all the even and odd pages in my document.

I have created a new command to create the title page (to simplify usage for me). This is how the title page is created:

% Title page
\newcommand{\maketitlepage}{
    \pagenumbering{roman}
    \begin{titlepage}
        \thispagestyle{headers_title}
        \ifthenelse{\boolean{branding}}{\ThisCenterWallPaper{1.0}{background_title.pdf}}{}
        \begin{center}
            \vspace*{1.5cm}
            \Huge{\textbf{\title}}

            \vspace*{1.5cm}
            \LARGE{\subtitle}

            \Large{-- bla bla --}

            \vspace*{3.75cm}
            \Large{Peter Folta}
        \end{center}
    \end{titlepage}
}

It places a special image on the title page. This works just fine, with the only problem that the title page now features two background images on top of each other: The title page image as well as the odd page image. This makes sense, as the title page is, in fact, an odd page. However, I'm looking for a solution to just have the title image on the title page.

Here is a minimal working example that illustrates my problem:

\documentclass[a4paper, twoside]{article}

\usepackage{watermark}
\usepackage{wallpaper}

\leftwatermark{\ThisCenterWallPaper{1.0}{background_page_even.pdf}}
\rightwatermark{\ThisCenterWallPaper{1.0}{background_page_odd.pdf}}

\newcommand{\maketitlepage}{
    \begin{titlepage}
        \ThisCenterWallPaper{1.0}{background_title.pdf}
        \begin{center}
            Contents of title page ...
        \end{center}
    \end{titlepage}
}

\begin{document}
    \maketitlepage

    Contents on an even page ...

    \newpage

    Contents on an odd page ...
\end{document}

Any ideas?

pfolta
  • 81
  • Welcome to TeX.SX! There are several packages thought for adding watermarks, and some provide commands for switching off the watermarks pagewise. So, the best would be, if you’d add a minimal working example (MWE) that illustrates your problem. It will be much easier for us to reproduce your situation and find out what the issue is when we see compilable code, starting with \documentclass{...} and ending with \end{document}. – Speravir Jan 10 '14 at 01:44
  • I've added an example in the main post, I hope that helps! Let me know if there's anything else I should provide. – pfolta Jan 10 '14 at 08:40

1 Answers1

5

I've just solved the problem myself. Instead of just using the \ThisCenterWallpaper command I had to wrap it in another watermark command.

This solves the problem:

\thiswatermark{\ThisCenterWallPaper{1.0}{background_title.pdf}}
pfolta
  • 81