[Top][All Lists]

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

Re: local keymap patch for key-binding

From: David Kastrup
Subject: Re: local keymap patch for key-binding
Date: Sat, 09 Sep 2006 17:15:19 +0200
User-agent: Gnus/5.11 (Gnus v5.11) Emacs/22.0.50 (gnu/linux)

Chong Yidong <address@hidden> writes:

> I have written a patch to address the following item in FOR-RELEASE:
>     ** Make key-binding use the maps specified by positions given in
>        the events.
> If a vector is passed to key-binding, and the first element of the
> vector looks like a valid click event, and the position specified by
> that click event contains a `keymap' property, then we look in that
> keymap first.
> Any objections to checking this in?

It does too little.  Check out what read-key-sequence (defined in
keyboard.c) does with regard to mouse events (EVENT_HAS_PARAMETERS).
The problem is that read-key-sequence does such a load of other stuff
that it is hard to extract the material and transfer it to

The problem is that keymaps may be provided by text properties and
overlays, and by keymap properties on strings that display as the
display or before-string or after-string properties of text properties
or overlays.

So one really wants to steal the logic from read-key-sequence without
stealing most of the complications...

(lookup-binding (read-key-sequence))
should arrive at the same conclusion as that which read-key-sequence
stores in the read_key_sequence_cmd variable as a side effect.

David Kastrup, Kriemhildstr. 15, 44793 Bochum

reply via email to

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