Google Groups no longer supports new Usenet posts or subscriptions. Historical content remains viewable.
Dismiss

matching base character

2 views
Skip to first unread message

Pádraig Brady

unread,
Jul 10, 2006, 4:58:20 AM7/10/06
to
Hi,

How does one compare characters using only primary weights?

For example I would like "a á â" to be equal according to the locale.
I think that strcoll will treat them as equal using primary weight,
but then iterate again to compare with secondary and tertiary weights.

thanks,
Pádraig.

--
Linux-UTF8: i18n of Linux on all levels
Archive: http://mail.nl.linux.org/linux-utf8/


Danilo Segan

unread,
Jul 13, 2006, 11:01:05 AM7/13/06
to
On Monday at 10:58, Pádraig Brady wrote:

> How does one compare characters using only primary weights?
>
> For example I would like "a á â" to be equal according to the locale.
> I think that strcoll will treat them as equal using primary weight,
> but then iterate again to compare with secondary and tertiary weights.

Perhaps write your own locale for that and set LC_COLLATE to it? On
GNU libc systems, you can have them locally installed (eg. in your
$HOME) as well using I18NPATH and LOCPATH environment variables.

Cheers,
Danilo

William J Poser

unread,
Jul 14, 2006, 10:37:23 PM7/14/06
to
Another way of getting a non-standard sort order is to use
a sort utility that allows you to specify the sort order explicitly.
My own contribution is msort (http://billposer.org/Software/msort.html).

Bill Poser

0 new messages