GeneralProcessList, SplitList and Xparse

LaTeX specific issues not fitting into one of the other forums of this category.
Post Reply
mhayes
Posts: 3
Joined: Tue May 01, 2012 12:07 am

ProcessList, SplitList and Xparse

Post by mhayes »

Currently, I'm attempting to use processlist and splitlist. However, it doesn't seem to recognize these, so to find out if I was inputting it correctly, I was using some sample code that was posted on these forums that supposedly worked:

Code: Select all

\documentclass{article}
\usepackage{xparse}
\NewDocumentCommand\mylist{>{\SplitList{;}}m}
  {
    \begin{itemize}
      \ProcessList {#1} { \insertitem}
    \end{itemize}
  }
\newcommand\insertitem[1]{\item #1}

\begin{document}
Short list:
\mylist{a;b}

Longer list:
\mylist{a;b;c;d}

List within a list:
\mylist{a;b\mylist{A;B;C;D};c;d}
\end{document}
However, instead of a bulleted list, what I get instead is something similar to this:
Short list:
ab

Longer list:
abcd

and so on. I'm using TeXLive 2011, so it shouldn't be an issue of it being out of date. Is there a reason that this isn't being parsed correctly?

Recommended reading 2024:

LaTeXguide.org • LaTeX-Cookbook.net • TikZ.org

NEW: TikZ book now 40% off at Amazon.com for a short time.

And: Currently, Packt sells ebooks for $4.99 each if you buy 5 of their over 1000 ebooks. If you choose only a single one, $9.99. How about combining 3 LaTeX books with Python, gnuplot, mathplotlib, Matlab, ChatGPT or other AI books? Epub and PDF. Bundle (3 books, add more for higher discount): https://packt.link/MDH5p

Stefan Kottwitz
Site Admin
Posts: 10324
Joined: Mon Mar 10, 2008 9:44 pm

Re: ProcessList, SplitList and Xparse

Post by Stefan Kottwitz »

Hi,

welcome to the board!

I'm using TeX Live 2011 too, but I updated from time to time. And I get bulleted lists with this code. So I recommend to consider updating.

Stefan
LaTeX.org admin
mhayes
Posts: 3
Joined: Tue May 01, 2012 12:07 am

Re: ProcessList, SplitList and Xparse

Post by mhayes »

Ah, thanks for suggesting an update. I recently downloaded 2011 so I figured that it would be current, but updating solved my issue!
Post Reply