unofficial mirror of bug-gnu-emacs@gnu.org 
 help / color / mirror / code / Atom feed
* bug#20110: maximize emacs at startup
@ 2015-03-15 14:53 Mario Valencia
  2015-03-15 19:20 ` martin rudalics
  0 siblings, 1 reply; 2+ messages in thread
From: Mario Valencia @ 2015-03-15 14:53 UTC (permalink / raw)
  To: 20110

[-- Attachment #1: Type: text/plain, Size: 575 bytes --]

The following, taken from the emacs faq, doesn't work:
(add-hook 'emacs-startup-hook
               (lambda () (w32-send-sys-command ?\xF030)))

I ran emacs with only this code in the init file. It appears to maximize
the window then resizes it again.


But the following does work:
(add-hook 'emacs-startup-hook 'toggle-frame-maximized)

This is on windows 8 with version
*GNU Emacs 24.4.1 (i686-pc-mingw32)*
* of 2014-10-24 on LEG570*

I also tried window-setup-hook. Didn't work. Note that the code that uses
w32-send-sys-command works fine if i evaluate it with C-x C-e.

[-- Attachment #2: Type: text/html, Size: 829 bytes --]

^ permalink raw reply	[flat|nested] 2+ messages in thread

* bug#20110: maximize emacs at startup
  2015-03-15 14:53 bug#20110: maximize emacs at startup Mario Valencia
@ 2015-03-15 19:20 ` martin rudalics
  0 siblings, 0 replies; 2+ messages in thread
From: martin rudalics @ 2015-03-15 19:20 UTC (permalink / raw)
  To: Mario Valencia, 20110

 > The following, taken from the emacs faq, doesn't work:
 > (add-hook 'emacs-startup-hook
 >                 (lambda () (w32-send-sys-command ?\xF030)))
 >
 > I ran emacs with only this code in the init file. It appears to maximize
 > the window then resizes it again.
 >
 >
 > But the following does work:
 > (add-hook 'emacs-startup-hook 'toggle-frame-maximized)
 >
 > This is on windows 8 with version
 > *GNU Emacs 24.4.1 (i686-pc-mingw32)*
 > * of 2014-10-24 on LEG570*
 >
 > I also tried window-setup-hook. Didn't work. Note that the code that uses
 > w32-send-sys-command works fine if i evaluate it with C-x C-e.

Thank you very much.  I updated the manual accordingly.  Using the
--maximized command-line option should work as well.  Hence, Emacs
should behave on Windows just like on GNU/Linux.

martin





^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2015-03-15 19:20 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-03-15 14:53 bug#20110: maximize emacs at startup Mario Valencia
2015-03-15 19:20 ` martin rudalics

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).