From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED!not-for-mail From: Eli Zaretskii Newsgroups: gmane.emacs.bugs Subject: bug#32637: 27.0.50; window-size-change-functions not run from local hook Date: Wed, 05 Sep 2018 18:26:55 +0300 Message-ID: <83k1o0x8w0.fsf@gnu.org> References: <87musx9dr1.fsf@mail.linkov.net> <5B8F8A0C.1030908@gmx.at> NNTP-Posting-Host: blaine.gmane.org X-Trace: blaine.gmane.org 1536161168 7153 195.159.176.226 (5 Sep 2018 15:26:08 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Wed, 5 Sep 2018 15:26:08 +0000 (UTC) Cc: 32637@debbugs.gnu.org, juri@linkov.net To: martin rudalics Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Wed Sep 05 17:26:04 2018 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by blaine.gmane.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fxZgw-0001g8-Hp for geb-bug-gnu-emacs@m.gmane.org; Wed, 05 Sep 2018 17:26:02 +0200 Original-Received: from localhost ([::1]:56771 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1fxZj2-0004yf-Mi for geb-bug-gnu-emacs@m.gmane.org; Wed, 05 Sep 2018 11:28:12 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:56933) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1fxZit-0004v6-UM for bug-gnu-emacs@gnu.org; Wed, 05 Sep 2018 11:28:04 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1fxZit-0005Rc-7F for bug-gnu-emacs@gnu.org; Wed, 05 Sep 2018 11:28:03 -0400 Original-Received: from debbugs.gnu.org ([208.118.235.43]:42313) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1fxZit-0005RW-39 for bug-gnu-emacs@gnu.org; Wed, 05 Sep 2018 11:28:03 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1fxZis-0007D7-Rk for bug-gnu-emacs@gnu.org; Wed, 05 Sep 2018 11:28:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Eli Zaretskii Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Wed, 05 Sep 2018 15:28:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 32637 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: Original-Received: via spool by 32637-submit@debbugs.gnu.org id=B32637.153616123227644 (code B ref 32637); Wed, 05 Sep 2018 15:28:02 +0000 Original-Received: (at 32637) by debbugs.gnu.org; 5 Sep 2018 15:27:12 +0000 Original-Received: from localhost ([127.0.0.1]:47327 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fxZi3-0007Bn-2F for submit@debbugs.gnu.org; Wed, 05 Sep 2018 11:27:12 -0400 Original-Received: from eggs.gnu.org ([208.118.235.92]:35669) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1fxZi1-0007BS-BY for 32637@debbugs.gnu.org; Wed, 05 Sep 2018 11:27:09 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1fxZhr-0004ou-97 for 32637@debbugs.gnu.org; Wed, 05 Sep 2018 11:27:04 -0400 Original-Received: from fencepost.gnu.org ([2001:4830:134:3::e]:45798) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1fxZhr-0004oi-3u; Wed, 05 Sep 2018 11:26:59 -0400 Original-Received: from [176.228.60.248] (port=1772 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1fxZhq-0002R1-ND; Wed, 05 Sep 2018 11:26:59 -0400 In-reply-to: <5B8F8A0C.1030908@gmx.at> (message from martin rudalics on Wed, 05 Sep 2018 09:47:24 +0200) X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.2.x-3.x [generic] X-Received-From: 208.118.235.43 X-BeenThere: bug-gnu-emacs@gnu.org List-Id: "Bug reports for GNU Emacs, the Swiss army knife of text editors" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Original-Sender: "bug-gnu-emacs" Xref: news.gmane.org gmane.emacs.bugs:150052 Archived-At: > Date: Wed, 05 Sep 2018 09:47:24 +0200 > From: martin rudalics > > > window-size-change-functions needs to notify the buffer > > that requested such notifications via this hook. > > This is a legitimate request but I'm not sure whether we should do > that for two reasons: > > The first reason is that we already run a buffer-local part of > 'window-configuration-change-hook' and I dislike it. Selecting a > window and making its buffer current for the sake of running a hook is > a bad idea IMO because both, selected window and current buffer, are > vital informations and a function run by a hook should be aware of > them. Worse even, we already make the selected window's buffer > current first which might defeat the expectations of a function run by > the global hook. > > Also the window in question might not have changed at all. The thing > that did change is the window configuration of a frame and it would be > much more interesting if the hook told me what really has changed > instead of telling me that a buffer's window might have changed. > > The second reason is a purely technical one: We'd have to walk the > window tree to find out which buffer may have been affected. However, > the function run by the local hook would still have to find out which > window(s) shouwing the buffer was (were) potentially affected. This > means that the buffer-local function would have to walk the window > tree a second time anyway. I actually don't understand why we need to support buffer-local hooks in window-size-change-functions. This hook clearly applies to the entire frame, so anything buffer-local sounds inappropriate there.