[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Auto Fill Comments
From: |
Michael Heerdegen |
Subject: |
Re: Auto Fill Comments |
Date: |
Mon, 30 Nov 2020 00:41:08 +0100 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux) |
Christopher Dimech <dimech@gmx.com> writes:
> Was trying to have a keybinding that cycles between three things:
>
> 1. Autofill Only Comments
> 2. Autofill Whole Buffer
> 3. Revert to No-Autofill
>
> Problem started because I should use buffer-local. People suggested
> I read the manual to figure out what to do. But couldn't follow things
> well enough to come up with something that works.
Any specific questions? About things you didn't understand when
reading?
The basics are simple: You make a variable buffer local in the current
buffer with `make-local-variable'. Then setting the variable whenever
that buffer is current sets the buffer local binding (in that buffer) of
this variable. Evaluation of a variable results in the buffer local
value when there is one, else in the global binding. `default-value' to
return the global binding of a variable regardless of buffer-local
bindings.
See also `setq-local' which makes a variable buffer local in the current
buffer an sets the value at the same time.
Regards,
Michael.
- Re: Auto Fill Comments, (continued)
- Re: Auto Fill Comments, Arthur Miller, 2020/11/28
- Re: Auto Fill Comments, Christopher Dimech, 2020/11/28
- Re: Auto Fill Comments, Arthur Miller, 2020/11/28
- Re: Auto Fill Comments, Christopher Dimech, 2020/11/28
- Re: Auto Fill Comments, Michael Heerdegen, 2020/11/28
- Re: Auto Fill Comments, Christopher Dimech, 2020/11/28
- Re: Auto Fill Comments, Michael Heerdegen, 2020/11/28
- Re: Auto Fill Comments, Christopher Dimech, 2020/11/28
- Re: Auto Fill Comments,
Michael Heerdegen <=
- Re: Auto Fill Comments, Christopher Dimech, 2020/11/29
- Re: Auto Fill Comments, Emanuel Berg, 2020/11/29
- Re: Auto Fill Comments, Christopher Dimech, 2020/11/29
- Re: Auto Fill Comments, Emanuel Berg, 2020/11/29
- Re: Auto Fill Comments, tomas, 2020/11/30
- Re: Auto Fill Comments, Christopher Dimech, 2020/11/30
- Re: Auto Fill Comments, tomas, 2020/11/30
- Re: Auto Fill Comments, Christopher Dimech, 2020/11/30
- Re: Auto Fill Comments, Jean Louis, 2020/11/30
- RE: Auto Fill Comments, Drew Adams, 2020/11/29