[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: toggle-frame-maximized

From: Jan Djärv
Subject: Re: toggle-frame-maximized
Date: Wed, 12 Dec 2012 07:49:36 +0100


11 dec 2012 kl. 21:38 skrev Sam Steingold <address@hidden>:

> A de-facto standard keybinding is f11: maximize/full screen the window.
> (chrome, gnome-terminal, freeciv - all comply).
> Here is an implementation for emacs:
> --8<---------------cut here---------------start------------->8---
> (defcustom frame-maximization-mode 'maximized
>  "The maximization style of \\[toggle-frame-maximized]."
>  :version "24.4"
>  :type '(choice
>          (const :tab "Respect window manager screen decorations." maximized)
>          (const :tab "Ignore window manager screen decorations." fullscreen))
>  :group 'frames)
> (defun toggle-frame-maximized ()
>  "Maximize/un-maximize Emacs frame according to `frame-maximization-mode'."
>  (interactive)
>  (modify-frame-parameters
>   nil `((fullscreen . ,(if (frame-parameter nil 'fullscreen)
>                            nil frame-maximization-mode)))))
> (define-key global-map [f11] 'toggle-frame-maximized)
> --8<---------------cut here---------------end--------------->8---
> I think this should go into frame.el.
> Objections?

It is a good idea overall.  But I would like to suggest Shift-f11 or Ctrl-f11 
or something to do the complement of frame-maximization-mode.  

I tend to use both, and having both available would be convinient.


        Jan D.

reply via email to

[Prev in Thread] Current Thread [Next in Thread]