Reputation: 26385
In Doxygen, to get the copyright symbol in HTML output, the documentation must use ©
, as in:
/// @copyright Copyright © 2012
In this case, I'd prefer to type it like this:
/// @copyright Copyright (c) 2012
In the latter example, it looks a little nicer and would probably translate over to plain text & RTF output better as well. Is it possible to create a text to entity mapping in Doxygen? For example, (c)
would map to ©
, and doxygen would simply replace all (c)
occurrences with ©
Upvotes: 2
Views: 730
Reputation: 14869
In general I think such substitutions are better handled by an input filter.
Here is a simple filter that would replace a (c)
followed by some digits by ©
and then the same digits:
#!/bin/perl
open(F,"<$ARGV[0]") || die("Failed to open file $ARGV[0]: $!");
while (<F>)
{
s/\([cC]\)(\s*\d+)/©\1/g;
print $_;
}
close(F);
To use this filter put the following in the config file:
INPUT_FILTER = "perl filter.pl"
Note 1 The filter will process the whole file. It might be a useful feature to allow a filter that is only applied to comments.
Note 2 If you use a UTF-8 capable editor and corresponding encoding (INPUT_ENCODING) you can also insert the copyright character directly (code C2 A9 hex)
Upvotes: 4