3

After compiling the code below, I get a blank first page in my output (which is undesirable). I have no idea why I'm getting this blank page. Can someone help?

\documentclass[twoside,openany,a5paper,14pt]{memoir}
%\usepackage{hyperref}
\usepackage[brazilian]{babel}
\usepackage[utf8]{inputenc}
\usepackage{titlesec}

\fixpdflayout

% Chapter style
\makeatletter
\renewcommand{\@makechapterhead}[1]{%
\vspace*{50 pt}%
{\setlength{\parindent}{0pt} \raggedright \normalfont
\bfseries\Huge
\ifnum \value{secnumdepth}>1 
\if@mainmatter\thechapter.\ \fi%
\fi
#1\par\nobreak\vspace{40 pt}}}

% Title style

\newlength\drop
\newcommand*{\titleGM}{%
\thispagestyle{empty}
\begingroup% Gentle Madness
\drop = 0.1\textheight
\vspace*{\baselineskip}
\vfill
\hbox{%
  \hspace*{0.2\textwidth}%
  \rule{1pt}{\dimexpr\textheight-28pt\relax}%
  \hspace*{0.05\textwidth}% 
  \parbox[b]{0.75\textwidth}{%
    \vbox{%
      \vspace{\drop}
      {\Huge\bfseries\raggedright\@title\par}\vskip2.37\baselineskip
      {\Large\@author\par}
      \vspace{0.5\textheight}
    }% end of vbox
  }% end of parbox
}% end of hbox
\vfill
\null
\endgroup}

\makeatother

\title{Seguir adiante}
\author{Jos\'e Rodrigues}
\date{}
\begin{document}
\pagenumbering{gobble}
\thispagestyle{empty}
\titleGM
\thispagestyle{empty}
\clearpage
\pagenumbering{arabic}

Test

\end{document}
7
  • 4
    provide a complete example which shows the behaviour and not only fragtments.
    – user2478
    Nov 20 '13 at 14:22
  • I just compile your .tex (adding \begin{document}...) and I don't have the blank page...
    – ppr
    Nov 20 '13 at 14:44
  • Welcome to TeX.SX! Please make your code compilable, starting with \documentclass{...} and ending with \end{document}. That may seem tedious to you, but think of the extra work it represents for TeX.SX users willing to help you. Help them help you: remove that one hurdle between you and a solution to your problem.
    – jub0bs
    Nov 20 '13 at 15:17
  • 2
    The \titleGM design is too tall for the the textblock, see the log file.
    – daleif
    Nov 20 '13 at 16:05
  • 1
    You have at least two baseline skips before the rule starts. In your document \the\dimexpr2\baselineskip\relax should print 35pt. As such, you should remove at least 35pt from \textheight for the \rule to fit.
    – Werner
    Nov 20 '13 at 17:17
3

Your

\rule{1pt}{\dimexpr\textheight-28pt\relax}%

is too tall to fit into the page. The simplest thing would be to shorten is a bit

\rule{1pt}{\dimexpr\textheight-35pt\relax}%
0

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.