On Thu, 18 Sep 2014 09:43:21 +0200 LacaK <la...@zoznam.sk> wrote: > Hi, > I use ReadXMLFile from fcl-xml package to read XML file in UTF-8 encoding. > Then I parse Nodes and use TextContent property which is string in > system encoding ... but I need it in UTF-8 encoding. > So I use again UTF8Encode(Node.TextContent). > Is there any SIMPLE way how to say that ReadXMLFile should not perform > translation from UTF-8 to system encoding? > (may be somehow with custom TDecoder or so ... or use Laz_ versions or ...?)
The Lazarus sources contain units to read/write XML using UTF8 strings. The units are based on the fcl-xml units. The widestrings were replaced with UTF8 Ansistrings. lazarus/components/lazutils/laz2_xml*. The units work standalone. You don't need Lazarus for them. Mattias _______________________________________________ fpc-pascal maillist - fpc-pascal@lists.freepascal.org http://lists.freepascal.org/cgi-bin/mailman/listinfo/fpc-pascal