[comp.terminals] termcap/terminfo stupidity?

loverso@encore.UUCP (John LoVerso) (09/02/87)

Can someone in-the-know tell me why magic-cookie glitches are not fully
described in either termcap or terminfo?  Termcap lets you specify
a magic cookie for standout or underline (sg,ug); terminfo only
has a capability for one magic cookie value (xmc).  Neither try to
describe cookies on attributes (blink, bold, dim, invis, rev).

My problem is that I've got a Wyse WY75.  It has an "enhance attribute
mode" which is magic cookie free.  However, all chars on the screen
written with enhance on have to be the same attribute - dim, inverse, or
underline.  SGR (\E[p0;p1...m) simply turns enhance on or off - only
the last param is effective, 0 being enhance off, >0 on.  So, I've got
standout set to use the enhance mode.  Wyse also includes a WYFDAT
(`field attribute') which gives you the 32 combinations of dim, blink,
blank, underline, and inverse.  However, this uses a magic cookie.
I use this for underline, and the appropriate atrributes.  I can give
"ug" for the underline magic cookie, but not for the others!

BTW, `more' in 4.3 correctly uses so/se/sg and us/ue/ug.  `ul' uses just
so/se, us/ue, plus the other attributes, but it mucks up badly because of
the lack of handling of magic cookies (sg/ug).  *sigh*

--
John LoVerso, Encore Computer Corp
encore!loverso, loverso@multimax.arpa (XXX)

gwyn@brl-smoke.ARPA (Doug Gwyn ) (09/04/87)

In article <1894@encore.UUCP> loverso@encore.UUCP (John LoVerso) writes:
>Can someone in-the-know tell me why magic-cookie glitches are not fully
>described in either termcap or terminfo?  Termcap lets you specify
>a magic cookie for standout or underline (sg,ug); terminfo only
>has a capability for one magic cookie value (xmc).  Neither try to
>describe cookies on attributes (blink, bold, dim, invis, rev).

Terminfo intends for "xmc" to cover all mode setting, on the assumption
that if one mode setting uses the "magic cookie" glitch, so will the
others.  Termcap "sg" and "ug" predate the "m*" mode-setting capabilities;
if you have magic cookie glitches for the "m*" capabilities, try setting
both "sg" and "ug" and hope that termcap-using applications are clever
enough to understand that this indicates that the "m*" capabilities are
similarly affected.

It really isn't practicaly for termcap/terminfo to try to anticipate
all the design botches that terminal manufacturers keep coming up
with.  They try to support a variety of implementations of a few simple
models for terminals; anything that does not fit the model cannot be
fully and correctly described by these databases.  Usually, though, a
subset of the terminal's capabilities CAN be described, and this is
what is normally done in such cases.

>My problem is that I've got a Wyse WY75.

Yes, that is your problem.  From what you say, the Wyse WY75 pretends
to support the ANSI mode-setting escape sequence, but doesn't do it
correctly.  If it indeed does not allow individual fields to have
different modes, then the 'm*" capabilities are NOT supported by the
terminal (at least no more than one of them), and your termcap should
reflect this.

You might try using the WYFDAT sequences and set all the "glitch"
capabilities (probably to 1).

allbery@ncoast.UUCP (09/07/87)

As quoted from <1894@encore.UUCP> by loverso@encore.UUCP (John LoVerso):
+---------------
| Can someone in-the-know tell me why magic-cookie glitches are not fully
| described in either termcap or terminfo?  Termcap lets you specify
| a magic cookie for standout or underline (sg,ug); terminfo only
| has a capability for one magic cookie value (xmc).  Neither try to
| describe cookies on attributes (blink, bold, dim, invis, rev).
+---------------

Wyse terminals are properly described as "even more braindamaged than
Televideos".  (You want _real_ brain damage?  I have a Teleray 1061!
You have two options for attributes:  _asymmetrical_ invisible magic
cookies, or symmetrical but visible (dual parallel vertical bars) ones.
The standard termcap uses invisible attributes and fixes the asymmetry
by including an extra space at appropriate points and setting sg#2!!!)

Wyse has other problems.  I can hang a Wyse 50 to the point that the power has
to be cycled to fix it by sending it VT100 control codes.  (Happened a lot at
TDI:  they have both, and move them around periodically.  And no reason for it
in the control codes; <ESC> [ is a cursor position command.)  I have yet to
see a Wyse terminal with the yoke on straight (the text looks like the Leaning
Tower of Pisa).  The stupid handling of attributes has already been mentioned;
with memory so cheap nowadays, *why* can't they release a terminal which does
attributes right???  After all, it's not as if they don't build new models
constantly -- they sell them to Altos; seen the "Altos V"?  RS422, forsooth!
And of course they had a chance to do it right with the 60, and didn't....

I, personally, will take a cheap PC clone running Procomm over a Wyse
so-called "VT100 compatible" any day.  It's cheaper, and the attributes
are done _right_.
-- 
	    Brandon S. Allbery, moderator of comp.sources.misc
  {{harvard,mit-eddie}!necntc,well!hoptoad,sun!mandrill!hal}!ncoast!allbery
ARPA: necntc!ncoast!allbery@harvard.harvard.edu  Fido: 157/502  MCI: BALLBERY
   <<ncoast Public Access UNIX: +1 216 781 6201 24hrs. 300/1200/2400 baud>>
All opinions in this message are random characters produced when my cat jumped
(-:		      up onto the keyboard of my PC.			   :-)

richard@islenet.UUCP (Richard Foulk) (09/08/87)

In article <4476@ncoast.UUCP> allbery@ncoast.UUCP (Brandon Allbery) writes:
>
> Wyse terminals are properly described as "even more braindamaged than
> Televideos".  [...]

God.  Nothing's worse than a Televideo.

> 
> Wyse has other problems.  I can hang a Wyse 50 to the point that the power has
> to be cycled to fix it by sending it VT100 control codes.  (Happened a lot at

Try hitting control-setup.  Unfortunately, most terminals have a
lock-keyboard sequence, at least the Wyse lets you unlock from the
keyboard if you know the trick.

> TDI:  they have both, and move them around periodically.  And no reason for it
> in the control codes; <ESC> [ is a cursor position command.)  I have yet to
> see a Wyse terminal with the yoke on straight (the text looks like the Leaning
> Tower of Pisa).  The stupid handling of attributes has already been mentioned;
> with memory so cheap nowadays, *why* can't they release a terminal which does
> attributes right???  After all, it's not as if they don't build new models
> 

The Wyse-50 isn't perfect.  But it is cheap, and it's fast as hell.  We
run ours at 38.4K baud with handshaking turned off, fed by lightly loaded
full-DMA ports with no problems.  Sure is nice.

> I, personally, will take a cheap PC clone running Procomm over a Wyse
> so-called "VT100 compatible" any day.  It's cheaper, and the attributes
> are done _right_.

Now that's one that'll make you wait all day for a screen-full to scroll.


-- 
Richard Foulk		...{dual,vortex,ihnp4}!islenet!richard
Honolulu, Hawaii