GNU bug report logs - #19875
25.0.50; Setting an input-method-function breaks prefix show on the echo area

Previous Next

Package: emacs;

Reported by: oscarfv <at> telefonica.net (Óscar Fuentes)

Date: Sun, 15 Feb 2015 17:05:01 UTC

Severity: normal

Found in version 25.0.50

Done: oscarfv <at> telefonica.net (Óscar Fuentes)

Bug is archived. No further changes may be made.

Full log


View this message in rfc822 format

From: oscarfv <at> telefonica.net (Óscar Fuentes)
To: Eli Zaretskii <eliz <at> gnu.org>
Cc: 19875 <at> debbugs.gnu.org
Subject: bug#19875: 25.0.50; Setting an input-method-function breaks prefix show on the echo area
Date: Sun, 15 Feb 2015 19:03:56 +0100
Eli Zaretskii <eliz <at> gnu.org> writes:

> This happens on the release branch, and in Emacs 24.4 as well.

The relevant area of code in keyboard.c is very old. The bug probably
has more than 15 years.

Semi-blind fix attempt:

diff --git a/src/keyboard.c b/src/keyboard.c
index bcb51cf..8b65f0e 100644
--- a/src/keyboard.c
+++ b/src/keyboard.c
@@ -3095,7 +3095,15 @@ read_char (int commandflag, Lisp_Object map,
 
       cancel_echoing ();
       ok_to_echo_at_next_pause = saved_ok_to_echo;
-      kset_echo_string (current_kboard, saved_echo_string);
+      /* Do not restore the echo area string if the user is
+         introducing a prefix argument. Otherwise we end with
+         repetitions of the partially introduced prefix
+         argument. (bug#19875) */
+      Lisp_Object pa = intern ("prefix-arg");
+      if (NILP(pa))
+        {
+          kset_echo_string (current_kboard, saved_echo_string);
+        }
       current_kboard->echo_after_prompt = saved_echo_after_prompt;
       if (saved_immediate_echo)
 	echo_now ();




This bug report was last modified 10 years and 147 days ago.

Previous Next


GNU bug tracking system
Copyright (C) 1999 Darren O. Benham, 1997,2003 nCipher Corporation Ltd, 1994-97 Ian Jackson.