I would like the abstract on the title page in the following style: 1. The word 'Abstract' centred above the text 2. A horizontal line immediately underneath the word 'Abstract', with a width equal to that of the text 3. A horizontal line of that same length immediately underneath the text 4. The word 'Keywords:' at the left-side that allows me to put some keywords specific to the thesis.

I have been trying to get this right, but apparently I am missing something. Thanks for the help! Current code can be found here:

\noindent \rule{\linewidth}{.5pt}\par{\bfseries \abstractname.}}
{\medskip\noindent \rule{\linewidth}{.5pt}

Picture of the end result I aspire:

enter image description here

  • You realize that the quote environment adds extra margin to the left and right? Commented Jun 2, 2018 at 13:41
  • @JohnKormylo I did not know that. However, after removing 'quote' it lead to a less desire result, so I like the style it gives.
    – Sean
    Commented Jun 2, 2018 at 13:44
  • As far as I can tell, the ONLY thing quote does is change the margins. Unless you are using some other document class. Commented Jun 2, 2018 at 15:00
  • You should decide where to ask. Either here or on LaTeX.org. Once again, you post a snippet, you do not give any indication which document class you are using, alas, you are never posting a suitable MWE. And what does the question have to do with {sharelatex}?
    – Johannes_B
    Commented Jun 3, 2018 at 5:24
  • A former question of yours asked for a title page that seems to contradict with this newer question. If the old question is obsolete, please either delete it or mark as duplicate of tex.stackexchange.com/questions/209993/…
    – Johannes_B
    Commented Jun 3, 2018 at 5:54

3 Answers 3


A solution based on tabularx, threeparttable and xparse for the keywords: it defines the abstract as a threeparttable – the abstract itself being a single row of a tabularx environment, and the list of keywords, input as an optional argument of the environment, inserted as a table note.

\usepackage{tabularx, threeparttable, booktabs}
\title{Some Title}
\author{Some One}
{\small\noindent\threeparttable\tabularx{\linewidth}{@{}>{\arraybackslash}X@{}}\bfseries\centering \abstractname\tabularnewline\addlinespace[1.5ex]\midrule\addlinespace[1ex]}%
{\endtabularx\vspace{-2ex}\hrule\IfNoValueF{#1}{ \begin{tablenotes}[flushleft, online]\smallskip\item[Keywords: ] #1


\begin{abstract}%[small $\beta$s, Fama-MacBeth two-pass procedure; foreign currency portfolios; factor pricing; stochastic discount factors; weak identification; principal components]


enter image description here


It might help to look at the definitions is the base folder (article.cls for example).

Since \rule expands in hmode, it always takes up \baselineskip, while \hrule expands in vmode and adds NO extra vertical space. The center environment add extra space at the end, which can be removed using \unskip.

\usepackage{lipsum}% MWE only
\usepackage{showframe}% MWE only

{\begin{center}\bfseries \abstractname




I said it before and I will say it again: There is no need to redefine the abstract environment.


% Masters/Doctoral Thesis 
% LaTeX Template
% Version 2.6 (26/4/18)
% This template was downloaded from:
% http://www.LaTeXTemplates.com
% Version 2.x major modifications by:
% Vel ([email protected])
% This template is based on a template by:
% Steve Gunn (http://users.ecs.soton.ac.uk/srg/softwaretools/document/templates/)
% Sunil Patel (http://www.sunilpatel.co.uk/thesis-template/)
% Template license:
% CC BY-NC-SA 3.0 (http://creativecommons.org/licenses/by-nc-sa/3.0/)
english, % ngerman for German
chapterinoneline, % Uncomment to place the chapter title next to the number on one line
]{MastersDoctoralThesis} % The class file specifying the document structure
\ihead{\headmark Author p X}
    {\scshape\LARGE Columbidae University \par}
    {\scshape\Large Final year project\par}
    {\huge\bfseries Pigeons love doves\par}
    {\Large\itshape John Birdwatch\par}
    supervised by\par
    Dr.~Mark \textsc{Brown}

    \noindent Keywords: Alpaca, Wombat, Capybara

    {\centering\large \today\par}

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .