Quote, Quotation, Quoting in LaTeX
Why quoting?
For every professional or, in any case, serious writer (i. e. bloggers, lawyers, authors, etc.) it's fundamental to have a good quoting tool.A quoting tool allows to highlight text in dedicated environments separated from ordinary context.
It could be a fragment from a book or a judgment, a poetry or every other source to pur in evidence.
LaTeX and quoting environments.
In LaTeX there's not a single quoting environment.There are a many quoting environments with many different outputs.
This post focalizes on the basic quotation commands, perfect to highlight parts of the text without changing too much the general formatting.
Quote and Quotation.
In the TexLive standard package distribution there are two quotation environments for prose (for poetry exists the environment verse): quote and quotation.They are very similar to each other and somebody tells that they are synonym.
But they are not completely equal.
The difference is described in LaTeX Wiki Book as follows:
- quote for a short quotation, or a series of small quotes, separated by blank lines.
- quotation for use with longer quotations, of more than one paragraph, because it indents the first line of each paragraph.
Examples and code.
Now is the moment to show the differences between quote and quotation.The quote input/output
The following is a little code for the quote environment.
Before QUOTE
\begin{quote}
\lipsum[1-2]
\end{quote}
After QUOTE
It should be noted the misalignment of the text before and after the quoted part and the left alignment of each paragraph.
The quotation input/output
The following is a little code for the quotation environment.
Before QUOTATION
\begin{quotation}
\lipsum[1-2]
\end{quotation}
After QUOTATION
It should be noted the alignment of the text before and after the quoted part and the indentation of each paragraph.
All together
To facilitate understanding of the differences here are the two environments together:The quoting library.
At this point somebody may wonder if there is an environment that combines all the necessary features to quote effectively.This environment exists and it's the quoting package.
As you can read in the official page the quoting package is a Consolidated environment for displayed text
As an alternative to the LATEX standard environments quotation and quote, the package provides a consolidated environment for displayed text. First-line indentation may be activated by adding a blank line before the quoting environment. A key-value interface (using kvoptions) allows the user to configure font properties and spacing and to control orphans within and after the environment.To use quoting quoting you must declare the package in the
head
: the command is \usepackage[]{quoting}
.Then you can use the
\begin{quoting}...\end{quoting}
environment in your document:
Before QUOTING
\begin{quoting}
\lipsum[1-2]
\end{quoting}
After QUOTING
And the following is the output with the option
\usepackage[font=itshape]{quoting}
:
Obviously, the advantage is the possibility to modify and change the settings with many other options.
So you can save time and get a more elegant and readable text.
Thank You for You attention and welcome to my blog.
Thank you for your helpful tips, I had not noticed the mismatch before and after {quote}. Now I can improve the typesetting of my thesis.
ReplyDeleteI'm glad you found it helpful
Delete