0

I'm trying to create a titlepage with a background image (full bleed). It works when using either eso-pic or wallpaper packages as mentioned in How to create a background image on title page with LaTeX?

But I am having a lot of trouble (spent many hours) getting the image full height and width when trudimen and mag options are given to the geometry package. I tried \newgeometry as well as just \geometry. The image always leaves some margin either on the right or the bottom. And, unfortunately, you can't specify \mag twice.

Here's my code:

\documentclass[12pt]{book} 
\usepackage[left=1in, right=1in, mag=1500, truedimen,a4paper]{geometry} 
\usepackage{graphicx}
\usepackage{blindtext}
\usepackage{wallpaper}
\AtBeginDocument{\let\maketitle\relax}


\begin{document}
\maketitle
\thispagestyle{empty}
\vspace{5in}
\ThisCenterWallPaper{2}{example-image-a}
\vfill
{\huge Title}
\vfill
{\large Author}
\vspace{0.2in}
{\small \today}
\vfill
\cleardoublepage

\chapter{Best 1}
\Blindtext
\end{document}

The code produces this:

notice the white space

2
  • Why would you need the mag (magnification, 1000 = normal) option anyway? – Dr. Manuel Kuehner Oct 25 '18 at 19:48
  • I updated my question with another screenshot. Please answer my question in the last comment, sometimes there are easier solutions at hand - when others know the real problem. – Dr. Manuel Kuehner Oct 28 '18 at 14:52
1
  • I do not fully understand your problem.
  • Why do you need the mag (magnification) option anyway?
  • Below, I just copy and pasted the example from the manual and it seems to work.
  • I used *true*in (the * is just to make it clearer) instead of in as mentioned in the manual.
  • I also put the mag option first, as in the manual.

Is there still a problem?


\documentclass[12pt]{book} 
\usepackage[mag=1500, left=1truein, right=1truein, truedimen,a4paper,showframe=true]{geometry} 
\usepackage{graphicx}
\usepackage{blindtext}
\usepackage{wallpaper}
\AtBeginDocument{\let\maketitle\relax}


\begin{document}
\maketitle
\thispagestyle{empty}
\vspace{5in}
\ThisCenterWallPaper{2}{example-image-a}
\vfill
{\huge Title}
\vfill
{\large Author}
\vspace{0.2in}
{\small \today}
\vfill
\cleardoublepage

\chapter{Best 1}
\Blindtext
\end{document}

enter image description here

enter image description here

enter image description here

2
  • You will notice that your code, like mine, doesn't stretch the image fully and produces white space. I added an image to my question. – karlos Oct 25 '18 at 21:24
  • @karlos (1) I added a new screenshot, as you can see, there is no white space. If my exact code gives on your system different results, then, please say so. (2) Please answer the question, why you need the mag option anyway. – Dr. Manuel Kuehner Oct 28 '18 at 14:51

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.