bug-ncurses
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

terminfo for Darwin PowerPC Console and MacOS X Terminal.app


From: Ben Sittler
Subject: terminfo for Darwin PowerPC Console and MacOS X Terminal.app
Date: Thu, 19 Jul 2001 15:30:07 -0500 (CDT)

Attached to this message are terminfo descriptions of the Darwin PowerPC
console ("xnuppc") and Apple's MacOS X Terminal.app ("nsterm"). These
supercede my previous descriptions (called "Darwin_Console" and
"Apple_Terminal", respectively.) The old names had three problems: they
were too long to append qualifiers to while still remaining within the
limits of classic compiled terminfo, they included uppercase characters,
and they were inaccurate.

These descriptions have been tested fairly extensively using ncurses and
Solaris curses, and appear to work.

Since many MacOS X programs were compiled with BSD curses, and BSD curses
is included in the C library (!), it can be rather difficult to get them
working with ncurses. Furthermore, the version of BSD curses (or termlib?)
they use is incapable of using references ("tc=xxx",) and dies on
commented-out capabilities (those starting with "..".) To work with these
programs, I autogenerate a TERMCAP environment variable at login using
these (bash) shell commands:

export TERMCAP="$(
                     infocmp -TCr 2>&- |
                         sed -ne '      s/^[    ]*//
                                        s/[     ]*$//
                                        s/^#.*//
                                  /^$/  b
                                        H
                                  $     {
                                            g
                                            s/^\n*//
                                            s/:\\\n:/:/g
                                            s/:\.\.[^:]*//g
                                            p
                                        }'
                 )"

This script produces a TERMCAP usable with the included versions of vi,
emacs and less.

Here are brief descriptions of the two terminfo files:


xnuppc - Darwin PowerPC Console (a.k.a. "darwin")

Apple's Darwin operating system runs on at least two platforms (x86 and
PowerPC,) and the console drivers for the two are different enough to
warrant separate terminfo descriptions. To reflect this accurately, the
Darwin PowerPC console entry has been renamed "xnuppc" (XNU stands for "X
is Not Unix", and seems to be Darwin's internal name for itself.) Since
most users will probably call the system "darwin", though, and will likely
run it on PowerPC hardware (at least for now,) the "xnuppc" terminfo
includes "darwin" aliases for all the "xnuppc" terminal types ("darwinppc"
was considered, but was too long to allow for qualifiers.)

Unfortunately the console tty driver sets the "rows" and "columns" tty
parameters once at startup, and never updates them to reflect subsequent
geometry changes.  Worse yet, the fields are readonly -- so they can't be
changed using stty! To work around this problem, I have included versions
of this terminfo with explicit rows and columns. They are invaluable when
I use "ssh" to connect to a remote machine.

See the comments in "xnuppc.ti" for more information.


nsterm - AppKit Terminal.app
(the Terminal application included with Apple's MacOS X)

Apple's MacOS X includes a terminal emulator derived from the old NeXT
Terminal.app (the name "nsterm" stands for "NeXTSTEP terminal".)
Terminal.app runs under the MacOS X Quartz windowing system (and other
AppKit-supported windowing systems.) A single "Apple_Terminal" alias has
been ratained for compatibility, but "nsterm" is the name I recommend
using.

The "nsterm" description was written for Terminal.app version 41, but
includes variants (nsterm-7 and nsterm-acs) that should work with future
Terminal.app versions with better color, charset and alternate-charset
support.

See the comments in "nsterm.ti" for more information.


Is there any chance these descriptions might find their way into future
ncurses or Darwin distributions?

-Ben

Attachment: nsterm.ti
Description: nsterm.ti

Attachment: xnuppc.ti
Description: xnuppc.ti


reply via email to

[Prev in Thread] Current Thread [Next in Thread]