Mercurial > emacs
comparison src/keymap.c @ 83468:b98066f4aa10
Merged from emacs@sv.gnu.org
Patches applied:
* emacs@sv.gnu.org/emacs--devo--0--patch-49
Update from CVS
* emacs@sv.gnu.org/emacs--devo--0--patch-50
Update from CVS
* emacs@sv.gnu.org/emacs--devo--0--patch-51
Make constrain-to-field notice overlays
* emacs@sv.gnu.org/emacs--devo--0--patch-52
Update from CVS
* emacs@sv.gnu.org/emacs--devo--0--patch-53
Update from CVS
* emacs@sv.gnu.org/emacs--devo--0--patch-54
Update from CVS
* emacs@sv.gnu.org/emacs--devo--0--patch-55
Merge from erc--emacs--0
* emacs@sv.gnu.org/emacs--devo--0--patch-56
Update from CVS
* emacs@sv.gnu.org/emacs--devo--0--patch-57
Merge from gnus--rel--5.10
* emacs@sv.gnu.org/emacs--devo--0--patch-58
Update from CVS
* emacs@sv.gnu.org/emacs--devo--0--patch-59
Update from CVS
* emacs@sv.gnu.org/emacs--devo--0--patch-60
Update from CVS
* emacs@sv.gnu.org/emacs--devo--0--patch-61
Update from CVS
* emacs@sv.gnu.org/emacs--devo--0--patch-62
Merge from gnus--rel--5.10
* emacs@sv.gnu.org/emacs--devo--0--patch-63
Update from CVS
* emacs@sv.gnu.org/emacs--devo--0--patch-64
Update from CVS
* emacs@sv.gnu.org/emacs--devo--0--patch-65
Merge from gnus--rel--5.10
* emacs@sv.gnu.org/emacs--devo--0--patch-66
Update from CVS
* emacs@sv.gnu.org/emacs--devo--0--patch-67
Update from CVS
* emacs@sv.gnu.org/emacs--devo--0--patch-68
Update from CVS
* emacs@sv.gnu.org/emacs--devo--0--patch-69
rcirc: Add flexible response formatting; Add nick abbrevs
* emacs@sv.gnu.org/emacs--devo--0--patch-70
Update from CVS
* emacs@sv.gnu.org/emacs--devo--0--patch-71
Merge from gnus--rel--5.10
* emacs@sv.gnu.org/emacs--devo--0--patch-72
Update from CVS: man/dired.texi (Tumme): More tumme documentation.
* emacs@sv.gnu.org/gnus--rel--5.10--patch-18
Update from CVS
* emacs@sv.gnu.org/gnus--rel--5.10--patch-19
Update from CVS
* emacs@sv.gnu.org/gnus--rel--5.10--patch-20
Update from CVS
* emacs@sv.gnu.org/gnus--rel--5.10--patch-21
Merge from emacs--devo--0
* emacs@sv.gnu.org/gnus--rel--5.10--patch-22
Update from CVS
* emacs@sv.gnu.org/gnus--rel--5.10--patch-23
Update from CVS
* emacs@sv.gnu.org/gnus--rel--5.10--patch-24
Update from CVS
* emacs@sv.gnu.org/gnus--rel--5.10--patch-25
Update from CVS
* emacs@sv.gnu.org/gnus--rel--5.10--patch-26
Merge from emacs--devo--0
* emacs@sv.gnu.org/gnus--rel--5.10--patch-27
Update from CVS: lisp/gnus.el: Remove bogus comment.
* emacs@sv.gnu.org/gnus--rel--5.10--patch-28
Merge from emacs--devo--0
* emacs@sv.gnu.org/gnus--rel--5.10--patch-29
Add sendmail.el and smptmail.el from Emacs tree to contrib/
git-archimport-id: lorentey@elte.hu--2004/emacs--multi-tty--0--patch-508
author | Karoly Lorentey <lorentey@elte.hu> |
---|---|
date | Sun, 12 Feb 2006 00:15:44 +0000 |
parents | 9b150bc96d33 13c1b7c5f555 |
children | 0cdee8b991e1 |
comparison
equal
deleted
inserted
replaced
83467:d04d8ccb3c41 | 83468:b98066f4aa10 |
---|---|
1 /* Manipulation of keymaps | 1 /* Manipulation of keymaps |
2 Copyright (C) 1985, 1986, 1987, 1988, 1993, 1994, 1995, | 2 Copyright (C) 1985, 1986, 1987, 1988, 1993, 1994, 1995, |
3 1998, 1999, 2000, 2001, 2002, 2003, 2004, | 3 1998, 1999, 2000, 2001, 2002, 2003, 2004, |
4 2005 Free Software Foundation, Inc. | 4 2005, 2006 Free Software Foundation, Inc. |
5 | 5 |
6 This file is part of GNU Emacs. | 6 This file is part of GNU Emacs. |
7 | 7 |
8 GNU Emacs is free software; you can redistribute it and/or modify | 8 GNU Emacs is free software; you can redistribute it and/or modify |
9 it under the terms of the GNU General Public License as published by | 9 it under the terms of the GNU General Public License as published by |
67 Lisp_Object Vminibuffer_local_completion_map; | 67 Lisp_Object Vminibuffer_local_completion_map; |
68 | 68 |
69 /* keymap used for minibuffers when doing completion in filenames */ | 69 /* keymap used for minibuffers when doing completion in filenames */ |
70 Lisp_Object Vminibuffer_local_filename_completion_map; | 70 Lisp_Object Vminibuffer_local_filename_completion_map; |
71 | 71 |
72 /* keymap used for minibuffers when doing completion in filenames | 72 /* keymap used for minibuffers when doing completion in filenames |
73 with require-match*/ | 73 with require-match*/ |
74 Lisp_Object Vminibuffer_local_must_match_filename_map; | 74 Lisp_Object Vminibuffer_local_must_match_filename_map; |
75 | 75 |
76 /* keymap used for minibuffers when doing completion and require a match */ | 76 /* keymap used for minibuffers when doing completion and require a match */ |
77 /* was MinibufLocalMustMatchMap */ | 77 /* was MinibufLocalMustMatchMap */ |
1361 some systems, static gets macro-defined to be the empty string. | 1361 some systems, static gets macro-defined to be the empty string. |
1362 Ickypoo. */ | 1362 Ickypoo. */ |
1363 static Lisp_Object *cmm_modes = NULL, *cmm_maps = NULL; | 1363 static Lisp_Object *cmm_modes = NULL, *cmm_maps = NULL; |
1364 static int cmm_size = 0; | 1364 static int cmm_size = 0; |
1365 | 1365 |
1366 /* Error handler used in current_minor_maps. */ | |
1367 static Lisp_Object | |
1368 current_minor_maps_error () | |
1369 { | |
1370 return Qnil; | |
1371 } | |
1372 | |
1373 /* Store a pointer to an array of the keymaps of the currently active | 1366 /* Store a pointer to an array of the keymaps of the currently active |
1374 minor modes in *buf, and return the number of maps it contains. | 1367 minor modes in *buf, and return the number of maps it contains. |
1375 | 1368 |
1376 This function always returns a pointer to the same buffer, and may | 1369 This function always returns a pointer to the same buffer, and may |
1377 free or reallocate it, so if you want to keep it for a long time or | 1370 free or reallocate it, so if you want to keep it for a long time or |
1469 break; | 1462 break; |
1470 cmm_size = newsize; | 1463 cmm_size = newsize; |
1471 } | 1464 } |
1472 | 1465 |
1473 /* Get the keymap definition--or nil if it is not defined. */ | 1466 /* Get the keymap definition--or nil if it is not defined. */ |
1474 temp = internal_condition_case_1 (Findirect_function, | 1467 temp = Findirect_function (XCDR (assoc), Qt); |
1475 XCDR (assoc), | |
1476 Qerror, current_minor_maps_error); | |
1477 if (!NILP (temp)) | 1468 if (!NILP (temp)) |
1478 { | 1469 { |
1479 cmm_modes[i] = var; | 1470 cmm_modes[i] = var; |
1480 cmm_maps [i] = temp; | 1471 cmm_maps [i] = temp; |
1481 i++; | 1472 i++; |
3873 DEFVAR_LISP ("minibuffer-local-completion-map", &Vminibuffer_local_completion_map, | 3864 DEFVAR_LISP ("minibuffer-local-completion-map", &Vminibuffer_local_completion_map, |
3874 doc: /* Local keymap for minibuffer input with completion. */); | 3865 doc: /* Local keymap for minibuffer input with completion. */); |
3875 Vminibuffer_local_completion_map = Fmake_sparse_keymap (Qnil); | 3866 Vminibuffer_local_completion_map = Fmake_sparse_keymap (Qnil); |
3876 Fset_keymap_parent (Vminibuffer_local_completion_map, Vminibuffer_local_map); | 3867 Fset_keymap_parent (Vminibuffer_local_completion_map, Vminibuffer_local_map); |
3877 | 3868 |
3878 DEFVAR_LISP ("minibuffer-local-filename-completion-map", | 3869 DEFVAR_LISP ("minibuffer-local-filename-completion-map", |
3879 &Vminibuffer_local_filename_completion_map, | 3870 &Vminibuffer_local_filename_completion_map, |
3880 doc: /* Local keymap for minibuffer input with completion for filenames. */); | 3871 doc: /* Local keymap for minibuffer input with completion for filenames. */); |
3881 Vminibuffer_local_filename_completion_map = Fmake_sparse_keymap (Qnil); | 3872 Vminibuffer_local_filename_completion_map = Fmake_sparse_keymap (Qnil); |
3882 Fset_keymap_parent (Vminibuffer_local_filename_completion_map, | 3873 Fset_keymap_parent (Vminibuffer_local_filename_completion_map, |
3883 Vminibuffer_local_completion_map); | 3874 Vminibuffer_local_completion_map); |
3884 | 3875 |
3885 | 3876 |
3886 DEFVAR_LISP ("minibuffer-local-must-match-map", &Vminibuffer_local_must_match_map, | 3877 DEFVAR_LISP ("minibuffer-local-must-match-map", &Vminibuffer_local_must_match_map, |
3887 doc: /* Local keymap for minibuffer input with completion, for exact match. */); | 3878 doc: /* Local keymap for minibuffer input with completion, for exact match. */); |
3888 Vminibuffer_local_must_match_map = Fmake_sparse_keymap (Qnil); | 3879 Vminibuffer_local_must_match_map = Fmake_sparse_keymap (Qnil); |
3889 Fset_keymap_parent (Vminibuffer_local_must_match_map, | 3880 Fset_keymap_parent (Vminibuffer_local_must_match_map, |
3890 Vminibuffer_local_completion_map); | 3881 Vminibuffer_local_completion_map); |
3891 | 3882 |
3892 DEFVAR_LISP ("minibuffer-local-must-match-filename-map", | 3883 DEFVAR_LISP ("minibuffer-local-must-match-filename-map", |
3893 &Vminibuffer_local_must_match_filename_map, | 3884 &Vminibuffer_local_must_match_filename_map, |
3894 doc: /* Local keymap for minibuffer input with completion for filenames with exact match. */); | 3885 doc: /* Local keymap for minibuffer input with completion for filenames with exact match. */); |
3895 Vminibuffer_local_must_match_filename_map = Fmake_sparse_keymap (Qnil); | 3886 Vminibuffer_local_must_match_filename_map = Fmake_sparse_keymap (Qnil); |
3896 Fset_keymap_parent (Vminibuffer_local_must_match_filename_map, | 3887 Fset_keymap_parent (Vminibuffer_local_must_match_filename_map, |
3897 Vminibuffer_local_must_match_map); | 3888 Vminibuffer_local_must_match_map); |
3898 | 3889 |
3899 DEFVAR_LISP ("minor-mode-map-alist", &Vminor_mode_map_alist, | 3890 DEFVAR_LISP ("minor-mode-map-alist", &Vminor_mode_map_alist, |
3900 doc: /* Alist of keymaps to use for minor modes. | 3891 doc: /* Alist of keymaps to use for minor modes. |
3901 Each element looks like (VARIABLE . KEYMAP); KEYMAP is used to read | 3892 Each element looks like (VARIABLE . KEYMAP); KEYMAP is used to read |