[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PATCH] font-core: add font-lock-{enable, disable}-global-for functi
From: |
Stefan Monnier |
Subject: |
Re: [PATCH] font-core: add font-lock-{enable, disable}-global-for functions |
Date: |
Sun, 04 Jan 2015 18:44:29 -0500 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/25.0.50 (gnu/linux) |
>> Maybe we should provide something like M-x customize-minor-mode-states RET
>> which would collect the presence/absence of `foo-mode' or `(lambda ()
>> (foo-mode N))' in all the hooks and let the user add/remove them from
>> those hooks.
> That might be handy.
> But that wouldn't solve the "derived modes problem" any better
> than a docstring would (if it would, how?).
Depends what you mean by "derived modes problem". My version of the
problem is when activating foo-mode in parent-mode and foo-mode fails to
be activated in child-mode.
This problem should not affect M-x customize-minor-mode-states RET.
> And scanning hooks for enabled/disabled modes would be necessarily
> imprecise: even if we take care of the three main variations (`foo-mode',
> (lambda () (foo-mode 1)), (lambda () (foo-mode -1))), that still leaves out
> random functions (lambdas or named) that include a `foo-mode' call among
> other code, that a more advanced user could have in their init file, or some
> yet-another package might include in their "initialize me" function.
That's no worse than the current font-lock-global-modes.
Stefan
- Re: [PATCH] font-core: add font-lock-{enable, disable}-global-for functions, (continued)
- Re: [PATCH] font-core: add font-lock-{enable, disable}-global-for functions, Stefan Monnier, 2015/01/03
- Re: [PATCH] font-core: add font-lock-{enable, disable}-global-for functions, Michal Nazarewicz, 2015/01/03
- Re: [PATCH] font-core: add font-lock-{enable, disable}-global-for functions, Stefan Monnier, 2015/01/03
- Re: [PATCH] font-core: add font-lock-{enable, disable}-global-for functions, Michal Nazarewicz, 2015/01/04
- Re: [PATCH] font-core: add font-lock-{enable, disable}-global-for functions, Stefan Monnier, 2015/01/04
- Re: [PATCH] font-core: add font-lock-{enable, disable}-global-for functions, Dmitry Gutov, 2015/01/04
- Re: [PATCH] font-core: add font-lock-{enable, disable}-global-for functions, Michal Nazarewicz, 2015/01/04
- Re: [PATCH] font-core: add font-lock-{enable, disable}-global-for functions, Dmitry Gutov, 2015/01/04
- Re: [PATCH] font-core: add font-lock-{enable, disable}-global-for functions, Stefan Monnier, 2015/01/04
- Re: [PATCH] font-core: add font-lock-{enable, disable}-global-for functions, Dmitry Gutov, 2015/01/04
- Re: [PATCH] font-core: add font-lock-{enable, disable}-global-for functions,
Stefan Monnier <=
- Re: [PATCH] font-core: add font-lock-{enable, disable}-global-for functions, Dmitry Gutov, 2015/01/04
- Re: [PATCH] font-core: add font-lock-{enable, disable}-global-for functions, Dmitry Gutov, 2015/01/04
- Re: [PATCH] font-core: add font-lock-{enable, disable}-global-for functions, Stefan Monnier, 2015/01/04