[fpc-devel] Is calling the Windows Unicode APIs really faster than the ANSI API's?

JoshyFun joshyfun at gmail.com
Fri Sep 26 12:31:05 CEST 2008


Hello Graeme,

Friday, September 26, 2008, 10:50:43 AM, you wrote:

GG> Good question and I have been wondering about this myself.  In D2009
GG> SizeOf(Char) = 2, so I have no idea how that works with surrogate
GG> pairs. Can anybody explain this please?

I don't know how D2009 and others do it, but for myself I'm using the
approach of use strings in two flavors:

raw mode: "String[x]:=Y;" where you access each char unit, no
surrogate pairs or packing information is being taking in account.

text mode: Substr, leftstr and alike, where the surogate pairs are
used and processed.

-- 
Best regards,
 JoshyFun




More information about the fpc-devel mailing list