diff options
author | Laszlo Pandy <lpandy@src.gnome.org> | 2011-08-11 15:04:25 +0200 |
---|---|---|
committer | Laszlo Pandy <lpandy@src.gnome.org> | 2011-08-11 15:08:29 +0200 |
commit | ec3ba963c5aec4f32bf005b798a3f8e515ec9eca (patch) | |
tree | cb46b3e8be633fac658c63f1db1309de3bd2a704 | |
parent | ea63c66d1822e91ddec1bc864cb1f77775958d13 (diff) | |
download | gobject-introspection-ec3ba963c5aec4f32bf005b798a3f8e515ec9eca.tar.gz |
[docbook] use C symbol for function title.
-rw-r--r-- | giscanner/docbookwriter.py | 9 |
1 files changed, 7 insertions, 2 deletions
diff --git a/giscanner/docbookwriter.py b/giscanner/docbookwriter.py index 1941846f..f3dbafae 100644 --- a/giscanner/docbookwriter.py +++ b/giscanner/docbookwriter.py @@ -86,6 +86,10 @@ class DocBookFormatter(object): self._writer.write_line(");\n") + def get_method_as_title(self, entity): + method = entity.get_ast() + return "%s ()" % method.symbol + def render_method(self, entity, link=False): method = entity.get_ast() self._writer.disable_whitespace() @@ -320,9 +324,10 @@ class DocBookWriter(object): def _render_method(self, entity): self._writer.push_tag('refsect2', - [('id', "%s-function" % entity.get_name()), + [('id', entity.get_ast().symbol), ('role', 'struct')]) - self._writer.write_tag("title", [], entity.get_name()) + self._writer.write_tag("title", [], + self._formatter.get_method_as_title(entity)) with self._writer.tagcontext("indexterm", [("zone", "%s" % entity.get_name())]): |