#msg = inliner.reporter.warning(
#'Doxygen symbol %s not found' % target, line=lineno)
#prb = inliner.problematic(rawtext, rawtext, msg)
- logger.warning('Doxygen symbol `%s` not found, rendering as monospace' % target)
- node = nodes.literal(rawtext, title if title else target, **options)
+ if title:
+ logger.warning("Doxygen symbol `{}` not found, rendering just link title".format(target))
+ node = nodes.inline(rawtext, title, **options)
+ else:
+ logger.warning("Doxygen symbol `{}` not found, rendering as monospace".format(target))
+ node = nodes.literal(rawtext, target, **options)
return [node], []
def register():
</ul>
<p>These should produce warnings:</p>
<ul>
+<li>Link to nonexistent name will be rendered as code: <code>nonExistent()</code></li>
+<li><span>Link to nonexistent name with custom title will be just text</span></li>
<li>Link to a section that doesn't have a title will keep the ID (this <em>may</em>
break on tagfile update, watch out): <a href="http://doc.magnum.graphics/corrade/corrade-cmake.html#corrade-cmake-add-test">corrade-cmake-add-test</a></li>
</ul>
These should produce warnings:
+- Link to nonexistent name will be rendered as code: :dox:`nonExistent()`
+- :dox:`Link to nonexistent name with custom title will be just text <nonExistent()>`
- Link to a section that doesn't have a title will keep the ID (this *may*
break on tagfile update, watch out): :dox:`corrade-cmake-add-test`