Skip to content

Commit

Permalink
fix: Improve pagination in text output (#1019)
Browse files Browse the repository at this point in the history
This fixes an edge case text pagination.
  • Loading branch information
kesara authored Jul 27, 2023
1 parent 656a6ba commit fa1ad02
Show file tree
Hide file tree
Showing 23 changed files with 117 additions and 116 deletions.
16 changes: 8 additions & 8 deletions tests/valid/docfile.html
Original file line number Diff line number Diff line change
Expand Up @@ -4,15 +4,15 @@
<meta charset="utf-8">
<meta content="Cherokee,Common,Greek,Latin" name="scripts">
<meta content="initial-scale=1.0" name="viewport">
<title>Xml2rfc Vocabulary Version 3 Schema xml2rfc release 3.17.3</title>
<title>Xml2rfc Vocabulary Version 3 Schema xml2rfc release 3.17.4</title>
<meta content="xml2rfc(1)" name="author">
<meta content="
This document provides information about the XML schema implemented in this release of xml2rfc, and the individual elements of that schema. The document is generated from the RNG schema file that is part of the xml2rfc distribution, so schema information in this document should always be in sync with the schema in actual use. The textual descriptions depend on manual updates in order to reflect the implementation.
" name="description">
<meta content="xml2rfc 3.17.3" name="generator">
<meta content="xml2rfc-docs-3.17.3" name="ietf.draft">
<meta content="xml2rfc 3.17.4" name="generator">
<meta content="xml2rfc-docs-3.17.4" name="ietf.draft">
<link href="tests/out/docfile.xml" rel="alternate" type="application/rfc+xml">
<link href="#copyright" rel="license">
<link href="xml2rfc.css" rel="stylesheet">
Expand All @@ -24,7 +24,7 @@
<thead><tr>
<td class="left"></td>
<td class="center">Xml2rfc Vocabulary V3 Schema</td>
<td class="right">June 2023</td>
<td class="right">July 2023</td>
</tr></thead>
<tfoot><tr>
<td class="left">xml2rfc(1)</td>
Expand All @@ -39,7 +39,7 @@
<dd class="workgroup">xml2rfc(1)</dd>
<dt class="label-published">Published:</dt>
<dd class="published">
<time datetime="2023-06-14" class="published">14 June 2023</time>
<time datetime="2023-07-26" class="published">26 July 2023</time>
</dd>
<dt class="label-authors">Author:</dt>
<dd class="authors">
Expand All @@ -49,7 +49,7 @@
</dd>
</dl>
</div>
<h1 id="title">Xml2rfc Vocabulary Version 3 Schema<br>xml2rfc release 3.17.3</h1>
<h1 id="title">Xml2rfc Vocabulary Version 3 Schema<br>xml2rfc release 3.17.4</h1>
<section id="section-abstract">
<h2 id="abstract"><a href="#abstract" class="selfRef">Abstract</a></h2>
<p id="section-abstract-1">
Expand Down Expand Up @@ -371,7 +371,7 @@ <h2 id="name-introduction">
<p id="section-1-5">
The latest version of this documentation is available in HTML form at <span><a href="https://ietf-tools.github.io/xml2rfc/">https://ietf-tools.github.io/xml2rfc/</a></span>.<a href="#section-1-5" class="pilcrow"></a></p>
<p id="section-1-6">
This documentation applies to xml2rfc version 3.17.3.<a href="#section-1-6" class="pilcrow"></a></p>
This documentation applies to xml2rfc version 3.17.4.<a href="#section-1-6" class="pilcrow"></a></p>
</section>
<section id="section-2">
<h2 id="name-schema-version-3-elements">
Expand Down Expand Up @@ -6366,7 +6366,7 @@ <h2 id="name-xml2rfc-documentation-templ">
<p id="appendix-D-1">

The following variables are available for use in an xml2rfc
manpage Jinja2 template, as of xml2rfc version 3.17.3:<a href="#appendix-D-1" class="pilcrow"></a></p>
manpage Jinja2 template, as of xml2rfc version 3.17.4:<a href="#appendix-D-1" class="pilcrow"></a></p>
<span class="break"></span><dl class="dlNewline" id="appendix-D-2">
<dt id="appendix-D-2.1">{{ bare_latin_tags }}:</dt>
<dd style="margin-left: 1.5em" id="appendix-D-2.2"></dd>
Expand Down
12 changes: 6 additions & 6 deletions tests/valid/draft-miek-test.html
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
This version is adapted to work with "xml2rfc" version 2.x.
' name="description">
<meta content="xml2rfc 3.17.3" name="generator">
<meta content="xml2rfc 3.17.4" name="generator">
<meta content="RFC" name="keyword">
<meta content="Request for Comments" name="keyword">
<meta content="I-D" name="keyword">
Expand All @@ -26,16 +26,16 @@
<meta content="Extensible Markup Language" name="keyword">
<meta content="draft-gieben-writing-rfcs-pandoc-02" name="ietf.draft">
<!-- Generator version information:
xml2rfc 3.17.3
xml2rfc 3.17.4
Python 3.10.6
ConfigArgParse 1.5.3
ConfigArgParse 1.7
google-i18n-address 3.1.0
intervaltree 3.1.0
Jinja2 3.1.2
lxml 4.9.2
platformdirs 3.7.0
lxml 4.9.3
platformdirs 3.9.1
pycountry 22.3.5
PyYAML 6.0
PyYAML 6.0.1
requests 2.31.0
setuptools 67.4.0
six 1.16.0
Expand Down
6 changes: 3 additions & 3 deletions tests/valid/draft-template-old.exp.xml
Original file line number Diff line number Diff line change
Expand Up @@ -479,7 +479,7 @@ main(int argc, char *argv[])
<author fullname="S. Bradner" initials="S." surname="Bradner"/>
<date month="March" year="1997"/>
<abstract>
<t>In many standards track documents several words are used to signify the requirements in the specification. These words are often capitalized. This document defines these words as they should be interpreted in IETF documents. This document specifies an Internet Best Current Practices for the Internet Community, and requests discussion and suggestions for improvements.</t>
<t>In many standards track documents several words are used to signify the requirements in the specification. These words are often capitalized. This document defines these words as they should be interpreted in IETF documents. This document specifies an Internet Best Current Practices for the Internet Community, and requests discussion and suggestions for improvements.</t>
</abstract>
</front>
<seriesInfo name="BCP" value="14"/>
Expand Down Expand Up @@ -511,7 +511,7 @@ main(int argc, char *argv[])
<author fullname="M. Rose" initials="M." surname="Rose"/>
<date month="June" year="1999"/>
<abstract>
<t>This memo presents a technique for using XML (Extensible Markup Language) as a source format for documents in the Internet-Drafts (I-Ds) and Request for Comments (RFC) series. This memo provides information for the Internet community.</t>
<t>This memo presents a technique for using XML (Extensible Markup Language) as a source format for documents in the Internet-Drafts (I-Ds) and Request for Comments (RFC) series. This memo provides information for the Internet community.</t>
</abstract>
</front>
<seriesInfo name="RFC" value="2629"/>
Expand All @@ -523,7 +523,7 @@ main(int argc, char *argv[])
<author fullname="B. Korver" initials="B." surname="Korver"/>
<date month="July" year="2003"/>
<abstract>
<t>All RFCs are required to have a Security Considerations section. Historically, such sections have been relatively weak. This document provides guidelines to RFC authors on how to write a good Security Considerations section. This document specifies an Internet Best Current Practices for the Internet Community, and requests discussion and suggestions for improvements.</t>
<t>All RFCs are required to have a Security Considerations section. Historically, such sections have been relatively weak. This document provides guidelines to RFC authors on how to write a good Security Considerations section. This document specifies an Internet Best Current Practices for the Internet Community, and requests discussion and suggestions for improvements.</t>
</abstract>
</front>
<seriesInfo name="BCP" value="72"/>
Expand Down
10 changes: 5 additions & 5 deletions tests/valid/draft-template-old.prepped.xml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
<?xml version='1.0' encoding='utf-8'?>
<rfc xmlns:xi="http://www.w3.org/2001/XInclude" version="3" category="info" consensus="false" docName="draft-ietf-xml2rfc-template-05" indexInclude="true" ipr="trust200902" prepTime="2023-01-17T08:46:47" scripts="Common,Latin" sortRefs="true" submissionType="IETF" symRefs="true" tocDepth="4" tocInclude="true" xml:lang="en">
<!-- xml2rfc v2v3 conversion 3.15.3 -->
<rfc xmlns:xi="http://www.w3.org/2001/XInclude" version="3" category="info" docName="draft-ietf-xml2rfc-template-05" ipr="trust200902" obsoletes="" updates="" submissionType="IETF" xml:lang="en" tocInclude="true" tocDepth="4" symRefs="true" sortRefs="true" consensus="false" prepTime="2023-07-26T21:42:41" indexInclude="true" scripts="Common,Latin">
<!-- xml2rfc v2v3 conversion 3.17.4 -->



Expand Down Expand Up @@ -556,7 +556,7 @@ main(int argc, char *argv[])
<author fullname="S. Bradner" initials="S." surname="Bradner"/>
<date month="March" year="1997"/>
<abstract>
<t indent="0">In many standards track documents several words are used to signify the requirements in the specification. These words are often capitalized. This document defines these words as they should be interpreted in IETF documents. This document specifies an Internet Best Current Practices for the Internet Community, and requests discussion and suggestions for improvements.</t>
<t indent="0">In many standards track documents several words are used to signify the requirements in the specification. These words are often capitalized. This document defines these words as they should be interpreted in IETF documents. This document specifies an Internet Best Current Practices for the Internet Community, and requests discussion and suggestions for improvements.</t>
</abstract>
</front>
<seriesInfo name="BCP" value="14"/>
Expand Down Expand Up @@ -669,7 +669,7 @@ main(int argc, char *argv[])
<author fullname="M. Rose" initials="M." surname="Rose"/>
<date month="June" year="1999"/>
<abstract>
<t indent="0">This memo presents a technique for using XML (Extensible Markup Language) as a source format for documents in the Internet-Drafts (I-Ds) and Request for Comments (RFC) series. This memo provides information for the Internet community.</t>
<t indent="0">This memo presents a technique for using XML (Extensible Markup Language) as a source format for documents in the Internet-Drafts (I-Ds) and Request for Comments (RFC) series. This memo provides information for the Internet community.</t>
</abstract>
</front>
<seriesInfo name="RFC" value="2629"/>
Expand All @@ -682,7 +682,7 @@ main(int argc, char *argv[])
<author fullname="B. Korver" initials="B." surname="Korver"/>
<date month="July" year="2003"/>
<abstract>
<t indent="0">All RFCs are required to have a Security Considerations section. Historically, such sections have been relatively weak. This document provides guidelines to RFC authors on how to write a good Security Considerations section. This document specifies an Internet Best Current Practices for the Internet Community, and requests discussion and suggestions for improvements.</t>
<t indent="0">All RFCs are required to have a Security Considerations section. Historically, such sections have been relatively weak. This document provides guidelines to RFC authors on how to write a good Security Considerations section. This document specifies an Internet Best Current Practices for the Internet Community, and requests discussion and suggestions for improvements.</t>
</abstract>
</front>
<seriesInfo name="BCP" value="72"/>
Expand Down
8 changes: 4 additions & 4 deletions tests/valid/draft-template-old.v2v3.xml
Original file line number Diff line number Diff line change
Expand Up @@ -33,7 +33,7 @@
<?rfc multiple-initials="yes" ?>
<!-- end of list of popular I-D processing instructions -->
<rfc xmlns:xi="http://www.w3.org/2001/XInclude" category="info" docName="draft-ietf-xml2rfc-template-05" ipr="trust200902" obsoletes="" updates="" submissionType="IETF" xml:lang="en" tocInclude="true" tocDepth="4" symRefs="true" sortRefs="true" version="3">
<!-- xml2rfc v2v3 conversion 3.15.3 -->
<!-- xml2rfc v2v3 conversion 3.17.4 -->
<?v3xml2rfc silence=".*[Pp]ostal address" ?>
<?v3xml2rfc silence="The document date .*? is more than 3 days away from today's date" ?>
<?v3xml2rfc silence="Found SVG with width or height specified" ?>
Expand Down Expand Up @@ -455,7 +455,7 @@ main(int argc, char *argv[])
<author fullname="S. Bradner" initials="S." surname="Bradner"/>
<date month="March" year="1997"/>
<abstract>
<t>In many standards track documents several words are used to signify the requirements in the specification. These words are often capitalized. This document defines these words as they should be interpreted in IETF documents. This document specifies an Internet Best Current Practices for the Internet Community, and requests discussion and suggestions for improvements.</t>
<t>In many standards track documents several words are used to signify the requirements in the specification. These words are often capitalized. This document defines these words as they should be interpreted in IETF documents. This document specifies an Internet Best Current Practices for the Internet Community, and requests discussion and suggestions for improvements.</t>
</abstract>
</front>
<seriesInfo name="BCP" value="14"/>
Expand Down Expand Up @@ -484,7 +484,7 @@ main(int argc, char *argv[])
<author fullname="M. Rose" initials="M." surname="Rose"/>
<date month="June" year="1999"/>
<abstract>
<t>This memo presents a technique for using XML (Extensible Markup Language) as a source format for documents in the Internet-Drafts (I-Ds) and Request for Comments (RFC) series. This memo provides information for the Internet community.</t>
<t>This memo presents a technique for using XML (Extensible Markup Language) as a source format for documents in the Internet-Drafts (I-Ds) and Request for Comments (RFC) series. This memo provides information for the Internet community.</t>
</abstract>
</front>
<seriesInfo name="RFC" value="2629"/>
Expand All @@ -497,7 +497,7 @@ main(int argc, char *argv[])
<author fullname="B. Korver" initials="B." surname="Korver"/>
<date month="July" year="2003"/>
<abstract>
<t>All RFCs are required to have a Security Considerations section. Historically, such sections have been relatively weak. This document provides guidelines to RFC authors on how to write a good Security Considerations section. This document specifies an Internet Best Current Practices for the Internet Community, and requests discussion and suggestions for improvements.</t>
<t>All RFCs are required to have a Security Considerations section. Historically, such sections have been relatively weak. This document provides guidelines to RFC authors on how to write a good Security Considerations section. This document specifies an Internet Best Current Practices for the Internet Community, and requests discussion and suggestions for improvements.</t>
</abstract>
</front>
<seriesInfo name="BCP" value="72"/>
Expand Down
6 changes: 3 additions & 3 deletions tests/valid/draft-template.exp.xml
Original file line number Diff line number Diff line change
Expand Up @@ -420,7 +420,7 @@ main(int argc, char *argv[])
<author fullname="S. Bradner" initials="S." surname="Bradner"/>
<date month="March" year="1997"/>
<abstract>
<t>In many standards track documents several words are used to signify the requirements in the specification. These words are often capitalized. This document defines these words as they should be interpreted in IETF documents. This document specifies an Internet Best Current Practices for the Internet Community, and requests discussion and suggestions for improvements.</t>
<t>In many standards track documents several words are used to signify the requirements in the specification. These words are often capitalized. This document defines these words as they should be interpreted in IETF documents. This document specifies an Internet Best Current Practices for the Internet Community, and requests discussion and suggestions for improvements.</t>
</abstract>
</front>
<seriesInfo name="BCP" value="14"/>
Expand Down Expand Up @@ -448,7 +448,7 @@ main(int argc, char *argv[])
<author fullname="M. Rose" initials="M." surname="Rose"/>
<date month="June" year="1999"/>
<abstract>
<t>This memo presents a technique for using XML (Extensible Markup Language) as a source format for documents in the Internet-Drafts (I-Ds) and Request for Comments (RFC) series. This memo provides information for the Internet community.</t>
<t>This memo presents a technique for using XML (Extensible Markup Language) as a source format for documents in the Internet-Drafts (I-Ds) and Request for Comments (RFC) series. This memo provides information for the Internet community.</t>
</abstract>
</front>
<seriesInfo name="RFC" value="2629"/>
Expand All @@ -461,7 +461,7 @@ main(int argc, char *argv[])
<author fullname="B. Korver" initials="B." surname="Korver"/>
<date month="July" year="2003"/>
<abstract>
<t>All RFCs are required to have a Security Considerations section. Historically, such sections have been relatively weak. This document provides guidelines to RFC authors on how to write a good Security Considerations section. This document specifies an Internet Best Current Practices for the Internet Community, and requests discussion and suggestions for improvements.</t>
<t>All RFCs are required to have a Security Considerations section. Historically, such sections have been relatively weak. This document provides guidelines to RFC authors on how to write a good Security Considerations section. This document specifies an Internet Best Current Practices for the Internet Community, and requests discussion and suggestions for improvements.</t>
</abstract>
</front>
<seriesInfo name="BCP" value="72"/>
Expand Down
12 changes: 6 additions & 6 deletions tests/valid/draft-template.html
Original file line number Diff line number Diff line change
Expand Up @@ -11,20 +11,20 @@
Insert an abstract: MANDATORY. This template is for creating an
Internet Draft.
" name="description">
<meta content="xml2rfc 3.17.3" name="generator">
<meta content="xml2rfc 3.17.4" name="generator">
<meta content="template" name="keyword">
<meta content="draft-ietf-xml2rfc-template-05" name="ietf.draft">
<!-- Generator version information:
xml2rfc 3.17.3
xml2rfc 3.17.4
Python 3.10.6
ConfigArgParse 1.5.3
ConfigArgParse 1.7
google-i18n-address 3.1.0
intervaltree 3.1.0
Jinja2 3.1.2
lxml 4.9.2
platformdirs 3.7.0
lxml 4.9.3
platformdirs 3.9.1
pycountry 22.3.5
PyYAML 6.0
PyYAML 6.0.1
requests 2.31.0
setuptools 67.4.0
six 1.16.0
Expand Down
Loading

0 comments on commit fa1ad02

Please sign in to comment.