Applications should be Unicode-sorted

Bug #621577 reported by Michael Terry
6
This bug affects 1 person
Affects Status Importance Assigned to Milestone
Unity
Fix Released
Medium
Mikkel Kamstrup Erlandsen
unity-lens-applications
Fix Released
Medium
Mikkel Kamstrup Erlandsen
unity (Ubuntu)
Fix Released
Undecided
Unassigned
unity-place-applications (Ubuntu)
Fix Released
Medium
Unassigned

Bug Description

Binary package hint: unity-place-applications

It appears that applications are currently sorted by code-point comparisons (i.e. the numeric Unicode value is higher or lower). But this isn't the Right Way to sort Unicode strings.

For example, see the attached screenshot. Where "Déjà Dup Backup Utility" comes after "Dogtail Recorder".

The Right Way way of sorting Unicode strings is according to the UCA: http://unicode.org/reports/tr10/ (which, to me, is pretty fascinating; it's a surprisingly complicated problem). This is the same method used by the Software Center to sort applications (https://wiki.ubuntu.com/SoftwareCenter#def-alphabetically).

There is a library, libicu that includes methods for sorting strings.

ProblemType: Bug
DistroRelease: Ubuntu 10.10
Package: unity-place-applications 0.2.12-0ubuntu1
ProcVersionSignature: Ubuntu 2.6.35-17.23-generic 2.6.35.2
Uname: Linux 2.6.35-17-generic i686
NonfreeKernelModules: nvidia
Architecture: i386
Date: Sat Aug 21 01:29:42 2010
EcryptfsInUse: Yes
ProcEnviron:
 LANGUAGE=en_US:en
 PATH=(custom, user)
 LANG=en_GB.utf8
 SHELL=/bin/bash
SourcePackage: unity-place-applications

Revision history for this message
Michael Terry (mterry) wrote :
Revision history for this message
Mikkel Kamstrup Erlandsen (kamstrup) wrote : Re: [Bug 621577] [NEW] Applications should be Unicode-sorted

We are purely relying on the unicode sorting libxapian provides right
now. I had actually expected that it would be correct, but evidently
not.

I'll look into if xapian has some magical switches to do correct
locale based collation, but if it's not built in I fear this may be
non-trivial to fix in a performant way.

Changed in unity-place-applications:
assignee: nobody → Mikkel Kamstrup Erlandsen (kamstrup)
importance: Undecided → Medium
status: New → Triaged
Revision history for this message
Mikkel Kamstrup Erlandsen (kamstrup) wrote :

Fixed in lp:unity-place-applications revision 115:
------------------------------------------------------------
revno: 115
fixes bug(s): https://launchpad.net/bugs/621577
committer: Mikkel Kamstrup Erlandsen <email address hidden>
branch nick: MASTER
timestamp: Tue 2010-09-28 15:44:45 +0200
message:
  Fix bug #621577 "Applications should be Unicode-sorted".

  The fix is done by implementing a Xapian::Sorter that uses g_utf8_collate_key() to generate collation keys for the current locale. In order for glib to pick up the correct collation rules we have to set LC_ALL and not just LC_MESSAGES on startup.
------------------------------------------------------------

Changed in unity-place-applications:
status: Triaged → Fix Committed
Changed in unity:
assignee: nobody → Mikkel Kamstrup Erlandsen (kamstrup)
importance: Undecided → Medium
status: New → Fix Committed
Omer Akram (om26er)
Changed in unity-place-applications (Ubuntu):
importance: Undecided → Medium
status: New → Triaged
Revision history for this message
Launchpad Janitor (janitor) wrote :

This bug was fixed in the package unity-place-applications - 0.2.26-0ubuntu2

---------------
unity-place-applications (0.2.26-0ubuntu2) maverick; urgency=low

  * Cherry-pick from upstream:
    - "Applications should be Unicode-sorted". (LP: #621577)
 -- Didier Roche <email address hidden> Fri, 01 Oct 2010 13:11:05 +0200

Changed in unity-place-applications (Ubuntu):
status: Triaged → Fix Released
Neil J. Patel (njpatel)
Changed in unity-place-applications:
status: Fix Committed → Fix Released
Changed in unity:
status: Fix Committed → Fix Released
Changed in unity (Ubuntu):
status: New → Fix Released
To post a comment you must log in.
This report contains Public information  
Everyone can see this information.

Other bug subscribers

Remote bug watches

Bug watches keep track of this bug in other bug trackers.