Cursor off/cursor on
Brian K. White
brian at aljex.com
Tue Jul 31 09:39:52 PDT 2007
----- Original Message -----
From: "Barry Wiseman" <barry at gensoftdes.com>
To: "filePro list" <filepro-list at lists.celestial.com>
Sent: Tuesday, July 31, 2007 11:12 AM
Subject: Cursor off/cursor on
> These appear to require CF and CN entries in termcap. I'm feeling really
> dumb that I
> cannot discover the correct values for these entries. Any help
> appreciated.
> Terminal type is linux console.
There is no garantee that a given terminal even has that feature or any
particular, or that it works right even if it claims to have it. It's
entirely possible the linux console simply lacks this feature. Unlikely in
this particular case, but just pointing out, different terminals supply
different features, or impliment them differently from others etc.
Also, several termcap features are known by more than one name. Search docs
for "cursor" not for CN.
And you may come across some other termcap field name that basically means
cursor-on, and you just copy the escape sequence to CN where fp can see it.
Also, several outward appearing features can be accomplished more than one
way, including sometimes very kludgy Rube Goldberg ways by using other
features that do exist. A thing might be technically possible but only by a
means so kludgy you should not do it. Like in this case, maybe the linux
console has no dedicated feature for cursor-on-off, but maybe it's possible
to, I dunno, move the cursor to a position off-screen or maybe somehow set
it's color to match the underlying background color (and somehow track that
as the cursor moves around to different colored areas of the screen), or
maybe less kludgy but not immediately obvious, change it's size to 0 or -1
lines.. or define a new scrolling window space off screen and shift focus
there...
All that said:
Searching for "cursor" in "man console_codes" yields:
----snip----
ESC [ ? 25 h
DECTECM (default on): Make cursor visible.
----snip----
...not helpful since I see no cursor-off there nor a way to deduce "off"
from "on" or other controls.
However, searching for "cursor" in "man termcap" yields:
---snip---
ve Normal cursor visible
vi Cursor invisible
---snip---
And searching for ":ve=" in the linux entry in /etc/termcap yields...
---snip---
:ve=\E[?25h\E[?0c:vi=\E[?25l\E[?1c:
---snip---
Voila.
Also, if /etc/termcap had not happened to define this feature, You could
still search for the same feature in terminfo and translate the result to
termcap. "man terminfo" to find the feature name, and then "infocmp |less"
to see if that feature is defined in your current terminfo.
If that still hadn't yielded it, There are still more places to look. Next
you would search both termcap and terminfo for the same feature in other
similar terminals besides linux itself. The linux console is closest to
vt220, which is almost the same as all the other vt's, vt100 is the most
common and docs about it exist everywhere so you might find some odd feature
documented there and it might turn out to work on linux even if the man page
doesn't specifically mention it. It's also similar to xterm, and ALL of
these are variants of "ansi".
Also, by search I mean searching google and not caring what OS the results
are from. Terminals are used on all os's and there may be some amazingly
detailed docs about ansi terminals in some sun or hpux docs or on a terminal
manufacturer site itself.
Brian K. White brian at aljex.com http://www.myspace.com/KEYofR
+++++[>+++[>+++++>+++++++<<-]<-]>>+.>.+++++.+++++++.-.[>+<---]>++.
filePro BBx Linux SCO FreeBSD #callahans Satriani Filk!
More information about the Filepro-list
mailing list