- Subject: Re: Access to terminfo-specific capabilities
- From: "John E. Davis" <davis>
- Date: Sat, 15 Sep 2001 03:04:36 -0400
Pavel Roskin <proski@xxxxxxx> wrote:
>SLtt_tigetstr() in S-Lang 1.4.4 accepts termcap names only and doesn't
>fallback to the raw terminfo names, such as "kmous".
Use "Km". Most terminfo man pages give both the terminfo names and
their termcap equivalents.
Incidently, I looked into writing a wrapper around the "kmous"
capability sometime last year. However, I concluded that either I did
not understand how to use this terminfo feature (its poorly
documented), or that its addition to the terminfo database was poorly
thought out. As I recall, there was a terminfo capability to enable
mouse use ("Gm"), but no corresponding ability to disable it. A
properly behaved program needs to do both. In addition, there was no
specification on how one is to parse the escape sequence to determine
the mouse position. In other words, one pretty much has to assume the
xterm mouse protocol, and hard-code support for it, which defeats the
purpose of having its specification in the terminfo database.
Finally, the meaning of the "kmous" capability appears to be open to
interpretation making its use somewhat non-portable. The following
text was extracted from the terminfo man page:
Be careful assigning the kmous capability. The ncurses
wants to interpret it as KEY_MOUSE, for use by terminals
and emulators like xterm that can return mouse-tracking
information in the keyboard-input stream.
--John
[2001 date index]
[2001 thread index]
[Thread Prev] [Thread Next]
[Date Prev] [Date Next]