README.TERM at [5c79fa6870]

File README.TERM artifact df37418102 part of check-in 5c79fa6870


README.TERM
		    Terminfo Notes for the CTk Toolkit

This file contains hints for setting up terminfo entries for use with CTk.
It assumes the reader already understands how to write terminfo entries
(as much as anyone really understands this black art).  See the manual
page, terminfo(4), for general information on terminfo.

@(#) $Id: ctk.shar,v 1.50 1996/01/15 14:47:16 andrewm Exp andrewm $

Special Keys
------------

CTk tries to map the curses key codes to X-11 keycodes and hence to
Tk key names.  This mapping (in reverse) is shown below:

	Tk Name		Capname
	-------		-------
	BackSpace	kbs
	Begin		kbeg
	Cancel		kcan
	Clear		kclr
	Delete		kdch1
	Shift-Delete	kdl1
	Down		kcud1
	End		kend
	End		kfnd
	Control-End	kll
	Execute		kcmd
	F1		kf1
	F10		kf10
	F2		kf2
	F3		kf3
	F4		kf4
	F5		kf5
	F6		kf6
	F7		kf7
	F8		kf8
	F9		kf9
	Help		khlp
	Home		khome
	Insert		kich1
	Insert		kmir
	Shift-Insert	kil1
	Left		kcub1
	Menu		kopt
	Next		knp
	Pause		kspd
	Print		kprt
	Prior		kpp
	Redo		krdo
	Return		kent
	Right		kcuf1
	Select		kslt
	Tab		knxt
	Shift-Tab	kcbt
	Shift-Tab	kprv
	Undo		kund
	Up		kcuu1

In addition the following special keys can be generated by control
keys (therefore, you cannot receive a <Control-h> event):

	Tk Name		Control Key
	-------		-----------
	Backspace	<Control-H>
	Tab		<Control-I>
	Return		<Control-M>

Other control keys are passed as the appropriate key press with the
Control Modifier set.


Display Attributes
------------------

CTk uses the following terminfo display attributes: standout (the focus),
reverse (selected), underline (entry widgets), bold (button widgets),
and dim (inactive widgets).  CTk does not try to use combinations of
attributes (for example: bold-underline) so you do not need to
define the "sgr" capability.  If an attribute is not defined the item
is displayed as plain text.

If possible, each of the attributes should have a unique appearance
(standout = bold is very bad, because a button will not change appearance
when it has the focus).  Following the ncurses recommendation that
standout should "represent a good, high contrast, easy-on-the-eyes,
format" I define standout as reverse-dim.


Custom CTk Terminfo Entries
---------------------------

If you find that the terminal definition you want for CTk conflicts with
what you want normally.  You can create the CTk entry with an alternate
name (like vt100-tk) and then set the environment variable CTK_TERM
to this alternate entry.  CTK_TERM is by CTk in preference to the TERM
environment variable.