Subject: Re: WSCONS color question
To: Jonathan Stone <jonathan@DSG.Stanford.EDU>
From: Matthias Drochner <drochner@zel459.zel.kfa-juelich.de>
List: current-users
Date: 03/17/1999 22:07:31
jonathan@DSG.Stanford.EDU said:
> Just from curiosity, what happens if i enable the vt100 emulator on a
> one-bit monochrome unix-workstation-vendor display, and then ask to
> use colours? 

The display driver passes a bitmask of so-called "capabilities"
to the wscons layer when it attaches. The terminal emulator is
supposed to check requests for character rendering attributes
against this mask so that it doesn't request things the display
driver can't do. It can select reasonable replacements instead;
the vt100 emulator will eg substitute "underline" by "brown
background" and ignore "blink" SGR requests if the display
driver doesn't provide it. On b/w displays, almost every kind
of highliting will end as "reverse" display. See
wsemul_vt100_subr.c:vt100_selectattribute() for details.

> Um, why is the screen size hardcoded into the name?  Won't that cause
> even more unecessary woes when we add support for reprogramming VGA
> text modes to use different screen sizes.  Or will the wscons design
> not support this at all? 

I didn't mention that there are more types: "80x50" and "80x50bf".
It's a linear list however which will grow by a factor for every
orthogonal feature introduced. Otoh, it might be that graphics hardware
is not that orthogonal - it might provide colors with one resolution
and not with another, so a protocol to tell the higher layers about
the capabilities could become quite complex if one tried to
optimize here.

best regards
Matthias