[fpc-pascal] TListBox bug in LCL of Lazarus?

Jürgen Hestermann juergen.hestermann at gmx.de
Sat Dec 20 18:46:06 CET 2008


I have analyzed the bug in the TListBox further and found that adding or 
modifying a string from to a TListBox fails if the strings contains 
foreign characters like german umlauts as in

Form1.ListBox1.Items.Strings[Count-1] := ('ööööööööööööö');

but it works if changed to UTF8 as in

Form1.ListBox1.Items.Strings[Count-1] := (AnsiToUTF8('ööööööööööööö'));

How is this supposed to work? Even if the wrong coding is used I don't 
understand why the whole string is dropped when not using AnsiToUTF8. 
Without the conversion I would expect to see incorrect characters 
instead of the umlauts.

Jürgen Hestermann.

More information about the fpc-pascal mailing list