2

This question is an extension of How to Imitate This Enumerate Display

Consider the code

\documentclass[10pt,openany]{book}
\usepackage{enumitem,xcolor}

\usepackage{xparse} 

\definecolor{granite}{RGB}{103,103,103}


\newlist{advice}{enumerate}{1}
\setlist[advice]{
  label=\formatadvicenumber{\textbf{\color{granite}\arabic*}},
  ref=\arabic*,
  leftmargin=1.25em, % changed from 4em
  labelsep=.45em, % added.
  itemsep=0.75em, % added.
  resume,
}
\NewDocumentCommand{\formatadvicenumber}{m}{%
  \raisebox{\dimexpr1.28\ht\strutbox-\height}[0pt][0pt]{\LARGE #1}%
}

\usepackage[margin=.5in,paperwidth=4in,paperheight=6in]{geometry}
\textheight=4.75in \textwidth 2.80in

\pagenumbering{arabic}

\usepackage[tracking=true]{microtype}  %This line must be commented out when using Xelatex to compile the Index

\usepackage{titlesec}
\renewcommand{\chaptername}{CHAPTER}
\titlespacing*{\chapter}{0pt}{.45in}{-.1in}
\titleformat{\chapter}[display]
        {\normalfont\Large\centering}{\textbf\chaptertitlename\ \textbf\thechapter}{0pt}{\Large\uppercase}

\begin{document}

\chapter{}
{\LARGE{\textbf{1}}} \hskip 2pt Subsequently, I would like produce an enumerate environment whereby the text of each item, beginning with the second line, extends all the way to the left-hand margin of the page, thus lying entirely underneath the item number.

\vspace*{7pt}

\begin{advice}
\item J. J. Sylvester had one remarkable peculiarity. He seldom remembered theorems, propositions, etc., but had always to deduce them when he wished to use them.

\item I remember once submitting to Sylvester some investigations that I had been engaged on, and he immediately denied my first statement, saying that such a proposition had never been heard of, let alone proved. To his astonishment, I showed him a paper of his own in which he had proved the proposition; in fact, I believe the object of his paper had been the very proof which was so strange to him.

\hfill William Durfee
\end{advice}

\chapter{}
\begin{advice}
%\itemsep0pt
\item Mr. Cayley, of whom it may be so truly said, whether the matter he takes in hand be great or small, ``nihil tetigit quod non ornavit,''\ldots 

\hfill J. J. Sylvester

\item The mathematical talent of Cayley was characterized by clearness and extreme elegance of analytical form; it was re-enforced by an incomparable capacity for work which has caused the distinguished scholar to be compared with Cauchy.

\hfill C. Hermite
\end{advice}
\end{document}

which produces

enter image description here

enter image description here

QUESTION: How may I modify the above code in order to have the items of the enumerate environment resemble the first paragraph of the output; that is, to have the text associated with each item wrap underneath the item number?

Thank you.

1 Answer 1

0

Add wide=0pt where indicated:

\documentclass[10pt,openany]{book}
\usepackage{enumitem,xcolor}

\usepackage{xparse} % NEEDED TO USE \NewDocumentCommand instead of \newcommand.

\definecolor{granite}{RGB}{103,103,103}


\newlist{advice}{enumerate}{1}
\setlist[advice]{
  label=\formatadvicenumber{\textbf{\color{granite}\arabic*}},
  ref=\arabic*,
  leftmargin=1.25em,
  labelsep=.45em, 
  itemsep=0.75em, 
  wide=0pt, % ADDED
  resume,
}
\NewDocumentCommand{\formatadvicenumber}{m}{%
  \raisebox{\dimexpr1.28\ht\strutbox-\height}[0pt][0pt]{\LARGE #1}%
}

\usepackage[margin=.5in,paperwidth=4in,paperheight=6in]{geometry}
\textheight=4.75in \textwidth 2.80in

\pagenumbering{arabic}

\usepackage[tracking=true]{microtype}  %This line must be commented out when using Xelatex to compile the Index

\usepackage{titlesec}
\renewcommand{\chaptername}{CHAPTER}
\titlespacing*{\chapter}{0pt}{.45in}{-.1in}
\titleformat{\chapter}[display]
        {\normalfont\Large\centering}{\textbf\chaptertitlename\ \textbf\thechapter}{0pt}{\Large\uppercase}

\begin{document}

\chapter{}
{\LARGE{\textbf{1}}} \hskip 2pt Subsequently, I would like produce an enumerate environment whereby the text of each item, beginning with the second line, extends all the way to the left-hand margin of the page, thus lying entirely underneath the item number.

\vspace*{7pt}

\begin{advice}
\item J. J. Sylvester had one remarkable peculiarity. He seldom remembered theorems, propositions, etc., but had always to deduce them when he wished to use them.

\item I remember once submitting to Sylvester some investigations that I had been engaged on, and he immediately denied my first statement, saying that such a proposition had never been heard of, let alone proved. To his astonishment, I showed him a paper of his own in which he had proved the proposition; in fact, I believe the object of his paper had been the very proof which was so strange to him.

\hfill William Durfee
\end{advice}

\chapter{}
\begin{advice}
%\itemsep0pt
\item Mr. Cayley, of whom it may be so truly said, whether the matter he takes in hand be great or small, ``nihil tetigit quod non ornavit,''\ldots 

\hfill J. J. Sylvester

\item The mathematical talent of Cayley was characterized by clearness and extreme elegance of analytical form; it was re-enforced by an incomparable capacity for work which has caused the distinguished scholar to be compared with Cauchy.

\hfill C. Hermite
\end{advice}
\end{document}

Hence, (partial output)---

enter image description here

You must log in to answer this question.

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