Re: [Doxygen-develop] feature request: utf encoding
Brought to you by:
dimitri
From: Jens S. <jen...@us...> - 2006-11-24 23:16:30
|
Hi Peter, On Fri, Nov 24, 2006 at 06:43:30PM +0100, Peter M=FCnster wrote: > since the encoding of my source files is utf-8 since some time, would i= t be > possible to add utf support to doxygen? of course. It should be not very difficult. > For HTML, this means > <meta http-equiv=3D"Content-Type" content=3D"text/html;charset=3Dutf-8"= > > instead of > <meta http-equiv=3D"Content-Type" content=3D"text/html;charset=3Diso-88= 59-1"> I tried it once for German documents but did not complete it. Nevertheless the attached patch give should you sufficient ideas what needs to be changed. (translator_de.h needs to be recoded to UTF-8 as well, this is missing in the patch to keep it small.) HTML is trivial, but do not forget other output formats. LaTeX could cause trouble. I noticed failures for a special Doxygen configuration. I think it was the PDF output created via LaTeX which failed because of a missing escaping of "_" but I forgot about it. After manual fixing two or three escaping errors I was able to process a large document containing German and Russian texts. Manual pages should also not depend on the encoding (the manual page encoding is hardcoded into man. It may be necessary to recode these from UTF-8 via an external script on systems which expect classical encodings). I don't know the RTF format. Using UTF-8 per default would also allow to drop the stupid Use Windows encoding option in the config file. It's also still possible to use INPUT_FILTER =3D "iconv -f iso-8859-1 -t = UTF-8 -c" for latin1 encoded source to keep these workings. Jens |