jgm/pandoc — pull request #1571 by jlduran (2014-08-27 20:43:23+00:00)
Title: LaTeX writer: Use a declaration for tight lists

Currently, pandoc has hard-coded the following in order to make tight lists in LaTeX:

```hs
text "\\itemsep1pt\\parskip0pt\\parsep0pt"
```

Which is fine, but does not allow customizations. For example, the `memoir` class already has a `\tightlist` declaration for this purpose:

```tex
\newcommand{\tightlist}{%
\setlength{\itemsep}{0pt}\setlength{\parskip}{0pt}}
```

I'm proposing to use a similar solution:

```diff
@@ In Writers/LaTeX.hs:
-then text "\\itemsep1pt\\parskip0pt\\parsep0pt"
+then text "\\tightlist"

@@ In templates/default.latex:
+\newcommand{\tightlist}{%
+ \setlength{\itemsep}{1pt}\setlength{\parskip}{0pt}\setlength{\parsep}{0pt}}
```

This allows us to customize the tightness to our needs.

If a person is using a custom LaTeX template (not based upon the `memoir` class), the `\tightlist` declaration must be added.