will incorrectly decode Unicode code points that decode to values greater than 0xffff. Unless this is just a transition on the way to a final API, Windows is going to get the “short” end of the stick. Unless you set juce_wchar to uint32 somewhere in a header I didn’t see.
Because Android has a wchar_t of 1 byte, and Windows has a wchar_t of 2 bytes, I’m having to create a custom juce_wchar which on those platforms is a typedef of an unsigned int. So any overloads that might cause confusion between a real unsigned int and a juce_wchar will have to be removed.
It shouldn’t be a big deal - just cast your value to an int or int64 instead.
Probably the same on all platforms, and will most likely default to utf32, but as I said, I’m still tinkering with this and thinking about it. If the O(N) random-access time isn’t a problem, I might make it all utf-8 instead.
I have literally hundreds of thousands of strings to millions of strings in my in-memory database so I will be storing them as utf-8 no matter what. I’m fine with however Juce will represent strings for Components and elsewhere (file paths, plugin API, etc). As long as Juce provides conversions between encodings (which it seems you already do), I don’t mind performing a conversion at display time or at a point of call.
TextEditor looks to be the most affected by removal of array based indexing into String.
I’ll probably provide a really simple templated string holder object for stuff like that, e.g. “StringBuffer<CharPointer_UTF8>” that can be read and written with Strings.