Skip site navigation (1)Skip section navigation (2)
Date:      Sat, 21 Nov 2015 23:57:46 +0300
From:      Andrey Chernov <ache@freebsd.org>
To:        Ed Schouten <ed@nuxi.nl>, Baptiste Daroussin <bapt@freebsd.org>
Cc:        Jilles Tjoelker <jilles@stack.nl>, "Sergey V. Dyatko" <sergey.dyatko@gmail.com>, FreeBSD Current <freebsd-current@freebsd.org>
Subject:   Re: /bin/ls formatting broken for non-C(?) locales
Message-ID:  <5650DACA.2090501@freebsd.org>
In-Reply-To: <CABh_MK=cz-zB7krcnKjhqfW9VnwjSmuaZ9%2BAETQiLy3AsHq_vw@mail.gmail.com>
References:  <20151120110556.6e20a71f@laptop.minsk.domain> <20151120104253.GA21071@ivaldir.etoilebsd.net> <20151120110212.GB21071@ivaldir.etoilebsd.net> <20151120122352.GA5751@stack.nl> <20151121003541.GF21071@ivaldir.etoilebsd.net> <CABh_MK=cz-zB7krcnKjhqfW9VnwjSmuaZ9%2BAETQiLy3AsHq_vw@mail.gmail.com>

next in thread | previous in thread | raw e-mail | index | archive | help
On 21.11.2015 15:18, Ed Schouten wrote:
> Hi Baptiste,
> 
> I suppose you should use the wcswidth() function somewhere to compute
> the visible width of the month name. Some characters may be
> double-width, others may have no effective width at all.
> 

I agree. Checking error return of wide chars functions with some
fallback will be good too.

-- 
http://ache.vniz.net/



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?5650DACA.2090501>