Bo Peng wrote:
It's OK. But why did you delete the // FIXME UNICODE?
By accident. Fixed and committed.
Anyway, what is this 'FIXME UNICODE'? They are everywhere and nobody
seems to be fixing them now.
They refer to string data in UTF-8 format that is being manipulated in
some way. An example can be found in the InsetHyperlink code just
committed by Uwe and commented on by Georg:
> - docstring const & name = getParam("name");
> + string url = to_utf8(getParam("target"));
Manipulation of a std::string containing UTF-8 encoded data is always
a bad idea because a single logical "char" can extend over multiple
std::string::char_type. It's immediately clear that data corruption
can occur.
It seems that "someone" has some work to do:
$ grep -rn 'FIXME UNICODE' . | grep -v 'svn-base' | wc -l
131
Some of the remaining std::strings, like 'LyXRC::user_name' and
'LyXRC::user_email' look like low-hanging fruit that would be trivial
to convert to docstring. Other instances, will, I am sure be much more
complex.
Angus