1 #\DeclareLyXModule{Adds an environment for hanging paragraphs.}{Hanging}
4 #Hanging paragraph code adapted from hanging.sty, available at:
5 # http://www.ctan.org/tex-archive/macros/latex/contrib/hanging/
6 #Copyright Peter R. Wilson.
7 #Released under the LaTeX Project Public License.
13 LatexName hangparagraphs
21 \IfFileExists{hanging.sty}{
23 \newenvironment{hangparagraphs}
25 \ifthenelse{\lengthtest{\parindent > 0pt}}%
26 {\setlength{\lyxhang}{\parindent}}%
27 {\setlength{\lyxhang}{2em}}%
28 \begin{hangparas}{\lyxhang}{1}%
32 \newenvironment{hangparagraphs}
34 \ifthenelse{\lengthtest{\parindent > 0pt}}%
35 {\setlength{\lyxhang}{\parindent}}%
36 {\setlength{\lyxhang}{2em}}%
40 \newcommand{\hangpara}{\hangindent \lyxhang \hangafter 1 \noindent}
41 \newenvironment{hangparas}{\setlength{\parindent}{\z@}
42 \everypar={\hangpara}}{\par}