delorie.com/archives/browse.cgi   search  
Mail Archives: cygwin/2002/11/06/18:31:37

Mailing-List: contact cygwin-help AT cygwin DOT com; run by ezmlm
List-Subscribe: <mailto:cygwin-subscribe AT cygwin DOT com>
List-Archive: <http://sources.redhat.com/ml/cygwin/>
List-Post: <mailto:cygwin AT cygwin DOT com>
List-Help: <mailto:cygwin-help AT cygwin DOT com>, <http://sources.redhat.com/ml/#faqs>
Sender: cygwin-owner AT cygwin DOT com
Mail-Followup-To: cygwin AT cygwin DOT com
Delivered-To: mailing list cygwin AT cygwin DOT com
Message-Id: <5.1.0.14.2.20021106151936.01febb78@pop3.cris.com>
X-Sender: rrschulz AT pop3 DOT cris DOT com
Date: Wed, 06 Nov 2002 15:31:33 -0800
To: cygwin AT cygwin DOT com
From: Randall R Schulz <rrschulz AT cris DOT com>
Subject: Re: Problem with function keys codes with vt100 emulation
In-Reply-To: <00eb01c285e9$2c10ae00$b001a8c0@coosbayreza>
References: <5 DOT 1 DOT 0 DOT 14 DOT 2 DOT 20021106131511 DOT 0212e850 AT pop3 DOT cris DOT com>
Mime-Version: 1.0

Reza,

The TERM variable is most certainly _not_ broken. You're misunderstanding 
what it's for. The TERM variable is how programs that must adapt to 
different terminal types (emulators or physical hardware) find out how to 
properly drive the terminal's display and respond to characters sent by it.

Some applications use termcap, others use compiled terminfo. They're 
conceptually the same thing (hence the possibility for a utility like 
"captoinfo"). They simply are a way to capture the details of how software 
should interact with a terminal (or a terminal emulator).

There are many terminals out there (I think--I haven't seen one for years 
now) and they all use distinct control sequences and produce distinct key 
sequences. That's why one needs something like termcap or terminfo.

Beyond curiosity, which is fine, there's no need for you to know the 
details of the design and operation of a terminal emulator (any more than 
you need to know how a hardware terminal works, as long as it does work...).

I'm not sure you actually have a problem, do you? Any program that uses 
either termcap or terminfo (correctly) should work under Cygwin as long as 
the TERM variable is set properly. Why are you trying to change TERM? Just 
leave it the way Cygwin initializes it and you should be fine.

As I said, I don't know anything about captoinfo, so I can't help you with 
it. Have you read its man page?

Randall Schulz
Mountain View, CA USA


At 15:06 2002-11-06, you wrote:
>Randall, thanks for the quick response.
>
>So the TERM environment variable is somewhat broken, in that setting it to
>something else is a no-op.  The first question that comes to mind is whether
>this is characterized as a bug or a feature, and if a bug how deep does it
>run, and how likely that it will ever be fixed.
>
>On the issue of 3 terminal emulation models (cygwin console, RXVT, and
>xterm) I am a bit lost.  Forgive me for being slow here, but if I understand
>you correctly the terminal emulation model is hard-coded into these
>applications (knowing how would be nice).  Does this mean that /etc/termcap
>is not used at all?  For example, if I change the termcap entry for linux
>(cygwin inherits from linux) to generate vt100 function key codes then will
>I get \EOP for f1 in the cygwin console?
>
>Is there any reference materials I can read to bring myself up to date on
>the architectural issues/shortcomings here?
>
>On the problem with captoinfo the issue is that it prints nothing (other
>than errors) to stdout.  I have captured the output of "captoinfo
>/etc/termcap" and "captoinfo -V /etc/termcap" in the two attached file for
>your reference.  As I said before, considering the findings so far, this is
>probably unrelated to the topic of the discussion.
>
>Thanks again,
>
>Reza


--
Unsubscribe info:      http://cygwin.com/ml/#unsubscribe-simple
Bug reporting:         http://cygwin.com/bugs.html
Documentation:         http://cygwin.com/docs.html
FAQ:                   http://cygwin.com/faq/

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019