Page Layoutmemoir | Page Width not working

Information and discussion about page layout specific issues (e.g. header and footer lines, page formats, page numbers).
Post Reply
niles
Posts: 92
Joined: Mon Dec 01, 2008 9:35 pm

memoir | Page Width not working

Post by niles »

Hi

Please take a look at this MWE:

Code: Select all

\documentclass[a4paper,11pt]{memoir}
\usepackage[ansinew]{inputenc}
\usepackage[T1]{fontenc}
\usepackage{graphicx}

\begin{document}

\begin{titlingpage}
\aliaspagestyle{titlingpage}{empty}

\makeatletter
\renewcommand{\@maketitle}{
  \newpage
  \null
  \vskip 2em%
  \vspace*{\droptitle}
  \maketitlehooka
  {\hspace{-\spinemargin}
   \includegraphics[width=\paperwidth]{Untitled-1} }
  \maketitlehookb
  \maketitlehookc

  \maketitlehookd
}
\makeatother

\maketitle

\end{titlingpage}

\end{document}
I have attached the picture "Untitled-1.pdf", which is just a black picture. My problem is that even though I use page width, the picture doesn't go fill the left part of the page. I'm not quite sure why, really, since nothing should change the page width.

The above is a MWE of this code, which interchanges the position of the author and the title in memoir: http://www.latex-community.org/forum/vi ... 986#p55986

Any help is appreciated.

Cheers,
Niles.
Attachments
Untitled-1.pdf
(8.31 KiB) Downloaded 163 times
Last edited by niles on Wed Sep 28, 2011 10:52 pm, edited 1 time in total.

Recommended reading 2024:

LaTeXguide.org • LaTeX-Cookbook.net • TikZ.org

NEW: TikZ book now 40% off at Amazon.com for a short time.

And: Currently, Packt sells ebooks for $4.99 each if you buy 5 of their over 1000 ebooks. If you choose only a single one, $9.99. How about combining 3 LaTeX books with Python, gnuplot, mathplotlib, Matlab, ChatGPT or other AI books? Epub and PDF. Bundle (3 books, add more for higher discount): https://packt.link/MDH5p

niles
Posts: 92
Joined: Mon Dec 01, 2008 9:35 pm

Re: memoir | Page Width not working

Post by niles »

Is my question poorly formulated or is the issue cumbersome or something else?
User avatar
Stefan Kottwitz
Site Admin
Posts: 10335
Joined: Mon Mar 10, 2008 9:44 pm

memoir | Page Width not working

Post by Stefan Kottwitz »

Hi Niles!

For example, there's a line break in the code after \hspace{-\spinemargin}, which has the effect of a white space. You could write that line

Code: Select all

  {\hspace{-\spinemargin}%
I often use a construction similar to

Code: Select all

\noindent\makebox[\textwidth]{\includegraphics[width=\paperwidth]{Untitled-1}}
for centering a wide image in relation to the text body, here with \paperwidth, which would be ok given symmetric margins, see Centering wide tables or figures.

Stefan
LaTeX.org admin
niles
Posts: 92
Joined: Mon Dec 01, 2008 9:35 pm

Re: memoir | Page Width not working

Post by niles »

Ah, I see. Thanks for taking the time to help!

Thread solved.
Post Reply