LaTeX forum ⇒ Text Formattingsinglespace in {quote}, doublespace elsewhere Topic is solved

Information and discussion about LaTeX's general text formatting features (e.g. bold, italic, enumerations, ...)
saimike
Posts: 20
Joined: Wed Apr 11, 2012 10:44 pm

singlespace in {quote}, doublespace elsewhere

Postby saimike » Mon Apr 23, 2012 10:09 pm

Preamble: I'm formatting a humanities dissertation so this may seem weird.

I have a lot of quotes from interviews and I want to have them single spaced (intra-paragraph) and doublespaced inter-paragraph. I was able to do this rather well using in my appendix using:

\setlength{\parskip}{11pt}
\singlespacing


Is there a way I can have all my {quote} in singlespace? i.e. whenever I start a \begin{quote}, it will be single spaced with an 11pt \parskip.

Link:
BBcode:
HTML:
Hide post links
Show post links

User avatar
Stefan Kottwitz
Site Admin
Posts: 7804
Joined: Mon Mar 10, 2008 9:44 pm
Location: Hamburg, Germany
Contact:

Postby Stefan Kottwitz » Mon Apr 23, 2012 10:20 pm

With a consistent macro typesetting software like LaTeX, it's no problem. Just extend the quote environment. A quick addition:

  1. \makeatletter
  2. \g@addto@macro\quote\singlespace
  3. \makeatother


\makeatletter and \makeatother are just required because @ is a special character, commonly used to mark internal macros, which is therefore not allowed for direct use in documents. This would not be necessary in a style file.

Stefan
Site admin

Link:
BBcode: Topic is solved[/url]" title="Click to select post's link in BBcode format" onclick="this.focus();this.select();" />
HTML: Topic is solved</a>" title="Click to select post's link in HTML format" onclick="this.focus();this.select();" />
Hide post links
Show post links

saimike
Posts: 20
Joined: Wed Apr 11, 2012 10:44 pm

Postby saimike » Mon Apr 23, 2012 11:06 pm

Stefan

Awesome, that worked very well!

Link:
BBcode:
HTML:
Hide post links
Show post links

saimike
Posts: 20
Joined: Wed Apr 11, 2012 10:44 pm

Postby saimike » Wed Apr 25, 2012 7:22 pm

Stefan

Would this macro affect the inter-paragraph spacing between the quote and the previous or following paragraph?

I am seeing inconsistent spacing when using it with puthesis.cls (https://engineering.purdue.edu/~mark/pu ... thesis.cls).

Link:
BBcode:
HTML:
Hide post links
Show post links

User avatar
Stefan Kottwitz
Site Admin
Posts: 7804
Joined: Mon Mar 10, 2008 9:44 pm
Location: Hamburg, Germany
Contact:

Postby Stefan Kottwitz » Wed Apr 25, 2012 7:32 pm

I don't think so. Have a look:

  1. \documentclass[aae,dissertation]{puthesis}
  2. \usepackage[english]{babel}
  3. \usepackage{blindtext}
  4. \usepackage{setspace}
  5. \makeatletter
  6. \g@addto@macro\quote\singlespace
  7. \makeatother
  8. \doublespace
  9. \begin{document}
  10. \blindtext
  11. \begin{quote}
  12. \blindtext
  13. \end{quote}
  14. \blindtext
  15. \end{document}


Perhaps show with code, similarly as I, what you mean with inconsistent spacing. There could be other reasons.

Stefan
Site admin

Link:
BBcode:
HTML:
Hide post links
Show post links

NeuroTex
Posts: 1
Joined: Fri May 17, 2013 8:34 am

Postby NeuroTex » Fri May 17, 2013 8:52 am

...thanks for a very helpful post here :D

but - is there a way for (and any sense in) putting the starred version of the \singlespace command? Say something like:


  1. \makeatletter
  2. \g@addto@macro\quote\singlespace*
  3. \makeatother


the above doesn't seem to be working form me
and using:

  1. \makeatletter
  2. \g@addto@macro{\quote}{\singlespace*}
  3. \makeatother


just adds an extra "*" in front of my quoted text.

...and what would be the valid/proper way to add \singlespace to every occurrence of a starred command like table* or chapter*?

Link:
BBcode:
HTML:
Hide post links
Show post links


Return to “Text Formatting”

Who is online

Users browsing this forum: No registered users and 10 guests