[Tex/LaTex] No indent in modified \maketitle in article

articleindentationtitles

I am looking to have the title left justified along with the name of the author and teacher and the date. I have managed to get it left justified but the name is being indented, this is not what I want. Here is a MWE.

\documentclass[12pt,letterpaper]{article}
\usepackage{lipsum}
\title{TITLE}

\author{
Name \textsc{Last name} \\ 
Mr. \textsc{Name}
\hspace*{-\tabcolsep}}

\begin{document}

\begingroup
\let\center\flushleft
\let\endcenter\endflushleft
\maketitle
\endgroup

\lipsum[1-10]
\end{document}

Best Answer

The titling package is specifically designed to alter the output of \maketitle. Its package documentation provides the standard definitions of \maketitle on page 2, so we just need to alter that.

Note that \and is the LaTeX way of introducing several authors. I also added \thanks author footnotes just to demonstrate that they work. In order for this solution to look 100% like your code, you’ll have to add a font size command like \large to \preauthor.

\documentclass[12pt]{article}
\usepackage{titling}

%% Standard `article' settings:
%\pretitle{\begin{center}\LARGE}
%\posttitle{\par\end{center}\vskip 0.5em}
%\preauthor{\begin{center}
%\large \lineskip 0.5em%
%\begin{tabular}[t]{c}}
%\postauthor{\end{tabular}\par\end{center}}
%\predate{\begin{center}\large}
%\postdate{\par\end{center}}

%% Adapted settings:
\pretitle{\begin{flushleft}\LARGE}
\posttitle{\par\end{flushleft}\vskip 0.5em}
\preauthor{\begin{flushleft}}
\postauthor{\end{flushleft}}
\predate{\begin{flushleft}\large}
\postdate{\par\end{flushleft}}

% Change \and to \newline (originally, it basically starts a new column
\renewcommand{\and}{\newline}

\title{TITLE}
\author{
Name \textsc{Last name}\thanks{Foo} \and Mr. \textsc{Name}\thanks{Bar}
}

\usepackage[paperheight=12cm]{geometry}% just for the demo
\begin{document}
\maketitle

Hello World.
\end{document}

output