Add proper collation support to Qt
authorLars Knoll <lars.knoll@nokia.com>
Fri, 1 Jun 2012 21:09:31 +0000 (23:09 +0200)
committerQt by Nokia <qt-info@nokia.com>
Sun, 10 Jun 2012 17:08:56 +0000 (19:08 +0200)
commit1e9be1327bed93542816abb1aef6bcee25216ce0
treec09fd0eb6674f76a4c3dc6232291c81df5c1b909
parent97e177e58d195f78ac103b3dd0b8ecedb1e07d4c
Add proper collation support to Qt

QString::localeAwareCompare() has always been a broken
way to support collation. The current implementation is
not even thread safe.

This adds a proper collation class that fixes the problems
and finally allows Qt to sort properly according to locale
rules.

The class is private for now, but is intendent to be made
public with 5.1

Change-Id: Idb4e75ff68a398c9813af622af884a90898d2be9
Reviewed-by: Thiago Macieira <thiago.macieira@intel.com>
src/corelib/tools/qcollator.cpp [new file with mode: 0644]
src/corelib/tools/qcollator_p.h [new file with mode: 0644]
src/corelib/tools/qstring.h
src/corelib/tools/tools.pri