help-source-highlight
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Help-source-highlight] Unicode files ?


From: Martin Gebert
Subject: Re: [Help-source-highlight] Unicode files ?
Date: Mon, 29 Mar 2010 20:33:42 +0200
User-agent: Mozilla/5.0 (X11; U; Linux i686; de-DE; rv:1.9.1.8) Gecko/20100306 Thunderbird/3.0.3

-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1


> has anybody got any idea on how adding such support to a C++
> program? Is it just a matter of using wchar for strings?
>

- From my limited knowledge, as far as UTF-16 is concerned this and
using the appropriate functions from wchar.h should do it. If you need
UTF-8 you're mostly on your own until C++0x comes out
<http://en.wikipedia.org/wiki/C%2B%2B0x#New_string_literals> (a
problem is e. g. strlen()). To use STL strings perhaps
basic_string<wchar> would work, as std::string is simply a typedef
basic_string<char>.
But as you're using boost anyway perhaps it can do something for you?

Martin
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v2.0.14 (GNU/Linux)
Comment: Using GnuPG with Mozilla - http://enigmail.mozdev.org/

iEYEARECAAYFAkuw8oUACgkQ0qFE1uHKpVcMNACgl9nTw32GlBzPpE+MCZDsw5uH
/GoAn3RkkbytkxncsJDU9kZbGgcG97qE
=hGip
-----END PGP SIGNATURE-----





reply via email to

[Prev in Thread] Current Thread [Next in Thread]