Hi Marco,

On 16/10/15 11:46, "Bubke Marco" <marco.bu...@theqtcompany.com> wrote:
>
>>> That is the
>>> power of iterators and with the new features of C++ they get really
>>>useful.
>>> But anyway,  I don't say that we have to change everything. The last
>>>time
>>> we did that we broke our event system which is still not working like
>>>it
>>> was before we introduced QWindow. I think we  should have an
>>>evolutionary
>>> process to  adapt to the  changing environment and not try to reiterate
>>> what was successful in the past.
>>
>> I agree with what you said in this paragraph. But it does not lead to a
>> conclusion about using UTF-8 or even providing our own UTF-8 class.
>>
>
>Introducing an utf 8 class is not that hard but providing the framework
>around. Collations are the problem. We have to use utf8 in QtCreator
>anyway so we could find out what is an useful API.  But colation support
>in Qt would be really helpful in the longer run.

The problem with Collation and utf-8 is that the only API offering utf-8
based collation is ICU (which offers both utf-8 and utf-16 based
collation). Mac and Windows only offer utf-16.

So we’d still need to convert in most cases. It would probably be possible
to do that on the stack for small strings to avoid a malloc though. So we
can discuss adding a QCollator::collateUtf8(const char *s1, int len1,
const char *s2, int len2).

But just out of curiosity, where does Creator need collation in a
performance critical place?

Cheers,
Lars

_______________________________________________
Development mailing list
Development@qt-project.org
http://lists.qt-project.org/mailman/listinfo/development

Reply via email to