summaryrefslogtreecommitdiff
path: root/doc/tools
diff options
context:
space:
mode:
Diffstat (limited to 'doc/tools')
-rw-r--r--doc/tools/doc_status.py20
-rw-r--r--doc/tools/makerst.py11
2 files changed, 10 insertions, 21 deletions
diff --git a/doc/tools/doc_status.py b/doc/tools/doc_status.py
index 170ded9f50..ab74c0b9d6 100644
--- a/doc/tools/doc_status.py
+++ b/doc/tools/doc_status.py
@@ -245,21 +245,6 @@ class ClassStatus:
status = ClassStatus()
status.name = c.attrib['name']
- # setgets do not count
- methods = []
- for tag in list(c):
- if tag.tag in ['methods']:
- for sub_tag in list(tag):
- methods.append(sub_tag.attrib['name'])
- if tag.tag in ['members']:
- for sub_tag in list(tag):
- try:
- if(sub_tag.attrib['setter'].startswith('_') == False):
- methods.remove(sub_tag.attrib['setter'])
- if(sub_tag.attrib['getter'].startswith('_') == False):
- methods.remove(sub_tag.attrib['getter'])
- except:
- pass
for tag in list(c):
if tag.tag == 'brief_description':
@@ -270,9 +255,8 @@ class ClassStatus:
elif tag.tag in ['methods', 'signals']:
for sub_tag in list(tag):
- if sub_tag.attrib['name'] in methods or tag.tag == 'signals':
- descr = sub_tag.find('description')
- status.progresses[tag.tag].increment(len(descr.text.strip()) > 0)
+ descr = sub_tag.find('description')
+ status.progresses[tag.tag].increment(len(descr.text.strip()) > 0)
elif tag.tag in ['constants', 'members']:
for sub_tag in list(tag):
status.progresses[tag.tag].increment(len(sub_tag.text.strip()) > 0)
diff --git a/doc/tools/makerst.py b/doc/tools/makerst.py
index dc015d781b..cd0108019b 100644
--- a/doc/tools/makerst.py
+++ b/doc/tools/makerst.py
@@ -7,6 +7,7 @@ import os
import xml.etree.ElementTree as ET
input_list = []
+cur_file = ""
for arg in sys.argv[1:]:
if arg.endswith(os.sep):
@@ -206,6 +207,7 @@ def rstize_text(text, cclass):
elif cmd == '/code':
tag_text = '``'
inside_code = False
+ escape_post = True
elif inside_code:
tag_text = '[' + tag_text + ']'
elif cmd.find('html') == 0:
@@ -217,7 +219,10 @@ def rstize_text(text, cclass):
param = tag_text[space_pos + 1:]
if param.find('.') != -1:
- (class_param, method_param) = param.split('.')
+ ss = param.split('.')
+ if len(ss) > 2:
+ sys.exit("Bad reference: '" + param + "' in file: " + cur_file)
+ (class_param, method_param) = ss
tag_text = ':ref:`' + class_param + '.' + method_param + '<class_' + class_param + '_' + method_param + '>`'
else:
tag_text = ':ref:`' + param + '<class_' + cclass + "_" + param + '>`'
@@ -519,8 +524,8 @@ for path in input_list:
elif os.path.isfile(path) and path.endswith('.xml'):
file_list.append(path)
-for file in file_list:
- tree = ET.parse(file)
+for cur_file in file_list:
+ tree = ET.parse(cur_file)
doc = tree.getroot()
if 'version' not in doc.attrib: