SF.net SVN: docutils:[9647 ] trunk/docutils

milde--- via Docutils-checkins <[email protected]>
Newsgroups gmane.text.docutils.cvs
Message-ID <[email protected]>
Revision: 9647
          http://sourceforge.net/p/docutils/code/9647
Author:   milde
Date:     2024-04-18 11:18:00 +0000 (Thu, 18 Apr 2024)
Log Message:
-----------
Reconcile Docutils DTD and Document Tree documentation.

There are some cases where docutils.dtd and doctree.txt diverged.
Change so, that the documentation is consistent and matches actual behaviour.

Remove declaration of element `<info>`:

* added to docutils.dtd and nodes.py but not doctree.txt 2004-03-21,
* never used,
* removed from nodes.py 2004-11-09.

Remove `<decoration>` from content model of `<section>` elements:

* added to docutils.dtd but not doctree.txt 2004-03-21,
* never used because the Docutils rST parser inserts `<decoration>`
  directly into `<document>` even if the "header" or "footer" directive
  is nested in a section.

Fix declaration of `<sidebar>` content:

* no `<subtitle>` without `<title>`.

Add `<subtitle>` to children of `<section>` elements in "doctree.txt":

* present in docutils.dtd,
* used in the functional test examples via SectSubTitle transform
  (with "sectsubtitle_xform" configuration setting True).

Modified Paths:
--------------
    trunk/docutils/HISTORY.txt
    trunk/docutils/RELEASE-NOTES.txt
    trunk/docutils/docs/ref/doctree.txt
    trunk/docutils/docs/ref/docutils.dtd

Modified: trunk/docutils/HISTORY.txt
===================================================================
--- trunk/docutils/HISTORY.txt	2024-04-17 19:14:57 UTC (rev 9646)
+++ trunk/docutils/HISTORY.txt	2024-04-18 11:18:00 UTC (rev 9647)
@@ -17,9 +17,16 @@
 Release 0.21.2b.dev (unpublished)
 =================================
 
-Post-release waiting.
+* Declare support for languages Georgian and Catalan (Valencian).
 
+* docs/ref/docutils.dtd
 
+  - Remove declaration of element <info>.
+  - Remove <decoration> from content declaration of <section> elements.
+
+* Fix test failures.
+
+
 Release 0.21.1 (2024-04-10)
 ===========================
 

Modified: trunk/docutils/RELEASE-NOTES.txt
===================================================================
--- trunk/docutils/RELEASE-NOTES.txt	2024-04-17 19:14:57 UTC (rev 9646)
+++ trunk/docutils/RELEASE-NOTES.txt	2024-04-18 11:18:00 UTC (rev 9647)
@@ -45,10 +45,15 @@
 .. _entry points:
     https://packaging.python.org/en/latest/specifications/entry-points/
 
-
 Document Tree / Docutils DTD
 ----------------------------
 
+* Allow multiple <term> elements in a <definition_list_item>
+  in Docutils 0.22 (cf. `feature-requests:60`__).
+  Third-party writers may need adaption.
+
+  __ https://sourceforge.net/p/docutils/feature-requests/60/
+
 * Do not lowercase reference names in the `refname attribute`_
   (matching hyperlinks, footnotes, and citations remains case insensitive),
   and drop the ``name`` attribute from <reference> nodes
@@ -137,17 +142,9 @@
 
   - No more changing case in to uppercase, leave it to the source.
 
-
 Misc
 ----
 
-* Document tree:
-  Allow multiple <term> elements in a <definition_list_item>
-  in Docutils 0.22 (cf. `feature-requests:60`__).
-  Third-party writers may need adaption.
-
-  __ https://sourceforge.net/p/docutils/feature-requests/60/
-
 * Remove `parsers.rst.directives.CSVTable.HeaderDialect`
   in Docutils 0.22.
 
@@ -197,12 +194,16 @@
 .. _use_latex_citations: docs/user/config.html#use-latex-citations
 .. _buildhtml.py: docs/user/tools.html#buildhtml-py
 
+
 Release 0.21.2b.dev (unpublished)
 =================================
 
-Post-release waiting.
+* Document Tree / Docutils DTD
 
+  - Remove declaration of unsupported element <info>.
+  - Remove <decoration> from content declaration of <section> elements.
 
+
 Release 0.21.1 (2024-04-10)
 ===========================
 

Modified: trunk/docutils/docs/ref/doctree.txt
===================================================================
--- trunk/docutils/docs/ref/doctree.txt	2024-04-17 19:14:57 UTC (rev 9646)
+++ trunk/docutils/docs/ref/doctree.txt	2024-04-18 11:18:00 UTC (rev 9647)
@@ -3010,11 +3010,11 @@
 :Parents:    The following elements may contain <section>:
              `\<document>`_, `\<section>`_
 
-:Children:   <section> elements begin with a `\<title>`_, and may contain
-             `body elements`_ as well as `\<transition>`_, `\<topic>`_,
-             and `\<sidebar>`_ elements::
+:Children:   <section> elements begin with a `\<title>`_, and optional
+             `\<subtitle>`_. They may contain `body elements`_ as well as
+             `\<transition>`_, `\<topic>`_, and `\<sidebar>`_ elements::
 
-                (title, %structure.model;)
+                (title, subtitle?, %structure.model;)
 
              See the `%structure.model;`_ parameter entity for details of
              the body of a <section>.
@@ -3106,11 +3106,12 @@
 :Parents:    The following elements may contain <sidebar>:
              `\<document>`_, `\<section>`_.
 
-:Children:   <sidebar> elements begin with optional `\<title>`_ and
-             `\<subtitle>`_ and contain `body elements`_ and
-             `\<topic>`_ elements::
+:Children:   <sidebar> elements begin with optional 
+             `\<title>`_ and `\<subtitle>`_ and contain
+             `body elements`_ and `\<topic>`_ elements. 
+             There must not be a <subtitle> without title. ::
 
-               (title, subtitle?,
+               ((title, subtitle?)?,
                 (%body.elements; | topic)+)
 
 :Attributes: The <sidebar> element contains only the `common attributes`_.
@@ -3213,7 +3214,8 @@
 <subtitle>
 ==========
 
-The <subtitle> element stores the subtitle of a `\<document>`_.
+The <subtitle> element stores the subtitle of a `\<document>`_,
+`\<section>`, or `\<sidebar>`.
 
 Details
 -------
@@ -3224,8 +3226,8 @@
              a <hgroup_> element.
 :Processing: A document's subtitle is usually rendered smaller
              than its `\<title>`_.
-:Parents:    The `\<document>`_ and `\<sidebar>`_ elements may contain
-             <subtitle>.
+:Parents:    The `\<document>`_, `\<section>`, and `\<sidebar>`_ elements
+             may contain <subtitle>.
 :Children:   <subtitle> elements may contain text data
              plus `inline elements`_ (`%text.model;`_).
 :Attributes: The <subtitle> element contains only the `common attributes`_.
@@ -3245,7 +3247,8 @@
 
     A paragraph.
 
-Complete pseudo-XML_ result after parsing and applying transforms_::
+Complete pseudo-XML_ result after parsing and applying the 
+`DocTitle transform`_::
 
     <document ids="title" names="title">
         <title>
@@ -4693,7 +4696,7 @@
 
    * A transition may not occur at the end of a document or section.
 
-The `%structure.model;`_ parameter entity is directly employed in the
+The ``%structure.model;`` parameter entity is directly employed in the
 content models of the `\<document>`_ and `\<section>`_ elements.
 
 

Modified: trunk/docutils/docs/ref/docutils.dtd
===================================================================
--- trunk/docutils/docs/ref/docutils.dtd	2024-04-17 19:14:57 UTC (rev 9646)
+++ trunk/docutils/docs/ref/docutils.dtd	2024-04-18 11:18:00 UTC (rev 9647)
@@ -286,11 +286,6 @@
 <!ELEMENT docinfo (%bibliographic.elements;)+>
 <!ATTLIST docinfo %basic.atts;>
 
-<!-- Container for bibliographic elements. May not be empty.
-Eventual replacement for docinfo? -->
-<!ELEMENT info (%bibliographic.elements;)+>
-<!ATTLIST info %basic.atts;>
-
 <!ELEMENT author %text.model;>
 <!ATTLIST author %basic.atts;>
 
@@ -357,7 +352,7 @@
 -->
 
 <!ELEMENT section
-    (title, subtitle?, info?, decoration?, %structure.model;)>
+    (title, subtitle?, %structure.model;)>
 <!ATTLIST section %basic.atts;>
 
 <!ELEMENT topic (title?, (%body.elements;)+)>
@@ -366,7 +361,7 @@
     depth %number;  #IMPLIED
     local %yesorno; #IMPLIED>
 
-<!ELEMENT sidebar (title?, subtitle?, (%body.elements; | topic)+)>
+<!ELEMENT sidebar ((title, subtitle?)?, (%body.elements; | topic)+)>
 <!ATTLIST sidebar %basic.atts;>
 
 <!ELEMENT transition EMPTY>

This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.



_______________________________________________
Docutils-checkins mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/docutils-checkins
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.