LaTeX forum ⇒ Text FormattingVertical Space around "quote" Environment

Information and discussion about LaTeX's general text formatting features (e.g. bold, italic, enumerations, ...)
Posts: 2
Joined: Mon Feb 06, 2012 5:05 pm

Vertical Space around "quote" Environment

Postby bobjones » Mon Feb 06, 2012 7:21 pm

I haven't found any threads exactly on topic here, though my issue does relate to an unresolved problem mentioned at the end of this thread: ... =44&t=7449

Basically, I am required to have a double-spaced document, but all the block quotations should have tighter spacing. I have tried a simple addition to the "quote" environment, such as:
  1. \let\oldquote=\quote
  2. \let\oldendquote=\endquote
  3. \renewenvironment{quote}
  4. {\oldquote\OnehalfSpacing}
  5. {\oldendquote}

(The reason for the caps in the \OnehalfSpacing command is because I'm using the Memoir class. I've also tried it with the standard setspace commands using a different document class, and I get similar results.)

This fixes the spacing within the quote environment, but it causes uneven spacing in the vertical whitespace above and below the block quote. In this case, the vertical space is greater after the block quote. But when I've tried varying the spacing of the main text and the block quotes (e.g., single spacing in main text, 1.5 spacing in quotes), I've gotten inconsistent results -- sometimes the space below is wider and sometimes it is narrower.

I don't much care about the exact size of the vertical space before and after a quote environment, but I do want it to be equal above and below.

How can I get the vertical spaces around the quote to be the same?

Minimal example with Memoir follows:
  1. \documentclass{memoir}
  2. \usepackage[english]{babel}
  3. \usepackage{blindtext}
  5. \DoubleSpacing
  7. \let\oldquote=\quote
  8. \let\oldendquote=\endquote
  9. \renewenvironment{quote}
  10. {\oldquote\OnehalfSpacing}
  11. {\oldendquote}
  13. \begin{document}
  14. \blindtext
  15. \begin{quote}
  16. \blindtext
  17. \end{quote}
  18. \blindtext
  19. \end{document}

Minimal example using setspace follows:
  1. \documentclass{book}
  2. \usepackage[english]{babel}
  3. \usepackage{blindtext}
  4. \usepackage{setspace}
  6. \doublespacing
  8. \let\oldquote=\quote
  9. \let\oldendquote=\endquote
  10. \renewenvironment{quote}
  11. {\oldquote\onehalfspacing}
  12. {\oldendquote}
  14. \begin{document}
  15. \blindtext
  16. \begin{quote}
  17. \blindtext
  18. \end{quote}
  19. \blindtext
  20. \end{document}

Posts: 3
Joined: Fri Sep 09, 2011 5:33 pm

Postby rdonohoe » Wed Mar 14, 2012 2:01 am

Any solution found for this? I have the exact same issue. I have 1.5 spacing in the body and need to make the quotes single spacing and footnotesize but when I edit the memoir file I get a huge whitespace after the quote block.

Any help would be great!

Posts: 2
Joined: Mon Feb 06, 2012 5:05 pm

Postby bobjones » Sun Jun 17, 2012 7:40 pm

I did find a workaround for this problem, if others still have it. Perhaps there's a more elegant solution available from someone who knows LaTeX inner workings in more detail.

Basically, my workaround is just appending some negative vertical space to the end of the quote environment, modifying my original redefinition as follows:

  1. \DoubleSpacing
  3. \let\oldquote=\quote
  4. \let\oldendquote=\endquote
  5. \renewenvironment{quote}
  6. {\oldquote\OnehalfSpacing}
  7. {\oldendquote\vspace{-0.5em}}

One could tweak the amount of vspace (here -0.5em) as needed. In my scenario -- going from double spaced to a 1.5 spaced quote environment -- I think what's happening is that the additional leading (whether 1.5 spacing or double) is added ABOVE each text line.

That is, the output is something like the following. (Note that in LaTeX, an "em" seems to be defined as a square space equal in height and width to the point size, i.e., the nominal height, of the font.)

  1. [1 EM SPACE]
  2. Here are double-
  3. [1 EM SPACE]
  4. spaced lines.
  6. [0.5 EM SPACE]
  7. Here are one-and-a-half-
  8. [0.5 EM SPACE]
  9. spaced lines.
  11. [1 EM SPACE]
  12. Here are double-
  13. [1 EM SPACE]
  14. spaced lines.

Even if the paragraph spaces (here labeled "QUOTE SPACE") surrounding the beginning and the end of the quote block are the same, there will be a larger gap after the quote. The "double-spacing" appears to insert additional vertical space before the first line of the last paragraph.

(I don't know for sure that this is what's happening -- perhaps someone more knowledgeable about LaTeX internals will know.)

Since my quote blocks are reduced from double-spaced (i.e., 1 em vertical space between lines) to 1.5-spaced (i.e., 0.5 em vertical space between lines), subtracting 0.5 em after the quote environment seems to do the trick. Again, there's probably a more elegant way to achieve equal spacing here.

I haven't tested this for other spacing combinations, but it makes sense and appears to solve my issue. Note that if you're dealing with single-spacing, that's NOT the same as ZERO em between lines -- usually, you still have about 0.2 em as default in LaTeX, depending on font size. This link has some further details in the answers:

Posts: 1
Joined: Thu Oct 18, 2018 9:45 pm

Postby cmcork3 » Thu Oct 18, 2018 9:55 pm

When dealing with how to create equal space above and below a quote environment in Memoir, when the quoted material is single-spaced but the main text is double-spaced, I found that this works:

Code: [Select all] [Expand/Collapse] [Download] ({untitled.tex})
  1. \begin{Spacing}{1}
  2. \begin{quote}
  3. % text to be quoted
  4. \end{quote}
  5. \end{Spacing}\noindent

Some variation on this may resolve the other issues.

Return to “Text Formatting”

Who is online

Users browsing this forum: No registered users and 1 guest