In other documentation systems, such as LuaDoc, there is a @brief directive lets you define a custom name for every token that is used intesd of the actual token name.
For example, you could have a function implemented as foo that will show as bar in the documentation.
This can be really handy if your source code passes through some kind of non-standard preprocessor before being compiled.
Or if your want to use Doxygen with a language that is not supported by Doxygen and you have to use a filter script to transform it into something Doxygen can parse.
Is there a way to achieve this behavior (renaming tokens for the docs only) in Doxygen?
You can filter input files using
INPUT_FILTER(same filter for all files), orFILTER_PATTERNS(filter for a specific extension).Normally the source code view (i.e.
SOURCE_BROWSER=YES) will not be processed, but you can change this usingFILTER_SOURCE_FILES=YESand use this in combination withFILTER_SOURCE_PATTERNSif you want to use a different filter for the source code than for the documentation.If you use a pass-through filter for the sources and a token rename filter for documentation, you should be able to get the effect that you are looking for.