0

I have the following code that I am trying to get to have the correct format for the header area.

\documentclass[12pt, letterpaper]{article}

\usepackage[top=1.0in, bottom=1.0in, left=1.0in, right=1.0in]{geometry}
\usepackage{unicode-math}
    \setmainfont[Ligatures=TeX, BoldFont=Timesbd.ttf, ItalicFont=Timesi.ttf, BoldItalicFont=Timesbi.ttf]{Times.ttf}
\usepackage[style=mla,backend=biber]{biblatex}
\usepackage{csquotes}
\usepackage{setspace}
    \doublespacing
\usepackage{indentfirst}
\usepackage{graphicx}
\usepackage{hyperref}
\usepackage{lua-ul}
\usepackage[leftmargin=1in, rightmargin=0in, vskip=0in]{quoting}
\usepackage{ragged2e}
\usepackage{fancyhdr} %Fancy-header package to modify header/page numbering (insert last name)
    \pagestyle{fancy}
    \lhead{} 
    \chead{} 
    \rhead{LastName \thepage} 
    \lfoot{} 
    \cfoot{} 
    \rfoot{} 
\renewcommand{\headrulewidth}{0pt} 
\renewcommand{\footrulewidth}{0pt} 
%To make sure we actually have header 0.5in away from top edge
%12pt is one-sixth of an inch. Subtract this from 0.5in to get headsep value
\setlength\headsep{0.333in}

\newcommand{\bibent}{\noindent \hangindent 40pt}
\newenvironment{workscited}{\newpage {\centering Works Cited\par}}{\newpage }

\setlength{\parindent}{0.5in}

\renewcommand{\section}[1]{{\noindent\textbf{#1}\par}
\setlength{\parindent}{0.5in}}

\renewcommand{\subsection}[1]{{\noindent\textit{#1}\par}
\setlength{\parindent}{0.5in}}

\renewcommand{\subsubsection}[1]{{\noindent\centering\textbf{#1}\par}
\setlength{\parindent}{0.5in}}

\renewcommand{\paragraph}[1]{{\noindent\centering\textit{#1}\par}
\setlength{\parindent}{0.5in}}

\renewcommand{\subparagraph}[1]{\refstepcounter{subparagraph}{\noindent\underLine{#1}\par}
\setlength{\parindent}{0.5in}}

\RaggedRight

\makeatletter
% Define custom commands for instructor and course
\NewDocumentCommand{\instructor}{m}{\def\@instructor{#1}}
\NewDocumentCommand{\course}{m}{\def\@course{#1}}

% Renew the maketitle command
\RenewDocumentCommand{\maketitle}{}{
    \noindent \@author\\
    \@instructor\\
    \@course\\
    \@date\\
    {\centering{\@title}\par}\setlength{\parindent}{0.5in}}
\makeatother

% Set author, instructor, course, date, and title in the preamble
\author{Author}
\instructor{Instructor}
\course{Course}
\date{\today}
\title{Title}

\begin{document}

\maketitle

There are lots of examples of good teamwork in theatre. Broadway shows like "Hamilton" by Lin-Manuel Miranda show how great collaboration can be. Miranda's writing and music, along with Thomas Kail's direction and Andy Blankenbuehler's choreography, created an amazing musical (Gillette, 2009). The Royal Shakespeare Company's adaptations of Shakespeare's plays show how teamwork can make old plays feel new again. Community and experimental theatres also rely a lot on teamwork, bringing different people together to make unique and powerful shows (Roznowski and Domer, 2016).

\begin{workscited}
  
\end{workscited}

\end{document}

When one compiles this ocde you get the error:

Package fancyhdr Warning: \headheight is too small (12.0pt): Make it at least 14.49998pt, for example: \setlength{\headheight}{14.49998pt}. You might also make \topmargin smaller to compensate:(fancyhdr) \addtolength{\topmargin}{-2.49998pt}.

However, when i add \setlength{\headheight}{14.49998pt} it will move just the text up a bit, and coupled with \addtolength{\topmargin}{-2.49998pt} it will move the header also a bit up.

When i'm trying to fix the error I'm pretty sure I'm neglecting both of these comments:

%To make sure we actually have header 0.5in away from top edge

%12pt is one-sixth of an inch. Subtract this from 0.5in to get headsep value

It seems that the header being .5 inches is an MLA required standard, but I assume that the `headsep` is too? Also, is the original version I even have correct format? should I ignore the error? I was told that I should never ignore LaTeX errors, so I am wanting to come on here to get opinions. Thank you for reading.

2
  • unrelated to your vertical space question but \renewcommand{\subsubsection}[1]{{\noindent\centering\textbf{#1}\par} really???? apart from completely disabling all latex's support for section headings, \noindent before \centering is really odd and only works at all by accident. It means that you are using \centering mid-paragraph and relying on it applying to the whole paragraph. Similarly you have \setlength{\parindent}{0.5in} which does nothing as you follow it by \RaggedRight which sets it to 0pt again and then you re-set it again (globally) after every section heading? Commented Jul 10 at 10:07
  • 1
    May I suggest that you try the template on Overleaf?:fr.overleaf.com/latex/templates/mla-style-paper-template/… The errors that come up are not important ones, they are only warnings and can be discarded, as they don't affect the output.
    – Xavier_B
    Commented Jul 10 at 11:10

0

You must log in to answer this question.

Browse other questions tagged .