[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
bug#23098: 25.0.92; (recenter -1) can leave point in the middle of the w
From: |
Drew Adams |
Subject: |
bug#23098: 25.0.92; (recenter -1) can leave point in the middle of the window |
Date: |
Sun, 27 Mar 2016 08:07:24 -0700 (PDT) |
> > (add-to-list
> > 'erc-mode-hook
> > #'(lambda () (set (make-local-variable 'scroll-conservatively) 100)))
>
> You should use add-hook for hook variables.
Also (nits):
1. No need to use #' with lambdas (no advantage in a context that
expects a function).
2. It is generally a good idea to use a named function (not a
lambda) on a hook. For one thing, removing it is easier and
more robust (`remove-hook') - no worries about differences in
whitespace etc.
3. Emacs now has `setq-local': `(setq-local VAR VALUE)'. (I too
use `(set (make-local-variable VAR) VALUE)', but mainly because
I usually need code that works also for older Emacs versions.)
- bug#23098: 25.0.92; (recenter -1) can leave point in the middle of the window, Jorgen Schaefer, 2016/03/23
- bug#23098: 25.0.92; (recenter -1) can leave point in the middle of the window, Eli Zaretskii, 2016/03/23
- bug#23098: 25.0.92; (recenter -1) can leave point in the middle of the window, Jorgen Schäfer, 2016/03/23
- bug#23098: 25.0.92; (recenter -1) can leave point in the middle of the window, Eli Zaretskii, 2016/03/23
- bug#23098: 25.0.92; (recenter -1) can leave point in the middle of the window, Jorgen Schäfer, 2016/03/24
- bug#23098: 25.0.92; (recenter -1) can leave point in the middle of the window, Eli Zaretskii, 2016/03/24
- bug#23098: 25.0.92; (recenter -1) can leave point in the middle of the window, Jorgen Schäfer, 2016/03/24
- bug#23098: 25.0.92; (recenter -1) can leave point in the middle of the window, Eli Zaretskii, 2016/03/24
- bug#23098: 25.0.92; (recenter -1) can leave point in the middle of the window, John Wiegley, 2016/03/26
- bug#23098: 25.0.92; (recenter -1) can leave point in the middle of the window, Andreas Schwab, 2016/03/27
- bug#23098: 25.0.92; (recenter -1) can leave point in the middle of the window,
Drew Adams <=
- bug#23098: 25.0.92; (recenter -1) can leave point in the middle of the window, Jorgen Schäfer, 2016/03/28
- bug#23098: 25.0.92; (recenter -1) can leave point in the middle of the window, Eli Zaretskii, 2016/03/28
- bug#23098: 25.0.92; (recenter -1) can leave point in the middle of the window, Jorgen Schäfer, 2016/03/28
- bug#23098: 25.0.92; (recenter -1) can leave point in the middle of the window, Eli Zaretskii, 2016/03/28