|
From: Günter M. <mi...@us...> - 2017-05-04 18:24:09
|
- **status**: open --> closed-fixed
- **Group**: --> None
- **Comment**:
The "class wrapper" for environments (block-level elements) is not in the SVN repo.
---
** [patches:#99] latex2e: Handle classes for bullet & field lists**
**Status:** closed-fixed
**Group:** None
**Created:** Thu Nov 15, 2012 03:22 PM UTC by Kirill Smelkov
**Last Updated:** Wed Feb 08, 2017 08:53 PM UTC
**Owner:** nobody
latex2e: Handle classes for bullet lists
For example authors could customize documents as follows:
.. class:: compact
\- item 1
\- item 2
\- item 3
and expect the writer to apply the class. This works for html writer,
but not yet for latex2e/xetex and that's why this patch is here.
Usual rules for customizing rendering for classed elements is done - for
class \`compact\`, if stylesheet provides an environment named
DUitemizecompact, it will be used, otherwise the default itemize.
Personally, for compact lists I use
\newenvironment\{DUitemizecompact\}\{%
\begingroup%
\small%
\begin\{itemize\}%
\itemsep=0pt\parskip=0pt%
\}\{%
\end\{itemize\}%
\endgroup%
\}
which make text a bit smaller and tightens inter-line gaps.
NOTES:
\* There is no \provideenvironment in LaTeX, so plain \newenviroment is used.
\* The implementation of DUitemize environment is a bit cumbersome.
That's because it is not possible to pass arguments to
end<something> when defining environments and because my TeX foo is
probably not high enough. \(help appreciated\)
\* I've patched the code to emit \begin\{DUitemize\} only when classes
attrubute is present - only to minimize changes to tests, for the
patch not being huge with low signal/noise ratio.
---
Sent from sourceforge.net because doc...@li... is subscribed to https://sourceforge.net/p/docutils/patches/
To unsubscribe from further messages, a project admin can change settings at https://sourceforge.net/p/docutils/admin/patches/options. Or, if this is a mailing list, you can unsubscribe from the mailing list. |