1

I am trying to create an abstract like below:

enter image description here

How can an abstract be moved to the right and have lines placed above it? Also is it possible to align the 'keywords'.

For the first there is an answer here and the second there are answers here and here. How can I combine these to get both please?

This is the text so far

\documentclass[a4paper, twocolumn]{article} 
\usepackage{lipsum}
\usepackage[paperwidth=8.5in, paperheight=11in]{geometry}
% move abstract in a bit
% https://tex.stackexchange.com/questions/151583/how-to-adjust-the-width-of-abstract
\renewenvironment{abstract}
 {\small
  \list{}{%
    \setlength{\leftmargin}{0.25\linewidth}% <---------- CHANGE HERE
    \setlength{\rightmargin}{0pt}%
  }%
  \item\relax }
 {\endlist} 
\title{ The title}
\author{} \date{}
\begin{document}
% https://tex.stackexchange.com/questions/28109/how-can-i-place-a-one-column-abstract-in-a-two-column-document
\twocolumn[
  \begin{@twocolumnfalse}
    \maketitle
    \begin{abstract}
      {\lipsum[1] \lipsum[2]}
    \end{abstract}
    \hspace{0.245\linewidth} \small keywords : {\lipsum[2]} \vspace{1cm}
  \end{@twocolumnfalse}
]
\section{Intro} 
\lipsum
\end{document}

Which produces a correctly moved abstract but unaligned 'keywords'. I have been unable to also add the lines. Thanks for any help.

enter image description here

1 Answer 1

2

One quick hack is to use a tabular environment. This involves hard coding the width of the table so that it wraps the text and using flushright to move it to the right handside margin. Using just this does not line up perfectly with the right margin of the text body due to the cell border in the table but you can use @{} p{12cm} @{} to remove this (thanks Werner)

\documentclass[a4paper, twocolumn]{article} 
\usepackage{lipsum}
\usepackage[paperwidth=8.5in, paperheight=11in]{geometry}

\title{ The title} \author{} \date{}
\begin{document}
\twocolumn[{%
  \small
  \begin{flushright}
    \begin{tabular}{@{} p{0.75\linewidth} @{}}
      \rule{\linewidth}{1pt}
      \lipsum[1]  \\ [-5pt]
      \rule{\linewidth}{1pt}
      keywords: \lipsum[2] \vspace{1cm}
    \end{tabular}
  \end{flushright}
}]

\section{Intro}
\lipsum
\end{document}

This produces

enter image description here

1
  • 1
    Just use this column spec: @{} p{12cm} @{}
    – Werner
    Sep 27, 2021 at 22:38

You must log in to answer this question.

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