[Coco] xterm termset descriptor

Willard Goosey goosey at virgo.sdc.org
Sun Dec 27 23:21:22 EST 2009


Ok, it looks like about the only difference between an xterm terminal
and an ansi terminal (at least that termset concerns itself with) is
that ansi terminals apparently[1] home the cursor on a clear-screen,
and xterms don't.

[1]The stock termset entry for ANSI assumes that clear-screen will
home the cursor.  The only documentation I have on the ANSI terminal
is the MS-DOS 5 manual on ansi.sys, which agrees that clear-screen
homes the cursor.

I just tested rxvt and konsole, and they don't home the cursor on
clear-screen.  

In the stock /etc/termcap distributed in Slackware 12, both ansi and
xterm reference a vt-generic type, which does not assume that a
cursor-home is done automatically by clear-screen.

So, the easiest way to get an xterm entry for termset is to run the
maketerm command:

Name: XTERM
Cursor Control code: $1b[\Y\Y;\X\XH
cursor offset value: $01
delete line: $1b[M
delete character: $1b[P
Clear Screen: $1b[H$1b[2J
Clear to end of line: $1b[K
Start Alternate: $1b[7m
End Alternate: $1b[0m
Screen Length: $18
Screen Width: $50

This may make for a better generic ANSI termset entry then the old
one, also.  YMMV.

I knew termset was sort of a stripped-down termcap, but I hadn't
realized just HOW stripped-down it was.  Notice a complete lack of
relative cursor positioning.  It's just as well that Microware quit
being so silly and just used termcap.

Willard
-- 
Willard Goosey  goosey at sdc.org
Socorro, New Mexico, USA
I search my heart and find Cimmeria, land of Darkness and the Night.
  -- R.E. Howard



More information about the Coco mailing list