Page Layoutflushright title for style article

Information and discussion about page layout specific issues (e.g. header and footer lines, page formats, page numbers).
Post Reply
jbike
Posts: 2
Joined: Mon Jan 04, 2010 2:00 pm

flushright title for style article

Post by jbike »

Hi,

I would like to create an article with the abstract and title information pinned to the first page of the text- and flushright instead of centered. When I use the \author \date as well as the \maketitle command to generate my title information on the same page as my abstract and article, I cannot find a way to set the title information flushright. Does anyone know how to do this?

Thanks,
Jbike

Recommended reading 2024:

LaTeXguide.org • LaTeX-Cookbook.net • TikZ.org

NEW: TikZ book now 40% off at Amazon.com for a short time.

User avatar
frabjous
Posts: 2064
Joined: Fri Mar 06, 2009 12:20 am

flushright title for style article

Post by frabjous »

You can do things like this by packing use of packages such as the abstract and titling packages. Here's an example:

Code: Select all

\documentclass{article}
\usepackage{lipsum} % used to auto-generate-text
\usepackage{titling}
\usepackage{abstract}

\title{Great Title Here}
\author{Roy G. Biv}
\date{\today}

\pretitle{\begin{flushright}\LARGE} % makes document title flush right
\posttitle{\end{flushright}}
\preauthor{\begin{flushright}\large} % makes author flush right
\postauthor{\end{flushright}}
\predate{\begin{flushright}\large} % makes date title flush right
\postdate{\end{flushright}}


\renewcommand{\absnamepos}{flushright} % makes word ``Abstract'' flushright
\setlength{\absrightindent}{0pt} % makes abstract go all the way to right
\setlength{\absleftindent}{0.2\textwidth} % makes abstract skip the left quarter of page
\renewcommand{\abstracttextfont}{\normalfont\small\raggedleft} % makes the abstract text flush right -- very ugly, don't do this!

\begin{document}
\maketitle
\begin{abstract}
\lipsum[1-2] % autogenerates abstract text; replace with yours
\end{abstract}
\lipsum[3-15] % auto-generate body text.
\end{document}
I recommend reading their documentation (titling / abstract) and similar ones on CTAN for more info.
jbike
Posts: 2
Joined: Mon Jan 04, 2010 2:00 pm

Re: flushright title for style article

Post by jbike »

Thanks so much for your quick reply. CTAN is the resource that I was missing. Perhaps now I can answer more of my own questions throughout the draft of my article, though I may post again if I run into trouble.

I cannot thank you enough.

Jbike
Post Reply