Emacs: move ido settings to org

This commit is contained in:
Tom Willemsen 2013-03-11 00:40:57 +01:00
parent 07586eb43b
commit 4798970751
3 changed files with 78 additions and 23 deletions

View file

@ -23,7 +23,6 @@
"Face for the supposedly empty line in commit messages."
:group 'local)
(eval-after-load "ido" '(oni:ido-init))
(eval-after-load "jabber" '(oni:jabber-init))
(eval-after-load "newst-treeview" '(require 'newsticker-init))
(eval-after-load "org" '(require 'org-init))
@ -98,12 +97,6 @@
(setq help-at-pt-display-when-idle t)
(setq highlight-80+-columns 72)
(setq identica-enable-striping t)
(setq ido-auto-merge-delay-time 1000000)
(setq ido-default-buffer-method 'selected-window)
(setq ido-max-window-height 1)
(setq ido-save-directory-list-file nil)
(setq ido-ubiquitous-command-exceptions
'(org-refile org-capture-refile))
(setq inferior-lisp-program "sbcl")
(setq inhibit-default-init t)
(setq inhibit-local-menu-bar-menus t)
@ -225,7 +218,6 @@
(global-set-key (kbd "M-2") 'split-window-below)
(global-set-key (kbd "M-3") 'split-window-right)
(global-set-key (kbd "M-4") 'split-window-horizontally)
(global-set-key (kbd "M-n") 'idomenu)
(global-set-key (kbd "M-o") 'other-window)
(global-set-key (kbd "\"") 'oni:self-insert-dwim)
@ -270,8 +262,6 @@
(cua-selection-mode t)
(electric-indent-mode)
(electric-pair-mode)
(ido-mode)
(ido-ubiquitous-mode)
(savehist-mode)
(show-paren-mode)
(winner-mode)

View file

@ -516,3 +516,81 @@
(setq jabber-use-global-history nil
jabber-history-dir "~/.emacs.d/jabber-hist")
#+END_SRC
* ido
Keep some buffers from showing up when using ido-mode. Either these
get used very rarely or they don't have any really useful
information in them.
#+BEGIN_SRC emacs-lisp
(defun oni:ido-init ()
"Initialization functionn for ido."
(setq ido-ignore-buffers
(list "^\\` " "^irc\\." "^\\#" "^\\*Customize Option:"
(eval-when-compile
(regexp-opt
'("*-jabber-roster-*"
"*Messages*"
"*fsm-debug*"
"*magit-process*"
"*magit-edit-log*"
"*Backtrace*"))))))
(eval-after-load "ido" '(oni:ido-init))
#+END_SRC
Ido tries to be smart and find files in other directories, I don't
like that, stop doing that (or at least wait a long time).
#+BEGIN_SRC emacs-lisp
(setq ido-auto-merge-delay-time 1000000)
#+END_SRC
Open files in the selected window when switching between buffers.
#+BEGIN_SRC emacs-lisp
(setq ido-default-buffer-method 'selected-window)
#+END_SRC
Only ever show one line of possibilities when using ido. I hate it
when the minibuffer grows.
#+BEGIN_SRC emacs-lisp
(setq ido-max-window-height 1)
#+END_SRC
Don't save ido state between invocations.
#+BEGIN_SRC emacs-lisp
(setq ido-save-directory-list-file nil)
#+END_SRC
Enable =ido-mode=.
#+BEGIN_SRC emacs-lisp
(ido-mode)
#+END_SRC
** ido-ubiquitous
Don't use ido when calling =org-refile= or =org-capture-refile=.
#+BEGIN_SRC emacs-lisp
(setq ido-ubiquitous-command-exceptions
'(org-refile org-capture-refile))
#+END_SRC
Enable =ido-ubiquitous=.
#+BEGIN_SRC emacs-lisp
(ido-ubiquitous-mode)
#+END_SRC
** idomenu
Call =idomenu= with ~M-n~.
#+BEGIN_SRC emacs-lisp
(global-set-key (kbd "M-n") 'idomenu)
#+END_SRC

View file

@ -129,19 +129,6 @@ DOT are intentionally being skipped."
(fci-mode)
(flycheck-mode))
(defun oni:ido-init ()
"Initialization functionn for ido."
(setq ido-ignore-buffers
(list "^\\` " "^irc\\." "^\\#" "^\\*Customize Option:"
(eval-when-compile
(regexp-opt
'("*-jabber-roster-*"
"*Messages*"
"*fsm-debug*"
"*magit-process*"
"*magit-edit-log*"
"*Backtrace*"))))))
(defun oni:indent-shift-left (start end &optional count)
"Rigidly indent region.
Region is from START to END. Move