help-gnu-emacs
[Top][All Lists]
Advanced

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

Using easy menu for mode-line lighter


From: uzibalqa
Subject: Using easy menu for mode-line lighter
Date: Mon, 10 Jul 2023 22:27:15 +0000

I want to use easy-menu so that the mode-line lighter for a minor uses the 
following

(defun tika-easy-menu-do ()
  "Set up an easy menu for Tika."

  (easy-menu-define tika-easy-menu tika-kymap "Tika Menu"
    '("Outl"
      ["Hide Body" outline-hide-body t]
      ["Hide-Entry" outline-hide-entry t]
      "---"
      ["Show Entry" outline-show-entry t]
      ["Show All" outline-show-all t])))

;;--------

(defvar tika-kymap

  (let ( (pfmap (make-sparse-keymap)) )

    (keymap-set pfmap "H-b" #'outline-hide-body)
    (keymap-set pfmap "H-m" #'outline-hide-entry)
    (keymap-set pfmap "H-w" #'outline-show-entry)
    (keymap-set pfmap "H-v" #'outline-show-all)

    pfmap))




reply via email to

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