[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: read_char() does not detect, handle special-event-map buffer changes
From: |
Stefan Monnier |
Subject: |
Re: read_char() does not detect, handle special-event-map buffer changes |
Date: |
Thu, 07 Feb 2013 11:25:31 -0500 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/24.3.50 (gnu/linux) |
> in a separate terminal. Move focus back to Emacs before the signal goes
> out. Hit `q' in the new buffer and Emacs will complain about "*foo*"
> being read-only. The second time you hit `q', Emacs will exit view mode
> and bury the buffer.
I think this is a known problem: the set of active keymaps is determined
at the end of the previous command, so any change performed via
something like a special-event-map binding or a process-filter will bump
into this problem (you don't even need to switch-to-buffer, just
enabling view-mode is sufficient).
It's a bug: we should instead wait until the first key is pressed
before figuring out the active keymaps.
Problem is, this bug is in read_key_sequence, which is a pretty
scary function.
In the mean time, you can work around the bug by adding to
unread-command-event (from your sigusr1-handler) a dummy event that is
bound in global-map to something like `ignore'.
Stefan
- read_char() does not detect, handle special-event-map buffer changes, Derek Upham, 2013/02/04
- Re: read_char() does not detect, handle special-event-map buffer changes, Derek Upham, 2013/02/07
- Re: read_char() does not detect, handle special-event-map buffer changes, Derek Upham, 2013/02/07
- Re: read_char() does not detect, handle special-event-map buffer changes,
Stefan Monnier <=
- Re: read_char() does not detect, handle special-event-map buffer changes, Derek Upham, 2013/02/07
- Re: read_char() does not detect, handle special-event-map buffer changes, Michael Albinus, 2013/02/08
- Re: read_char() does not detect, handle special-event-map buffer changes, Derek Upham, 2013/02/08
- Re: read_char() does not detect, handle special-event-map buffer changes, Michael Albinus, 2013/02/08
- Re: read_char() does not detect, handle special-event-map buffer changes, Derek Upham, 2013/02/09
- Re: read_char() does not detect, handle special-event-map buffer changes, Stefan Monnier, 2013/02/11
- Re: read_char() does not detect, handle special-event-map buffer changes, Derek Upham, 2013/02/12
- Re: read_char() does not detect, handle special-event-map buffer changes, Stefan Monnier, 2013/02/12