Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > gnu.bash.bug > #11425

help builtin generates unaligned results for multicolumn widechars.

From "Mingye Wang (Arthur2e5)" <arthur200126@hotmail.com>
Newsgroups gnu.bash.bug
Subject help builtin generates unaligned results for multicolumn widechars.
Date 2015-08-22 21:59 +0800
Message-ID <mailman.71.1440251977.11330.bug-bash@gnu.org> (permalink)

Show all headers | View raw


[Multipart message — attachments visible in raw view] - view raw

Version: <= 4.4-alpha

In bash's `help.def' builtin, wdispcolumn() is used to display `help'
columns. It terminates the string at wcstr[width - 1], with a comment
that assmues each wide character to be exactly one column wide.

This works fine with most languages where widechars are, actually, one
column wide. But with East Asian languages, more specifically Chinese,
Japanese & Korean, it would produce terrible results.

Maybe bash should consult wcswidth(wcstr+1,displen), or get the `len' in
wcsnwidth() changed to some additional int* argument to store it, and
consider the the difference between the real width and displen.

-- 
Regards,
Arthur2e5 (0x222D7BDA)


Back to gnu.bash.bug | Previous | Next | Find similar


Thread

help builtin generates unaligned results for multicolumn widechars. "Mingye Wang (Arthur2e5)" <arthur200126@hotmail.com> - 2015-08-22 21:59 +0800

csiph-web