Take care about how wxString and wxArrayString are substituted in the docs. There are some cases where it is a substring and so should not be replaced.

This commit is contained in:
Robin Dunn
2016-09-08 12:31:15 -07:00
parent fc85531951
commit 1e448352be
2 changed files with 7 additions and 2 deletions

View File

@@ -168,9 +168,14 @@ def buildEnumsAndMethods(sphinxDir):
text = text.replace(item, '""')
# Replace ArrayXXX stuff...
for cpp in ['ArrayString()', 'ArrayInt()', 'ArrayDouble()', 'ArrayString']:
for cpp in ['ArrayString()', 'ArrayInt()', 'ArrayDouble()']:
text = text.replace(cpp, '[]')
for cpp, py in [('`ArrayString`', 'list of strings'),
('`ArrayInt`', 'list of integers'),
('`ArrayDouble`', 'list of floats')]:
text = text.replace(cpp, py)
# Remove lines with "Event macros" in them...
text = text.replace('Event macros:', '')

View File

@@ -178,7 +178,7 @@ def replaceCppItems(line):
if item in CPP_ITEMS:
continue
if 'wxString' in item:
if 'wxString' == item:
item = 'string'
elif 'wxCoord' == item:
item = 'int'