Take the 2-minute tour ×
TeX - LaTeX Stack Exchange is a question and answer site for users of TeX, LaTeX, ConTeXt, and related typesetting systems. It's 100% free, no registration required.

I'm trying to change the margins around some paragraphs with hanging indents, but LaTeX throws an error and doesn't really explain what's wrong. I'm a LaTeX newbie, so please forgive me if I'm making a simple mistake. Thanks for your help.

\documentclass[a4paper,11pt]{article}

\usepackage{fullpage}
\usepackage{hanging}
\usepackage{changepage}

%\setlength{\parindent}{0pt}
\setlength{\parskip}{16pt}

\begin{document}

\begin{adjustwidth}{.25in}{0in}
\begin{hangparas}{.25in}{1}

    \setlength{\parindent}{0in}

    \textbf{One.}
    \hspace{6pt}
    Some text.  Some text.  Some text.  Some text.  Some text.  Some text.
    Some text.  Some text.  Some text.  Some text.  Some text.  Some text.
    Some text.

    \textbf{Two.}
    \hspace{6pt}
    Some more text.  Some more text.  Some more text.  Some more text.  Some
    more text.  Some more text.  Some more text.  Some more text.  Some more
    text.  Some more text.  Some more text.

\end{hangparas}
\end{adjustwidth}

\end{document}


This is XeTeX, Version 3.1415926-2.4-0.9998 (TeX Live 2012/Debian)
 restricted \write18 enabled.
entering extended mode
(./test.tex
LaTeX2e <2011/06/27>
Babel <v3.8m> and hyphenation patterns for english, dumylang, nohyphenation, fa
rsi, arabic, monogreek, greek, ibycus, ancientgreek, loaded.
(/usr/share/texlive/texmf-dist/tex/latex/base/article.cls
Document Class: article 2007/10/19 v1.4h Standard LaTeX document class
(/usr/share/texlive/texmf-dist/tex/latex/base/size11.clo))
(/usr/share/texlive/texmf-dist/tex/latex/preprint/fullpage.sty)
(/usr/share/texlive/texmf-dist/tex/latex/hanging/hanging.sty)
(/usr/share/texlive/texmf-dist/tex/latex/changepage/changepage.sty) (./test.aux
)

! LaTeX Error: Something's wrong--perhaps a missing \item.

See the LaTeX manual or LaTeX Companion for explanation.
Type  H <return>  for immediate help.
 ...

l.30 \end{adjustwidth}

?
share|improve this question
1  
No, you can't: adjustwidth uses a list environment, which sets \parshape, which takes over the parameters used by hanging. What precisely do you want to get? –  egreg Mar 8 at 17:54
    
Thank you for the explanation. I just want paragraphs with hanging indents to have different left margins, moved into the page some. –  Casey Mar 8 at 18:03
    
Welcome to TeX.SX! You can have a look at our starter guide to familiarize yourself further with our format. –  Martin Schröder Mar 8 at 18:04
    
Related question: How could I have found out myself that these two packages are incompatible? –  Casey Mar 8 at 18:05
add comment

1 Answer 1

You need neither adjustwidth nor hangparas:

\documentclass[a4paper,11pt]{article}
\usepackage{lipsum}

\newenvironment{outpar}
 {\par\setlength{\parindent}{-0.25in}}
 {\par}

\begin{document}

\lipsum[1]

\begin{outpar}
\textbf{One.}\quad
  Some text.  Some text.  Some text.  Some text.  Some text.  Some text.
  Some text.  Some text.  Some text.  Some text.  Some text.  Some text.
  Some text.

\textbf{Two.}\quad
  Some more text.  Some more text.  Some more text.  Some more text.  Some
  more text.  Some more text.  Some more text.  Some more text.  Some more
  text.  Some more text.  Some more text.
\end{outpar}

\lipsum[2]

\end{document}

enter image description here

I removed the setting of \parskip because I consider it against good typography. In any case, 16pt is too much for any respectable document. ;-)

share|improve this answer
add comment

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

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