Correct toolbar environment sorting for other locales.

git-svn-id: svn://svn.lyx.org/lyx/lyx-devel/trunk@22634 a592a061-630c-0410-9148-cb99ea01b6c8
This commit is contained in:
Pavel Sanda 2008-01-19 23:46:03 +00:00
parent c0414bef66
commit 75a5c1c7a1

View File

@ -277,7 +277,7 @@ void GuiLayoutBox::addItemSort(QString const & item, bool sorted)
// Let the default one be at the beginning
int i = 1;
for (setCurrentIndex(i); currentText() < item;) {
for (setCurrentIndex(i); currentText().localeAwareCompare(item) < 0; ) {
// e.g. --Separator--
if (currentText()[0].category() != QChar::Letter_Uppercase)
break;