Re: [xml] Using wchar_t string with libxml2.



On Wed, Jan 26, 2005 at 10:05:10AM +0000, Arthur_Yarwood scee net wrote:
How should I be passing my wide strings into these functions? I could just 
convert them to char strings, but I could loose data. Are the any other 
issues I should be concerned about to ensure my xml is valid? e.g.  what 
encoding standard should I use? UTF-16?

  You must convert your wide strings into UTF-8 strings before passing them
to the libxml2 API. I think 
    http://xmlsoft.org/encoding.html#internal
is clear about that. If not I take patches to make this clearer.

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]