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#25380: 25.1; save-window-excursion problem in batch mode Date: Tue, 10 Jan 2017 19:11:27 +0200 Message-ID: <837f62et6o.fsf@gnu.org> References: <7qwpe5xusr.fsf@fencepost.gnu.org> <58735A58.80801@gmx.at> <83pojwi7qc.fsf@gnu.org> <5873B811.4000404@gmx.at> <83inpodvyw.fsf@gnu.org> Reply-To: Eli Zaretskii NNTP-Posting-Host: blaine.gmane.org X-Trace: blaine.gmane.org 1484068343 7629 195.159.176.226 (10 Jan 2017 17:12:23 GMT) X-Complaints-To: usenet@blaine.gmane.org NNTP-Posting-Date: Tue, 10 Jan 2017 17:12:23 +0000 (UTC) Cc: p.stephani2@gmail.com, 25380@debbugs.gnu.org To: rudalics@gmx.at Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Tue Jan 10 18:12:18 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 1cQzxz-0000Qh-FJ for geb-bug-gnu-emacs@m.gmane.org; Tue, 10 Jan 2017 18:12:11 +0100 Original-Received: from localhost ([::1]:48688 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1cQzxy-00040C-R1 for geb-bug-gnu-emacs@m.gmane.org; Tue, 10 Jan 2017 12:12:10 -0500 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:34910) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1cQzxt-0003zv-Fj for bug-gnu-emacs@gnu.org; Tue, 10 Jan 2017 12:12:06 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1cQzxq-0001Ps-A1 for bug-gnu-emacs@gnu.org; Tue, 10 Jan 2017 12:12:05 -0500 Original-Received: from debbugs.gnu.org ([208.118.235.43]:33684) by eggs.gnu.org with esmtps (TLS1.0:RSA_AES_128_CBC_SHA1:16) (Exim 4.71) (envelope-from ) id 1cQzxq-0001Pk-77 for bug-gnu-emacs@gnu.org; Tue, 10 Jan 2017 12:12:02 -0500 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1cQzxq-00074n-2z for bug-gnu-emacs@gnu.org; Tue, 10 Jan 2017 12:12:02 -0500 X-Loop: help-debbugs@gnu.org Resent-From: Eli Zaretskii Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Tue, 10 Jan 2017 17:12:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 25380 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: Original-Received: via spool by 25380-submit@debbugs.gnu.org id=B25380.148406829727167 (code B ref 25380); Tue, 10 Jan 2017 17:12:02 +0000 Original-Received: (at 25380) by debbugs.gnu.org; 10 Jan 2017 17:11:37 +0000 Original-Received: from localhost ([127.0.0.1]:49083 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1cQzxR-000747-DT for submit@debbugs.gnu.org; Tue, 10 Jan 2017 12:11:37 -0500 Original-Received: from eggs.gnu.org ([208.118.235.92]:43636) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1cQzxQ-00073t-By for 25380@debbugs.gnu.org; Tue, 10 Jan 2017 12:11:36 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1cQzxI-000153-6H for 25380@debbugs.gnu.org; Tue, 10 Jan 2017 12:11:31 -0500 Original-Received: from fencepost.gnu.org ([2001:4830:134:3::e]:33655) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1cQzxI-00014y-38; Tue, 10 Jan 2017 12:11:28 -0500 Original-Received: from 84.94.185.246.cable.012.net.il ([84.94.185.246]:2242 helo=home-c4e4a596f7) by fencepost.gnu.org with esmtpsa (TLS1.2:RSA_AES_256_CBC_SHA1:256) (Exim 4.82) (envelope-from ) id 1cQzxH-0003ca-8R; Tue, 10 Jan 2017 12:11:27 -0500 In-reply-to: <83inpodvyw.fsf@gnu.org> (message from Eli Zaretskii on Mon, 09 Jan 2017 18:44:23 +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:127968 Archived-At: > Date: Mon, 09 Jan 2017 18:44:23 +0200 > From: Eli Zaretskii > Cc: p.stephani2@gmail.com, 25380@debbugs.gnu.org > > > > I just ran Emacs under a debugger with a breakpoint in > > > Fcurrent_window_configuration, then put a watchpoint on every top_line > > > member of every window that got saved there, and waited for it to > > > break. > > > > That's obvious. But how do I find out where that menubar line gets set? > > I will see what I can do about that. Further debugging reveals that I was mistaken: the frame's FRAME_MENU_BAR_LINES value is already 1 when Emacs starts. The problem is that the window's top is not in sync with that value; I guess resize_frame_windows was never called for the windows of the frame, not even in temacs. So perhaps one possible solution would be to call resize_frame_windows somehow during temacs run. > Could this be related to the bug#18136, bug#18196 woes? Only tangentially, I think. IOW, the same code is involved here, but the menu-bar lines value is correct in this case.