2

I wanted to indent some quoted content (both 1cm from left and 1cm from right), so I defined a new environment (MWE) as follows

\documentclass[11pt,a4paper,openany]{book}
\usepackage{latexsym}
\usepackage{cases}
\usepackage{indentfirst} 
\usepackage{changepage}   % for the adjustwidth environment
\newenvironment{qt}{\begin{adjustwidth}{1cm}{1cm}}{\end{adjustwidth}}
\begin{document}
\chapter{Group Theory}
\subsection{Homomorphism from S4 to S3} % not sure if the structure matters in this problem..
It is not hard to check that 

To show it is surjective, thanks to the answer provided by @David Wheeler on MSE:
\begin{qt}
No indent here No indent here No indent here No indent here

Let's examine the mapping is surjective surjective surjective surjective surjective surjective surjective surjective surjective surjective 
\end{qt}
no indent for the first line..
\end{document}

When I put all of my quoted content into the newly defined qt environment, after compiling I noticed that the first line of the quoted content was not indented, despite my usage of the indentfirst package:

enter image description here

Of course, the adjustwidth environment did work, because the leftmost and rightmost of the included content were both indented 1cm, as is seen on the picture. The problem was just that the first line ("Denote ....") wasn't in place. There was supposed to be an indent before the word "Denote", just like before the first words in all the other lines, but there wasn't.

I also tried inserting an \indent before "Denote", which still didn't work.

So how am I supposed to make the first line indent (to be exact, indent from left)? Thanks in advance!

PS: MWE fixed finally..I'm sorry that it's the first time for me to write an MWE, I made many mistakes and didn't fix them till just two minutes ago, now it's alright.

  • Please help us help you and add a minimal working example (MWE) that illustrates your problem. Reproducing the problem and finding out what the issue is will be much easier when we see compilable code, starting with \documentclass{...} and ending with \end{document}. – user31729 Aug 8 '15 at 8:54
  • Well it seems that the quote environment did the job perfectly well and there is literally no need for me to define a new one... – Vim Aug 8 '15 at 9:34
4

There is alredy a built in environment for this:

\documentclass[11pt,a4paper,openany]{book}
\usepackage{indentfirst}

\begin{document}
\chapter{Group Theory}
\subsection{Homomorphism from $S_4$ to $S_3$}

It is not hard to check that 

To show it is surjective, thanks to the answer provided by @David Wheeler on MSE:
\begin{quote}
No indent here No indent here No indent here No indent here

Let's examine the mapping is surjective surjective surjective surjective surjective surjective surjective surjective surjective surjective 
\end{quote}
no indent for the first line..
\end{document}

output

|improve this answer|||||
  • @Vim -- You're welcome! Is the left and right indent ok with the standard settings of quote? – Ruben Aug 8 '15 at 9:39
  • Yes they look good and to be honest set off the quoted content better, for example some additional vertical space is made between the previous paragraph and the quoted lines. – Vim Aug 8 '15 at 9:42
  • It should be $S_4$ and $S_3$ also in the section title – egreg Aug 8 '15 at 18:08

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.