2017-07-30 10:00 GMT+02:00 Michael Van Canneyt via Lazarus <[email protected]>: > > > On Sat, 29 Jul 2017, Marcos Douglas B. Santos via Lazarus wrote: > >> Hi, >> >> Nowadays, we have full Unicode support in FPC. >> So, my question is: The units bellow is still necessary to use XML >> with Lazarus or we can use just the original provided by FCL? >> >> laz2_DOM >> laz2_XMLRead >> laz2_XMLWrite >> laz2_XMLCfg >> laz2_XMLUtils >> laz_XMLStreaming > > > The FPC units use UnicodeString (UTF16), the lazarus units use UTF8. > If the end result is used excluively in UTF8 strings, the lazarus version > may be > faster as there will be less conversions. >
I wonder if we can move the UTF8-based XML units to FPC, to be available in the main FPC distribution too? (Possibly renamed like Utf8_XMLXxx or such, instead of LazX_XMLXxx.) The reason I ask: This requirement (wanting to have XML units based on AnsiStrings, not WideStrings, because your data is almost always in UTF8 and you're fine storing it in AnsiString ) is not really specific to Lazarus, or applications build on top of Lazarus. E.g. in Castle Game Engine I would prefer using UTF8-based XML units too, I often read UTF8 XML files (like X3D, Collada 3D models). But I don't want the "core" CGE to depend on LCL (this makes the process of building and testing simpler -- you can use CGE components in Lazarus, but you can also use CGE with our own minimalistic window management without Lazarus). Regards, Michalis -- _______________________________________________ Lazarus mailing list [email protected] https://lists.lazarus-ide.org/listinfo/lazarus
