U++ framework
Do not panic. Ask here before giving up.

Home » U++ Library support » U++ Core » Strings with national specific characters are wrongly sorted - Sort
Re: Strings with national specific characters are wrongly sorted - Sort [message #57470 is a reply to message #57468] Thu, 26 August 2021 13:09 Go to previous messageGo to previous message
busiek is currently offline  busiek
Messages: 71
Registered: February 2011
Location: Poland
Member
For Polish alphabet I use such function to map wchar into something comparable according to our needs:
auto CharRepr = [](wchar c)
{
    wchar d = ToLower(c);
    d = d == u'ł' ? 'l' : d;
    return MakeTuple(IsLetter(c), ToAscii(d), c);
};

Then, to compare, I map each WString into the appropriate vector of tuples.

Cheers,
Kuba
 
Read Message
Read Message
Read Message
Read Message
Previous Topic: Probable nasty bug with StringBuffer
Next Topic: POSIX home directory symbol '~' is causing trouble
Goto Forum:
  


Current Time: Sat Sep 05 15:09:40 GMT+2 2026

Total time taken to generate the page: 0.00622 seconds