diff options
author | Stefan Sauer <ensonic@users.sf.net> | 2018-10-19 20:13:45 +0200 |
---|---|---|
committer | Stefan Sauer <ensonic@users.sf.net> | 2018-10-19 20:14:43 +0200 |
commit | 9b8ab135c63139cd6ba77eea9c48b945a990cc6a (patch) | |
tree | 2570b495bde9f7fef53f29866a709a13fec51f49 | |
parent | 44a4d36e67d00618937afda90382b6983c0edea7 (diff) | |
download | gtk-doc-9b8ab135c63139cd6ba77eea9c48b945a990cc6a.tar.gz |
mkhtml2: Pass tree_node to get_titles for error reporting.
-rw-r--r-- | gtkdoc/mkhtml2.py | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/gtkdoc/mkhtml2.py b/gtkdoc/mkhtml2.py index e8631fe..27644a6 100644 --- a/gtkdoc/mkhtml2.py +++ b/gtkdoc/mkhtml2.py @@ -221,13 +221,14 @@ def gen_chunk_name(node, chunk_params): return name -def get_chunk_titles(module, node): +def get_chunk_titles(module, node, tree_node): tag = node.tag (title, subtitle) = TITLE_XPATHS.get(tag, TITLE_XPATHS['_']) ctx = { 'module': module, 'files': [], + 'node': tree_node, } result = { 'title': None, @@ -272,7 +273,7 @@ def chunk(xml_node, module, depth=0, idx=0, parent=None): tag = xml_node.tag chunk_params = CHUNK_PARAMS.get(tag) if chunk_params: - title_args = get_chunk_titles(module, xml_node) + title_args = get_chunk_titles(module, xml_node, parent) chunk_name = gen_chunk_name(xml_node, chunk_params) # check idx to handle 'sect1'/'section' special casing and title-only |