annotate lisp/x11/x-win-xfree86.el @ 0:376386a54a3c r19-14

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