Thread View: news.software.readers
3 messages
3 total messages
Started by John E. Davis
Thu, 10 Apr 1997 00:00
Re: slrn and colors
Author: John E. Davis
Date: Thu, 10 Apr 1997 00:00
Date: Thu, 10 Apr 1997 00:00
79 lines
3569 bytes
3569 bytes
On 06 Apr 1997 20:40:02 EDT, Vikas Agnihotri <vikas@insight.att.com>
wrote:
> Why cant I set the background /foreground colors to anything that I want i.e.
>any color that I can otherwise set my xterm to using xterm -bg or -fg?
[...]
>For that matter, why cant I specify any color in the X rgb.txt file for the
>slrn foreground/background colors of any 'object� ?
It does not work that way. The terminal is emulating a color ANSI
terminal and slrn communicates with it by sending escape
sequences. As far as color is concerned, the escape sequences are
of the form:
ESC [ 3 f m
ESC [ 4 b m
where `f' and `b' are integers that specify the foreground and
bounground color, resp. The integers only range from 0 to 7 which
means that only 8 different colors are possible. In particular:
f or b RGB description
------------------------------------
0 000 black
1 100 red
2 010 green
3 110 brown
4 001 blue
5 101 magenta
6 011 cyan
7 111 gray
It might be possible for you to configure your terminal to associate
different colors with these integers. I am sure that this is possible
with rxvt and it is most likely possible with a color xterm.
Two other character attributes can influence the color of a character;
however, I do not believe that they are standard:
Bold attribute (ESC [ 1 m)
Blink attribute (ESC [ 5 m)
If a character is displayed with the bold attribute, the color of the
foreground character may appear brigher. For example, brown (f = 3)
may appear as yellow and gray may appear as white. The high intensity
attribute only affects the foreground color--- not the background
color. Thus by using this attribute, it is possible to get 16
distinct foreground colors on most ANSI terminals (but only 8
background colors).
As far as I know, only rxvt allows high intensity background colors
via the blink attribute. That is, one can get a bright brown (or
yellow) background in rxvt by setting the blink attribute for a
character whose background color is brown. Other terminals may simply
display a flashing character. (The VGA video card can be programmed
to allow the blink attribute to enable high intensity background
colors. For that reason, it should be possible to get such colors on
the Linux console. Unfortunately, this feature does not seem to be
available to programs. slrn under OS/2 and MSDOS reprograms the video
card to allow, e,g., a white background. Under the Linux console,
only light gray appears possible at this time.)
If you run slrn using rxvt, or you have a terminal that enables the
blink attribute used this way, add
set use_blink 1
to your .slrnrc file. If using jed, add
TERM_BLINK_MODE = 1;
to your .jedrc file.
--John
Re: slrn and colors
Author: Rod
Date: Fri, 11 Apr 1997 00:00
Date: Fri, 11 Apr 1997 00:00
60 lines
2436 bytes
2436 bytes
John E. Davis, davis@space.mit.edu:
>It might be possible for you to configure your terminal to associate
>different colors with these integers. I am sure that this is possible
>with rxvt and it is most likely possible with a color xterm.
The color-xterm (per?)versions I'v run across so far have all had
entries in the /usr/lib/X11/app-defaults/XTerm file that look
something like this (my changes notwithstanding):
xterm.?.foreground: ivory
xterm.?.background: black
*underLine: on
!
*VT100*color0: black
*VT100*color1: red3
*VT100*color2: green4
.
.
.
.
*VT100*color15: grey85
*VT100*colorBD: rosybrown3
*VT100*colorUL: cyan4
This is from an ansi-sb-on-right-blah-ad-infinitum, but all the ones
I've seen (so far), look like this. I've forgotton which are which,
so it'll be trial and error, but one shoud be able to add any or
all to the command line via: -xrm "*VT100*color0: hotpink", should
one be so inclined.
>color. Thus by using this attribute, it is possible to get 16
>distinct foreground colors on most ANSI terminals (but only 8
>background colors).
That would explain the number in the resource file.
>As far as I know, only rxvt allows high intensity background colors
>via the blink attribute. That is, one can get a bright brown (or
>yellow) background in rxvt by setting the blink attribute for a
[...]
Now, if only the attributes wouldn't change underneath the
curser in jed (I know you've mentioned that it's an xterm
problem, not a jed problem) so that I didn't need to do
a screen refresh manually from time to time, I'd be a
happy camper.
--
davids@davids.psyberlink.net
Steinberger:
State of the Instrument
Re: slrn and colors
Author: T.E.Dickey
Date: Fri, 11 Apr 1997 00:00
Date: Fri, 11 Apr 1997 00:00
13 lines
1009 bytes
1009 bytes
John E. Davis <davis@space.mit.edu> wrote: : As far as I know, only rxvt allows high intensity background colors : via the blink attribute. That is, one can get a bright brown (or XFree86 xterm makes blink & bold equivalent (though of course, that's not something that portable applications should assume ;-) -- Thomas E. Dickey dickey@clark.net http://www.clark.net/pub/dickey
Thread Navigation
This is a paginated view of messages in the thread with full content displayed inline.
Messages are displayed in chronological order, with the original post highlighted in green.
Use pagination controls to navigate through all messages in large threads.
Back to All Threads