[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Nmh-workers] Thoughts: header/address parsing

From: Ralph Corderoy
Subject: Re: [Nmh-workers] Thoughts: header/address parsing
Date: Mon, 25 Aug 2014 11:09:07 +0100

Hi Ken,

> So ... what would break if the newline _wasn't_ counted?  I am leaning
> towards going the wcwidth() route and simply not counting things like
> that as printable.  I will note that isprint('\n') returns 0.

There's been many detours along the way so I could be confused, but I
think including it means formatting that attempts to fill the rest of
the terminal's line stops one short of the end, thus not triggering the
terminal's automatic right margin, assuming it has `am' or `sam'
terminfo capability.  You can see the difference by turning them off.

    $ printf '%*dfoo\n' `tput cols` 42
    $ tput rmam; printf '%*dfoo\n' `tput cols` 42; tput smam

How aware of the terminal are output routines?

Cheers, Ralph.

reply via email to

[Prev in Thread] Current Thread [Next in Thread]