* Is that change a good idea?
@ 2005-03-17 22:07 David Kastrup
2005-03-17 22:16 ` Stefan Monnier
0 siblings, 1 reply; 5+ messages in thread
From: David Kastrup @ 2005-03-17 22:07 UTC (permalink / raw)
I have seen
2005-03-16 Stefan Monnier <monnier@iro.umontreal.ca>
* help.el (describe-mode): Allow a :minor-mode-function property to
specify a different minor mode toggle function than the variable.
* simple.el (auto-fill-function):
* subr.el (add-minor-mode): Use it.
I have my doubts that the resulting flexibility is really in the best
interest of the users... In the case where we have to deal with
backward compatibility, would it not be better to use either
defvaralias or defalias to point the "traditional" at the
"straightforward" variable or function?
What do others think?
--
David Kastrup, Kriemhildstr. 15, 44793 Bochum
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: Is that change a good idea?
2005-03-17 22:07 Is that change a good idea? David Kastrup
@ 2005-03-17 22:16 ` Stefan Monnier
2005-03-18 8:24 ` Sascha Wilde
0 siblings, 1 reply; 5+ messages in thread
From: Stefan Monnier @ 2005-03-17 22:16 UTC (permalink / raw)
Cc: emacs-devel
> * help.el (describe-mode): Allow a :minor-mode-function property to
> specify a different minor mode toggle function than the variable.
> * simple.el (auto-fill-function):
> * subr.el (add-minor-mode): Use it.
> I have my doubts that the resulting flexibility is really in the best
> interest of the users...
100% agreement.
It's only meant to clean up the code, not as a new feature.
I.e. it's an internal thing and should stay that way.
Stefan
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: Is that change a good idea?
2005-03-17 22:16 ` Stefan Monnier
@ 2005-03-18 8:24 ` Sascha Wilde
2005-03-18 13:45 ` Stefan Monnier
0 siblings, 1 reply; 5+ messages in thread
From: Sascha Wilde @ 2005-03-18 8:24 UTC (permalink / raw)
On Thu, Mar 17, 2005 at 05:16:41PM -0500, Stefan Monnier wrote:
> > * help.el (describe-mode): Allow a :minor-mode-function property to
> > specify a different minor mode toggle function than the variable.
> > * simple.el (auto-fill-function):
> > * subr.el (add-minor-mode): Use it.
>
> > I have my doubts that the resulting flexibility is really in the best
> > interest of the users...
>
> 100% agreement.
> It's only meant to clean up the code,
Wouldn't it be far more cleaner to convert old minor-modes which would
need this hack to proper minor-modes following standard semantics?
> not as a new feature.
I would guess: when its there, it will be used...
btw. I posted a patch, convertinge auto-fill-function to a standard
minor-mode (thus addressing the same problem) earlier this week, but
got no response -- was it _that_ bad?
cheers
sascha
--
Sascha Wilde : "Lies, was ich meine, nicht, was ich schreibe."
: (Urs Traenkner in de.alt.admin)
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: Is that change a good idea?
2005-03-18 8:24 ` Sascha Wilde
@ 2005-03-18 13:45 ` Stefan Monnier
2005-03-18 14:07 ` David Kastrup
0 siblings, 1 reply; 5+ messages in thread
From: Stefan Monnier @ 2005-03-18 13:45 UTC (permalink / raw)
>> > * help.el (describe-mode): Allow a :minor-mode-function property to
>> > specify a different minor mode toggle function than the variable.
>> > * simple.el (auto-fill-function):
>> > * subr.el (add-minor-mode): Use it.
>>
>> > I have my doubts that the resulting flexibility is really in the best
>> > interest of the users...
>>
>> 100% agreement.
>> It's only meant to clean up the code,
> Wouldn't it be far more cleaner to convert old minor-modes which would
> need this hack to proper minor-modes following standard semantics?
You do realize that there are packages over which we have no control, right?
>> not as a new feature.
> I would guess: when its there, it will be used...
> btw. I posted a patch, convertinge auto-fill-function to a standard
> minor-mode (thus addressing the same problem) earlier this week, but
> got no response -- was it _that_ bad?
No: if it were bad you'd have received complaints.
I thought the code was acceptable, but at the same I found it someone
unsatisfactory because there are then two variables that decide whether the
mode is ON or not: auto-fill-mode and auto-fill-function and you have to
make sure they're kept in sync. Maybe we could do (defvaralias
'auto-fill-function 'auto-fill-mode) and then slowly change modes
to replace (if auto-fill-function (funcall auto-fill-function)) with
(if auto-fill-mode (funcall normal-auto-fill-function)).
Stefan
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: Is that change a good idea?
2005-03-18 13:45 ` Stefan Monnier
@ 2005-03-18 14:07 ` David Kastrup
0 siblings, 0 replies; 5+ messages in thread
From: David Kastrup @ 2005-03-18 14:07 UTC (permalink / raw)
Cc: emacs-devel
Stefan Monnier <monnier@iro.umontreal.ca> writes:
>>> > * help.el (describe-mode): Allow a :minor-mode-function property to
>>> > specify a different minor mode toggle function than the variable.
>>> > * simple.el (auto-fill-function):
>>> > * subr.el (add-minor-mode): Use it.
>>>
>>> > I have my doubts that the resulting flexibility is really in the best
>>> > interest of the users...
>>>
>>> 100% agreement.
>>> It's only meant to clean up the code,
>
>> Wouldn't it be far more cleaner to convert old minor-modes which would
>> need this hack to proper minor-modes following standard semantics?
>
> You do realize that there are packages over which we have no
> control, right?
Well, then we won't need to worry about us not being able to use
define-minor-mode for them.
> make sure they're kept in sync. Maybe we could do (defvaralias
> 'auto-fill-function 'auto-fill-mode) and then slowly change modes to
> replace (if auto-fill-function (funcall auto-fill-function)) with
> (if auto-fill-mode (funcall normal-auto-fill-function)).
That won't work if modes set auto-fill-function themselves to a
function...
--
David Kastrup, Kriemhildstr. 15, 44793 Bochum
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2005-03-18 14:07 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2005-03-17 22:07 Is that change a good idea? David Kastrup
2005-03-17 22:16 ` Stefan Monnier
2005-03-18 8:24 ` Sascha Wilde
2005-03-18 13:45 ` Stefan Monnier
2005-03-18 14:07 ` David Kastrup
Code repositories for project(s) associated with this public inbox
https://git.savannah.gnu.org/cgit/emacs.git
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).