1

I need to use the two quotation styles shown below (the first paragraph is the normal text):


quotation example

To this end, I am currently using the following code:

\documentclass[a4paper]{article}

\usepackage{lipsum}
\usepackage{quoting}

\begin{document}

\lipsum[1]

\begin{quoting}[indentfirst=false,font={itshape},leftmargin=3cm,rightmargin=\rightmargin]
  \lipsum[1]
\end{quoting}

\begin{quoting}[indentfirst=false,leftmargin=1.5cm,rightmargin=\rightmargin]
  \lipsum[1]
\end{quoting}
\end{document}

With my current code, I'll have to repeat informing the options

[indentfirst=false,font={itshape},leftmargin=3cm,rightmargin=\rightmargin]

and

[indentfirst=false,leftmargin=1.5cm,rightmargin=\rightmargin]

and I can't help but think there is an easier and more consistent way of accomplishing this.

Is there a way to obtain this? Is there a correct way of doing this in LaTeX?

  • It might also be possible to change the defaults, although I would have to look more closely at quoting to get an idea how difficult it would be. – John Kormylo Apr 27 '19 at 22:07
0

Define new environments (named as you wish):

\documentclass[a4paper]{article}

\usepackage{lipsum}
\usepackage{quoting}

\newenvironment{myquoteA}{\begin{quoting}[indentfirst=false,font={itshape},leftmargin=3cm,rightmargin=\rightmargin]}{\end{quoting}}
\newenvironment{myquoteB}{\begin{quoting}[indentfirst=false,leftmargin=1.5cm,rightmargin=\rightmargin]}{\end{quoting}}
\begin{document}

\lipsum[1]

\begin{quoting}[indentfirst=false,font={itshape},leftmargin=3cm,rightmargin=\rightmargin]
  \lipsum[1]
\end{quoting}

\begin{quoting}[indentfirst=false,leftmargin=1.5cm,rightmargin=\rightmargin]
  \lipsum[1]
\end{quoting}

\begin{myquoteA}
\lipsum[1]
\end{myquoteA}

\begin{myquoteB}
\lipsum[1]
\end{myquoteB}
\end{document}

enter image description here

| improve this answer | |
  • That solved my problem, thank you very much. I cannot upvote yet because of low reputation, or else I would – Rafael B Apr 27 '19 at 15:12
  • @RafaelBeirigo, welcome to TEX.SE. – Sigur Apr 27 '19 at 15:14

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.