diff --git a/README.md b/README.md index 50f78d9..5d2274c 100644 --- a/README.md +++ b/README.md @@ -205,6 +205,7 @@ Keybinding | Description C-h A | Run `apropos` (search in all Emacs symbols). M-/ | Run `hippie-expand` (a replacement for the default `dabbrev-expand`). C-x C-b | Open `ibuffer` (a replacement for the default `buffer-list`). +F11 | Make the window full screen. F12 | Toggle the Emacs menu bar. C-x g | Open Magit's status buffer. C-= | Run `expand-region` (incremental text selection). diff --git a/core/prelude-core.el b/core/prelude-core.el index 1962e20..b14c55f 100644 --- a/core/prelude-core.el +++ b/core/prelude-core.el @@ -514,5 +514,13 @@ With numeric prefix arg DEC, decrement the integer by DEC amount." (interactive "p") (prelude-increment-integer-at-point (- (or dec 1)))) +(defun prelude-fullscreen () + "Makes Emacs window fullscreen. + +This follows freedesktop standards." + (interactive) + (x-send-client-message nil 0 nil "_NET_WM_STATE" 32 + '(2 "_NET_WM_STATE_FULLSCREEN" 0))) + (provide 'prelude-core) ;;; prelude-core.el ends here diff --git a/core/prelude-global-keybindings.el b/core/prelude-global-keybindings.el index 2cbff9b..db959f4 100644 --- a/core/prelude-global-keybindings.el +++ b/core/prelude-global-keybindings.el @@ -96,6 +96,9 @@ ;; replace buffer-menu with ibuffer (global-set-key (kbd "C-x C-b") 'ibuffer) +;; make window fullscreen +(global-set-key (kbd "") 'prelude-fullscreen) + ;; toggle menu-bar visibility (global-set-key (kbd "") 'menu-bar-mode)