Sign in Join

Live chat for Free Pascal, Lazarus, Delphi and every Pascal programmer.

Mailing lists / lazarus / 2012-11

StrLen

3 messages · 2 people · –

Reply by email Subscribe to this list Your subscription

Read-only archive. Use j and k to move between messages.

Martin
to Kamen Ketev
Kamen Ketev wrote 8 lines
Hi, When I am using StrLen or Length or StrCharLength for counting symbols on latin everything is ok. But when count cyrillic symbols is NOT count properly. How I can count cyrillic symbols in string?

Utf8Length

However strictly spoken afaik it counts codepoints.

Some chars are combined of multiply codepoints (see wikipedia utf8 combining).

And on top of that, this does not tell anything about what you see on display. In some scripts two chars are displayed as one symbol (ligature)

Reply by email

Kamen Ketev

Thanks, Martin!

-------- ?????????? ????? --------
??: Martin
???????: Re: [Lazarus] StrLen
??: Lazarus mailing list
????????? ??: ???????, 2012, ??????? 20 00:11:45 EET

Kamen Ketev wrote 15 lines
Hi, When I am using StrLen or Length or StrCharLength for counting symbols on latin everything is ok. But when count cyrillic symbols is NOT count properly. How I can count cyrillic symbols in string?

Utf8Length

However strictly spoken afaik it counts codepoints.

Some chars are combined of multiply codepoints (see wikipedia utf8

combining).

And on top of that, this does not tell anything about what you see on

display. In some scripts two chars are displayed as one symbol (ligature)

Reply by email