Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit baacc08

Browse files
committed
Turn \input, \include, and \verbatiminput into XInclude elements instead
of something ad-hoc.
1 parent bf99017 commit baacc08

2 files changed

Lines changed: 14 additions & 10 deletions

File tree

Doc/tools/sgmlconv/conversion.xml

Lines changed: 13 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -184,7 +184,7 @@
184184

185185
<!-- "See also:" sections. -->
186186
<macro name="seemodule">
187-
<attribute name="ref" optional="yes"/>
187+
<attribute name="" optional="yes"/>
188188
<attribute name="name"/>
189189
<child name="description"/>
190190
</macro>
@@ -279,11 +279,11 @@
279279
</macro>
280280

281281
<!-- Entity management. -->
282-
<macro name="include">
283-
<attribute name="source"/>
282+
<macro name="include" outputname="xi:include">
283+
<attribute name="href"/>
284284
</macro>
285-
<macro name="input">
286-
<attribute name="source"/>
285+
<macro name="input" outputname="xi:include">
286+
<attribute name="href"/>
287287
</macro>
288288

289289
<!-- Large-scale document structure. -->
@@ -300,7 +300,11 @@
300300
endcloses="chapter chapter* section section*
301301
subsection subsection*
302302
subsubsection subsubsection*
303-
paragraph paragraph* subparagraph subparagraph*"/>
303+
paragraph paragraph* subparagraph
304+
subparagraph*">
305+
<attribute name="xmlns:xi"
306+
>http://www.w3.org/2001/XInclude</attribute>
307+
</environment>
304308

305309
<macro name="chapter"
306310
closes="chapter chapter* section section* subsection subsection*
@@ -458,9 +462,9 @@
458462
<!-- not used anywhere, but it's a standard LaTeXism -->
459463
<attribute name="spaces">visible</attribute>
460464
</environment>
461-
<macro name="verbatiminput" ouptutname="input">
462-
<attribute name="verbatim">yes</attribute>
463-
<attribute name="source"/>
465+
<macro name="verbatiminput" ouptutname="xi:include">
466+
<attribute name="parse">text</attribute>
467+
<attribute name="href"/>
464468
</macro>
465469

466470
<!-- Table markup. -->

Doc/tools/sgmlconv/docfixer.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -615,7 +615,7 @@ def move_elements_by_name(doc, source, dest, name, sep=None):
615615

616616
PARA_LEVEL_PRECEEDERS = (
617617
"setindexsubitem", "author",
618-
"stindex", "obindex", "COMMENT", "label", "input", "title",
618+
"stindex", "obindex", "COMMENT", "label", "xi:include", "title",
619619
"versionadded", "versionchanged", "declaremodule", "modulesynopsis",
620620
"moduleauthor", "indexterm", "leader",
621621
)

0 commit comments

Comments
 (0)