I'm using the enumitem package with a setlist header-include to customize definition lists, and it's working great, except that no matter what value I give to itemsep the vertical space between items remains unaffected. Similarly, parsep does not work. The other options in my setlist work as expected (leftmargin=15pt, labelwidth=\widthof{\bfseries99}, font=\normalfont). I'm writing in markdown and using YAML metadata and Pandoc to generate a PDF. Here is my metadata, followed by the Pandoc command I've been using:


title: |
    | The Title of This Document Is Itself the Title
author: Me Myself
documentclass: apa7
- doc
- donotrepeattitle
- 12pt
   - \affiliation{Lorem Ipsum Institute}
   - \shorttitle{shortish title}
   - \raggedright
   - \righthyphenmin=62
   - \lefthyphenmin=62
   - \usepackage{hanging}
   - \usepackage{setspace}
   - \setstretch{1.25}
   - \usepackage{enumitem}
   - \setlist[description]{itemsep=1in, leftmargin=15pt, labelwidth=\widthof{\bfseries99}, font=\normalfont}
   - \newfontfamily\GreekToMe[Scale=MatchLowercase]{EB Garamond}
   - \renewcommand{\abstractname}{   }
   - \abstract{\singlespacing\small{Lorem ipsum…}}

Here’s some text. I’m writing entirely in markdown. I am using a definition list as a way to align a bit of dialogue, like so:

: Person A speaks to Person B, and drones on and on and on, just to illustrate why I’m using definition lists. When I used the package hanging, I lost my markdown formatting in the dialogue; e.g. the word “space” in the next line appeared in the PDF as \*space\* instead of *space*. Using the definition list, I get my hanging indent and keep my markdown formatting.

: Person B says, Can I please have some *space*, man?

: Person A says, No can do—even though `itemsep=1in`!

Pandoc command:

$ pandoc --pdf-engine=xelatex input.md -o output.pdf

And here is the resulting PDF: output.pdf

I'm new to using LaTeX and Pandoc and YAML, and I won't be surprised if I'm missing something obvious. But it does seem weird that most options in the setlist are working and the vertical space ones are not.

  • 2
    Welcome to TeX.se. Can simplify your example and make it compilable? And show how you're actually entering the lists in the .md file. Are they raw LaTeX (\begin{description} \item[ ] ... \end{description} or Markdown?
    – Alan Munn
    Feb 22, 2023 at 20:57
  • I've updated the example. I compiled it with the Pandoc command shown, and the result was the same: itemsep has no effect.
    – Mark
    Feb 23, 2023 at 6:07

1 Answer 1


For reasons that I don't understand, pandoc makes extensive use of the macro \tightlist which it seems to insert in every list it generates. The tightlist macro sets the list \itemsep and \parsep to 0pt which is why your changes using enumitem are being overridden. The simplest way to solve this is to simply add the line

   - \let\tightlist\relax

to your header-includes block. This will make \tightlist do nothing, and the settings you set with enumitem will be respected.

Unrelated, but the \affiliation macro is deprecated in the apa7 class. You're apparently supposed to use \authorsaffiliations according to the warning text.

To debug this sort of problem in the future, it can be helpful to have pandoc generate the .tex file instead of the .pdf so that you can inspect its code directly. Of course if you're new to LaTeX this might not be so helpful, but if you become more familiar with it, it will probably be a useful tool for debugging.

  • This worked. Thank you very much. If I did want to look at the LateX code directly, what program would you recommend that would show the code big & clearly? I downloaded TexMaker the other day, and the output code was tiny and cramped.
    – Mark
    Feb 23, 2023 at 19:55
  • In fact, now that tightlist is relaxed, I need to set itemsep to a low negative value to get the spacing I want.
    – Mark
    Feb 23, 2023 at 20:03
  • I use TeXShop which is a mature native IDE. I’m not sure you should be setting itemsep to a negative value.
    – Alan Munn
    Feb 24, 2023 at 0:48
  • I will check out TeXShop, thank you. Are there negative consequences to setting itemsep to a negative number, or a better way to accomplish narrowing vertical spacing in the list, or just bad karma?…
    – Mark
    Feb 24, 2023 at 5:24
  • Not necessarily bad, but it's likely there's a more sensible way to achieve what you want. :)
    – Alan Munn
    Feb 24, 2023 at 14:00

You must log in to answer this question.

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