I would like to find a substring in UTF-8 string, case-insensitive. from what I read, the usual way it's done is case folding the strings in order to bring them to canonical form.
However, since case folding can change the length of the strings (and I don't want to change the length of the strings because I need to know what is the exact offset of the substring match in the original string), it seems I should be using Simple case mapping. although the case-insensitive comparison won't be accurate, it will be best effort.
However, I cannot find in ICU API functions that operate on strings with Simple case mapping. I can find Simple case mapping only for single char functions (u_foldCase()
in uchar.h). Is there an option to use Simple case folding for whole strings?