Re: [xml] Using wchar_t string with libxml2.
- From: Daniel Veillard <veillard redhat com>
- To: Arthur Yarwood <arthur fubaby com>
- Cc: xml gnome org
- Subject: Re: [xml] Using wchar_t string with libxml2.
- Date: Wed, 26 Jan 2005 09:25:16 -0500
On Wed, Jan 26, 2005 at 02:05:31PM +0000, Arthur Yarwood wrote:
xml-bounces gnome org wrote on 26/01/2005 12:48:07:
Am I just mis-using it somehow?
Looks okay. But this is not a mailing list about characters encoding
or the iconv API, really...
I'm guessing I've got the wrong code for
the input. Any ideas?
http://www.opengroup.org/onlinepubs/007908799/xsh/stddef.h.html
the definition of wchar_t doesn't define an encoding. Seems to be
a sequence of code point. Doesn't even define the *size* of the C objects,
maybe your encoding is UCS4 but you really ought to know better what
you are using. It's likely to even be system dependant ! Anyway if you
use embedded systems that sounds a sure way to waste globs of memory,
I would not do that...
UTF-8 representation is defined in rfc2044 .
libxml2 has a function to take an Unicode code point and write it
in an xmlChar buffer:
http://xmlsoft.org/html/libxml-parserInternals.html#xmlCopyCharMultiByte
Ahh, yeah I forgot that they append that. I do apologise, I'll use my
own personal email account from now on.
okay.
Daniel
--
Daniel Veillard | Red Hat Desktop team http://redhat.com/
veillard redhat com | libxml GNOME XML XSLT toolkit http://xmlsoft.org/
http://veillard.com/ | Rpmfind RPM search engine http://rpmfind.net/
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]