[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

bug#29272: 26.0.90; "C-h k C-mouse-3" followed by menu selection asks fo

From: Alan Mackenzie
Subject: bug#29272: 26.0.90; "C-h k C-mouse-3" followed by menu selection asks for more keys
Date: Wed, 29 Nov 2017 18:37:17 +0000
User-agent: Mutt/1.7.2 (2016-11-26)

Hello, Martin.

On Wed, Nov 29, 2017 at 09:39:38 +0100, martin rudalics wrote:

[ .... ]

> BTW: Could someone please fix that

> (not (sit-for (/ double-click-time 1000.0) t))

> form so it handles at least those values of `double-click-time'
> described in its documentation:

>    Maximum time between mouse clicks to make a double-click.
>    Measured in milliseconds.  The value nil means disable double-click
>    recognition; t means double-clicks have no time limit and are detected
>    by position only.

This is very strange indeed.  I wasn't aware of the t and nil values for
double-click-time, and of the six or seven uses of the variable in the
Emacs Lisp code, there are at least two other uses, possibly more, which
are likewise unaware of nil and t.

Looking at the change log, double-click-time was changed into a Lisp
variable, complete with values nil and t, by Jim Blandy in 1993, which
is hardly recent.  The documentation seems OK.

So why have so many programmers been oblivious to these values?

> I'm not sure what `sit-for' is supposed to return in those cases.

Presumably we shouldn't be calling sit-for for double-click-time nil and
t.  But, when does a key sequence consisting of mouse buttons end when
d-c-t is t?  This is a more important question, I think, for C-h c and
C-h k than for actually running commands.

Personally, I think the value t is a bad idea, and we should obsolete
it.  I can't see the use case.  Anybody who wants an indefinitely long
double-click-time can use a near infinite integer, in which case
anything that happens (or fails to happen) in C-h c and C-h k is her own
fault.  Surely, nobody is going to want to click the mouse, go off for a
cup of coffee, come back, then complete a double click.

Maybe we should interpret t as a moderately long finite interval, say 10
seconds.  That still leaves anybody the option of using a larger

> Thanks, martin

Alan Mackenzie (Nuremberg, Germany).

reply via email to

[Prev in Thread] Current Thread [Next in Thread]