[RFC] ColorD

Adam D. Ruppe destructionator at gmail.com
Sun Oct 28 06:51:12 PDT 2012


On Sunday, 28 October 2012 at 10:44:58 UTC, Jens Mueller wrote:
> How?

The file /etc/termcap has the data too so opening it and quickly 
parsing should give the same result as the environment variable.

It looks like this:

vg|vt-generic|Generic VT entries:\
         :bs:mi:ms:pt:xn:xo:it#8:\
<snip>
# Slackware 3.1 linux termcap entry (Sat Apr 27 23:03:58 CDT 
1996):
lx|linux|console|con80x25|LINUX System Console:\
         :do=^J:co#80:li#25:cl=\E[H\E[J:sf=\ED:sb=\EM:\
<snip>

and so on. The $TERM variable is used as a key into one of those 
names, then the rest of the data is on the following lines.

The termcap entries can also inherit from other entries, but 
again it is just a key lookup into the list.





More information about the Digitalmars-d mailing list