emacs-devel
[Top][All Lists]
Advanced

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

Re: Interactive hat.


From: Miles Bader
Subject: Re: Interactive hat.
Date: Wed, 25 Mar 2009 19:30:13 +0900

Alan Mackenzie <address@hidden> writes:
> How is an external library writer going to use the interactive "^"?
> Assuming that the library should also work under XEmacs and Emacs 22,
> just using the "^" won't work; an interactive string with "^" throws an
> error in Emacs 22.

Isn't that a pretty basic problem with _any_ extension to interactive?
Do you think `interactive' should never be extended?

In this case, I think the right solution would be to simply add another,
possibly clunkier method for commands to indicate they want to enable
shift-selection behavior.

E.g.: have the command loop also look for a `handle-shift-select'
property on command-name's plist, and treat that as it would "^" in the
interactive string.  Then external library authors who are worried about
backwards compability could use (put COMMAND 'handle-shift-select t)
instead of putting ^ in COMMAND's interactive string.

[Yeah, that only works for commands which are defined functions, but I
think that's an acceptable limitation for a feature like this which
should be used only rarely.]

-Miles

-- 
"1971 pickup truck; will trade for guns"




reply via email to

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