From: Vladimír Vondruš Date: Thu, 13 Sep 2018 16:44:43 +0000 (+0200) Subject: doxygen: ignore private non-virtual functions in user-defined groups. X-Git-Url: https://www.chiark.greenend.org.uk/ucgi/~cjwatson/git?a=commitdiff_plain;h=497e6a820f74a3ba45f21691b3b731015f4c0010;p=blog.git doxygen: ignore private non-virtual functions in user-defined groups. Only documented virtual private functions are shown. --- diff --git a/doxygen/dox2html5.py b/doxygen/dox2html5.py index c3d68f50..0fac50f1 100755 --- a/doxygen/dox2html5.py +++ b/doxygen/dox2html5.py @@ -2473,6 +2473,11 @@ def parse_xml(state: State, xml: str): list += [('typedef', typedef)] if typedef.has_details: compound.has_typedef_details = True elif memberdef.attrib['kind'] == 'function': + # Gather only private functions that are virtual and + # documented + if memberdef.attrib['prot'] == 'private' and (memberdef.attrib['virt'] == 'non-virtual' or (not memberdef.find('briefdescription').text and not memberdef.find('detaileddescription').text)): + continue + func = parse_func(state, memberdef) if func: list += [('func', func)] diff --git a/doxygen/test/compound_listing/Directory/Sub/Class.h b/doxygen/test/compound_listing/Directory/Sub/Class.h index 9440e57f..7b12ba85 100644 --- a/doxygen/test/compound_listing/Directory/Sub/Class.h +++ b/doxygen/test/compound_listing/Directory/Sub/Class.h @@ -110,6 +110,9 @@ class Class { /** @brief Private virtual function in a group */ virtual int doStuff() = 0; + /** @brief Private non-virtual function in a group shouldn't appear in the docs */ + int doStuffIgnored(); + /*@}*/ /** @brief This shouldn't appear in the docs */