Take the 2-minute tour ×
TeX - LaTeX Stack Exchange is a question and answer site for users of TeX, LaTeX, ConTeXt, and related typesetting systems. It's 100% free, no registration required.

This is how my letter looks like

\documentclass[a4paper, 11pt]{letter}

\usepackage{fontspec}
\usepackage{fancyhdr}


\newcommand{\DocumentTitle}{Motivation Letter}
\newcommand{\Author}{John Smith}

\setmainfont{Times New Roman}
\newfontfamily\hdrfont[ LetterSpace=5.0, WordSpace=1.0, Scale=0.9, Color=FFFFFF ]{Arial}

\usepackage[hmargin=1in,vmargin=1.8in]{geometry}
\linespread{1.2}

\pagestyle{fancy}
\fancyhf{} % clear all header and footers
\setlength{\headheight}{0.5in}
\fancyhead[L]{\hdrfont\textbf{\DocumentTitle} \\ \emph{\Author}}
\fancyhead[R]{\hdrfont\thepage}
\fancyfoot[L]{\hdrfont\textbf{\DocumentTitle} \\ \emph{\Author}}
\fancyfoot[R]{\hdrfont\thepage}

\renewcommand{\headrulewidth}{0.4pt}
\renewcommand{\footrulewidth}{0.4pt}

\begin{document}
\name{ \Author }
\signature{ \Author }
\begin{letter}{}
\renewcommand{\today}{ February 16, 2009 }


\opening{To Whom It May Concern,}
\thispagestyle{fancy}
\closing{Respectfully,}
My Letter
\end{letter}

\end{document}

What like the pdf looks like

--------------------------------------- PAGE BEGIN
                                        H
--------------------------------------- HEADER RULE
                                        M1
To Whom It May Concern,---------------- TEXT BEGIN
My Letter
Respectfully,-------------------------- closing
                                        S
John Smith----------------------------- signature
--------------------------------------- TEXT END
                                        M2
--------------------------------------- FOOTER RULE
                                        F
--------------------------------------- PAGE END

I want that H = F M1 = M2 and length S is too big. But now, H != F and M1 != M2. How I can achieve that?

share|improve this question

1 Answer 1

up vote 0 down vote accepted

For having H = F include includehead,includefoot in the option of geometry.

For reducing the space between the closing and the signature you can use the etoolbox package to patch the distance:

\usepackage{etoolbox}
\patchcmd{\closing}{6}{2}{}{}

or

\pathcmd{\closing}{6\medskipamount}{<insert the distance you prefer>}{}{}

It seems to me that to vertically center the content of the letter (i.e., M1 = M2) would require a substantial rewriting of the letter class. One has to consider whether it does not fit in one page, and then processing it accordingly.

share|improve this answer
    
I added includehead,includefoot (\usepackage[hmargin=1in,vmargin=1.2in,includehead,includefoot]{geometry}). Still H != F. –  user14416 Nov 16 '12 at 16:04
    
Have you removed the \setlength{\headheight} line from your code? –  Guido Nov 16 '12 at 17:48

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.