From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!.POSTED!not-for-mail From: Paul Rankin Newsgroups: gmane.emacs.bugs Subject: bug#28844: 26.0.90; display-line-numbers-mode should call window-configuration-change-hook Date: Tue, 17 Oct 2017 10:35:57 +1000 Message-ID: <1508200557.2705080.1141019864.6A2B8BD5@webmail.messagingengine.com> References: <1508054203.3504379.1139170720.0D0E99E9@webmail.messagingengine.com> <59E32D49.4030007@gmx.at> <1508065717.3534312.1139251176.600E646A@webmail.messagingengine.com> <59E350AE.3060005@gmx.at> <1508074073.3557079.1139314312.4BFE5BC2@webmail.messagingengine.com> <83o9p8h2yv.fsf@gnu.org> <1508124120.3709085.1139805520.1F653A1C@webmail.messagingengine.com> <87efq37knc.fsf@gmail.com> <1508130850.3734431.1139876192.21CE8281@webmail.messagingengine.com> <83zi8rf8rx.fsf@gnu.org> NNTP-Posting-Host: blaine.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable X-Trace: blaine.gmane.org 1508201571 12109 195.159.176.226 (17 Oct 2017 00:52:51 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Tue, 17 Oct 2017 00:52:51 +0000 (UTC) Cc: 28844@debbugs.gnu.org, agrambot@gmail.com To: Eli Zaretskii Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Tue Oct 17 02:52:47 2017 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 1e4G7c-0001DU-RH for geb-bug-gnu-emacs@m.gmane.org; Tue, 17 Oct 2017 02:52:41 +0200 Original-Received: from localhost ([::1]:35944 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1e4G7f-0004en-61 for geb-bug-gnu-emacs@m.gmane.org; Mon, 16 Oct 2017 20:52:43 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:41515) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1e4Fra-00089C-Bn for bug-gnu-emacs@gnu.org; Mon, 16 Oct 2017 20:36:07 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1e4FrW-0000g0-SK for bug-gnu-emacs@gnu.org; Mon, 16 Oct 2017 20:36:06 -0400 Original-Received: from debbugs.gnu.org ([208.118.235.43]:35807) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1e4FrW-0000fo-O0 for bug-gnu-emacs@gnu.org; Mon, 16 Oct 2017 20:36:02 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1e4FrW-0006PM-9k for bug-gnu-emacs@gnu.org; Mon, 16 Oct 2017 20:36:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: Paul Rankin Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Tue, 17 Oct 2017 00:36:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 28844 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: Original-Received: via spool by 28844-submit@debbugs.gnu.org id=B28844.150820055924623 (code B ref 28844); Tue, 17 Oct 2017 00:36:02 +0000 Original-Received: (at 28844) by debbugs.gnu.org; 17 Oct 2017 00:35:59 +0000 Original-Received: from localhost ([127.0.0.1]:44488 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1e4FrT-0006P5-FW for submit@debbugs.gnu.org; Mon, 16 Oct 2017 20:35:59 -0400 Original-Received: from out4-smtp.messagingengine.com ([66.111.4.28]:45957) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1e4FrR-0006Ox-W8 for 28844@debbugs.gnu.org; Mon, 16 Oct 2017 20:35:58 -0400 Original-Received: from compute3.internal (compute3.nyi.internal [10.202.2.43]) by mailout.nyi.internal (Postfix) with ESMTP id 909E320C0D; Mon, 16 Oct 2017 20:35:57 -0400 (EDT) Original-Received: from web5 ([10.202.2.215]) by compute3.internal (MEProxy); Mon, 16 Oct 2017 20:35:57 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=paulwrankin.com; h=cc:content-transfer-encoding:content-type:date:from :in-reply-to:message-id:mime-version:references:subject:to :x-me-sender:x-me-sender:x-sasl-enc; s=fm1; bh=NgOgTLlDlW5uz3e/U bnpgl0IANf+J6NEwZOfqxVhKxI=; b=2Q+vkbG/I5ktflN3P+qWck177FryXlLel aNtpPMwbZ8LGMnOTsp/S38HIXzVV6fzLbgrqf7v5Y1vekWmWiTsqMJrweN3hF6IO GmmroPcUng/jc1+RJ0cxYfB6yG2MFBuRU8LbtJAePiKChkAVCGpa+vVwa6RjNFdl TIm5wIhKerG5xEOreHPIjI3TUlMudRvlbgytUXhXXEr+LYdUZOgiAY6kMsCVhkqc yOLh5bpJ8paza9YQqHiU4Y22b8ins2otieFxIZXWmhC8ZYyvET/P8y3i+sIdtt1x EW/02/3SKLRCF/V+vLb8bLRLoO9VYosho0JbuQTyEtM27FmwMT+gg== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:content-transfer-encoding:content-type :date:from:in-reply-to:message-id:mime-version:references :subject:to:x-me-sender:x-me-sender:x-sasl-enc; s=fm1; bh=NgOgTL lDlW5uz3e/Ubnpgl0IANf+J6NEwZOfqxVhKxI=; b=dusYJLGguoIGNmYIDt99J3 oj7VQFduqxNLBtFP5xq3zL+wD/0tJU0JuvSI4O8+tjqER06QWUpPhIBvcDswVEiq qeE9LXij4r44QEuV2iGqWL6Fap/5YRLAokt5U9TQ9OhrBZEsM4MAxzxgxdmMsDc0 1IXcq1KeIfnxcBeiH7+UM53ewMGq17Mk0C7DDLRdIVHeTbF6lSG7Vh0GLVFDQMs2 f8IV5ToHN83RJQ+TqG7n3w+V9Y+G7CYUQJY+ADgZ0J8nMrpvbEk22gNNQ87RYGad UbsZPwzScPFKrisY1aZ84ZdZDYd339pmc5dcqe/u763JzAiOjftGaPim1DOEW/4g == X-ME-Sender: Original-Received: by mailuser.nyi.internal (Postfix, from userid 99) id 6B0D69E303; Mon, 16 Oct 2017 20:35:57 -0400 (EDT) X-Mailer: MessagingEngine.com Webmail Interface - ajax-26fdae60 In-Reply-To: <83zi8rf8rx.fsf@gnu.org> 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:138566 Archived-At: On Tue, 17 Oct 2017, at 12:48 AM, Eli Zaretskii wrote: > > From: Paul Rankin > > Cc: Eli Zaretskii , 28844@debbugs.gnu.org > > Date: Mon, 16 Oct 2017 15:14:10 +1000 > >=20 > > > To see if line numbers are present in a buffer (and to make it > > > compatible with older Emacsen), you should use something like: > > >=20 > > > (bound-and-true-p display-line-numbers) >=20 > Indeed, if the problem is with determining whether > line-number-display-width should be called, then bound-and-true-p is > the way. Sorry I didn't realize this was the issue. >=20 > > Sweet, thanks! I=E2=80=99ve encountered another bug with this mode #288= 55, so I think until it gets its house in order, the best thing to go with = is: > > (if (bound-and-true-p display-line-numbers) (display-line-numbers-mode = 0)) >=20 > So does this mean the issue in this bug report (which AFAIU was how to > set the window's display margins in a way that is sensitive to > display-line-numbers-mode) is resolved for you? Or is there anything > else to be done about this? (Bug#28855 is a separate issue, I will > respond to that there.) Your mode updates the display on its own without notifying Emacs. The basic= conceptual problem is that =E2=80=9Cevery time you need the value=E2=80=9D= is predicated on when display-line-numbers-mode changes the value. There= =E2=80=99s no way for another lisp program to know when that is.