comparison src/minibuf.c @ 31105:0c34d4d76e65

(Vcompletion_auto_help): Renamed from `auto_help'. (do_completion, Fminibuffer_complete_word): Use it. (syms_of_minibuf): Turn completion-auto-help into a proper Lisp var so it can take non-boolean values.
author Stefan Monnier <monnier@iro.umontreal.ca>
date Tue, 22 Aug 2000 22:49:22 +0000
parents 6a0caa788013
children 943b0b727bc4
comparison
equal deleted inserted replaced
31104:79c890cce460 31105:0c34d4d76e65
52 52
53 int minibuf_level; 53 int minibuf_level;
54 54
55 /* Nonzero means display completion help for invalid input. */ 55 /* Nonzero means display completion help for invalid input. */
56 56
57 int auto_help; 57 Lisp_Object Vcompletion_auto_help;
58 58
59 /* The maximum length of a minibuffer history. */ 59 /* The maximum length of a minibuffer history. */
60 60
61 Lisp_Object Qhistory_length, Vhistory_length; 61 Lisp_Object Qhistory_length, Vhistory_length;
62 62
1635 { 1635 {
1636 /* not an exact match */ 1636 /* not an exact match */
1637 UNGCPRO; 1637 UNGCPRO;
1638 if (completedp) 1638 if (completedp)
1639 return 5; 1639 return 5;
1640 else if (auto_help) 1640 else if (!NILP (Vcompletion_auto_help))
1641 Fminibuffer_completion_help (); 1641 Fminibuffer_completion_help ();
1642 else 1642 else
1643 temp_echo_area_glyphs (" [Next char not unique]"); 1643 temp_echo_area_glyphs (" [Next char not unique]");
1644 return 6; 1644 return 6;
1645 } 1645 }
1972 1972
1973 /* If got no characters, print help for user. */ 1973 /* If got no characters, print help for user. */
1974 1974
1975 if (i == ZV - prompt_end_charpos) 1975 if (i == ZV - prompt_end_charpos)
1976 { 1976 {
1977 if (auto_help) 1977 if (!NILP (Vcompletion_auto_help))
1978 Fminibuffer_completion_help (); 1978 Fminibuffer_completion_help ();
1979 return Qnil; 1979 return Qnil;
1980 } 1980 }
1981 1981
1982 /* Otherwise insert in minibuffer the chars we got */ 1982 /* Otherwise insert in minibuffer the chars we got */
2356 A number means that length; t means infinite. Truncation takes place\n\ 2356 A number means that length; t means infinite. Truncation takes place\n\
2357 just after a new element is inserted. Setting the history-length\n\ 2357 just after a new element is inserted. Setting the history-length\n\
2358 property of a history variable overrides this default."); 2358 property of a history variable overrides this default.");
2359 XSETFASTINT (Vhistory_length, 30); 2359 XSETFASTINT (Vhistory_length, 30);
2360 2360
2361 DEFVAR_BOOL ("completion-auto-help", &auto_help, 2361 DEFVAR_LISP ("completion-auto-help", &Vcompletion_auto_help,
2362 "*Non-nil means automatically provide help for invalid completion input."); 2362 "*Non-nil means automatically provide help for invalid completion input.");
2363 auto_help = 1; 2363 Vcompletion_auto_help = Qt;
2364 2364
2365 DEFVAR_BOOL ("completion-ignore-case", &completion_ignore_case, 2365 DEFVAR_BOOL ("completion-ignore-case", &completion_ignore_case,
2366 "Non-nil means don't consider case significant in completion."); 2366 "Non-nil means don't consider case significant in completion.");
2367 completion_ignore_case = 0; 2367 completion_ignore_case = 0;
2368 2368