If you haven’t used imenu, do this, load up some source code or an
org-mode file, and:
Return(to select the function)
Slick. The problem is you have to either use the mouse, or do a lot of typing with tab to get to the function or header you want.
Assuming you have use-package installed to both install and configure
packages, put this in your
.emacs file and smoke it:
(use-package idomenu :ensure t :bind ("C-c i" . idomenu))
Now, you have a key binding to search your functions using IDO’s sweet approach to text selection.
If you are mousy or don’t want the visual clutter associated with
increasing your mini-buffer, I suggest using imenu+ and its expansion
on the standard menu support for
(use-package imenu+ :ensure t :init (add-hook 'prog-mode-hook 'imenup-add-defs-to-menubar) (add-hook 'org-mode-hook 'imenup-add-defs-to-menubar))
Finally, if you are a Helm person, this approach creates a list of all functions/headers in a side buffer making it easier to see more options. Good for when you are looking at new source code:
(use-package helm :ensure t :bind (("C-c M-i" . helm-imenu)))
Next time, we should talk about tags…