From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: David Engster Newsgroups: gmane.emacs.bugs Subject: bug#22000: 25.0.50; Running dired changes frame width, gtk_distribute_natural_allocation throws assertion Date: Wed, 25 Nov 2015 17:15:17 +0100 Message-ID: <87k2p6oy22.fsf@isaac.fritz.box> References: <87k2p8h1vn.fsf@isaac.fritz.box> <56541F95.8010006@gmx.at> <87y4dnfind.fsf@isaac.fritz.box> <5654B9F2.7000609@gmx.at> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: ger.gmane.org 1448468191 12239 80.91.229.3 (25 Nov 2015 16:16:31 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Wed, 25 Nov 2015 16:16:31 +0000 (UTC) Cc: 22000@debbugs.gnu.org To: martin rudalics Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Wed Nov 25 17:16:14 2015 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1a1cjq-0007dj-Mg for geb-bug-gnu-emacs@m.gmane.org; Wed, 25 Nov 2015 17:16:10 +0100 Original-Received: from localhost ([::1]:46241 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1a1cjs-0006g1-Fl for geb-bug-gnu-emacs@m.gmane.org; Wed, 25 Nov 2015 11:16:12 -0500 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:52927) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1a1cjn-0006fv-Ug for bug-gnu-emacs@gnu.org; Wed, 25 Nov 2015 11:16:08 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1a1cji-0005ft-OZ for bug-gnu-emacs@gnu.org; Wed, 25 Nov 2015 11:16:07 -0500 Original-Received: from debbugs.gnu.org ([208.118.235.43]:35012) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1a1cji-0005fn-9l for bug-gnu-emacs@gnu.org; Wed, 25 Nov 2015 11:16:02 -0500 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.80) (envelope-from ) id 1a1cjh-0001UY-V6 for bug-gnu-emacs@gnu.org; Wed, 25 Nov 2015 11:16:02 -0500 X-Loop: help-debbugs@gnu.org Resent-From: David Engster Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Wed, 25 Nov 2015 16:16:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 22000 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: Original-Received: via spool by 22000-submit@debbugs.gnu.org id=B22000.14484681435703 (code B ref 22000); Wed, 25 Nov 2015 16:16:01 +0000 Original-Received: (at 22000) by debbugs.gnu.org; 25 Nov 2015 16:15:43 +0000 Original-Received: from localhost ([127.0.0.1]:52953 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1a1cjP-0001Tu-69 for submit@debbugs.gnu.org; Wed, 25 Nov 2015 11:15:43 -0500 Original-Received: from randomsample.de ([5.45.97.173]:54527) by debbugs.gnu.org with esmtp (Exim 4.80) (envelope-from ) id 1a1cj4-0001TO-9h for 22000@debbugs.gnu.org; Wed, 25 Nov 2015 11:15:41 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=randomsample.de; s=a; h=Content-Type:MIME-Version:Message-ID:Date:References:In-Reply-To:Subject:Cc:To:From; bh=wUmMOkdkSPWw4xxaTUnHPvj0W+7kcPMhnGmjBcv2d9U=; b=kF5/WLo5qalQXhMWO8iaxMre+qYQzzstam7ihWdOmyrPOSWxUNlOmfkXH3fd/7Tl18ZTYa6LG9pg3TQ1qbvqbhT4CBoAWrmvcbRSo/pJJMHclaB9bINgC/0boZTUKh5K; Original-Received: from ip4d1645ea.dynamic.kabel-deutschland.de ([77.22.69.234] helo=isaac.fritz.box) by randomsample.de with esmtpsa (TLS1.2:RSA_AES_128_CBC_SHA1:128) (Exim 4.80) (envelope-from ) id 1a1cj3-0006XQ-07; Wed, 25 Nov 2015 17:15:21 +0100 In-Reply-To: <5654B9F2.7000609@gmx.at> (martin rudalics's message of "Tue, 24 Nov 2015 20:26:42 +0100") User-Agent: Gnus/5.13001 (Ma Gnus v0.10) Emacs/24.5 (gnu/linux) X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.15 Precedence: list X-detected-operating-system: by eggs.gnu.org: GNU/Linux 3.x 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-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.bugs:109237 Archived-At: martin rudalics writes: >> Yes. But at least I know now what really triggers this problem: GTK >> throws this assertion when the menubar is not completely visible. This >> is also why running Dired triggers this, because it adds a bunch of >> additional menu entries. The frame is then resized so that the menu-bar >> fits. > > Magnificent! Easy to trigger here by continuously narrowing the frame > until a menubar item disappears. And starting dired from a fairly > narrow frame with the menubar fully visible resizes the frame so that > all menubar items are visible. Thanks for finding the cause of this. > > And obviously this is Bug#15700 ;-) I really need to improve my search-fu... > I don't think we can/should do anything about this. Not sure about the "can", but I think we definitely should. The dired-thing is already pretty annoying for people like my co-worker who are very adamant about having an Emacs frame that is *exactly* 80 characters wide. He has to resize the frame every time he leaves Dired. Also, after some more testing, it seems pretty clear that the frame size is battled out between GTK and Emacs when you make the width smaller than the menu-bar. If you resize with the mouse, it depends on the window manager what exactly happens, but I've seen two things: - with 'wmii', the window simply snaps back to the width that's needed by the menu bar - with 'i3', I can resize to a smaller width with the mouse, but during the resize I see flickering to the menu-bar width Also, it seems to be impossible to programatically set a frame width that is smaller than the menu-bar. `set-frame-width' doesn't work, neither does `initial-frame-alist' or even the '-geometry' switch. Unfortunately, I'm not very familiar with GTK. My guess is that you would somehow have to catch the 'size-allocate' signal and do The Right Thing in the callback, but my hacks so far were not successful. > But at least we have to document it somewhere. Any ideas? For starters, I think this should be documented in the Emacs manual about frame parameters and in functions/variables like `set-frame-width' and `initial-frame-alist'. -David