From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: martin rudalics Newsgroups: gmane.emacs.bugs Subject: bug#8242: Issue with help menu and set-frame-font Date: Sun, 13 Mar 2011 14:44:33 +0100 Message-ID: <4D7CCA41.6010307@gmx.at> References: <64B7C423-6AF7-4655-BCAE-908EF130D5B9@gmail.com> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Trace: dough.gmane.org 1300025904 4821 80.91.229.12 (13 Mar 2011 14:18:24 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Sun, 13 Mar 2011 14:18:24 +0000 (UTC) Cc: 8242@debbugs.gnu.org To: Harold Pimentel Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Sun Mar 13 15:18:19 2011 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1Pym7b-0006kN-6b for geb-bug-gnu-emacs@m.gmane.org; Sun, 13 Mar 2011 15:18:15 +0100 Original-Received: from localhost ([127.0.0.1]:60392 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Pylwp-0004ja-1D for geb-bug-gnu-emacs@m.gmane.org; Sun, 13 Mar 2011 10:07:07 -0400 Original-Received: from [140.186.70.92] (port=43104 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Pylwg-0004eS-DK for bug-gnu-emacs@gnu.org; Sun, 13 Mar 2011 10:06:59 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Pylwf-00072D-8R for bug-gnu-emacs@gnu.org; Sun, 13 Mar 2011 10:06:58 -0400 Original-Received: from debbugs.gnu.org ([140.186.70.43]:35853) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Pylwf-000728-5O for bug-gnu-emacs@gnu.org; Sun, 13 Mar 2011 10:06:57 -0400 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.69) (envelope-from ) id 1PylbS-0002Wt-Rb; Sun, 13 Mar 2011 09:45:02 -0400 X-Loop: help-debbugs@gnu.org Resent-From: martin rudalics Original-Sender: debbugs-submit-bounces@debbugs.gnu.org Resent-To: owner@debbugs.gnu.org Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sun, 13 Mar 2011 13:45:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 8242 X-GNU-PR-Package: emacs X-GNU-PR-Keywords: Original-Received: via spool by 8242-submit@debbugs.gnu.org id=B8242.13000238849684 (code B ref 8242); Sun, 13 Mar 2011 13:45:02 +0000 Original-Received: (at 8242) by debbugs.gnu.org; 13 Mar 2011 13:44:44 +0000 Original-Received: from localhost ([127.0.0.1] helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1PylbA-0002W9-84 for submit@debbugs.gnu.org; Sun, 13 Mar 2011 09:44:44 -0400 Original-Received: from mailout-de.gmx.net ([213.165.64.22]) by debbugs.gnu.org with smtp (Exim 4.69) (envelope-from ) id 1Pylb7-0002Vw-TX for 8242@debbugs.gnu.org; Sun, 13 Mar 2011 09:44:43 -0400 Original-Received: (qmail invoked by alias); 13 Mar 2011 13:44:35 -0000 Original-Received: from 62-47-56-138.adsl.highway.telekom.at (EHLO [62.47.56.138]) [62.47.56.138] by mail.gmx.net (mp070) with SMTP; 13 Mar 2011 14:44:35 +0100 X-Authenticated: #14592706 X-Provags-ID: V01U2FsdGVkX19/d0hpPl1/V9PZyoAWBnWs+5NY9gmK/tlivM7+QQ VhlYQp9bHBAEpV User-Agent: Thunderbird 2.0.0.21 (Windows/20090302) In-Reply-To: <64B7C423-6AF7-4655-BCAE-908EF130D5B9@gmail.com> X-Y-GMX-Trusted: 0 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.11 Precedence: list Resent-Date: Sun, 13 Mar 2011 09:45:02 -0400 X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6 (newer, 3) X-Received-From: 140.186.70.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: , Original-Sender: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Errors-To: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.bugs:44969 Archived-At: > I'm having an issue with set-frame-font. It is as follows: > > - I use: > (set-frame-font "Menlo-12") Doesn't this already change the (pixel-)size of the frame? > - I split the current frame into two windows > - If I raise the help menu it goes into the opposite window, changing that buffer (this is normal) > - I maximize my window > - I was using maximize-frame.el, but simply making the window as large as possible until it "clicks" will suffice > - Now, if raise the help menu, it splits the current window vertically instead of putting the help into the other window (BUG HERE) > - If I don't change the font, I will not have this issue Large parts of Emacs think in terms of lines and columns. So what happens in my opinion is that with the default (larger, I presume) frame font less lines fit on one frame of the same pixel height than with the Menlo-12 font you want to use. If you invoke `set-frame-font' with the second argument nil, Emacs will usually adjust the frame's pixel height in order to make it occupy the same number of lines as with the previously used font. Hence, a subsequent check whether a window can be split fails just as if you hadn't changed the font at all, so an existing window gets reused. But if you maximize the frame, then with the Menlo-12 font _more_ lines may fit into a window than with the original font. So when you invoke help in the maximized frame, the test (via `split-height-threshold') whether an existing window can be split succeeds and a new window gets popped up. If you invoke `set-frame-font' with the second argument non-nil, Emacs should keep the (non-maximized) frame pixel height constant and you should be able to observe the splitting behavior with a non-maximized frame as well. Could you try to verify these my suppositions? martin