[LyX/2.5.x] Sort colors locale-aware
Juergen Spitzmueller <[email protected]> Thu, 14 May 2026 15:21:37 +0000
| Newsgroups | gmane.editors.lyx.cvs |
|---|---|
| Message-ID | <[email protected]> |
commit 2407ec9c7329b8509c095d7e1aa5bc4a6be40ddf Author: Juergen Spitzmueller <[email protected]> Date: Thu May 14 15:59:08 2026 +0200 Sort colors locale-aware Otherwise sorting is wrong outside English (cherry picked from commit b5f346da1a68a89bf9b3a2615222ee8d7a503ece) --- src/frontends/qt/qt_helpers.cpp | 3 ++- status.25x | 2 ++ 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/src/frontends/qt/qt_helpers.cpp b/src/frontends/qt/qt_helpers.cpp index 14f70f3f31..f84d2ec5a9 100644 --- a/src/frontends/qt/qt_helpers.cpp +++ b/src/frontends/qt/qt_helpers.cpp @@ -231,7 +231,8 @@ bool SortLocaleAware(QString const & lhs, QString const & rhs) bool ColorSorter(ColorCode lhs, ColorCode rhs) { - return compare_no_case(lcolor.getGUIName(lhs), lcolor.getGUIName(rhs)) < 0; + return QString::localeAwareCompare(toqstr(lcolor.getGUIName(lhs)), + toqstr(lcolor.getGUIName(rhs))) < 0; } diff --git a/status.25x b/status.25x index 78d74aebcf..9d5ffaa4e4 100644 --- a/status.25x +++ b/status.25x @@ -80,6 +80,8 @@ What's new - Fix on-screen representation of "pagewidth" length (bug 13309). +- Fix sorting of colors in preferences. + * INTERNALS -- lyx-cvs mailing list [email protected] https://lists.lyx.org/mailman/listinfo/lyx-cvs