aboutsummaryrefslogtreecommitdiffstats
path: root/src/keyboard.c
diff options
context:
space:
mode:
authorMiles Bader2004-07-17 02:46:48 +0000
committerMiles Bader2004-07-17 02:46:48 +0000
commit21d1ca18bfb71eb82b574fd55339bc7441e6a449 (patch)
tree454ad66687571c05feba856074dca94209292a4a /src/keyboard.c
parent89f3c0c9fda25756ee311a6d0467a97bac203eb5 (diff)
parentdd0a3ea36a52518f4fcd2dea97859cfba63158f8 (diff)
downloademacs-21d1ca18bfb71eb82b574fd55339bc7441e6a449.tar.gz
emacs-21d1ca18bfb71eb82b574fd55339bc7441e6a449.zip
Revision: miles@gnu.org--gnu-2004/emacs--unicode--0--patch-24
Merge from lorentey@elte.hu--2004/emacs--hacks--0, emacs--cvs-trunk--0 Patches applied: * lorentey@elte.hu--2004/emacs--hacks--0--patch-2 Prevent special events from appending dashes to the echo string. * lorentey@elte.hu--2004/emacs--hacks--0--patch-4 Added ChangeLog entry. * miles@gnu.org--gnu-2004/emacs--cvs-trunk--0--patch-451 Update from CVS: lisp/subr.el (get-buffer-window-list): Doc fix. * miles@gnu.org--gnu-2004/emacs--cvs-trunk--0--patch-452 - miles@gnu.org--gnu-2004/emacs--cvs-trunk--0--patch-454 Update from CVS * miles@gnu.org--gnu-2004/emacs--cvs-trunk--0--patch-455 Bash the dashes * miles@gnu.org--gnu-2004/emacs--cvs-trunk--0--patch-456 - miles@gnu.org--gnu-2004/emacs--cvs-trunk--0--patch-458 Update from CVS
Diffstat (limited to 'src/keyboard.c')
-rw-r--r--src/keyboard.c15
1 files changed, 15 insertions, 0 deletions
diff --git a/src/keyboard.c b/src/keyboard.c
index 382f99058d4..eb8c0c43fe6 100644
--- a/src/keyboard.c
+++ b/src/keyboard.c
@@ -802,6 +802,21 @@ echo_dash ()
802 == SCHARS (current_kboard->echo_string)) 802 == SCHARS (current_kboard->echo_string))
803 return; 803 return;
804 804
805 /* Do nothing if we have already put a dash at the end. */
806 if (SCHARS (current_kboard->echo_string) > 1)
807 {
808 Lisp_Object last_char, prev_char, idx;
809
810 idx = make_number (SCHARS (current_kboard->echo_string) - 2);
811 prev_char = Faref (current_kboard->echo_string, idx);
812
813 idx = make_number (SCHARS (current_kboard->echo_string) - 1);
814 last_char = Faref (current_kboard->echo_string, idx);
815
816 if (XINT (last_char) == '-' && XINT (prev_char) != ' ')
817 return;
818 }
819
805 /* Put a dash at the end of the buffer temporarily, 820 /* Put a dash at the end of the buffer temporarily,
806 but make it go away when the next character is added. */ 821 but make it go away when the next character is added. */
807 current_kboard->echo_string = concat2 (current_kboard->echo_string, 822 current_kboard->echo_string = concat2 (current_kboard->echo_string,