[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: misalignment in ls -l in fr_FR locale
From: |
Pádraig Brady |
Subject: |
Re: misalignment in ls -l in fr_FR locale |
Date: |
Fri, 20 Mar 2009 15:25:52 +0000 |
User-agent: |
Thunderbird 2.0.0.6 (X11/20071008) |
Samuel Thibault wrote:
> Pádraig Brady, le Fri 20 Mar 2009 12:23:29 +0000, a écrit :
>>
>> Note that I get shorter abmon values, and also the alignment is fine?
>
> That's because it's an old glibc. You can try using some other locale
> that has variable sized-abmon, like possibly ar_JO, ar_LB, ar_SY, as_IN,
> bn_BD, bn_IN, el_GR, fa_IR, ga_IE, hi_IN, ht_HT, hu_HU, mi_NZ, ml_IN,
> sd_IN, ta_IN, te_IN, yi_US.
>> All my french locales have the shorter abbreviations BTW?
>> $ locale -a | grep ^fr.*utf8 | while read LANG; do echo -n $(locale abmon);
>> echo " $LANG"; done
>> jan;fév;mar;avr;mai;jun;jui;aoû;sep;oct;nov;déc fr_BE.utf8
>
> Yes, that's the old abmon from glibc, is has changed in HEAD.
Oh right:
http://sourceware.org/bugzilla/show_bug.cgi?id=9859
http://sourceware.org/cgi-bin/cvsweb.cgi/libc/localedata/locales/fr_FR.diff?r1=1.14&r2=1.15&cvsroot=glibc&f=h
Wow misaligned names are surprisingly unreadable:
$ LANG=ga_IE.utf8 TIME_STYLE=+"%b %e %H:%M" ./ls -l -h ls.c echo.c
-rw-rw-r-- 1 padraig padraig 6.3K Ean 21 17:46 echo.c
-rw-rw-r-- 1 padraig padraig 124K Márta 6 22:47 ls.c
As in the other thread that Eric referenced above,
strftime("%5b") should align to displayed characters rather than bytes.
If that is not feasible (I guess it might not be) then we could
detect the %b (with or without width), and use something like
this to format that portion separately.
http://git.kernel.org/?p=utils/util-linux-ng/util-linux-ng.git;a=blob;f=misc-utils/cal.c;h=2417f1b5a999f0546d16a46dc1e85d937bafb671;hb=HEAD#l765
cheers,
Pádraig.
- misalignment in ls -l in fr_FR locale, Samuel Thibault, 2009/03/17
- Re: misalignment in ls -l in fr_FR locale, Eric Blake, 2009/03/18
- Re: misalignment in ls -l in fr_FR locale, Pádraig Brady, 2009/03/20
- Re: misalignment in ls -l in fr_FR locale, Samuel Thibault, 2009/03/20
- Re: misalignment in ls -l in fr_FR locale,
Pádraig Brady <=
- Re: misalignment in ls -l in fr_FR locale, Pádraig Brady, 2009/03/23
- Re: misalignment in ls -l in fr_FR locale, Pádraig Brady, 2009/03/24
- Re: misalignment in ls -l in fr_FR locale, Pádraig Brady, 2009/03/24
- Re: misalignment in ls -l in fr_FR locale, Pádraig Brady, 2009/03/25
- Re: misalignment in ls -l in fr_FR locale, Jim Meyering, 2009/03/26
- Re: misalignment in ls -l in fr_FR locale, Jim Meyering, 2009/03/26
- Re: misalignment in ls -l in fr_FR locale, Pádraig Brady, 2009/03/26
- Re: misalignment in ls -l in fr_FR locale, Jim Meyering, 2009/03/26
- Re: misalignment in ls -l in fr_FR locale, Jim Meyering, 2009/03/26
- Re: misalignment in ls -l in fr_FR locale, Pádraig Brady, 2009/03/27