diff options
| author | milde <milde@929543f6-e4f2-0310-98a6-ba3bd3dd1d04> | 2009-01-30 13:37:26 +0000 |
|---|---|---|
| committer | milde <milde@929543f6-e4f2-0310-98a6-ba3bd3dd1d04> | 2009-01-30 13:37:26 +0000 |
| commit | 0ab970fa30912a440c46df4f7aeac1fe990e13f3 (patch) | |
| tree | 6bc1caba30561b3c042ff5bcd519c2f4bc393288 /docutils/test/functional/input | |
| parent | 5c62d143244b966f4b65891af12ccebbe1f6a922 (diff) | |
| download | docutils-0ab970fa30912a440c46df4f7aeac1fe990e13f3.tar.gz | |
latex2e writer: backwards compatible implementation of failsave custom roles
git-svn-id: http://svn.code.sf.net/p/docutils/code/trunk@5862 929543f6-e4f2-0310-98a6-ba3bd3dd1d04
Diffstat (limited to 'docutils/test/functional/input')
| -rw-r--r-- | docutils/test/functional/input/data/custom_roles_latex.txt | 28 | ||||
| -rw-r--r-- | docutils/test/functional/input/data/option_lists.txt (renamed from docutils/test/functional/input/data/latex2e.txt) | 11 | ||||
| -rw-r--r-- | docutils/test/functional/input/standalone_rst_latex.txt | 16 |
3 files changed, 42 insertions, 13 deletions
diff --git a/docutils/test/functional/input/data/custom_roles_latex.txt b/docutils/test/functional/input/data/custom_roles_latex.txt new file mode 100644 index 000000000..cc423fcf4 --- /dev/null +++ b/docutils/test/functional/input/data/custom_roles_latex.txt @@ -0,0 +1,28 @@ +Custom Roles in LaTeX +--------------------- + +* Role names and class arguments are are converted to conform to the regular + expression ``[a-z][-a-z0-9]*`` (all non-conforming characters are replaced + by a hyphen, all letters are downcased). + + Class arguments may contain numbers and hyphens, which need special + treatment in LaTeX command names. + + .. role:: custom4 + :class: large custom4 small_caps custom.role custom\role + + :custom4:`Interpreted Text` + + +* With LaTeX, roles can be styled within the document using the `raw` + directive. + + .. raw:: latex + + \newcommand{\docutilsrolelarge}[1]{{\large #1}} + \makeatletter + \@namedef{docutilsrolesmall-caps}{\textsc} + \@namedef{docutilsrolecustom4}{\textbf} + \makeatother + + :custom4:`Interpreted Text` in large, bold, small-caps. diff --git a/docutils/test/functional/input/data/latex2e.txt b/docutils/test/functional/input/data/option_lists.txt index 223831c16..285143244 100644 --- a/docutils/test/functional/input/data/latex2e.txt +++ b/docutils/test/functional/input/data/option_lists.txt @@ -1,14 +1,7 @@ -Some Tests for the LaTeX2e Writer -================================= - -These tests have been written to exercise some unusual combinations of -syntax elements which may cause trouble for the LaTeX writer but do -not need to be tested with other writers (e.g. the HTML writer). - -This file is user by the standalone_rst_latex test. +.. This file is used by the standalone_rst_latex test. Option lists -============ +------------ The LaTeX-2e description environment is used for definition lists. The definition is continued on the same line as the term, this should diff --git a/docutils/test/functional/input/standalone_rst_latex.txt b/docutils/test/functional/input/standalone_rst_latex.txt index 787bbde58..06c9abffd 100644 --- a/docutils/test/functional/input/standalone_rst_latex.txt +++ b/docutils/test/functional/input/standalone_rst_latex.txt @@ -1,16 +1,24 @@ .. include:: data/standard.txt +.. the standalone_rst_html4css1.txt document includes this: + .. include:: data/header_footer.txt + Applicable for latex too? [GM] .. include:: data/table_colspan.txt .. include:: data/table_rowspan.txt - +.. include:: data/custom_roles.txt Tests for the LaTeX writer ========================== -.. include:: data/latex2e.txt +Test syntax elements which may cause trouble for the LaTeX writer but might +not need to be tested with other writers (e.g. the HTML writer). +.. include:: data/custom_roles_latex.txt +.. include:: data/option_lists.txt .. include:: data/nonalphanumeric.txt .. include:: data/unicode.txt -.. include:: data/custom_roles.txt +.. unusual combinations (from newlatex, should we test them) + .. include:: data/latex.txt -.. include:: data/errors.txt +.. end of the special tests for the LaTeX writer +.. include:: data/errors.txt |
