chiark / gitweb /
doxygen: support one more level of Markdown headings.
authorVladimír Vondruš <mosra@centrum.cz>
Wed, 6 Dec 2017 20:35:46 +0000 (21:35 +0100)
committerVladimír Vondruš <mosra@centrum.cz>
Thu, 7 Dec 2017 01:23:41 +0000 (02:23 +0100)
doxygen/dox2html5.py
doxygen/test/contents_typography/input.dox
doxygen/test/contents_typography/warnings.html

index 6cfe2b650f19c3c70ff8bef71466d2884e8d4c23..f4aa4f5346e5daa4f093a048d241541669037162 100755 (executable)
@@ -252,6 +252,8 @@ def parse_desc_internal(state: State, element: ET.Element, immediate_parent: ET.
                 tag = 'h3'
             elif i.attrib['level'] == '3':
                 tag = 'h4'
+            elif i.attrib['level'] == '4':
+                tag = 'h5'
             else: # pragma: no cover
                 assert False
             logging.warning("Prefer @section over Markdown heading for properly generated TOC")
index b362bb62992e6cf952ac8921efc2e0404b9fa01d..411b8d32c3a13cd913b1444593f721e2f1f0fb1b 100644 (file)
@@ -40,4 +40,6 @@ This is a `typewriter text`, *emphasis* and **bold**. http://google.com and
 
 ### Markdown heading 3
 
+#### Markdown heading 4
+
 */
index 1bb044b32f545310c0edeae3d2e905e47bb0bf2e..acc9fbd08e3997e1c9298be80d60147d8efacceb 100644 (file)
@@ -37,7 +37,7 @@
         <h1>
           Content that produces warnings
         </h1>
-<h2>Markdown heading 1</h2><h3>Markdown heading 2</h3><h4>Markdown heading 3</h4>
+<h2>Markdown heading 1</h2><h3>Markdown heading 2</h3><h4>Markdown heading 3</h4><h5>Markdown heading 4</h5>
       </div>
     </div>
   </div>