* Plague of dashes in command echo
@ 2004-07-12 5:00 Lőrentey Károly
2004-07-12 23:58 ` Richard Stallman
0 siblings, 1 reply; 4+ messages in thread
From: Lőrentey Károly @ 2004-07-12 5:00 UTC (permalink / raw)
[-- Attachment #1: Type: text/plain, Size: 601 bytes --]
Start Emacs under X, press C-x and wait until the echo "C-x-" appears
in the echo area. Now move the mouse over an area with a help-echo
property (like the modeline), and note that each small mouse movement
adds a new bogus dash to the end of the command echo. The bug is not
limited to the help-echo event; special events like iconify-frame and
make-frame-visible have similar side-effects.
I think this is caused by a simple bug in read_char ("goto retry;"
repeats the echo_dash call, too). The following patch fixes it for
me in a general way:
lorentey@elte.hu--2004/emacs--hacks--0--patch-2
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: Type: text/x-patch, Size: 820 bytes --]
--- orig/src/keyboard.c
+++ mod/src/keyboard.c
@@ -802,6 +802,21 @@
== SCHARS (current_kboard->echo_string))
return;
+ /* Do nothing if we have already put a dash at the end. */
+ if (SCHARS (current_kboard->echo_string) > 1)
+ {
+ Lisp_Object last_char, prev_char, idx;
+
+ idx = make_number (SCHARS (current_kboard->echo_string) - 2);
+ prev_char = Faref (current_kboard->echo_string, idx);
+
+ idx = make_number (SCHARS (current_kboard->echo_string) - 1);
+ last_char = Faref (current_kboard->echo_string, idx);
+
+ if (XINT (last_char) == '-' && XINT (prev_char) != ' ')
+ return;
+ }
+
/* Put a dash at the end of the buffer temporarily,
but make it go away when the next character is added. */
current_kboard->echo_string = concat2 (current_kboard->echo_string,
[-- Attachment #3: Type: text/plain, Size: 183 bytes --]
2004-07-12 Károly Lőrentey <lorentey@elte.hu>
* keyboard.c (echo_dash): Do nothing if there already is a
dash at the end of the echo string.
--
Károly
[-- Attachment #4: Type: text/plain, Size: 142 bytes --]
_______________________________________________
Emacs-devel mailing list
Emacs-devel@gnu.org
http://lists.gnu.org/mailman/listinfo/emacs-devel
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: Plague of dashes in command echo
2004-07-12 5:00 Plague of dashes in command echo Lőrentey Károly
@ 2004-07-12 23:58 ` Richard Stallman
2004-07-13 16:44 ` Lőrentey Károly
0 siblings, 1 reply; 4+ messages in thread
From: Richard Stallman @ 2004-07-12 23:58 UTC (permalink / raw)
Cc: emacs-devel
Your change looks good enough; would you please install it?
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: Plague of dashes in command echo
2004-07-12 23:58 ` Richard Stallman
@ 2004-07-13 16:44 ` Lőrentey Károly
2004-07-13 22:15 ` Miles Bader
0 siblings, 1 reply; 4+ messages in thread
From: Lőrentey Károly @ 2004-07-13 16:44 UTC (permalink / raw)
Cc: Miles Bader, emacs-devel
Richard Stallman <rms@gnu.org> writes:
> Your change looks good enough; would you please install it?
I don't have a CVS account on Savannah yet; so far I used Miles Bader's
tla archive to access the repository.
I think it would be desirable to preserve Arch metadata if I am to get
commit access, but that means my patches would need to go through
Miles's archive and I don't know how to do that. Miles?
--
Károly
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: Plague of dashes in command echo
2004-07-13 16:44 ` Lőrentey Károly
@ 2004-07-13 22:15 ` Miles Bader
0 siblings, 0 replies; 4+ messages in thread
From: Miles Bader @ 2004-07-13 22:15 UTC (permalink / raw)
Cc: Miles Bader, Richard Stallman, emacs-devel
On Tue, Jul 13, 2004 at 06:44:43PM +0200, L?rentey K?roly wrote:
> I think it would be desirable to preserve Arch metadata if I am to get
> commit access, but that means my patches would need to go through
> Miles's archive and I don't know how to do that. Miles?
Well I'd love to have (1) an archive writable by others, but you'd have to
have a gnu account for that, and there are probably details to be worked out
(like group privs or something), or (2) some sort of patch-queue manager, but
that requires work to set up, and maybe some system privs.
But for now you can just send me a (tarred-up) changeset, and I'll apply it.
Either:
* Make the changes without committing, and do `tla undo -o CSET'
* Commit to some branch and, send me that changeset instead.
`tla get-changeset REVISION CSET'
or `tla delta REVISION1 REVISION2 CSET'
or if it's a clean branch (no extraneous changes),
`tla changes -o CSET miles@gnu.org--gnu-2004/emacs--cvs-trunk--0'
-Miles
--
/\ /\
(^.^)
(")")
*This is the cute kitty virus, please copy this into your sig so it can spread.
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2004-07-13 22:15 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2004-07-12 5:00 Plague of dashes in command echo Lőrentey Károly
2004-07-12 23:58 ` Richard Stallman
2004-07-13 16:44 ` Lőrentey Károly
2004-07-13 22:15 ` Miles Bader
Code repositories for project(s) associated with this public inbox
https://git.savannah.gnu.org/cgit/emacs.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).