From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: PierGianLuca Newsgroups: gmane.emacs.help Subject: Scrollbar width not respected in restored frames Date: Mon, 20 Nov 2023 11:46:37 +0100 Message-ID: <76293cb5-bba5-77ab-8420-cc60787a6fd4@magnaspesmeretrix.org> Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8bit Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="26236"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Thunderbird/102.15.1 To: help-gnu-emacs@gnu.org Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane-mx.org@gnu.org Mon Nov 20 11:47:36 2023 Return-path: Envelope-to: geh-help-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 1r51oV-0006e3-R0 for geh-help-gnu-emacs@m.gmane-mx.org; Mon, 20 Nov 2023 11:47:36 +0100 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1r51nm-0005fd-52; Mon, 20 Nov 2023 05:46:50 -0500 Original-Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1r51nk-0005fR-75 for help-gnu-emacs@gnu.org; Mon, 20 Nov 2023 05:46:48 -0500 Original-Received: from manu28.manufrog.com ([138.128.182.226]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1r51nh-0000nq-Vi for help-gnu-emacs@gnu.org; Mon, 20 Nov 2023 05:46:47 -0500 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=magnaspesmeretrix.org; s=default; h=Content-Transfer-Encoding:Content-Type: Subject:From:To:MIME-Version:Date:Message-ID:Sender:Reply-To:Cc:Content-ID: Content-Description:Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc :Resent-Message-ID:In-Reply-To:References:List-Id:List-Help:List-Unsubscribe: List-Subscribe:List-Post:List-Owner:List-Archive; bh=SAc0VUZWdSgzIv6+owniVXygNvozAu1jfh62s+8ELXg=; b=cwcV7Hvtx+zUFXBmHGy6t5g6AR 5ibIZpuNpDfvPx+5Zmy+6aP4R0tbr0Vkrg2GJ0xwjVR5592u87rDTyctDdxiIir7Flxv6+6KJXiIQ VzkvUgAYj9yCjoZFucTzLMzHA; Original-Received: from 164.51-174-11.customer.lyse.net ([51.174.11.164]:51582 helo=[192.168.10.171]) by manu28.manufrog.com with esmtpsa (TLS1.2) tls TLS_ECDHE_RSA_WITH_AES_128_GCM_SHA256 (Exim 4.96.2) (envelope-from ) id 1r51ng-0006zO-2D for help-gnu-emacs@gnu.org; Mon, 20 Nov 2023 11:46:43 +0100 Content-Language: en-GB, en-US X-AntiAbuse: This header was added to track abuse, please include it with any abuse report X-AntiAbuse: Primary Hostname - manu28.manufrog.com X-AntiAbuse: Original Domain - gnu.org X-AntiAbuse: Originator/Caller UID/GID - [47 12] / [47 12] X-AntiAbuse: Sender Address Domain - magnaspesmeretrix.org X-Get-Message-Sender-Via: manu28.manufrog.com: authenticated_id: luca@magnaspesmeretrix.org X-Authenticated-Sender: manu28.manufrog.com: luca@magnaspesmeretrix.org Received-SPF: pass client-ip=138.128.182.226; envelope-from=luca@magnaspesmeretrix.org; helo=manu28.manufrog.com X-Spam_score_int: -18 X-Spam_score: -1.9 X-Spam_bar: - X-Spam_report: (-1.9 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, SPF_HELO_NONE=0.001, SPF_PASS=-0.001, T_SCC_BODY_TEXT_LINE=-0.01 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane-mx.org@gnu.org Original-Sender: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane-mx.org@gnu.org Xref: news.gmane.io gmane.emacs.help:145556 Archived-At: Hi everyone, I'm on Ubuntu 20.04, KDE Plasma X11. Emacs 29.1 from tarball. I consistently see a discrepancy between the vertical-scrollbar width of the initial frames, restored from a previous session, and of subsequent frames called with make-frame-command (C-x52). Here is an example, I'd like to know whether others see this behaviour too: 1. Make sure Desktop-save-mode is on 2. Select any geometry you like in default-frame-alist and specify scroll-bar-width with some value (in my case it's "21") 3. Create a new frame with "C-x 5 2". 4. Check that the vertical scrollbar respects the width specified in default-frame-alist. If you like, check the window geometry with some tool like "xwininfo". 5. Close all other frames, make sure the one you created in step 3. is the only one left. 6. Quit the Emacs session 7. Start Emacs. You should see the frame from the previous session. 8. Check the width of the vertical scrollbar in this frame. You should see it's different from the one right before you quit Emacs. This should be confirmed by "xwininfo" or similar tool. 9. Create a new frame with "C-x 5 2". You should see that the new frame respects the scrollbar width of "default-frame-alist" (and it's different from the one of the first, initially restored frame). May this be a bug in desktop-save-mode? Here are some additional details: • If the frame width is changed *manually* (for instance first enlarge then bring to original size) then the correct width is restored upon restarting Emacs • The erroneous scrollbar width that Emacs presents when restoring windows seems to be the default one • Specifying the width in "early-init.el" with (add-to-list 'default-frame-alist '(scroll-bar-width . 21)) has no effect. Same if initial-frame-alist is used instead/in addition • Specifying (setq frame-resize-pixelwise t) either in init.el or early-init.el doesn't solve this. • I see this behaviour both when configuring Emacs with "--with-x-toolkit=lucid" and with "--with-x-toolkit=gtk", and both with or without "--without-toolkit-scroll-bars". • My windows manager (KWin) has an explicit rule to respect any geometry that Emacs asks. I made sure of this: I can resize the Emacs windows as I please, and their geometries are respected upon restarting. Cheers, Luca