# Beautiful quotes in documentclass article [duplicate]

Possible Duplicate:
“Inspirational” quote at start of chapter

I'm using \documentclass[a4paper,12pt]{article}. How to do this beautiful quote by using \renewenvironment{quote} or having my own \newenvironment{myQuote}?

• Welcome to TeX.sx! A tip: You can use backticks  to mark your inline code as I did in my edit. – Joseph Wright Aug 5 '12 at 10:09
• No it's not duplicate because this is using article – guest453453 Aug 5 '12 at 10:17
• It's very close, but I'll try to come up with a solution. – lockstep Aug 5 '12 at 10:20
• Since this question has been closed as a duplicate, I propose to merge it into the duplicate would, in order to have all the answers in one place, and flagged it accordingly. – doncherry Nov 14 '16 at 21:58

I took Gonzalo Medina's second solution in his answer to "Inspirational" quote at start of chapter and changed the following:

• Instead of using the memoir class, the epigraph package (from memoirs author) is loaded;

• \epigraphfontsize is replaced with \epigraphsize;

• The etoolbox package is used to patch the internal \@epitext command so that \itshape works.

\documentclass{article}

\usepackage{epigraph}

% \epigraphsize{\small}% Default
\setlength\epigraphwidth{8cm}
\setlength\epigraphrule{0pt}

\usepackage{etoolbox}

\makeatletter
\patchcmd{\epigraph}{\@epitext{#1}}{\itshape\@epitext{#1}}{}{}
\makeatother

\begin{document}

\section{Graph Theory}

\epigraph{Begin at the beginning," the King said gravely, and go on till you come to the end: then stop."}{--- \textup{Lewis Carroll}, Alice in Wonderland}

\end{document}


• Thanks this works so far, but how to do it 100% width, like \begin{quote}...\end{quote} would do it? (I don't need \section btw.) – guest453453 Aug 5 '12 at 10:40
• @guest453453 I wouldn't redefine the quote environment because it might be needed for block quotes in the text body. BTW, quote uses a width of somehat less than 100%, and in my example you may change the value of the \epigraphwidth length. – lockstep Aug 5 '12 at 10:43
• ok lockstep, but how can I do \newenvironment{myQuote} then (or full width like \begin{quote}...\end{quote} would do it if using \epigraph)? – guest453453 Aug 5 '12 at 10:45
• The epigraph package offers an epigraphs environment where you write individual quotes using \qitem`-- have a look at the manual. – lockstep Aug 5 '12 at 10:54
• I got it working by doing \setlength\epigraphwidth{16cm}, thanks all. – guest453453 Aug 5 '12 at 10:59