emacs-devel
[Top][All Lists]
Advanced

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

Re: Q: How to programatically terminate repeat-mode


From: T.V Raman
Subject: Re: Q: How to programatically terminate repeat-mode
Date: Sat, 10 Sep 2022 12:44:48 -0700

Works like a charm, that took less than a minute to implement and
test:-)
T.V Raman writes:
 > Juri Linkov <juri@linkov.net> writes:
 > 
 > will try your suggestions. Would be nice to have  a simple API to do
 > this.
 > 
 > >> I have been using repeat-mode to good effect in emacspeak e.g. in the
 > >> context of its media player etc.
 > >>
 > >> One issue  I have is that once a command to stop media has been
 > >> executed, I'd like the repeat to stop i.e. without me executing
 > >> another explicit kbd command like C-g to terminate the repeat.
 > >
 > > The simplest way is just not to put the property 'repeat-map'
 > > on the symbol of the command that stops media.  Then executing
 > > this command will terminate the repeat.
 > >
 > >> How do I do this from lisp?
 > >
 > > It's no easy to do the same from Lisp because in repeat-post-hook
 > > the value of 'exitfun' returned from 'set-transient-map' is not
 > > exposed outside.  Maybe the value of 'exitfun' should be stored
 > > in a variable?  Currently 'exitfun' is used only by repeat-exit-timer.
 > >
 > >> I'd rather not call keyboard-quit  explicitly -- that sounds like
 > >> overkill?
 > >
 > > Or you could put 'repeat-exit-key' on 'unread-command-events'.
 > 
 > -- 
 > 
 > Thanks,
 > 
 > --Raman(I Search, I Find, I Misplace, I Research)
 > ♉ Id: kg:/m/0285kf1  🦮

-- 

Thanks,

--Raman(I Search, I Find, I Misplace, I Research)
♉ Id: kg:/m/0285kf1  🦮

--

Thanks,

--Raman(I Search, I Find, I Misplace, I Research)
♉ Id: kg:/m/0285kf1  🦮



reply via email to

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