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#1348: set-frame-width and set-frame-position seem buggy on at least MSWindows Date: Tue, 18 Nov 2008 14:03:27 +0100 Message-ID: <4922BD1F.2080604@gmx.at> References: Reply-To: martin rudalics , 1348@emacsbugs.donarmstrong.com NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="------------050206010601090607060303" X-Trace: ger.gmane.org 1227015038 29233 80.91.229.12 (18 Nov 2008 13:30:38 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Tue, 18 Nov 2008 13:30:38 +0000 (UTC) Cc: 1348@emacsbugs.donarmstrong.com To: Themba Fletcher Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane.org@gnu.org Tue Nov 18 14:31:38 2008 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.50) id 1L2Qfz-0004Nj-HE for geb-bug-gnu-emacs@m.gmane.org; Tue, 18 Nov 2008 14:31:31 +0100 Original-Received: from localhost ([127.0.0.1]:60555 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1L2Qeq-0005k4-Nv for geb-bug-gnu-emacs@m.gmane.org; Tue, 18 Nov 2008 08:30:20 -0500 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1L2Qel-0005jS-B3 for bug-gnu-emacs@gnu.org; Tue, 18 Nov 2008 08:30:15 -0500 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1L2Qei-0005ia-Ab for bug-gnu-emacs@gnu.org; Tue, 18 Nov 2008 08:30:14 -0500 Original-Received: from [199.232.76.173] (port=42554 helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1L2Qei-0005iX-5v for bug-gnu-emacs@gnu.org; Tue, 18 Nov 2008 08:30:12 -0500 Original-Received: from rzlab.ucr.edu ([138.23.92.77]:49116) by monty-python.gnu.org with esmtps (TLS-1.0:DHE_RSA_AES_256_CBC_SHA1:32) (Exim 4.60) (envelope-from ) id 1L2Qei-0001uS-1m for bug-gnu-emacs@gnu.org; Tue, 18 Nov 2008 08:30:12 -0500 Original-Received: from rzlab.ucr.edu (rzlab.ucr.edu [127.0.0.1]) by rzlab.ucr.edu (8.13.8/8.13.8/Debian-3) with ESMTP id mAIDU8jd027524; Tue, 18 Nov 2008 05:30:09 -0800 Original-Received: (from debbugs@localhost) by rzlab.ucr.edu (8.13.8/8.13.8/Submit) id mAIDF3fp023471; Tue, 18 Nov 2008 05:15:03 -0800 X-Loop: don@donarmstrong.com Resent-From: martin rudalics Resent-To: bug-submit-list@donarmstrong.com Resent-CC: Emacs Bugs Resent-Date: Tue, 18 Nov 2008 13:15:03 +0000 Resent-Message-ID: Resent-Sender: don@donarmstrong.com X-Emacs-PR-Message: report 1348 X-Emacs-PR-Package: emacs X-Emacs-PR-Keywords: Original-Received: via spool by 1348-submit@emacsbugs.donarmstrong.com id=B1348.122701355822158 (code B ref 1348); Tue, 18 Nov 2008 13:15:03 +0000 Original-Received: (at 1348) by emacsbugs.donarmstrong.com; 18 Nov 2008 13:05:58 +0000 Original-Received: from mail.gmx.net (mail.gmx.net [213.165.64.20]) by rzlab.ucr.edu (8.13.8/8.13.8/Debian-3) with SMTP id mAID5sHR022144 for <1348@emacsbugs.donarmstrong.com>; Tue, 18 Nov 2008 05:05:55 -0800 Original-Received: (qmail invoked by alias); 18 Nov 2008 13:05:48 -0000 Original-Received: from 62-47-49-27.adsl.highway.telekom.at (EHLO [62.47.49.27]) [62.47.49.27] by mail.gmx.net (mp021) with SMTP; 18 Nov 2008 14:05:48 +0100 X-Authenticated: #14592706 X-Provags-ID: V01U2FsdGVkX1/aNNAJe5LafDtGl23M8Rv6KcnIetH8ZxKa2SoYSd qtzGeli8SY/Nxl User-Agent: Thunderbird 2.0.0.16 (Windows/20080708) In-Reply-To: X-Y-GMX-Trusted: 0 X-FuHaFi: 0.72,0.55 X-detected-operating-system: by monty-python.gnu.org: GNU/Linux 2.6 (newer, 3) Resent-Date: Tue, 18 Nov 2008 08:30:14 -0500 X-BeenThere: bug-gnu-emacs@gnu.org X-Mailman-Version: 2.1.5 Precedence: list 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:22470 Archived-At: This is a multi-part message in MIME format. --------------050206010601090607060303 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit >>> When migrating to Emacs 22.3.1 on microsoft windows, the following >>> lines in my .emacs file do not behave as expected: > >>> (set-frame-position (selected-frame) 0 0) >>> (sleep-for 2) ; not originally in my .emacs -- testing only >>> (set-frame-width (selected-frame) 150) >>> (sleep-for 2) >>> (set-frame-height (selected-frame) 55) >>> (sleep-for 2)) [...] > 1. The bug is present in 22.2 > 2. (set-frame-size) is not affected, and is probably a better work-around > than I gave in my previous message. Interesting. Does the attached patch give better results? martin --------------050206010601090607060303 Content-Type: text/plain; name="dispnew.diff" Content-Transfer-Encoding: 7bit Content-Disposition: inline; filename="dispnew.diff" *** dispnew.c.~1.424.~ 2008-10-28 07:22:51.656250000 +0100 --- dispnew.c 2008-11-18 13:57:27.546875000 +0100 *************** *** 6305,6310 **** --- 6305,6316 ---- int new_frame_total_cols; int count = SPECPDL_INDEX (); + /* If an argument is zero, set it to the current value. */ + if (newheight == 0) + newheight = FRAME_LINES (f); + if (newwidth == 0) + newwidth = FRAME_COLS (f); + /* If we can't deal with the change now, queue it for later. */ if (delay || (redisplaying_p && !safe)) { *************** *** 6318,6329 **** f->new_text_lines = 0; f->new_text_cols = 0; - /* If an argument is zero, set it to the current value. */ - if (newheight == 0) - newheight = FRAME_LINES (f); - if (newwidth == 0) - newwidth = FRAME_COLS (f); - /* Compute width of windows in F. This is the width of the frame without vertical scroll bars. */ new_frame_total_cols = FRAME_TOTAL_COLS_ARG (f, newwidth); --- 6324,6329 ---- --------------050206010601090607060303--