Opened 12 years ago

Closed 5 years ago

#1586 closed bug (fixed)

Queries: not case-insensitive for "Umlauts"

Reported by: humdinger Owned by: zooey
Priority: normal Milestone: Unscheduled
Component: Applications/Tracker Version: R1/pre-alpha1
Keywords: Cc:
Blocked By: Blocking:
Has a Patch: no Platform: All

Description

This is in vmware, hrev22714.

When you do a query for any filename containing "über", the generated formula is (name=="*ü[bB][eE][rR]*"). The "Umlaut" is not case-insensitive. It should be (name=="*[üÜ][bB][eE][rR]*")

Change History (9)

comment:1 by axeld, 12 years ago

Milestone: R1Unscheduled

This will be fixed when Haiku gets a locale kit - until then, you have to live with it, sorry.

comment:2 by humdinger, 12 years ago

That's OK. I was just wondering why the query didn't return all files I expected...

comment:3 by pulkomandy, 10 years ago

Owner: changed from axeld to pulkomandy

Now there is a locale kit :)

I looked at it quickly and would like some advice : should I change query.cpp to use locale kit API directly, or should I change ctype.h so that isalpha, toupper and tolower work properly ?

comment:4 by pulkomandy, 10 years ago

Status: newassigned

comment:5 by pulkomandy, 9 years ago

Owner: changed from pulkomandy to zooey
Status: in-progressassigned

Oliver is working on POSIX locale stuff, including ctypes, so he will fix this.

comment:6 by zooey, 7 years ago

Status: assignedin-progress

Well, the POSIX locale stuff is working now, but this problem hasn't been fixed by that. No surprise, really, as isalpha() (which is used in StorageKit's BQuery) isn't able to cope with chars that require more than

comment:7 by zooey, 7 years ago

I tried to solve this in hrev43951, but that doesn't work, since BUnicodeChar is missing information for the relevant characters.

Hm, I suppose we need to implement BUnicodeChar directly on top of ICU to get the required information. Going all the way (i.e. doing it right for all use cases) is likely to require changes to the API, too, as for instance the result of a toupper() may not always be a single char (like for the German 'ß', which in uppercase is usually represented as 'SS').

comment:8 by axeld, 7 years ago

BUnicodeChar originally was built on top of the ICU data, and definitely did support for all unicode characters. I don't remember what happened when that file was absent, but maybe that's what you are seeing.

Anyway, just FYI: an uppercase 'ß' does actually exist since some time (http://de.wikipedia.org/wiki/Gro%C3%9Fes_%C3%9F).

comment:9 by pulkomandy, 5 years ago

Resolution: fixed
Status: in-progressclosed

It seems to work ok now.

hrev43951 switched to BUnicodeChar. hrev45462 made BUnicodeChar use ICU.

Note: See TracTickets for help on using tickets.