From: <sm...@us...> - 2013-12-15 11:34:28
|
Revision: 7741 http://sourceforge.net/p/docutils/code/7741 Author: smerten Date: 2013-12-15 11:34:24 +0000 (Sun, 15 Dec 2013) Log Message: ----------- Added support for <substitution_reference>. Modified Paths: -------------- trunk/sandbox/xml2rst/global.log trunk/sandbox/xml2rst/tag.log trunk/sandbox/xml2rst/version.py trunk/sandbox/xml2rst/xml2rstlib/xml2rst-noexslt.xsl trunk/sandbox/xml2rst/xml2rstlib/xml2rst-nopy.xsl trunk/sandbox/xml2rst/xml2rstlib/xml2rst.xsl Added Paths: ----------- trunk/sandbox/xml2rst/tests/enriched/ trunk/sandbox/xml2rst/tests/enriched/expected/ trunk/sandbox/xml2rst/tests/enriched/expected/substitutionReference.rst trunk/sandbox/xml2rst/tests/enriched/filterunit.cfg trunk/sandbox/xml2rst/tests/enriched/input/ trunk/sandbox/xml2rst/tests/enriched/input/substitutionReference.xml trunk/sandbox/xml2rst/tests/enriched/original/ trunk/sandbox/xml2rst/tests/enriched/original/substitutionReference.rst trunk/sandbox/xml2rst/tests/enriched/readable/ trunk/sandbox/xml2rst/tests/enriched/readable/substitutionReference.xml trunk/sandbox/xml2rst/tests.xalan/enriched/ trunk/sandbox/xml2rst/tests.xalan/enriched/filterunit.cfg trunk/sandbox/xml2rst/tests.xsltproc/enriched/ trunk/sandbox/xml2rst/tests.xsltproc/enriched/filterunit.cfg Modified: trunk/sandbox/xml2rst/global.log =================================================================== --- trunk/sandbox/xml2rst/global.log 2013-12-07 11:49:02 UTC (rev 7740) +++ trunk/sandbox/xml2rst/global.log 2013-12-15 11:34:24 UTC (rev 7741) @@ -1,4 +1,108 @@ ************************************** +Date: Sun Dec 15 12:11:23 CET 2013 +Author: stefan +Tag: xml2rst_1_244 + +-------------------------------------- +Update of /home/stefan/vault/sm/xml2rst/tests.xalan/enriched +In directory eskebo:/home/stefan/free/xml2rst/tests.xalan/enriched + +Added Files: + filterunit.cfg + +-------------------------------------- +Log Message: +Added tests for no-EXSLT implementation. +************************************** +Date: Sat Dec 14 18:09:05 CET 2013 +Author: stefan +Tag: xml2rst_1_243 + +-------------------------------------- +Update of /home/stefan/vault/sm/xml2rst/tests.xsltproc/enriched +In directory eskebo:/home/stefan/free/xml2rst/tests.xsltproc/enriched + +Added Files: + filterunit.cfg + +-------------------------------------- +Log Message: +Added tests for no-Python implementation. +************************************** +Date: Sat Dec 14 18:01:34 CET 2013 +Author: stefan +Tag: xml2rst_1_242 + +-------------------------------------- +Update of /home/stefan/vault/sm/xml2rst/xml2rstlib +In directory eskebo:/home/stefan/free/xml2rst/xml2rstlib + +Modified Files: + xml2rst.xsl + +-------------------------------------- +Log Message: +Added support for <substitution_reference>. +************************************** +Date: Sat Dec 14 17:56:32 CET 2013 +Author: stefan +Tag: xml2rst_1_241 + +-------------------------------------- +Update of /home/stefan/vault/sm/xml2rst/tests +In directory eskebo:/home/stefan/free/xml2rst/tests + +Modified Files: + Makefile + +-------------------------------------- +Update of /home/stefan/vault/sm/xml2rst/tests/enriched +In directory eskebo:/home/stefan/free/xml2rst/tests/enriched + +Added Files: + Makefile filterunit.cfg + +-------------------------------------- +Update of /home/stefan/vault/sm/xml2rst/tests/enriched/input +In directory eskebo:/home/stefan/free/xml2rst/tests/enriched/input + +Added Files: + substitutionReference.xml + +-------------------------------------- +Update of /home/stefan/vault/sm/xml2rst/tests/enriched/readable +In directory eskebo:/home/stefan/free/xml2rst/tests/enriched/readable + +Added Files: + substitutionReference.xml + +-------------------------------------- +Log Message: +Completed test for `substitution_reference` in a new test suite for +enriched tests. Do not work yet. +************************************** +Date: Sat Dec 14 17:41:27 CET 2013 +Author: stefan +Tag: xml2rst_1_240 + +-------------------------------------- +Update of /home/stefan/vault/sm/xml2rst/tests/simple/expected +In directory eskebo:/home/stefan/free/xml2rst/tests/simple/expected + +Added Files: + substitutionReference.rst + +-------------------------------------- +Update of /home/stefan/vault/sm/xml2rst/tests/simple/original +In directory eskebo:/home/stefan/free/xml2rst/tests/simple/original + +Added Files: + substitutionReference.rst + +-------------------------------------- +Log Message: +Added tests for `substitution_reference`. Do not work yet. +************************************** Date: Sat Dec 7 12:41:20 CET 2013 Author: stefan Tag: xml2rst_1_239 Modified: trunk/sandbox/xml2rst/tag.log =================================================================== --- trunk/sandbox/xml2rst/tag.log 2013-12-07 11:49:02 UTC (rev 7740) +++ trunk/sandbox/xml2rst/tag.log 2013-12-15 11:34:24 UTC (rev 7741) @@ -1 +1 @@ -xml2rst_1_239 +xml2rst_1_244 Index: trunk/sandbox/xml2rst/tests/enriched =================================================================== --- trunk/sandbox/xml2rst/tests/enriched 2013-12-07 11:49:02 UTC (rev 7740) +++ trunk/sandbox/xml2rst/tests/enriched 2013-12-15 11:34:24 UTC (rev 7741) Property changes on: trunk/sandbox/xml2rst/tests/enriched ___________________________________________________________________ Added: svn:ignore ## -0,0 +1,2 ## +*.gmk +Makefile Added: trunk/sandbox/xml2rst/tests/enriched/expected/substitutionReference.rst =================================================================== --- trunk/sandbox/xml2rst/tests/enriched/expected/substitutionReference.rst (rev 0) +++ trunk/sandbox/xml2rst/tests/enriched/expected/substitutionReference.rst 2013-12-15 11:34:24 UTC (rev 7741) @@ -0,0 +1,6 @@ +.. |simple| replace:: SIMPLE + +.. |two words| replace:: TWO WORDS + +This is a |simple| substitution reference and one consisting of |two +words| split onto two lines. Property changes on: trunk/sandbox/xml2rst/tests/enriched/expected/substitutionReference.rst ___________________________________________________________________ Added: svn:keywords ## -0,0 +1 ## +Author Date Id Revision \ No newline at end of property Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: trunk/sandbox/xml2rst/tests/enriched/filterunit.cfg =================================================================== --- trunk/sandbox/xml2rst/tests/enriched/filterunit.cfg (rev 0) +++ trunk/sandbox/xml2rst/tests/enriched/filterunit.cfg 2013-12-15 11:34:24 UTC (rev 7741) @@ -0,0 +1,8 @@ +# These tests use input which is enriched compared to the original `rst2xml` +# output. + +inputExtension = .xml +expectedExtension = .rst + +command = ../../xml2rst.py +arguments = $< Added: trunk/sandbox/xml2rst/tests/enriched/input/substitutionReference.xml =================================================================== --- trunk/sandbox/xml2rst/tests/enriched/input/substitutionReference.xml (rev 0) +++ trunk/sandbox/xml2rst/tests/enriched/input/substitutionReference.xml 2013-12-15 11:34:24 UTC (rev 7741) @@ -0,0 +1,3 @@ +<?xml version="1.0" encoding="utf-8"?> +<document source="original/substitutionReference.rst"><substitution_definition names="simple">SIMPLE</substitution_definition><substitution_definition names="two\ words">TWO WORDS</substitution_definition><paragraph>This is a <substitution_reference refname="simple">simple</substitution_reference> substitution reference and one consisting of <substitution_reference refname="two words">two +words</substitution_reference> split onto two lines.</paragraph></document> \ No newline at end of file Property changes on: trunk/sandbox/xml2rst/tests/enriched/input/substitutionReference.xml ___________________________________________________________________ Added: svn:keywords ## -0,0 +1 ## +Author Date Id Revision \ No newline at end of property Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: trunk/sandbox/xml2rst/tests/enriched/original/substitutionReference.rst =================================================================== --- trunk/sandbox/xml2rst/tests/enriched/original/substitutionReference.rst (rev 0) +++ trunk/sandbox/xml2rst/tests/enriched/original/substitutionReference.rst 2013-12-15 11:34:24 UTC (rev 7741) @@ -0,0 +1,6 @@ +.. |simple| replace:: SIMPLE + +.. |two words| replace:: TWO WORDS + +This is a |simple| substitution reference and one consisting of |two +words| split onto two lines. Property changes on: trunk/sandbox/xml2rst/tests/enriched/original/substitutionReference.rst ___________________________________________________________________ Added: svn:keywords ## -0,0 +1 ## +Author Date Id Revision \ No newline at end of property Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: trunk/sandbox/xml2rst/tests/enriched/readable/substitutionReference.xml =================================================================== --- trunk/sandbox/xml2rst/tests/enriched/readable/substitutionReference.xml (rev 0) +++ trunk/sandbox/xml2rst/tests/enriched/readable/substitutionReference.xml 2013-12-15 11:34:24 UTC (rev 7741) @@ -0,0 +1,7 @@ +<?xml version="1.0" encoding="utf-8"?> +<document source="original/substitutionReference.rst"> + <substitution_definition names="simple">SIMPLE</substitution_definition> + <substitution_definition names="two\ words">TWO WORDS</substitution_definition> + <paragraph>This is a <substitution_reference refname="simple">simple</substitution_reference> substitution reference and one consisting of <substitution_reference refname="two words">two +words</substitution_reference> split onto two lines.</paragraph> +</document> Property changes on: trunk/sandbox/xml2rst/tests/enriched/readable/substitutionReference.xml ___________________________________________________________________ Added: svn:keywords ## -0,0 +1 ## +Author Date Id Revision \ No newline at end of property Added: svn:eol-style ## -0,0 +1 ## +native \ No newline at end of property Added: trunk/sandbox/xml2rst/tests.xalan/enriched/filterunit.cfg =================================================================== --- trunk/sandbox/xml2rst/tests.xalan/enriched/filterunit.cfg (rev 0) +++ trunk/sandbox/xml2rst/tests.xalan/enriched/filterunit.cfg 2013-12-15 11:34:24 UTC (rev 7741) @@ -0,0 +1,3 @@ +include ../common.cfg + +suiteDirectory = ../../tests/enriched Added: trunk/sandbox/xml2rst/tests.xsltproc/enriched/filterunit.cfg =================================================================== --- trunk/sandbox/xml2rst/tests.xsltproc/enriched/filterunit.cfg (rev 0) +++ trunk/sandbox/xml2rst/tests.xsltproc/enriched/filterunit.cfg 2013-12-15 11:34:24 UTC (rev 7741) @@ -0,0 +1,8 @@ +include ../common.cfg + +suiteDirectory = ../../tests/enriched + +<tagWith> + # These tests need Python code + off = quoteBlock quoteOriginal +</tagWith> Modified: trunk/sandbox/xml2rst/version.py =================================================================== --- trunk/sandbox/xml2rst/version.py 2013-12-07 11:49:02 UTC (rev 7740) +++ trunk/sandbox/xml2rst/version.py 2013-12-15 11:34:24 UTC (rev 7741) @@ -1 +1 @@ -version = '1.2.1' +version = '1.3.0' Modified: trunk/sandbox/xml2rst/xml2rstlib/xml2rst-noexslt.xsl =================================================================== --- trunk/sandbox/xml2rst/xml2rstlib/xml2rst-noexslt.xsl 2013-12-07 11:49:02 UTC (rev 7740) +++ trunk/sandbox/xml2rst/xml2rstlib/xml2rst-noexslt.xsl 2013-12-15 11:34:24 UTC (rev 7741) @@ -1839,11 +1839,15 @@ mode="bullet_list"> <xsl:call-template name="u:outputClass"/> - <xsl:call-template - name="u:BandI"/> - <xsl:value-of - select="../@bullet"/> - &tSP; <!-- space after bullet --> + <xsl:if + test="name(*[1]) != 'bullet_list'"> + <!-- Start the list item only if the first child is not another list --> + <xsl:call-template + name="u:BandI"/> + <xsl:value-of + select="../@bullet"/> + &tSP; <!-- space after bullet --> + </xsl:if> <xsl:apply-templates/> </xsl:template> @@ -2529,6 +2533,20 @@ <!-- == inline_element --> <xsl:template + match="substitution_reference"> + <xsl:call-template + name="u:bkslshEscPre"/> + <xsl:text>|</xsl:text> + <xsl:apply-templates/> + <xsl:text>|</xsl:text> + <xsl:call-template + name="u:bkslshEscSuf"/> + </xsl:template> + + <!-- ******************************************************************** --> + + <!-- == inline_element --> + <xsl:template match="emphasis"> <xsl:call-template name="u:bkslshEscPre"/> Modified: trunk/sandbox/xml2rst/xml2rstlib/xml2rst-nopy.xsl =================================================================== --- trunk/sandbox/xml2rst/xml2rstlib/xml2rst-nopy.xsl 2013-12-07 11:49:02 UTC (rev 7740) +++ trunk/sandbox/xml2rst/xml2rstlib/xml2rst-nopy.xsl 2013-12-15 11:34:24 UTC (rev 7741) @@ -1842,11 +1842,15 @@ mode="bullet_list"> <xsl:call-template name="u:outputClass"/> - <xsl:call-template - name="u:BandI"/> - <xsl:value-of - select="../@bullet"/> - &tSP; <!-- space after bullet --> + <xsl:if + test="name(*[1]) != 'bullet_list'"> + <!-- Start the list item only if the first child is not another list --> + <xsl:call-template + name="u:BandI"/> + <xsl:value-of + select="../@bullet"/> + &tSP; <!-- space after bullet --> + </xsl:if> <xsl:apply-templates/> </xsl:template> @@ -2511,6 +2515,20 @@ <!-- == inline_element --> <xsl:template + match="substitution_reference"> + <xsl:call-template + name="u:bkslshEscPre"/> + <xsl:text>|</xsl:text> + <xsl:apply-templates/> + <xsl:text>|</xsl:text> + <xsl:call-template + name="u:bkslshEscSuf"/> + </xsl:template> + + <!-- ******************************************************************** --> + + <!-- == inline_element --> + <xsl:template match="emphasis"> <xsl:call-template name="u:bkslshEscPre"/> Modified: trunk/sandbox/xml2rst/xml2rstlib/xml2rst.xsl =================================================================== --- trunk/sandbox/xml2rst/xml2rstlib/xml2rst.xsl 2013-12-07 11:49:02 UTC (rev 7740) +++ trunk/sandbox/xml2rst/xml2rstlib/xml2rst.xsl 2013-12-15 11:34:24 UTC (rev 7741) @@ -2532,6 +2532,20 @@ <!-- == inline_element --> <xsl:template + match="substitution_reference"> + <xsl:call-template + name="u:bkslshEscPre"/> + <xsl:text>|</xsl:text> + <xsl:apply-templates/> + <xsl:text>|</xsl:text> + <xsl:call-template + name="u:bkslshEscSuf"/> + </xsl:template> + + <!-- ******************************************************************** --> + + <!-- == inline_element --> + <xsl:template match="emphasis"> <xsl:call-template name="u:bkslshEscPre"/> This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |