Discussion:
[ast-developers] New -T/-P option for AST wc(1) to count in terminal cells ? / was: Fwd: Does AST printf(1)'s field width in "%3.4Ls" count in terminal cells or number of characters ?
Roland Mainz
2014-09-11 22:34:40 UTC
Permalink
Hi!

----

As a small followup to the question I'd like to add a new option to
wc(1) which measures in terminal cells using |wcwidth()|. I have the
patch ready&&tested except one question:

... Glenn: What would be the preferred option - "-T" for "terminal
cells" or "-P" for "positions" (POSIX wcwidth manpage talks about
"number of column positions of a wide-character code") ?

----

Bye,
Roland

---------- Forwarded message ----------
From: Roland Mainz <roland.mainz at nrubsig.org>
Date: Fri, Sep 12, 2014 at 12:08 AM
Subject: Does AST printf(1)'s field width in "%3.4Ls" count in
terminal cells or number of characters ?
To: AST / Korn Shell Users List <ast-users at research.att.com>


Hi!

----

Does AST printf(1)'s field width for "%Ls" count in terminal cells
(e.g. uses |wcwidth()|) or does it count in (multibyte-)charactes ?

What do typeset -L/-R use to measure/limit strings ?

----

Bye,
Roland

--
__ . . __
(o.\ \/ /.o) roland.mainz at nrubsig.org
\__\/\/__/ MPEG specialist, C&&JAVA&&Sun&&Unix programmer
/O /==\ O\ TEL +49 641 3992797
(;O/ \/ \O;)
--
__ . . __
(o.\ \/ /.o) roland.mainz at nrubsig.org
\__\/\/__/ MPEG specialist, C&&JAVA&&Sun&&Unix programmer
/O /==\ O\ TEL +49 641 3992797
(;O/ \/ \O;)
Loading...