Quote:
Originally Posted by Jellby
I always wonder, on the fundamental side of the problem (i.e., about the ordering itself, not about how to achieve it), what is the best way of sorting multilingual entries.
|
AFAIK, c++ has locale-aware sort functions, e.g.
collate, which produces the following sort orders, depending on the locale:
Code:
Default locale collation order: Zebra ar förnamn zebra ängel år ögrupp
English locale collation order: ängel ar år förnamn ögrupp zebra Zebra
Swedish locale collation order: ar förnamn zebra Zebra år ängel ögrupp
However, as KevinH has said,
Sigil doesn't do any sorting, but relies on QString comparison, which is a locale-unaware Qt library function. I.e., the only way to get the desired sort order would be to add the unaccented word in the second column.
For example, if you change the last entry to:
Code:
âge ages/âges de la vie
It'll be listed under A:
Code:
Acton
Acton Harold 1
agenda 1
ages
âges de la vie 1
Agnelli
Agnelli Gianni 1
agrafe 1
Obviously, as post-editing step, you'd have to change "ages" back to "âges." This could be handled by a Python script, either as a Sigil plugin, as suggested in
this post, or a stand-alone script.