From 85c5ccfab94012b2a7c5f3e98014a75be4b06c52 Mon Sep 17 00:00:00 2001 From: Georg Brandl Date: Thu, 5 Feb 2009 11:38:23 +0000 Subject: #4563: disable alpha and roman lists, fixes wrong formatting of contributor list. --- Doc/tools/sphinxext/pyspecific.py | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/Doc/tools/sphinxext/pyspecific.py b/Doc/tools/sphinxext/pyspecific.py index 018f4ac..fefe1c1 100644 --- a/Doc/tools/sphinxext/pyspecific.py +++ b/Doc/tools/sphinxext/pyspecific.py @@ -13,6 +13,14 @@ ISSUE_URI = 'http://bugs.python.org/issue%s' from docutils import nodes, utils +# monkey-patch reST parser to disable alphabetic and roman enumerated lists +from docutils.parsers.rst.states import Body +Body.enum.converters['loweralpha'] = \ + Body.enum.converters['upperalpha'] = \ + Body.enum.converters['lowerroman'] = \ + Body.enum.converters['upperroman'] = lambda x: None + + def issue_role(typ, rawtext, text, lineno, inliner, options={}, content=[]): issue = utils.unescape(text) text = 'issue ' + issue -- cgit v0.12