From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.io!.POSTED.blaine.gmane.org!not-for-mail From: David Hedlund Newsgroups: gmane.emacs.devel Subject: Re: Solution to a proposed FAQ, how to maximize emacs quickly (like `emacs --maximize`) for GNU/Linux Date: Fri, 29 Sep 2023 22:57:23 +0200 Message-ID: <61633510-00fa-45e4-ace5-54ef38be038f@beloved.name> References: <19e53542-bfb0-4e48-8845-01fd34d93dbb@beloved.name> <83il7t1n1z.fsf@gnu.org> <834jjcc27s.fsf@gnu.org> Mime-Version: 1.0 Content-Type: multipart/alternative; boundary="------------IqhWc4su4G8nc6IS1OUkglq0" Injection-Info: ciao.gmane.io; posting-host="blaine.gmane.org:116.202.254.214"; logging-data="1554"; mail-complaints-to="usenet@ciao.gmane.io" User-Agent: Mozilla Thunderbird To: emacs-devel@gnu.org Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Fri Sep 29 22:58:09 2023 Return-path: Envelope-to: ged-emacs-devel@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 1qmKYq-0000AM-7D for ged-emacs-devel@m.gmane-mx.org; Fri, 29 Sep 2023 22:58:08 +0200 Original-Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1qmKYF-0000AE-Oe; Fri, 29 Sep 2023 16:57:32 -0400 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 1qmKYD-0000A5-Fh for emacs-devel@gnu.org; Fri, 29 Sep 2023 16:57:29 -0400 Original-Received: from relay9-d.mail.gandi.net ([217.70.183.199]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1qmKY9-00074I-Au for emacs-devel@gnu.org; Fri, 29 Sep 2023 16:57:29 -0400 Original-Received: by mail.gandi.net (Postfix) with ESMTPSA id A4357FF809 for ; Fri, 29 Sep 2023 20:57:23 +0000 (UTC) Content-Language: en-US In-Reply-To: <834jjcc27s.fsf@gnu.org> X-GND-Sasl: public@beloved.name Received-SPF: pass client-ip=217.70.183.199; envelope-from=public@beloved.name; helo=relay9-d.mail.gandi.net X-Spam_score_int: -25 X-Spam_score: -2.6 X-Spam_bar: -- X-Spam_report: (-2.6 / 5.0 requ) BAYES_00=-1.9, HTML_MESSAGE=0.001, RCVD_IN_DNSWL_LOW=-0.7, RCVD_IN_MSPIKE_H5=0.001, RCVD_IN_MSPIKE_WL=0.001, SPF_HELO_PASS=-0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane-mx.org@gnu.org Xref: news.gmane.io gmane.emacs.devel:311192 Archived-At: This is a multi-part message in MIME format. --------------IqhWc4su4G8nc6IS1OUkglq0 Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8bit On 9/29/23 19:35, Eli Zaretskii wrote: >> Date: Fri, 29 Sep 2023 19:12:15 +0200 >> From: David Hedlund >> >> I'm not sure I understand the need for these methods. Doesn't F11 do >> this job on all GUI subsystems we support? >> >> And if you are talking about starting with a maximized frame, then why >> aren't "emacs --maximize" and/or X resources (and their Registry >> emulation on MS-Windows) good enough? >> >> IOW, before describing your suggested solutions, and for the FAQ on >> top of that, could you please describe the problem in more details, >> specifically for each GUI environment/toolkit where you see a problem? >> >> Please read the mail in this thread with subject: "Re: Solution to a proposed FAQ, how to maximize >> emacs quickly (like `emacs --maximize`) for GNU/Linux - Improved solution by Chad: ~ >> /.emacs.d/early-init.el" to understand, so I don't need to re-send it. > I always read everything on this list. I read those messages as well. > You don't need to repeat them. But if the suggestions proposed here > didn't solve the problems you had in mind, my question still stands. > -------------------------------------------------------8<------------------------------------------------------------------ From https://www.gnu.org/software/emacs/manual/html_node/efaq/Fullscreen-mode-on-MS_002dWindows.html 5.48 How can I start Emacs in fullscreen mode on MS-Windows? Beginning with Emacs 24.4 either run Emacs with the ‘--maximized’ command-line option or put the following form in your init file (see How do I set up an init file properly? ): (add-hook 'emacs-startup-hook 'toggle-frame-maximized) With older versions use the function |w32-send-sys-command|. For example, you can put the following in your init file: (add-hook 'emacs-startup-hook (lambda () (w32-send-sys-command ?\xF030))) To avoid the slightly distracting visual effect of Emacs starting with its default frame size and then growing to fullscreen, you can add an ‘Emacs.Geometry’ entry to the Windows Registry settings. See X Resources in The GNU Emacs Manual. To compute the correct values for width and height you use in the Registry settings, first maximize the Emacs frame and then evaluate |(frame-height)| and |(frame-width)| with M-:. Alternatively, you can avoid the visual effect of Emacs changing its frame size entirely in your init file (i.e., without using the Registry), like this: (setq frame-resize-pixelwise t) (set-frame-position nil 0 0) (set-frame-size nil (display-pixel-width) (display-pixel-height) t) ------------------------------------------------------->8------------------------------------------------------------------ -------------------------------------------------------8<------------------------------------------------------------------ Proposed new page https://www.gnu.org/software/emacs/manual/html_node/efaq/*Maximized*-mode-on-GNU-Linux.html How can I start Emacs in maximized mode on GNU/Linux? Beginning with Emacs 24.4 either run Emacs with the ‘--maximized’ command-line option or put the following form in your init file (see How do I set up an init file properly? ): (add-hook 'emacs-startup-hook 'toggle-frame-maximized) To avoid the slightly distracting visual effect of Emacs starting with its default frame size and then being *maximized*, you can add an add this to ~/.emacs.d/early-init.el: (push '(fullscreen . maximized) default-frame-alist) ------------------------------------------------------->8------------------------------------------------------------------ --------------IqhWc4su4G8nc6IS1OUkglq0 Content-Type: text/html; charset=UTF-8 Content-Transfer-Encoding: 8bit


On 9/29/23 19:35, Eli Zaretskii wrote:
Date: Fri, 29 Sep 2023 19:12:15 +0200
From: David Hedlund <public@beloved.name>

I'm not sure I understand the need for these methods.  Doesn't F11 do
this job on all GUI subsystems we support?

And if you are talking about starting with a maximized frame, then why
aren't "emacs --maximize" and/or X resources (and their Registry
emulation on MS-Windows) good enough?

IOW, before describing your suggested solutions, and for the FAQ on
top of that, could you please describe the problem in more details,
specifically for each GUI environment/toolkit where you see a problem?

Please read the mail in this thread with subject: "Re: Solution to a proposed FAQ, how to maximize
emacs quickly (like `emacs --maximize`) for GNU/Linux - Improved solution by Chad: ~
/.emacs.d/early-init.el" to understand, so I don't need to re-send it.
I always read everything on this list.  I read those messages as well.
You don't need to repeat them.  But if the suggestions proposed here
didn't solve the problems you had in mind, my question still stands.


-------------------------------------------------------8<------------------------------------------------------------------

From https://www.gnu.org/software/emacs/manual/html_node/efaq/Fullscreen-mode-on-MS_002dWindows.html


5.48 How can I start Emacs in fullscreen mode on MS-Windows?

Beginning with Emacs 24.4 either run Emacs with the ‘--maximized’ command-line option or put the following form in your init file (see How do I set up an init file properly?):

(add-hook 'emacs-startup-hook 'toggle-frame-maximized)

With older versions use the function w32-send-sys-command. For example, you can put the following in your init file:

(add-hook 'emacs-startup-hook
          (lambda () (w32-send-sys-command ?\xF030)))

To avoid the slightly distracting visual effect of Emacs starting with its default frame size and then growing to fullscreen, you can add an ‘Emacs.Geometry’ entry to the Windows Registry settings. See X Resources in The GNU Emacs Manual. To compute the correct values for width and height you use in the Registry settings, first maximize the Emacs frame and then evaluate (frame-height) and (frame-width) with M-:.

Alternatively, you can avoid the visual effect of Emacs changing its frame size entirely in your init file (i.e., without using the Registry), like this:

(setq frame-resize-pixelwise t)
(set-frame-position nil 0 0)
(set-frame-size nil (display-pixel-width) (display-pixel-height) t)


------------------------------------------------------->8------------------------------------------------------------------


-------------------------------------------------------8<------------------------------------------------------------------

Proposed new page https://www.gnu.org/software/emacs/manual/html_node/efaq/Maximized-mode-on-GNU-Linux.html

How can I start Emacs in maximized mode on GNU/Linux?

Beginning with Emacs 24.4 either run Emacs with the ‘--maximized’ command-line option or put the following form in your init file (see How do I set up an init file properly?):

(add-hook 'emacs-startup-hook 'toggle-frame-maximized)


To avoid the slightly distracting visual effect of Emacs starting with its default frame size and then being maximized, you can add an add this to ~/.emacs.d/early-init.el:

(push '(fullscreen . maximized) default-frame-alist)

------------------------------------------------------->8------------------------------------------------------------------


--------------IqhWc4su4G8nc6IS1OUkglq0--