0
|
1 ;;; x-win-xfree86.el --- runtime initialization for XFree86 servers
|
|
2 ;; Copyright (C) 1995 Sun Microsystems, Inc.
|
|
3 ;; Copyright (C) 1995 Ben Wing.
|
|
4
|
|
5 ;; Author: Ben Wing
|
|
6 ;; Keywords: terminals
|
|
7
|
|
8 ;; This file is part of XEmacs.
|
|
9
|
|
10 ;; XEmacs is free software; you can redistribute it and/or modify it
|
|
11 ;; under the terms of the GNU General Public License as published by
|
|
12 ;; the Free Software Foundation; either version 2, or (at your option)
|
|
13 ;; any later version.
|
|
14
|
|
15 ;; XEmacs is distributed in the hope that it will be useful, but
|
|
16 ;; WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
17 ;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
|
|
18 ;; General Public License for more details.
|
|
19
|
|
20 ;; You should have received a copy of the GNU General Public License
|
70
|
21 ;; along with XEmacs; see the file COPYING. If not, write to the
|
|
22 ;; Free Software Foundation, Inc., 59 Temple Place - Suite 330,
|
|
23 ;; Boston, MA 02111-1307, USA.
|
0
|
24
|
|
25 ;;; Commentary:
|
|
26
|
|
27 ;; This file is loaded by x-win.el at run-time when we are sure that XEmacs
|
|
28 ;; is running on the display of something running XFree86 (Linux,
|
|
29 ;; NetBSD, FreeBSD, and perhaps other Intel Unixen).
|
|
30
|
|
31 ;;; #### bleck!!! Use key-translation-map!
|
|
32
|
|
33 ;; For no obvious reason, shift-F1 is called F13, although Meta-F1 and
|
|
34 ;; Control-F1 have normal names.
|
|
35
|
|
36 (let ((mapping '((f13 . (shift f1))
|
|
37 (f14 . (shift f2))
|
|
38 (f15 . (shift f3))
|
|
39 (f16 . (shift f4))
|
|
40 (f17 . (shift f5))
|
|
41 (f18 . (shift f6))
|
|
42 (f19 . (shift f7))
|
|
43 (f20 . (shift f8))
|
|
44 (f21 . (shift f9))
|
|
45 (f22 . (shift f10))
|
|
46 (f23 . (shift f11))
|
|
47 (f24 . (shift f12)))))
|
|
48
|
|
49 ;; now define them and also the control, meta, and meta-control versions.
|
|
50 (while mapping
|
|
51 (let* ((foo (caar mapping))
|
|
52 (bar (cdar mapping))
|
|
53 (foo (if (listp foo) foo (list foo)))
|
|
54 (bar (if (listp bar) bar (list bar))))
|
|
55 (let ((mods '(() (control) (meta) (meta control))))
|
|
56 (while mods
|
|
57 (let ((k1 (vector (append (car mods) foo)))
|
|
58 (k2 (vector (append (car mods) bar))))
|
70
|
59 (define-key global-map k1 k2))
|
0
|
60 (setq mods (cdr mods))))
|
|
61 (setq mapping (cdr mapping)))))
|