From 608f4cf68d51bd72da4a582b6746772d75286ab6 Mon Sep 17 00:00:00 2001 From: wiemann Date: Tue, 26 Apr 2005 23:03:00 +0000 Subject: Added the rest of the new LaTeX writer (I accidentally committed newlatex.py together with nodes.py). To test the new LaTeX writer you must (currently) specify tools/latex.tex as a stylesheet. You can use test/functional/input/standalone_rst_latex.txt as input document. Note that the writer is not yet complete; I'm checking it in to the trunk anyway because I don't want to have to merge changes from the trunk to a branch. Things to do: * Implement support for missing elements. * Restructure. * Add tests for a lot of special cases. * Write documentation, esp. how to customize the behavior. git-svn-id: http://svn.code.sf.net/p/docutils/code/trunk/docutils@3260 929543f6-e4f2-0310-98a6-ba3bd3dd1d04 --- tools/rst2newlatex.py | 27 +++++++++++++++++++++++++++ 1 file changed, 27 insertions(+) create mode 100755 tools/rst2newlatex.py (limited to 'tools/rst2newlatex.py') diff --git a/tools/rst2newlatex.py b/tools/rst2newlatex.py new file mode 100755 index 000000000..46524753f --- /dev/null +++ b/tools/rst2newlatex.py @@ -0,0 +1,27 @@ +#!/usr/bin/env python + +# Author: David Goodger +# Contact: goodger@users.sourceforge.net +# Revision: $Revision$ +# Date: $Date$ +# Copyright: This module has been placed in the public domain. + +""" +A minimal front end to the Docutils Publisher, producing LaTeX using +the new LaTeX writer. +""" + +try: + import locale + locale.setlocale(locale.LC_ALL, '') +except: + pass + +from docutils.core import publish_cmdline, default_description + + +description = ('Generates LaTeX documents from standalone reStructuredText ' + 'sources. This writer is EXPERIMENTAL and should not be used ' + 'in a production environment. ' + default_description) + +publish_cmdline(writer_name='newlatex2e', description=description) -- cgit v1.2.1