termcap and negative numbers
Brandon S. Allbery KB8JRR
allbery at NCoast.ORG
Sun Feb 3 05:23:24 AEST 1991
As quoted from <17263 at cgl.ucsf.EDU> by srp at babar.mmwb.ucsf.edu (Scott R. Presnell):
+---------------
| Is there a standard extention to the termcap source code that
| allows the extraction of negative numbers via the tgetnum() call? Or has
| anyone implemented something like this? I'm just looking for a precedent.
+---------------
Since -1 from tgetnum() means "capability not present", there's potential for
interpretation problems here.
Note that "not present" is quite different from "0" in some cases; consider
"sg#0" vs. "sg@". The former is usually interpreted as the terminal has
"field" attributes which don't use visible screen memory, while the latter
means that the terminal has "character" attributes. (I still argue that the
former is really the "ms@" attribute, but the current behavior is too well
entrenched now to be changed.) Thus, the value "0" can't be used to say "not
present".
++Brandon
--
Me: Brandon S. Allbery VHF/UHF: KB8JRR on 220, 2m, 440
Internet: allbery at NCoast.ORG Packet: KB8JRR @ WA8BXN
America OnLine: KB8JRR AMPR: KB8JRR.AmPR.ORG [44.70.4.88]
uunet!usenet.ins.cwru.edu!ncoast!allbery Delphi: ALLBERY
More information about the Alt.sources.d
mailing list