From Wiki
< Command
Revision as of 20:20, 25 September 2020 by Taco (talk | contribs) (Created page with "Documentation for \writetolist")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search



The command \writetolist is used to write entries to a defined list.


...=...,...inherits from \setuplist

list The name of a list defined with \definelist
number The "item number"
text Actual text


If you use this command after an unnumbered section commands beware that it will become a candidate for a page break. A workaround is:
\subject{\bf My title!}
\writetolist[myrandompart]{}{It's a test}

However, according to mailing list messages (from 2010), keep in mind that it introduces 'something' in the text stream, so when whitespace is setup, in some cases you can get some extra. Also, this box can end up on the current page or the next one, depending on the circumstances. In practice it's no real problem as one will do explicit writes inside boxes or so. I.e., just bind the write to some text.

In addition you might get spurious spaces after this command. So it is best to add a % sign after it.

The default table of contents is combined list. To write to it one has to choose the level to which it should be inserted: \writetolist[chapter]{1.}{Chapter list entry A}, \writetolist[section]{1.1}{Section list entry A}, etc.


Example 1


  \section{Sec 1}
  \writetolist[Reprints]{1.}{List entry A}%
  \writetolist[Reprints]{}{With no number}%
  \subsection{Subsec 1}
  \writetolist[Reprints]{2.}{List entry B}%


See also

Help from ConTeXt-Mailinglist/Forum

All issues with: