From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: Aaron Jensen Newsgroups: gmane.emacs.bugs Subject: bug#45748: 28.0.50; fit-frame-to-buffer ignores leading spaces Date: Sat, 9 Jan 2021 09:43:27 -0600 Message-ID: Mime-Version: 1.0 Content-Type: text/plain; charset="UTF-8" Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="35909"; mail-complaints-to="usenet@ciao.gmane.io" To: 45748@debbugs.gnu.org Original-X-From: bug-gnu-emacs-bounces+geb-bug-gnu-emacs=m.gmane-mx.org@gnu.org Sat Jan 09 16:44:09 2021 Return-path: Envelope-to: geb-bug-gnu-emacs@m.gmane-mx.org Original-Received: from lists.gnu.org ([209.51.188.17]) by ciao.gmane.io with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.92) (envelope-from ) id 1kyGPR-0009F8-DG for geb-bug-gnu-emacs@m.gmane-mx.org; Sat, 09 Jan 2021 16:44:09 +0100 Original-Received: from localhost ([::1]:52812 helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1kyGPQ-0001KC-FW for geb-bug-gnu-emacs@m.gmane-mx.org; Sat, 09 Jan 2021 10:44:08 -0500 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:53668) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1kyGPK-0001K0-G2 for bug-gnu-emacs@gnu.org; Sat, 09 Jan 2021 10:44:02 -0500 Original-Received: from debbugs.gnu.org ([209.51.188.43]:40909) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1kyGPK-0006Fn-7t for bug-gnu-emacs@gnu.org; Sat, 09 Jan 2021 10:44:02 -0500 Original-Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1kyGPK-0000TT-53 for bug-gnu-emacs@gnu.org; Sat, 09 Jan 2021 10:44:02 -0500 X-Loop: help-debbugs@gnu.org Resent-From: Aaron Jensen Original-Sender: "Debbugs-submit" Resent-CC: bug-gnu-emacs@gnu.org Resent-Date: Sat, 09 Jan 2021 15:44:01 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: report 45748 X-GNU-PR-Package: emacs X-Debbugs-Original-To: bug-gnu-emacs@gnu.org Original-Received: via spool by submit@debbugs.gnu.org id=B.16102070241790 (code B ref -1); Sat, 09 Jan 2021 15:44:01 +0000 Original-Received: (at submit) by debbugs.gnu.org; 9 Jan 2021 15:43:44 +0000 Original-Received: from localhost ([127.0.0.1]:52455 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kyGP2-0000Sn-E8 for submit@debbugs.gnu.org; Sat, 09 Jan 2021 10:43:44 -0500 Original-Received: from lists.gnu.org ([209.51.188.17]:46960) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1kyGP0-0000Se-14 for submit@debbugs.gnu.org; Sat, 09 Jan 2021 10:43:43 -0500 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]:53646) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1kyGOz-0001IA-Pz for bug-gnu-emacs@gnu.org; Sat, 09 Jan 2021 10:43:41 -0500 Original-Received: from mail-yb1-xb35.google.com ([2607:f8b0:4864:20::b35]:36423) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1kyGOy-00067b-Ba for bug-gnu-emacs@gnu.org; Sat, 09 Jan 2021 10:43:41 -0500 Original-Received: by mail-yb1-xb35.google.com with SMTP id y4so12487357ybn.3 for ; Sat, 09 Jan 2021 07:43:39 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=mime-version:from:date:message-id:subject:to; bh=bPXGY//NrmUfE7N9VvQbc+y/DNh/6/wtdPm4thsPWsQ=; b=Nn/ne8PXPxvbJz/ZKhoikAw5oghPMzAothpY9hkCubP3mcHCV2557pQwEUDzGDwEcV 3b5ltLNqrPUsVUolfU/btPRvwTlg+qibSOWfSdDockVQoW3UxIdcUvNbR2Z/8YH3qejn uzTnFbjNKoX24iIbJiLo4m9o0l2InnmvOrnvBRNcHxcKuZL9KEs6FwksylUZAoR0+fX8 CiUA2WbaCkKFW3n1uXqEvIbKT0lbnM54LvNKZU5ZaMOC4FZV+dn1HXaao99Vs55Y4tys 9aF4gVv0J2GT6xcLKHF3tk7n7poxLLqrXgyGcJ9M4OQZY88lmYc9SXM1KWp05IGiAAFB hBqg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:from:date:message-id:subject:to; bh=bPXGY//NrmUfE7N9VvQbc+y/DNh/6/wtdPm4thsPWsQ=; b=sIv+qMSZQP3AFANbu3ZT3ZAe10hFeqeXuk+Hsxw3Ljzi2bjicPoVewjnUVtXCedFOa B2+KTUcCjs6/VfgQW+sT3yJCiIKMfKvEDSCqXEdBknvwAIsmY28JYun6WcAKEGJHYnSW r/0rUEu2k/454j1hbKInHXsQV8+vCuVJs2tLKJPfpGv3ZKtLHZscsXI5dEfxPtbLTs2d 0IlmdsyWWshfFnZyt13luVFVgC0MibbIv9c5mS24spXqeNiDUojdNf+qR/6yLlptecJb yhIbwh0Fx1RNcAL9VkHCBfysVgXi7LCSWcyBRpEWum4S+y5dTCO17uYRuUVqgIMZ37Ib w9MA== X-Gm-Message-State: AOAM531RScmxrCZQE7LfxIrARh7fstlJhKF2hrjOg0Z5O3+/zhiQ0kXv n69tqWmsYkmfo5NX5bbk3ya7HaypVIiHteoYMboqpwlOd5y01A== X-Google-Smtp-Source: ABdhPJyYdQj0SFzWGPfYJW5bC1mu09tc8kYh+5vcM/YweldyLH5/adfVy6eZQ6oOXzGtbqf5HqjxjXjRir9+VBDV53w= X-Received: by 2002:a25:9c07:: with SMTP id c7mr13127354ybo.21.1610207018414; Sat, 09 Jan 2021 07:43:38 -0800 (PST) Received-SPF: pass client-ip=2607:f8b0:4864:20::b35; envelope-from=aaronjensen@gmail.com; helo=mail-yb1-xb35.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FROM=0.001, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list 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-mx.org@gnu.org Original-Sender: "bug-gnu-emacs" Xref: news.gmane.io gmane.emacs.bugs:197553 Archived-At: >From emacs -Q: Create a buffer with only the following text and no trailing newline (note the leading space): XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX M-x fit-frame-to-buffer The frame will be resized to the width of the X's, not including the leading space, causing the line to wrap. If the leading space is removed, it works as expected. Any number of leading spaces are ignored, as are trailing spaces. This has practical applications with company-posframe, which uses sometimes one line child windows to show completion options and has leading and trailing spaces around each completion. In GNU Emacs 28.0.50 (build 1, x86_64-apple-darwin19.6.0, NS appkit-1894.60 Version 10.15.7 (Build 19H114)) of 2021-01-08 built on aaron-sub.local Repository revision: d1c5e7afb1ad9890d925e8c1a5392b701a754dd5 Repository branch: master Windowing system distributor 'Apple', version 10.3.1894 System Description: Mac OS X 10.15.7 Aaron