org-config-examples.org: fix link to David O'Toole GTD configuration
[Worg.git] / org-configs / org-config-examples.org
blobfc01e7d18f09eb79d5a346938ab18bbfec197090
1 #+OPTIONS:    H:3 num:nil toc:t \n:nil @:t ::t |:t ^:t -:t f:t *:t TeX:t LaTeX:t skip:nil d:(HIDE) tags:not-in-toc
2 #+STARTUP:    align fold nodlcheck hidestars oddeven lognotestate
3 #+SEQ_TODO:   TODO(t) INPROGRESS(i) WAITING(w@) | DONE(d) CANCELED(c@)
4 #+TAGS:       Write(w) Update(u) Fix(f) Check(c)
5 #+TITLE:      Org configuration(s)
6 #+AUTHOR:     Worg people
7 #+EMAIL:      bzg AT altern DOT org
8 #+LANGUAGE:   en
9 #+PRIORITIES: A C B
10 #+CATEGORY:   worg
12 # This file is the default header for new Org files in Worg.  Feel free
13 # to tailor it to your needs.
15 * GTD setups
17 - David O'Toole [[http://orgmode.org/worg/code/elisp/dto-org-gtd.el][GTD configuration file]]
19 * General Configuration/Customization
21 ** Some useful keybindings
23 Here is a subset of my personal org-mode key-bindings that others may
24 find useful.
26 # please anyone else should feel free to edit/change/remove parts of
27 # this example
29 #+begin_example
30 (add-hook 'org-mode-hook (lambda ()
31                            (local-set-key "\M-n" 'outline-next-visible-heading)
32                            (local-set-key "\M-p" 'outline-previous-visible-heading)
33                            ;; table
34                            (local-set-key "\M-\C-w" 'org-table-copy-region)
35                            (local-set-key "\M-\C-y" 'org-table-paste-rectangle)
36                            (local-set-key "\M-\C-l" 'org-table-sort-lines)
37                            ;; display images
38                            (local-set-key "\M-I" 'org-toggle-iimage-in-org)
39                            ;; fix tab
40                            (local-set-key "\C-y" 'yank)
41                            ;; yasnippet (allow yasnippet to do it's thing in org files)
42                            (make-variable-buffer-local 'yas/trigger-key)
43                            (setq yas/trigger-key [tab])
44                            (define-key yas/keymap [tab] 'yas/next-field-group)))
45 #+end_example
47 References and Explanations of the above:
48 - see [[* iimage in org (display images in org files)]] for an explanation
49   of the =org-toggle-iimage-in-org= function (inline images in
50   org-mode files).
51 - [[http://code.google.com/p/yasnippet/][yasnippet]] is a tools for snippet expansion in Emacs.  Since Org-Mode
52   is descendant of text-mode, all text snippets will work inside of
53   org files, I also use the following to simplify the creation of
54   example and source code blocks.
56 block
57 #+begin_example
58 #name : #+begin_...#+end_
59 # --
60 #+begin_$1 $2
62 #+end_$1
63 #+end_example
66 ** iimage in org (display images in org files)
67 Thanks to many on the mailing list for this great addition to
68 Org-Mode.  See [[http://www.netlaputa.ne.jp/~kose/Emacs/iimage.html][iimage]] for information on iimage-minor-mode.
70 #+begin_example
71 (add-to-list 'iimage-mode-image-regex-alist
72              (cons (concat "\\[\\[file:\\(~?" iimage-mode-image-filename-regex
73                            "\\)\\]")  1))
75 (defun org-toggle-iimage-in-org ()
76   "display images in your org file"
77   (interactive)
78   (if (face-underline-p 'org-link)
79       (set-face-underline-p 'org-link nil)
80       (set-face-underline-p 'org-link t))
81   (iimage-mode))
82 #+end_example