1

For my own use (consisting in putting a box before the first item !), I want to change the indentation of the first item, something like this file: enter image description here

I obtained this result, by the ugly method in the .tex file what I add here, just to watch up the result I want to obtain:

\documentclass[12pt]{article}
\newcounter{ItemsCounter}
\begin{document}
\pagestyle{empty}
\noindent
\textbf{Hello world}
\begin{list}
{\bfseries{}\arabic{ItemsCounter}.~}
{
\usecounter{ItemsCounter}
\addtolength\leftmargin{14mm}
}
\item A\\ multilined\\ text

\end{list}

\begin{list}
{\bfseries{}\arabic{ItemsCounter}.~}
{
\usecounter{ItemsCounter}
\setcounter{ItemsCounter}{1}}
\item Item two
\item Item three

\end{list}
\end{document}

I want to change only the first item by something like the command \addtolength\leftmargin{14mm}, but it's accepted only in global option and not locally for one item. I used this acrobaty, using two successive list environments, and iterating the items, to obtain the suitable result, but I obviously want to use a more elegant method, for enumerate and itemize environments. How can I obtain the compilation here, so change the indentation only for the first item, with a useful method ? Thank you.

1 Answer 1

1

Perhaps something like this?

\documentclass{article}
\usepackage{enumitem}
\begin{document}
\begin{enumerate}[label=\bfseries{\arabic{enumi}}.,leftmargin=1em]
\item[]\stepcounter{enumi}
\begin{enumerate}[label=\bfseries{\arabic{enumi}}.,leftmargin=3em]
\item A\\ multilined\\ text
\end{enumerate}
\item Item two
\item Item three
\end{enumerate}
\end{document}

enter image description here

You can adjust the identitation by playing with the leftmargin parameters.

14
  • Thanks for your answer, which is useful, but it's an "acrobaty" like mine.. I made two successive enumerate, and you made two imbricated ones ! Your idea is more beautiful, and I'll wait some time before accepting it. Thanks Jan 15, 2018 at 14:35
  • @FaouziBellalouna I agree with you that it is not too beautiful, but I was able to simplify the snippet slightly.
    – user121799
    Jan 15, 2018 at 14:43
  • There is another problem. There will be some objects, some small boxes in the empty space, and I think that there will be some problem with superposing with \color{white} Jan 15, 2018 at 14:45
  • @FaouziBellalouna Yes, that's precisely what the simplification was about.
    – user121799
    Jan 15, 2018 at 14:46
  • 1
    @marmot, is it indeed an impossibility to change the leftmargin of an individual item without recurring to an additional list (nested or sequential)?
    – gusbrs
    Jan 15, 2018 at 14:56

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .