[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [Groff] preserve ascii escape characters from input
From: |
Ralph Corderoy |
Subject: |
Re: [Groff] preserve ascii escape characters from input |
Date: |
Thu, 25 Feb 2010 09:30:01 +0000 |
Hi,
I wrote:
> Perhaps better would be to give an example command that shows the
> effect, e.g. using printf(1)
>
> printf 'before\x1b[1mbold\x1b[mafter\n'
>
> and have the user run that if they think their terminal supports it.
The man page should probably also mention terminal-independent ways of
doing some of these escape sequences, e.g. tput(1) and terminfo(5).
These two produce the same bytes on a terminal that supports ANSI,
printf 'aaa\x1b[1mbbb\x1b[m\x1b(Bccc\n'
echo "aaa`tput bold`bbb`tput sgr0`ccc"
but the latter will also work on other terminals. It's horrible when
commands hard-code ANSI escape sequences, e.g. the otherwise good
dstat(1).
Cheers,
Ralph.
- [Groff] preserve ascii escape characters from input, Leonardo Boiko, 2010/02/24
- Re: [Groff] preserve ascii escape characters from input, Werner LEMBERG, 2010/02/24
- Re: [Groff] preserve ascii escape characters from input, Ted Harding, 2010/02/24
- Re: [Groff] preserve ascii escape characters from input, Ralph Corderoy, 2010/02/25
- Re: [Groff] preserve ascii escape characters from input, Ted Harding, 2010/02/25
- Re: [Groff] preserve ascii escape characters from input,
Ralph Corderoy <=
- Re: [Groff] preserve ascii escape characters from input, Leonardo Boiko, 2010/02/25
- Re: [Groff] preserve ascii escape characters from input, Keith Marshall, 2010/02/25
- Re: [Groff] preserve ascii escape characters from input, Leonardo Boiko, 2010/02/27
- Re: [Groff] preserve ascii escape characters from input, Ralph Corderoy, 2010/02/27
- Re: [Groff] preserve ascii escape characters from input, Ralph Corderoy, 2010/02/27
- Re: [Groff] preserve ascii escape characters from input, Mike Bianchi, 2010/02/27
- Re: [Groff] preserve ascii escape characters from input, Werner LEMBERG, 2010/02/25