summaryrefslogtreecommitdiff
path: root/.config/emacs/modules/bd--image.el
blob: ca2a11a060513376b20826ae521df36e3ad421e1 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
;;; -*- lexical-binding: t; -*-
;;; Commentary:
;;; Code:


(require 'image-mode)
(defun toggle-mode-line ()
  "If the mode line is displayed, toggle it off.
If the mode line is off, set it to the default value."
  (interactive)
  (setq mode-line-format
        (if mode-line-format
            nil
          (default-value 'mode-line-format))))


;;;; hooks
(add-hook 'image-mode-hook 'toggle-mode-line)


;;;; binds
(keymap-set image-mode-map "l" #'toggle-mode-line)


(provide 'bd--image)
;;; bd-image ends here