Up: SGI graphics Frequently Asked Questions (FAQ)
Next: -19- How can I configure my keyboard like a VT100?
Previous: -17- How can I find out what fonts are available?
Subject: -18- How can I use the Alt key as a Meta key in an xwsh
window?
Date: 23 Jun 1994 00:00:01 EST
First, put the following X resources wherever you put X resources:
--- beginning of resources ---
! This turns Alt-key into Meta-key.
XWsh*metaKeyMask: 8
! This allows multiple key modifiers in keybindings (so we can do
! meta-shift, meta-control, etc. and incidentally a) turns vt100
! cursor key mode off and b) changes the cursor key bindings.
XWsh*keyboardType: xlib
! This turns vt100 cursor key mode back on. Running 'tset' at login
! resets the terminal and turns the cursor keys back off, so don't
! run it.
XWsh*initSequence: \233?1h
! The iris-ansi terminfo entry has arrow key sequences for the ibmrt
! keyboard, not the xlib keyboard; for curses applications to work,
! the arrow keys must be bound to the sequences in the terminfo
! entry. Rebinding the arrow keys to match the terminfo entry is more
! convenient than changing the terminfo entry.
XWsh*ckmeKeyMap: \
Left(any): send("\033[D"); \
Right(any): send("\033[C"); \
Up(any): send("\033[A"); \
Down(any): send("\033[B");
--- end of resources ---
'tset' resets your terminal, so running it will undo the initSequence
resource setting. There is a 'tset' command in the default csh/tcsh
~/.login file; replace the line
eval `tset -s -Q`
with
if (! $?TERM) then
eval `tset -s -Q`
endif
so 'tset' will run only if the TERM environment variable isn't
already set. (You can't say 'if (! $?TERM) eval `tset -sQ`', because
csh/tcsh evaluates the backquotes *before* the if.)
Finally, if you use GNU Emacs, put the following in your .emacs:
(set-input-mode nil nil t)
This tells Emacs to allow Meta key usage even though the iris-ansi
(xwsh) terminal description doesn't specify a Meta key.
Up: SGI graphics Frequently Asked Questions (FAQ)
Next: -19- How can I configure my keyboard like a VT100?
Previous: -17- How can I find out what fonts are available?