[pacman-dev] coloured pacman
Aaron Griffin
aaronmgriffin at gmail.com
Tue Feb 6 15:37:04 EST 2007
On 2/6/07, Dan McGee <dpmcgee at gmail.com> wrote:
> On 2/6/07, Jürgen Hötzel <juergen at hoetzel.info> wrote:
> > Its not easy to display colored text in a portable way. An easy, but
> > wrong way is using ANSI escape sequences directly because you make
> > assumption about the tty.
> >
> > A much more portable way is querying the database of terminal capabilities
> > (termcap/terminfo).
> >
> > Jürgen
>
> Much better put than my point about hardcoding the escape sequences in
> C code. Although not necessarily good in a bash script, the code can
> be edited if necessary quite easily to fix escape sequences. However,
> Jürgen makes the excellent point that these escape sequences cannot
> always be assumed to be portable.
And, one of the things I said the last time (6 months ago?) about this
topic, was that, it'd be nice to support bold/underline or whatever on
mono terminals too, in the absence of color. That'd be real fancy.
More information about the pacman-dev
mailing list