This is what I am trying to do: I want to have a document written in Arial 12pt, with a half transparent background image centered in the first page, with customized margins.
This code compiled with XeLaTeX would be alright:
\documentclass[a4paper,12pt,oneside]{report}
\usepackage{graphicx}
\usepackage{fontspec}
\setmainfont{Arial}
\usepackage[pages=some]{background}
\backgroundsetup{
scale=1,
color=black,
opacity=0.2,
angle=0,
contents={%
\includegraphics[width=\paperwidth,height=\paperheight]{ufpr_marcadagua.jpg}
}%
}
\begin{document}
\BgThispage
\centerline{text}\par
more text
\clearpage
\end{document}
But when I reset the margins (code below) as I want the background image gets badly repositioned
\documentclass[a4paper,12pt,oneside]{report}
\usepackage{graphicx}
\usepackage{fontspec}
\setmainfont{Arial}
\setlength{\voffset}{-1in}
\setlength{\topmargin}{1cm}
\setlength{\headheight}{1cm}
\setlength{\headsep}{0.5cm}
\setlength{\hoffset}{-1in}
\setlength{\oddsidemargin}{2.5cm}
\setlength{\evensidemargin}{2.0cm}
\setlength{\textwidth}{16.5cm}
\setlength{\textheight}{25.2cm}
\setlength{\marginparsep}{0.5cm}
\setlength{\footskip}{1cm}
\usepackage[pages=some]{background}
\backgroundsetup{
scale=1,
color=black,
opacity=0.2,
angle=0,
contents={%
\includegraphics[width=\paperwidth,height=\paperheight]{ufpr_marcadagua.jpg}
}%
}
\begin{document}
\BgThispage
\centerline{text}\par
more text
\clearpage
\end{document}
How can I position the background image in the center of the page having reset margins?
geometry
? Is there a reason to do it all manually?\voffset
and\hoffset