From 627fb581aed103ff9ed9268d8bff8aea44845415 Mon Sep 17 00:00:00 2001 From: "Richard M. Stallman" Date: Sat, 21 Oct 2006 17:40:03 +0000 Subject: [PATCH] (Vread_expression_map): Define here. (Qread_expression_history): New variable. (syms_of_minibuf): Initialize them. (Feval_minibuffer): Use Vread_expression_map and Qread_expression_history. --- src/ChangeLog | 8 ++++++++ src/minibuf.c | 18 ++++++++++++++++-- 2 files changed, 24 insertions(+), 2 deletions(-) diff --git a/src/ChangeLog b/src/ChangeLog index 930c2a44d4d..2a10a65c71b 100644 --- a/src/ChangeLog +++ b/src/ChangeLog @@ -1,3 +1,11 @@ +2006-10-21 Richard Stallman + + * minibuf.c (Vread_expression_map): Define here. + (Qread_expression_history): New variable. + (syms_of_minibuf): Initialize them. + (Feval_minibuffer): Use Vread_expression_map and + Qread_expression_history. + 2006-10-21 Kenichi Handa * xfns.c (xic_create_fontsetname): If ADSTYLE field is not a wild diff --git a/src/minibuf.c b/src/minibuf.c index bb9c80b4e7d..46c54d8724f 100644 --- a/src/minibuf.c +++ b/src/minibuf.c @@ -132,7 +132,8 @@ int minibuffer_auto_raise; static Lisp_Object last_exact_completion; -extern Lisp_Object Voverriding_local_map; +/* Keymap for reading expressions. */ +Lisp_Object Vread_expression_map; Lisp_Object Quser_variable_p; @@ -142,6 +143,10 @@ Lisp_Object Qcurrent_input_method, Qactivate_input_method; Lisp_Object Qcase_fold_search; +Lisp_Object Qread_expression_history; + +extern Lisp_Object Voverriding_local_map; + extern Lisp_Object Qmouse_face; extern Lisp_Object Qfield; @@ -1040,7 +1045,9 @@ arguments are used as in `read-from-minibuffer'.) */) (prompt, initial_contents) Lisp_Object prompt, initial_contents; { - return Feval (Fread_minibuffer (prompt, initial_contents)); + return Feval (read_minibuf (Vread_expression_map, initial_contents, + prompt, Qnil, 1, Qread_expression_history, + make_number (0), Qnil, 0, 0)); } /* Functions that use the minibuffer to read various things. */ @@ -2808,6 +2815,9 @@ syms_of_minibuf () Qcase_fold_search = intern ("case-fold-search"); staticpro (&Qcase_fold_search); + Qread_expression_history = intern ("read-expression-history"); + staticpro (&Qread_expression_history); + DEFVAR_LISP ("read-buffer-function", &Vread_buffer_function, doc: /* If this is non-nil, `read-buffer' does its work by calling this function. */); Vread_buffer_function = Qnil; @@ -2933,6 +2943,10 @@ properties. */); Vminibuffer_prompt_properties = Fcons (intern ("read-only"), Fcons (Qt, Qnil)); + DEFVAR_LISP ("read-expression-map", &Vread_expression_map, + doc: /* Minibuffer keymap used for reading Lisp expressions. */); + Vread_expression_map = Qnil; + defsubr (&Sset_minibuffer_window); defsubr (&Sread_from_minibuffer); defsubr (&Seval_minibuffer); -- 2.39.2