unofficial mirror of help-gnu-emacs@gnu.org
 help / color / mirror / Atom feed
* Toggle fullscreen with one key
@ 2005-03-17 23:56 Johan Josefsson
  2005-03-18  0:57 ` Drew Adams
                   ` (3 more replies)
  0 siblings, 4 replies; 5+ messages in thread
From: Johan Josefsson @ 2005-03-17 23:56 UTC (permalink / raw)


I am currently using two keys (f2 and C-f2) and two functions for 
maximizing and restoring the frame in win32:

--- functions

(defun my-frame-maximize () "Maximize Emacs window in win32" 
(interactive) 
(w32-send-sys-command ?\xf030))

(defun my-frame-restore () "Restore Emacs window in win32" 
(interactive) 
(w32-send-sys-command ?\xF120))

--- keys

(global-set-key [f2] 'my-frame-maximize) ; Maximize Emacs window
(global-set-key [C-f2] 'my-frame-restore) ; Restore Emacs window

---

It works as intended, but I wonder, is there any simple way to replace 
these two keys with a function that use only one key (f2) to toggle 
between these two states?

Thanks,
Johan

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

end of thread, other threads:[~2005-03-19  0:30 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2005-03-17 23:56 Toggle fullscreen with one key Johan Josefsson
2005-03-18  0:57 ` Drew Adams
2005-03-18  1:08 ` Pascal Bourguignon
2005-03-18 12:11 ` Mathias Dahl
2005-03-19  0:30 ` rgb

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).