* bug#17778: 24.4.50; rcirc-omit-mode should only call `recenter' if `current-buffer' is equal to `window-buffer'
@ 2014-06-14 11:27 Kan-Ru Chen
2014-06-14 12:50 ` Daimrod
0 siblings, 1 reply; 2+ messages in thread
From: Kan-Ru Chen @ 2014-06-14 11:27 UTC (permalink / raw)
To: 17778
[-- Attachment #1: Type: text/plain, Size: 437 bytes --]
Step to reproduce:
(add-hook 'rcirc-mode-hook 'rcirc-omit-mode)
When rcirc trys auto-connect to channels, emacs will show
(error "`recenter'ing a window that does not display current-buffer.")
Patch attached
In GNU Emacs 24.4.50.6 (x86_64-unknown-linux-gnu, GTK+ Version 3.12.2)
of 2014-06-14 on isil
Windowing system distributor `The X.Org Foundation', version 11.0.11501000
System Description: Debian GNU/Linux unstable (sid)
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: 0001-net-rcirc.el-Only-call-recenter-if-current-buffer-is.patch --]
[-- Type: text/x-diff, Size: 1472 bytes --]
From 901b38e1f17def0b4ee64f78f54d04e3295eb6db Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Kan-Ru=20Chen=20=28=E9=99=B3=E4=BE=83=E5=A6=82=29?=
<kanru@kanru.info>
Date: Sat, 14 Jun 2014 19:21:00 +0800
Subject: [PATCH] net/rcirc.el: Only call `recenter' if `current-buffer' is
equal to `window-buffer'
---
lisp/ChangeLog | 5 +++++
lisp/net/rcirc.el | 4 +++-
2 files changed, 8 insertions(+), 1 deletion(-)
diff --git a/lisp/ChangeLog b/lisp/ChangeLog
index 1df12d4..8317393 100644
--- a/lisp/ChangeLog
+++ b/lisp/ChangeLog
@@ -1,3 +1,8 @@
+2014-06-14 Kan-Ru Chen <kanru@kanru.info>
+
+ * net/rcirc.el (rcirc-omit-mode): Only call `recenter' if
+ `current-buffer' is equal to `window-buffer'.
+
2014-06-13 Glenn Morris <rgm@gnu.org>
* Makefile.in ($(lisp)/cus-load.el, $(lisp)/finder-inf.el)
diff --git a/lisp/net/rcirc.el b/lisp/net/rcirc.el
index 41cc002..1e3ee32 100644
--- a/lisp/net/rcirc.el
+++ b/lisp/net/rcirc.el
@@ -1903,7 +1903,9 @@ Uninteresting lines are those whose responses are listed in
(message "Rcirc-Omit mode enabled"))
(remove-from-invisibility-spec '(rcirc-omit . nil))
(message "Rcirc-Omit mode disabled"))
- (recenter (when (> (point) rcirc-prompt-start-marker) -1)))
+ (when (and (eq (current-buffer) (window-buffer))
+ (> (point) rcirc-prompt-start-marker))
+ (recenter -1)))
(defun rcirc-switch-to-server-buffer ()
"Switch to the server buffer associated with current channel buffer."
--
2.0.0
^ permalink raw reply related [flat|nested] 2+ messages in thread
* bug#17778: 24.4.50; rcirc-omit-mode should only call `recenter' if `current-buffer' is equal to `window-buffer'
2014-06-14 11:27 bug#17778: 24.4.50; rcirc-omit-mode should only call `recenter' if `current-buffer' is equal to `window-buffer' Kan-Ru Chen
@ 2014-06-14 12:50 ` Daimrod
0 siblings, 0 replies; 2+ messages in thread
From: Daimrod @ 2014-06-14 12:50 UTC (permalink / raw)
To: Kan-Ru Chen; +Cc: 17778
Kan-Ru Chen (陳侃如) <kanru@kanru.info> writes:
> Step to reproduce:
>
> (add-hook 'rcirc-mode-hook 'rcirc-omit-mode)
>
> When rcirc trys auto-connect to channels, emacs will show
>
> (error "`recenter'ing a window that does not display current-buffer.")
I've reported this issue yesterday, see bug#17769.
Best,
--
Daimrod/Greg
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2014-06-14 12:50 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-06-14 11:27 bug#17778: 24.4.50; rcirc-omit-mode should only call `recenter' if `current-buffer' is equal to `window-buffer' Kan-Ru Chen
2014-06-14 12:50 ` Daimrod
Code repositories for project(s) associated with this external index
https://git.savannah.gnu.org/cgit/emacs.git
https://git.savannah.gnu.org/cgit/emacs/org-mode.git
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.