Re: Ambiente list

#17500
Up
0
Down
::

Per dei motivi particolari sono costretto ad usare l’ambiente list (devo controllare manualmente la numerazione) e ho bisogno di indentare alcuni punti più degli altri. Cercando e scavando sono riuscito a fare in modo da riuscire ad aumentare l’indentatura della prima riga di un item, ma se il testo è parecchio viene vanificato. Vi faccio un esempio così ci capiamo meglio:
`\documentclass{minimal}

\usepackage[italian]{babel}

\newcounter{line}
\setcounter{line}{0}

\newcommand{\aumind}{\addtolength{\itemindent}{\parindent}\addtolength{\labelsep}{\parindent}}
\newcommand{\dimind}{\addtolength{\itemindent}{-\parindent}\addtolength{\labelsep}{-\parindent}}

\begin{document}
\makeatletter
\begin{list}{\small \arabic{line}}{%
\topsep\z@%
\itemsep\z@ \labelsep 0.6em \itemindent\z@ \listparindent 2em%
\partopsep\z@ \parskip\z@ \parsep\z@%
\labelwidth 1.2em%
\leftmargin\labelwidth \addtolength{\leftmargin}{\labelsep}%
}
\makeatother
\stepcounter{line}
\item[\arabic{line}] a b c d e f g h i l m n o p q r s t u v z a b c d e f g
h i l m n o p q r s t u v z a b c d e f g h i l m n o p q r s t u v z a b
c d e f g h i l m n o p q r s t u v z a b c d e f g h i l m n o p q r s t
u v z a b c d e f g h i l m n o p q r s t u v z
\aumind
\stepcounter{line}
\item[\arabic{line}]a b c d e f g h i l m n o p q r s t u v z a b c d e f g
h i l m n o p q r s t u v z a b c d e f g h i l m n o p q r s t u v z a b
c d e f g h i l m n o p q r s t u v z a b c d e f g h i l m n o p q r s t
u v z a b c d e f g h i l m n o p q r s t u v z a b c d e f g h i l m n o
p q r s t u v z
\end{list}
\end{document}
`

Se guardate l’item 1 è ok, anche l’indentazione della prima riga dell’item 2, il punto è che però vorrei che tutto l’item 2 abbia quella indentazione.

Scusate se sono stato confuso… mi avete capito?

Temo che anche aumentando \leftmargin non si ottenga nulla. In realtà ciò che stai chiedendo è di avere liste annidate: il secondo \item è in effetti una lista a sé stante annidata nella prima.

Già che ci sono: se nel secondo argomento di \list scrivi anche \usecounter{line}, non avrai bisogno di specificare \stepcounter{line} e \item[\arabic{line}]: basta \item

Ciao
Enrico

Go to top