Emacs Right Click Context menu
This package is in development.
A customizable context menu, call it from right-click of mouse. You can also use the context menu from keyboard.
Demo
Install
Cask
(depends-on "right-click-context" :git "git@github.com:zonuexe/right-click-context.git")Setup
Easy way (use minor-mode)
(right-click-context-mode 1)
;; If want to use context menu by keyboard
;(define-key right-click-context-mode-map (kbd "C-c :") 'right-click-context-menu)Use keymap
If you do not need the minor-mode, you can add a command to global keymap.
(global-set-key (kbd "<mouse-3>") 'right-click-context-menu)
(bind-key "C-c <mouse-3>" 'right-click-context-menu)
(bind-key "C-c :" 'right-click-context-menu)Hide lighter
You will feel mode line is that it is complicated.
;; Use emoji
(setq right-click-context-mode-lighter "🐭")
;; hidden
(setq right-click-context-mode-lighter "")Customize Menu
DSL
(require 'datetime-format nil t)
(let ((right-click-context-local-menu-tree
(append right-click-context-global-menu-tree
'(("Insert"
("FooBar" :call (insert "FooBar"))
("Current Time" :call (insert (datetime-format 'atom)) :if (fboundp 'datetime-format)))))))
(right-click-context-menu))Region Convert (region-convert.el)
Interactive
- Select text region (mark region)
M-x region-convert(or press binding key)- Input function name (completing read)
Key binding
(global-set-key (kbd "C-c r") 'region-convert)Use from Lisp
(region-convert 5 22 'upcase)
