From: Dan White Date: Thu, 1 Nov 2012 02:46:53 +0000 (-0500) Subject: Tweak doxy2swig.py output to include Returns header X-Git-Tag: v1.0rc1~12 X-Git-Url: http://developer.intra2net.com/git/?p=libftdi;a=commitdiff_plain;h=a67c3be47d1af396f4ad1eb7e770fb3be4d58334 Tweak doxy2swig.py output to include Returns header Underlines are proportional to the title now also. --- diff --git a/bindings/doxy2swig.py b/bindings/doxy2swig.py index 96573dc..c6c972c 100644 --- a/bindings/doxy2swig.py +++ b/bindings/doxy2swig.py @@ -237,6 +237,7 @@ class Doxy2SWIG: if key == 'kind': if val == 'param': text = 'Parameters' elif val == 'exception': text = 'Exceptions' + elif val == 'retval': text = 'Returns' else: text = val break self.add_text(['\n', '\n', text, ':', '\n']) @@ -410,8 +411,8 @@ class Doxy2SWIG: _data = "".join(ret) ret = [] for i in _data.split('\n\n'): - if i == 'Parameters:' or i == 'Exceptions:': - ret.extend([i, '\n-----------', '\n\n']) + if i == 'Parameters:' or i == 'Exceptions:' or i == 'Returns:': + ret.extend([i, '\n'+'-'*len(i), '\n\n']) elif i.find('// File:') > -1: # leave comments alone. ret.extend([i, '\n']) else: