3 @setfilename ../info/org
4 @settitle Org Mode Manual
7 @set DATE December 2004
11 * Org Mode: (org). Outline-based notes management and organizer
14 @c Version and Contact Info
15 @set MAINTAINERSITE @uref{http://www.astro.uva.nl/~dominik/Tools/org/,maintainers webpage}
16 @set MAINTAINER Carsten Dominik
17 @set MAINTAINEREMAIL @email{dominik@@science.uva.nl}
18 @set MAINTAINERCONTACT @uref{mailto:dominik@@science.uva.nl,contact the maintainer}
24 @c Subheadings inside a table. Need a difference between info and the rest.
25 @macro tsubheading{text}
35 This manual is for Org-mode (version @value{VERSION}).
37 Copyright @copyright{} 2004 Free Software Foundation
40 Permission is granted to copy, distribute and/or modify this document
41 under the terms of the GNU Free Documentation License, Version 1.1 or
42 any later version published by the Free Software Foundation; with no
43 Invariant Sections, with the Front-Cover texts being ``A GNU Manual,''
44 and with the Back-Cover Texts as in (a) below. A copy of the
45 license is included in the section entitled ``GNU Free Documentation
48 (a) The FSF's Back-Cover Text is: ``You have freedom to copy and modify
49 this GNU Manual, like GNU software. Copies published by the Free
50 Software Foundation raise funds for GNU development.''
55 @title Org Mode Manual
57 @subtitle Release @value{VERSION}
58 @author by Carsten Dominik
60 @c The following two commands start the copyright page.
62 @vskip 0pt plus 1filll
66 @c Output the table of contents at the beginning.
70 @node Top, Introduction, (dir), (dir)
77 * Introduction:: Getting started
78 * Document Structure:: A tree works like your brain
79 * TODO items:: Every tree branch can be a TODO item
80 * Tables:: Pure magic for quick formatting
81 * Hyperlinks:: Notes in context
82 * Timestamps:: Assign date and time to items
83 * Timeline and Agenda:: Use time-stamped items to produce an agenda
84 * Exporting:: Sharing and publishing of notes
85 * Miscellaneous:: All the rest which did not fit elsewhere
86 * Index:: The fast road to specific information
87 * Key Index:: Key bindings and where they are described
90 --- The Detailed Node Listing ---
94 * Summary:: Brief summary of what Org-mode does
95 * Installation:: How to install Org-mode
99 * Outlines:: Org-mode is based on outline-mode
100 * Headlines:: How to typeset org-tree headlines
101 * Visibility cycling:: Show ad hide, much simplified
102 * Motion:: Jumping to other headlines
103 * Structure editing:: Changing sequence and level of headlines
104 * Sparse trees:: Matches embedded in context
108 * TODO basics:: Marking and displaying TODO entries
109 * Priorities:: Some things are more important than others
110 * TODO extensions:: Workflow and assignments
112 Extended use of TODO keywords
114 * Workflow states:: From TODO to DONE in steps
115 * TODO types:: I do this, Fred the rest
116 * Per file keywords:: Different files, different requirements
120 * Built-in table editor:: Simple tables
121 * table.el:: Complex tables
122 * orgtbl-mode:: The table editor as minor mode
126 * Links:: URL-like links to the world
127 * Remember:: Org-trees store quick notes
131 * Time stamps:: Assigning a time to a tree entry
132 * Creating timestamps:: Commands which insert timestamps
136 * Timeline (single file):: Time-sorted view for single file
137 * Agenda (multiple files):: Your weekly planner
138 * Agenda commands:: Remote editing of org trees
139 * Calendar/Diary integration:: Integrating Anniversaries and more
141 Calendar/Diary integration
143 * Diary to agenda:: Agenda incorporates the diary
144 * Agenda to diary:: Diary incorporates the agenda
148 * Export commands:: Commands which export and display
149 * HTML formatting:: Interpretation of the buffer content
150 * Export options:: How to influence exports
151 * Comment lines:: Lines which will not be exported
155 * Completion:: M-TAB knows what you need
156 * Customization:: Adapting Org-mode to your taste
157 * Tips and Tricks:: An author-imposed FAQ, sort of
158 * Interaction:: Other Emacs packages
159 * Acknowledgments:: These people provided feedback and more
160 * Bugs:: Things which do not work perfectly
165 @node Introduction, Document Structure, Top, Top
166 @chapter Introduction
170 * Summary:: Brief summary of what Org-mode does
171 * Installation:: How to install Org-mode
174 @node Summary, Installation, Introduction, Introduction
178 Org-mode is a mode for keeping notes, maintaining ToDo lists, and doing
179 project planning with a fast and effective plain-text system.
181 Org-mode develops organizational tasks around NOTES files that contain
182 information about projects as plain text. Org-mode is implemented on
183 top of outline-mode, which makes it possible to keep the content of
184 large files well structured. Visibility cycling and structure editing
185 help to work with the tree. Tables are easily created with a built-in
186 table editor. Org-mode supports ToDo items, deadlines, time stamps,
187 and scheduling. It dynamically compiles entries into an agenda.
188 Plain text URL-like links connect to websites, emails, usenet
189 messages, BBDB entries, and any files related to the projects. For
190 printing and sharing of notes, an Org-mode file can be exported as a
191 structured ASCII file, or as HTML.
193 Org-mode keeps simple things simple. Not every outline branch needs
194 to be an action item, not every action item needs to have priority or
195 scheduling information associated with it. Org-mode can be used on
196 different levels and in different ways, for example
199 @r{@bullet{} as an outline extension with visibility cycling and structure editing}
200 @r{@bullet{} as an ASCII system and table editor to take structured notes}
201 @r{@bullet{} as a simple hypertext system, with HTML export}
202 @r{@bullet{} as a TODO list editor}
203 @r{@bullet{} as a full agenda and planner with deadlines and work scheduling}
206 The Org-mode table editor can be used integrated into any major mode
207 by activating the minor Ortbl-mode.
209 There is a website for Org-mode which provides links to the newest
210 version of Org-mode, as well as additional information, screen shots
211 and example files. This page is located at
212 @uref{http://www.astro.uva.nl/~dominik/Tools/org/}.
217 @node Installation, , Summary, Introduction
218 @section Installation
221 @cindex global keybindings
222 @cindex keybindings, global
224 The instructions below assume that you have downloaded Org-mode from
225 the web. If Org-mode is part of the Emacs distribution or an XEmacs
226 package, you only need to add to @file{.emacs} the last three Lisp
227 lines below - all the rest will be taken care of automatically.
229 Byte-compile @file{org.el} and put it on your load path. If you'd
230 like to use the Info documentation, copy the file @file{org} into the
231 directory containing info files and run the command @code{install-info
234 Then copy the following lines into @file{.emacs}. The last two lines
235 define @emph{global} keys for the commands @command{org-store-link}
236 and @command{org-agenda} - please choose suitable keys yourself.
239 (autoload 'org-mode "org" "Org mode" t)
240 (autoload 'org-diary "org" "Diary entries from Org mode")
241 (autoload 'org-agenda "org" "Multi-file agenda from Org mode" t)
242 (autoload 'org-store-link "org" "Store a link to the current location" t)
243 (autoload 'orgtbl-mode "org" "Org tables as a minor mode" t)
244 (autoload 'turn-on-orgtbl "org" "Org tables as a minor mode")
245 (add-to-list 'auto-mode-alist '("\\.org$" . org-mode))
246 (define-key global-map "\C-cl" 'org-store-link)
247 (define-key global-map "\C-ca" 'org-agenda)
250 @cindex org-mode, turning on
252 This will put all files with extension @samp{.org} into Org-mode. As
253 an alternative, make the first line of a file look like this:
256 MY PROJECTS -*- mode: org; -*-
259 @noindent which will select Org-mode for this buffer no matter what
262 @node Document Structure, TODO items, Introduction, Top
263 @chapter Document Structure
264 @cindex document structure
265 @cindex structure of document
267 Org-mode is based on outline mode and provides flexible commands to
268 edit the structure of the document.
271 * Outlines:: Org-mode is based on outline-mode
272 * Headlines:: How to typeset org-tree headlines
273 * Visibility cycling:: Show ad hide, much simplified
274 * Motion:: Jumping to other headlines
275 * Structure editing:: Changing sequence and level of headlines
276 * Sparse trees:: Matches embedded in context
279 @node Outlines, Headlines, Document Structure, Document Structure
284 Org-mode is implemented on top of outline-mode. Outlines allow to
285 organize a document in a hierarchical structure, which (at least for
286 me) is the best representation of notes and thoughts. Overview over
287 this structure is achieved by folding (hiding) large parts of the
288 document to show only the general document structure and the parts
289 currently being worked on. Org-mode greatly simplifies the use of
290 outlines by compressing the entire show/hide functionality into a
291 single command @command{org-cycle}, which is bound to the @key{TAB}
294 @node Headlines, Visibility cycling, Outlines, Document Structure
299 Headlines define the structure of an outline tree. The Headlines in
300 Org-mode start with one or more stars, for example
309 * Another top level headline
312 @node Visibility cycling, Motion, Headlines, Document Structure
313 @section Visibility cycling
314 @cindex visibility cycling
315 @cindex trees, visibility
317 Outlines make it possible to hide parts of the text in the buffer.
318 Org-mode uses a single command bound to the @key{TAB} key to change
319 the visibility in the buffer.
321 @cindex subtree visibility states
322 @cindex folded, subtree visibility state
323 @cindex children, subtree visibility state
324 @cindex subtree, subtree visibility state
328 Rotate current subtree between the states
330 ,-> FOLDED -> CHILDREN -> SUBTREE --.
331 '-----------------------------------'
333 At the beginning of the buffer (or when called with @kbd{C-u}), this does
334 the same as the command @kbd{S-@key{TAB}} below.
336 @cindex global visibility states
337 @cindex overview, global visibility state
338 @cindex contents, global visibility state
339 @cindex show all, global visibility state
342 Rotate the entire buffer between the states
344 ,-> OVERVIEW -> CONTENTS -> SHOW ALL --.
345 '--------------------------------------'
347 Note that inside tables, @kbd{S-@key{TAB}} jumps to the previous field.
349 @cindex show all, command
355 @node Motion, Structure editing, Visibility cycling, Document Structure
357 @cindex motion, between headlines
358 @cindex jumping, to headlines
359 The following commands jump to other headlines in the buffer.
370 Next heading same level.
373 Previous heading same level.
376 Backward to higher level heading.
379 Jump to a different place without changing the current outline
380 visibility. Shows the document structure in a temporary buffer, where
381 you can use visibility cycling (@key{TAB}) to find your destination.
382 After pressing @key{RET}, the cursor moves to the selected location in
383 the original buffer, and the headings hierarchy above it is made
387 @node Structure editing, Sparse trees, Motion, Document Structure
388 @section Structure editing
389 @cindex structure editing
390 @cindex headline, promotion and demotion
391 @cindex promotion, of subtrees
392 @cindex demotion, of subtrees
393 @cindex subtree, cut and paste
394 @cindex pasting, subtrees
395 @cindex cutting, subtrees
396 @cindex copying, subtrees
401 Insert new heading with same level as current
404 Promote current heading by one level
405 @kindex M-@key{right}
407 Demote current heading by one level
408 @kindex M-S-@key{left}
410 Promote the current subtree by one level
411 @kindex M-S-@key{right}
412 @item M-S-@key{right}
413 Demote the current subtree by one level
416 Move subtree up (swap with previous subtree of same level)
417 @kindex M-S-@key{down}
419 Move subtree down (swap with next subtree of same level)
422 Kill subtree, i.e. remove it from buffer but save in kill ring.
425 Copy subtree to kill ring.
428 Yank subtree from kill ring. This does modify the level of subtree to
429 make sure the tree fits in nicely at the yank position. The yank
430 level can also be specified with a prefix arg, or by yanking after a
431 headline marker like @samp{****}.
434 @cindex region, active
435 @cindex active region
436 @cindex transient-mark-mode
437 When there is an active region (transient-mark-mode), promotion and
438 demotion work on all headlines in the region. To select a region of
439 headlines, it is best to place both point and mark at the beginning of a
440 line, mark at the beginning of the first headline, and point at the line
441 just after the last headline to change. Note that when the cursor is
442 inside a table (@pxref{Tables}), the Meta-Cursor keys have different
445 @node Sparse trees, , Structure editing, Document Structure
446 @section Sparse trees
448 @cindex trees, sparse
449 @cindex folding, sparse trees
450 @cindex occur, command
452 An important feature of Org-mode is the ability to construct
453 @emph{sparse trees} for selected information in an outline tree. A
454 sparse tree means that the entire document is folded as much as
455 possible, but the selected information is made visible along with the
456 headline structure above it. Just try it out and you will see
457 immediately how it works.
459 Org-mode contains several commands creating such trees. The most
460 basic one is @command{org-occur}:
465 Occur. Prompts for a regexp and shows a sparse tree with all matches.
466 If the match is in a headline, the headline is made visible. If the
467 match is in the body of an entry, headline and body are made visible.
468 In order to provide minimal context, also the full hierarchy of
469 headlines above the match is shown, as well as the headline following
473 Other commands are using this feature as well. For example @kbd{C-c
474 C-v} creates a sparse TODO tree (@pxref{TODO basics}).
476 @node TODO items, Tables, Document Structure, Top
480 Org-mode does not maintain TODO lists as a separate document. TODO
481 items are an integral part of the notes file, because TODO items
482 usually come up while taking notes! With Org-mode, you simply mark
483 any entry in a tree as being a TODO item. In this way, the
484 information is not duplicated, and the entire context from which the
485 item emerged is always present when you check.
487 Of course, this technique causes TODO items to be scattered throughout
488 your file. Org-mode provides methods to give you an overview over all
489 things you have to do.
492 * TODO basics:: Marking and displaying TODO entries
493 * Priorities:: Some things are more important than others
494 * TODO extensions:: Workflow and assignments
497 @node TODO basics, Priorities, TODO items, TODO items
498 @section Basic TODO functionality
500 Any headline can become a TODO item by starting it with the word TODO,
504 *** TODO Write letter to Sam Fortune
508 The most important commands to work with TODO entries are:
513 Rotate the TODO state of the current item between
515 ,-> (unmarked) -> TODO -> DONE --.
516 '--------------------------------'
519 @cindex sparse tree, for TODO
521 View TODO items in a @emph{sparse tree} (@pxref{Sparse trees}). Folds
522 the entire buffer, but shows all TODO items and the headings hierarchy
523 above them. With prefix arg, show also the DONE entries.
526 @node Priorities, TODO extensions, TODO basics, TODO items
530 If you use Org-mode extensively to organize your work, you may end up
531 with a number of TODO entries so large that you'd like to prioritize
532 them. You can do this by placing a @emph{priority cookie} into the
536 *** TODO [#A] Write letter to Sam Fortune
540 With its standard setup, Org-mode supports priorities @samp{A},
541 @samp{B}, and @samp{C}. @samp{A} is the highest priority. An entry
542 without a cookie is treated as priority @samp{B}. Priorities make a
543 difference only in the multi-file agenda (@pxref{Agenda (multiple files)}).
548 Set the priority of the current item. The command prompts for a
549 priority character @samp{A}, @samp{B} or @samp{C}. When you press
550 @key{SPC} instead, the priority cookie is removed from the headline.
555 Increase/decrease priority of current item. Note that these keys are
556 also used to modify time stamps (@pxref{Creating timestamps}).
560 @node TODO extensions, , Priorities, TODO items
561 @section Extended use of TODO keywords
562 @cindex extended TODO keywords
564 The default implementation of TODO entries is just two states: TODO
565 and DONE. You can, however, use the TODO feature for more
566 complicated things by configuring the variables
567 @code{org-todo-keywords} and @code{org-todo-interpretation}. Using
568 special setup, you can even use TODO keywords in different ways in
572 * Workflow states:: From TODO to DONE in steps
573 * TODO types:: I do this, Fred the rest
574 * Per file keywords:: Different files, different requirements
577 @node Workflow states, TODO types, TODO extensions, TODO extensions
578 @subsection TODO keywords as workflow states
579 @cindex TODO workflow
580 @cindex workflow states as TODO keywords
582 You can use TODO keywords to indicate different states in the process
583 of working on an item, for example
586 (setq org-todo-keywords '("TODO" "FEEDBACK" "VERIFY" "DONE")
587 org-todo-interpretation 'sequence)
590 With this setup, the command @kbd{C-c C-t} will cycle an entry from
591 TODO to FEEDBACK, then to VERIFY, and finally too DONE. You may also
592 use a prefix argument to quickly select a specific state. For example
593 @kbd{C-3 C-c C-t} will change the state immediately to VERIFY.
594 If you define many keywords, you can use in-buffer completion (see
595 @ref{Completion}) to insert these words into the buffer.
597 @node TODO types, Per file keywords, Workflow states, TODO extensions
598 @subsection TODO keywords as types
600 @cindex names as TODO keywords
601 @cindex types as TODO keywords
603 The second possibility is to use TODO keywords to indicate different
604 types of action items. For example, when you work with several people
605 on a single project, you might want to assign action items to
609 (setq org-todo-keywords '("Fred" "Sara" "Lucy" "Mike" "DONE")
610 org-todo-interpretation 'type)
613 In this case, different keywords do not indicate a sequence, but
614 rather different levels. This changes the behavior of the command
615 @kbd{C-c C-t} slightly. When used several times in succession, it
616 will still cycle through all names. But when when you return to the
617 item after some time and execute @kbd{C-c C-t} again, it will switch
618 from each name directly to DONE. Use prefix arguments or completion
619 to quickly select a specific name.
621 @node Per file keywords, , TODO types, TODO extensions
622 @subsection Setting up TODO keywords for individual files
623 @cindex keyword options
624 @cindex per file keywords
626 It can be very useful to use different aspects of the TODO mechanism
627 in different files. For this you need to add special lines to the
628 file which set the keywords and interpretation for that file only.
629 For example, to set one of the two examples discussed above, you
630 need one of the following lines, starting in column zero anywhere in
634 #+SEQ_TODO: TODO FEEDBACK VERIFY DONE
635 #+TYP_TODO: Fred Sara Lucy Mike DONE
638 @cindex Completing option keywords
640 @noindent To make sure you are using the correct keyword, type
641 @samp{#+} into the buffer and then use @kbd{M-@key{TAB}} completion.
643 @cindex DONE, final TODO keyword
644 Remember that the last keyword must always mean that the
645 item is DONE (you may use a different word, though). After changing
646 these lines, use @kbd{M-x normal-mode} to make the changes known to
647 Org-mode. Also note that in each file, only one of the two aspects
648 of TODO keywords can be used.
650 If you want to use very many keywords, for example when working with a
651 large group of people, you may split the names over several lines:
654 #+TYP_TODO: Fred Sara Lucy Mike
655 #+TYP_TODO: Luis George Jules Jessica
656 #+TYP_TODO: Kim Arnold Peter
660 @node Tables, Hyperlinks, TODO items, Top
664 For taking notes, tables are an essential tool because they allow
665 immediate and clear structuring of data. Org-mode has a very fast and
666 intuitive table editor built-in. More complex tables can be created
667 with the Emacs table.el package.
670 * Built-in table editor:: Simple tables
671 * table.el:: Complex tables
672 * orgtbl-mode:: The table editor as minor mode
675 @node Built-in table editor, table.el, Tables, Tables
676 @section The built-in table editor
677 @cindex table editor, builtin
679 Org-mode makes it easy to format tables in plain ASCII. Any line with
680 @samp{|} as the first non-white character is considered part of a
681 table. @samp{|} is also the column separator. A table might look
685 | Name | Phone | Age |
686 |-------+-------+-----|
687 | Peter | 1234 | 17 |
691 A table is re-aligned automatically each time you press @key{TAB} or
692 @key{RET} inside the table. @key{TAB} also moves to the next field
693 (@key{RET} to the next row) and creates new table rows at the end of the
694 table or before horizontal lines. The indentation of the table is set
695 by the first line. Any line starting with @samp{|-} is considered as a
696 horizontal separator line and will be expanded on the next re-align to
697 span the whole table width. So, to create the above table, you would
705 @noindent and then press @key{TAB} to align the table and start filling in
709 @tsubheading{Creation and conversion}
712 Recognize @file{table.el} table. Works when the cursor is in a
717 Convert region to table. Works when the cursor is not in an existing
718 table, and when there is a region defined. If every line contains at
719 least one TAB character, the function assumes that the material is tab
720 separated. If not, lines are split at whitespace into fields. You
721 can use a prefix argument to indicate how many consecutive spaces are
722 at least required to indicate a field separator (default: just one).
724 @item M-x org-table-create
725 Creates an empty Org-mode table. However, it is much easier to just
726 start typing, like @kbd{|Name|Phone|Age @key{RET} |- @key{TAB}}
728 @tsubheading{Re-aligning and field motion}
731 Re-align the table without moving the cursor.
735 Re-align the table, move to the next field. Creates a new row if
740 Move to previous field.
744 Re-align the table and move down to next row. Creates a new row if
745 necessary. At the beginning or end of a line, @key{RET} still does
746 NEWLINE, so it can be used to split a table.
750 Copy from first non-empty
751 field above current field.
753 @tsubheading{Column and row editing}
755 @kindex M-@key{right}
758 Move the current column left/right
760 @kindex M-S-@key{left}
762 Kill the current column.
764 @kindex M-S-@key{right}
765 @item M-S-@key{right}
766 Insert a new column to the left of the cursor position.
772 Move the current row up/down
776 Kill the current row or horizontal line.
778 @kindex M-S-@key{down}
780 Insert a new row above (with arg: below) the current row.
784 Insert a horizontal line below current row. With prefix arg, line is
785 created above the current line.
787 @tsubheading{Regions}
790 Copy an rectangular region from a table to a special clipboard. Point
791 and mark determine edge fields of the rectangle. The process ignores
792 horizontal separator lines.
795 Copy an rectangular region from a table to a special clipboard, and
796 blank all fields in the rectangle.
799 Paste a rectangluar region into a table.
800 The upper right corner ends up in the current field. All involved fields
801 will be overwritten. If the rectangle does not fit into the present table,
802 the table is enlarged as needed. The process ignores horizontal separator
806 Wrap several fields in a column like a paragraph. If there is an active
807 region, and both point and mark are in the same column, the text in the
808 column is wrapped to minimum width for the given number of lines. A
809 prefix ARG may be used to change the number of desired lines. If there
810 is no region, the current field is split at the cursor position and the
811 text fragment to the right of the cursor is prepended to the field one
812 line down. If there is no region, but you specify a prefix ARG, the
813 current field gets blank, and the content is appended to the field
816 @tsubheading{Calculations}
819 Which table column is the cursor in? Displays number >0 in echo
822 @cindex region, active
823 @cindex active region
824 @cindex transient-mark-mode
827 Sum the numbers in the current column, or in the rectangle defined by
828 the active region. The result is displayed in the echo area and can
829 be inserted with @kbd{C-y}.
831 @cindex formula, in tables
832 @cindex calculations, in tables
835 Replace current field with the result of a formula. Requires the
836 Emacs calc package. The formula can access the current field with
837 @samp{$}, and the other fields in the current row
838 with @samp{$1}, @samp{$2},... For details see the documentation of the
839 command @command{org-table-eval-formula}.
841 @tsubheading{Miscellaneous}
844 Toggle the visibility of vertical lines in tables. The lines are
845 still there, only made invisible with a text property. Any @samp{|}
846 added by hand will become invisible on the next align.
847 Typographically it is good style to have no vertical lines in tables.
849 @item M-x org-table-import
850 Import a file as a table. The table should be TAB- or whitespace
851 separated. Useful for example to import an Excel table or data from a
852 database, because these programs generally can write TAB-separated text
853 files. This command works by inserting the file into the buffer and
854 then converting the region to a table. Any prefix argument is passed on
855 to the converter, which uses it to determine the separator.
857 @item M-x org-table-export
858 Export the table as a TAB-separated file. Useful for data exchange with
859 for example Excel or database programs.
863 If you don't like the automatic table editor because it gets into your
864 way in lines which you would like to start with @samp{|}, you can turn
867 (setq org-enable-table-editor nil)
869 @noindent The only table command which then still works is
870 @kbd{C-c C-c} to do a manual re-align.
872 @node table.el, orgtbl-mode, Built-in table editor, Tables
873 @section The @file{table.el} package
875 @cindex table editor, table.el
876 @cindex @file{table.el}
878 More complex ASCII tables (with automatic line wrapping, column- and
879 row-spanning, and alignment) can be created using the Emacs table
880 package by Takaaki Ota (@uref{http://sourceforge.net/projects/table}).
881 When @key{TAB} or @kbd{C-c C-c} is pressed in such a table, Org-mode
882 will call @command{table-recognize-table} and move the cursor into the
883 table. Inside a table, the keymap of Org-mode is inactive. In order
884 to execute org-related commands, leave the table.
889 Insert a table.el table. If there is already a table at point, this
890 command converts it between the table.el format and the Org-mode
891 format. See the documentation string of the command
892 @code{org-convert-table} for the restrictions under which this is
896 @node orgtbl-mode, , table.el, Tables
897 @section The Orgtbl minor mode
899 @cindex Minor mode for tables
901 If you like the intuitive way the Org-mode table editor works, you
902 might want to use it also in other modes like text-mode or mail-mode.
903 The minor mode Orgtbl-mode make this possible. You can always toggle
904 the mode with @kbd{M-x orgtbl-mode}. To turn it on by default, for
905 example in mail mode, use
907 (add-hook 'mail-mode-hook 'turn-on-orgtbl)
910 @node Hyperlinks, Timestamps, Tables, Top
914 Just like HMTL, Org-mode provides links to other files, usenet
915 articles, emails and much more.
918 * Links:: URL-like links to the world
919 * Remember:: Org-trees store quick notes
922 @node Links, Remember, Hyperlinks, Hyperlinks
929 @cindex WANDERLUST links
933 Org-mode supports links to files, websites, usenet and email messages;
934 and BBDB database entries. Links are just plain-text URL-like locators.
935 The following list shows examples for each link type.
938 http://www.astro.uva.nl/~dominik @r{on the web}
939 file:/home/dominik/images/jupiter.jpg @r{file, absolute path}
940 file:papers/last.pdf @r{file, relative path}
941 file:~/code/main.c:255 @r{file, with line number}
942 news:comp.emacs @r{Usenet link}
943 mailto:adent@@galaxy.net @r{Mail link}
944 vm:folder @r{VM folder link}
945 vm:folder#id @r{VM message link}
946 vm://myself@@some.where.org/folder#id @r{VM on remote machine}
947 wl:folder @r{WANDERLUST folder link}
948 wl:folder#id @r{WANDERLUST message link}
949 rmail:folder @r{RMAIL folder link}
950 rmail:folder#id @r{RMAIL message link}
951 gnus:group @r{GNUS group link}
952 gnus:group#id @r{GNUS article link}
953 bbdb:Richard Stallman @r{BBDB link}
954 shell:ls *.org @r{A shell command}
957 A link may contain space characters and is terminated by the end of
958 the line. Therefore, there can be only one link per line (but see the
959 variable @code{org-allow-space-in-links}).
961 @cindex storing links
965 Store a link to the current location. This is a @emph{global} command
966 which can be used in any buffer to create a link. The link will be
967 stored for later insertion into an Org-mode buffer (see below). For VM,
968 RMAIL, WANDERLUST, GNUS and BBDB buffers, the link will point to the
969 current article/entry. For W3 and W3M buffer, the link goes to the
970 current URL. For any other files, the link will just point to the file.
971 The key binding @kbd{C-c l} is only a suggestion - see
976 Insert a link. This prompts for a link to be inserted into the
977 buffer. You can just type a link, using one of the link type prefixes
978 mentioned in the examples above. Through completion, all links stored
979 during the current session can be accessed. When called with prefix
980 arg, you can use file name completion to enter a file link. Note that
981 you don't have to use this command to insert a link. Links in
982 Org-mode are plain text, and you can type or paste them straight into
985 @cindex inserting links
988 Open link at point. This will launch a web browser for URLs (using
989 @command{browse-url-at-point}), run vm/gnus/bbdb for the corresponding
990 links, execute the command in a shell link, visit text files with
991 Emacs and select a suitable application for non-text files.
992 Classification of files is based on file extension only. See option
993 @code{org-file-apps}. If there is no link at point, the current
994 subtree will be searched for one. If you want to override the default
995 application and visit the file with Emacs, use a @kbd{C-u} prefix.
996 If the cursor is on a time stamp, compiles the agenda for that date.
998 @strong{IMPORTANT}: Be careful not to use any dangerous commands in a
1003 On links, @kbd{mouse-2} will open the link just like @kbd{C-c C-o} would.
1007 Like @kbd{mouse-2}, but force file links to be opened with Emacs.
1010 @node Remember, , Links, Hyperlinks
1012 @cindex @file{remember.el}
1014 Another way to create org entries with links to other files is through
1015 the @emph{Remember} package by John Wiegley. @emph{Remember} lets you
1016 store quick notes with little interruption of your work flow. See
1017 @uref{http://www.emacswiki.org/cgi-bin/wiki/RememberMode} for more
1018 information. The notes produced by @emph{Remember} can be stored in
1019 different ways, and Org-mode files are a good target.
1020 Org-mode allows to file away notes either to a default file, or
1021 directly to the correct location in your Org-mode outline tree. The
1022 following customization will tell @emph{Remember} to use org files as
1023 target, and to create annotations compatible with Org-mode links.
1026 @c FIXME: The autoload will not be necessary when Org-mode is part of Emacs
1028 (autoload 'org-remember-annotation "org")
1029 (autoload 'org-remember-handler "org")
1030 (setq org-directory "~/path/to/my/orgfiles/")
1031 (setq org-default-notes-file "~/.notes")
1032 (setq remember-annotation-functions '(org-remember-annotation))
1033 (setq remember-handler-functions '(org-remember-handler))
1036 When you compose a note with remember, you have to press @kbd{C-c C-c}
1037 to exit remember-mode and to file away the note. The handler first
1038 prompts for a target file - if you press @key{RET}, the value of
1039 @code{org-default-notes-file} is used. Then the command offers the
1040 headings tree of the selected file. You can either immediately press
1041 @key{RET} to get the note appended to the file. Or you can use
1042 vertical cursor motion (@key{up} and @key{down}) and visibility
1043 cycling (@key{TAB}) to find a better place. Pressing @key{RET} or
1044 @key{left} or @key{right} leads to the following result.
1046 @multitable @columnfractions 0.2 0.1 0.7
1047 @item @b{Cursor position} @tab @b{Key} @tab @b{Note gets inserted}
1048 @item buffer-start @tab @key{RET} @tab as level 2 heading at end of file
1049 @item on headline @tab @key{RET} @tab as sublevel of the heading at cursor
1050 @item @tab @key{left} @tab as same level, before current heading
1051 @item @tab @key{right} @tab as same level, after current heading
1052 @item not on headline @tab @key{RET}
1053 @tab at cursor position, level taken from context.
1054 Or use prefix arg to specify level manually.
1057 So the fastest way to store the note is to press @kbd{C-c C-c @key{RET}
1058 @key{RET}} to append it to the default file. But with little extra
1059 effort, you can push it directly to the correct location.
1061 Before inserting the text into a tree, the function ensures that the
1062 text has a headline, i.e. a first line that starts with a @samp{*}.
1063 If not, a headline is constructed from the current date and some
1064 additional data. If the variable @code{org-adapt-indentation} is
1065 non-nil, the entire text is also indented so that it starts in the
1066 same column as the headline (after the asterixes).
1068 @node Timestamps, Timeline and Agenda, Hyperlinks, Top
1071 Items can be labeled with timestamps to make them useful for project
1075 * Time stamps:: Assigning a time to a tree entry
1076 * Creating timestamps:: Commands which insert timestamps
1080 @node Time stamps, Creating timestamps, Timestamps, Timestamps
1081 @section Time stamps, deadlines and scheduling
1086 A time stamp is a specification of a date (possibly with time) in a
1087 special format, either @samp{<2003-09-16 Tue>} or @samp{<2003-09-16
1088 Tue 09:39>}. A time stamp can appear anywhere in the headline or body
1089 of an org-tree entry. Its presence allows to show entries on specific
1090 dates in the agenda (@pxref{Agenda (multiple files)}). We distinguish:
1095 A simple time stamp just assigns a date/time to an item. In the
1096 timeline and agenda displays, the headline of the entry will be shown
1097 exactly on that date.
1101 Two time stamps connected by @samp{--} denote a time range. The
1102 headline will be shown on the first and last day of the range, and on
1103 any dates that are displayed and fall in the range. Here is an
1107 ** Meeting in Amsterdam
1108 <2004-08-23 Mon>--<2004-08-26 Thu>
1113 If a time stamp is preceded by the word @samp{DEADLINE:}, the task
1114 (most likely a TODO item) is supposed to be finished on that date, and
1115 it will be listed then. In addition, the compilation for the
1116 @emph{current day} will carry a warning about the approaching or
1117 missed deadline, starting @code{org-deadline-warning-days} before the
1118 due date, and continuing until the entry is marked DONE. An example:
1121 *** TODO write article about the Earth for the Guide
1122 The editor in charge is bbdb:Ford Prefect
1123 DEADLINE: <2004-02-29 Sun>
1128 If a time stamp is preceded by the word @samp{SCHEDULED:}, it means
1129 you are planning to start working on that task on the given date. The
1130 headline will be listed under the given date. In addition, a reminder
1131 that the scheduled date has passed will be present in the compilation
1132 for the @emph{current day}, until the entry is marked DONE. I.e., the
1133 task will automatically be forwarded.
1136 @node Creating timestamps, , Time stamps, Timestamps
1137 @section Creating timestamps
1138 @cindex creating timestamps
1140 For Org-mode to recognize time stamps, they need to be in the specific
1141 format. All commands listed below produce time stamps in the correct
1147 Prompt for a date and insert a corresponding time stamp. When the
1148 cursor is at a previously used time stamp, it is updated to NOW. When
1149 this command is used twice in succession, a time range is inserted.
1153 Like @kbd{C-c .}, but use the alternative format which contains date
1158 Insert a time stamp corresponding to the cursor date in the Calendar.
1162 Access the Emacs calendar for the current date. If there is a
1163 timestamp in the current line, goto the corresponding date
1168 Access the agenda for the date given by the time stamp at point
1169 (@pxref{Agenda (multiple files)}).
1173 Insert @samp{DEADLINE} keyword along with a stamp.
1175 @cindex sparse tree, for deadlines
1177 Create a sparse tree with all deadlines that are either past-due, or
1178 which will become due within @code{org-deadline-warning-days}.
1179 With @kbd{C-u} prefix, show all deadlines in the file. With a numeric
1180 prefix, check that many days. For example, @kbd{C-1 C-c C-w} shows
1181 all deadlines due tomorrow.
1185 Insert @samp{SCHEDULED} keyword along with a stamp.
1187 @kindex S-@key{left}
1188 @kindex S-@key{right}
1190 @itemx S-@key{right}
1191 Change date at cursor by one day.
1194 @kindex S-@key{down}
1197 Change the item under the cursor in a timestamp. The cursor can be on
1198 a year, month, day, hour or minute. Note that if the cursor is not at
1199 a time stamp, these same keys modify the priority of an item
1200 (@pxref{Priorities}).
1203 @cindex evaluate time range
1205 Evaluate a time range by computing the difference between start and
1206 end. With prefix arg, insert result after the time range (in a table:
1207 into the following column).
1210 @cindex date, reading in minibuffer
1211 @cindex time, reading in minibuffer
1212 @cindex calendar, for selecting date
1213 When org prompts for a date/time, the function reading your input will
1214 replace anything you choose not to specify with the current date and
1215 time. For details, see the documentation string of
1216 @command{org-read-date}. Also, a calender will pop up to allow
1217 selecting a date. The calendar can be fully controlled from the
1218 minibuffer, and a date can be selected with the following commands:
1223 Scroll calendar backwards by one month.
1226 Scroll calendar forwards by one month.
1229 Select date by clicking on it.
1230 @kindex S-@key{right}
1233 @kindex S-@key{left}
1236 @kindex S-@key{down}
1242 @kindex M-S-@key{right}
1243 @item M-S-@key{right}
1245 @kindex M-S-@key{left}
1246 @item M-S-@key{left}
1250 Choose date in calendar (only if nothing typed into minibuffer).
1253 @node Timeline and Agenda, Exporting, Timestamps, Top
1254 @chapter Timeline and Agenda
1257 We have already described three commands to filter important
1258 information in an org file into a sparse tree (@pxref{Sparse trees}):
1260 @cindex sparse trees
1263 The TODO tree, (@kbd{C-c C-v}), see @ref{TODO items}.
1265 The occur tree @kbd{C-c /}, see @ref{TODO items}.
1267 Checking upcoming deadlines with @kbd{C-c C-w}, see @ref{Creating
1272 Instead of using the sparse trees, Org-mode can also collect and
1273 time-sort the important items into a separate buffer, which we call
1274 the @emph{timeline} of the org file. It can also collect information
1275 from a @emph{list of files} and in this way provide an @emph{agenda}
1276 which covers all of your current projects, action items and
1280 * Timeline (single file):: Time-sorted view for single file
1281 * Agenda (multiple files):: Your weekly planner
1282 * Agenda commands:: Remote editing of org trees
1283 * Calendar/Diary integration:: Integrating Anniversaries and more
1286 @node Timeline (single file), Agenda (multiple files), Timeline and Agenda, Timeline and Agenda
1287 @section Timeline for a single file
1288 @cindex single file summary
1289 @cindex agenda, for single file
1290 @cindex timeline, single file
1291 @cindex time-sorted view
1293 The timeline shows all time-stamped items in a single Org-mode file,
1294 in @emph{time-sorted view}. The main purpose of this command is to
1295 give an overview over events in a project.
1300 Show a time-sorted view of the org file, with all time-stamped items
1301 of today or later. When called with a @kbd{C-u} prefix, past dates
1302 will be included as well. When called with two @kbd{C-u C-u}
1303 prefixes, all unfinished TODO entries (scheduled or not) are also
1304 listed under the current date.
1308 The timeline is shown in a temporary buffer @file{*Org Agenda*}. The
1309 commands available in the Agenda buffer are listed in @ref{Agenda
1312 @node Agenda (multiple files), Agenda commands, Timeline (single file), Timeline and Agenda
1313 @section Agenda from multiple files
1314 @cindex agenda, from multiple files
1316 An agenda can be compiled from one or more org files. The main
1317 purpose of this command is to act like a planner, in order to show you
1318 what tasks are up for the current week, similar to a paper agenda.
1320 The Org-mode files to be processed in order to generate the agenda are
1321 listed in the variable @code{org-agenda-files}. You can customize
1322 this variable, but the easiest way to maintain it is through the
1325 @cindex files, adding to agenda list
1329 Add current file to the list of agenda files
1332 Remove current file from the list of agenda files.
1335 The Org menu contains the list of all files and can be used to quickly
1338 The global command @command{org-agenda} compiles the agenda from all
1342 @cindex org-agenda, command
1345 Compile an agenda for the current week from a list of org files. The
1346 agenda shows the entries for each day. With a @kbd{C-u} prefix (or
1347 when the variable @code{org-agenda-include-all-todo} is @code{t}), all
1348 unfinished TODO items (also those without a date) are also listed at
1349 the beginning of the buffer, before the first date.@*
1350 The key binding @kbd{C-c a} is only a suggestion - see
1354 The commands available in the Agenda buffer are listed in
1355 @ref{Agenda commands}.
1357 @subsection Categories
1360 In the agenda buffer, each entry is preceded by a @emph{category},
1361 which is derived from the file name. You can also set the category of
1362 a file through file variables, for example by making the first line of
1363 the file look like this:
1365 @cindex file variables
1367 Planet Finder -*- mode: org; org-category: Cheops -*-
1370 Or, like with TODO keywords (@pxref{Per file keywords}), you can
1371 insert a special line anywhere in the file:
1377 The display looks best if the category is no longer than 10 characters.
1380 @subsection Sorting of agenda items
1381 @cindex sorting, of agenda items
1382 @cindex priorities, of agenda items
1383 The entries for each day are sorted. The default order is to first
1384 collect all items containing an explicit time-of-day specification.
1385 These entries will be shown at the beginning of the list, as a
1386 @emph{schedule} for the day. After that, items remain grouped in
1387 categories, in the sequence given by @code{org-agenda-files}. Within
1388 each category, items are sorted by priority (@pxref{Priorities}).
1390 A time-of-day specification looks like @samp{12:45} or @samp{3pm} and
1391 must appear in the headline. For example, a timestamp in a headline
1392 that contains not only a date but also a time will trigger this
1393 mechanism. Specifications of a time in diary entries are recognized
1394 as well, so the schedule will be mixed from diary entries and Org-mode
1397 The priority is a numerical quantity composed of the base priority
1398 (2000 for priority @samp{A}, 1000 for @samp{B}, and 0 for @samp{C}),
1399 plus additional increments for overdue scheduled or deadline items.
1401 Sorting can be customized using the variable
1402 @code{org-agenda-sorting-strategy}.
1404 @node Agenda commands, Calendar/Diary integration, Agenda (multiple files), Timeline and Agenda
1405 @section Commands in the agenda buffer
1407 Entries in the agenda buffer are linked back to the org file. You are
1408 not allowed to edit the agenda buffer itself, but commands are provided
1409 to edit the org-files ``remotely'' from the agenda buffer. In this
1410 way, all information is stored only once, and you don't risk that your
1411 agenda and note files diverge.
1413 Some commands can be executed with mouse clicks on agenda lines. For
1414 the other commands, the cursor needs to be in the desired line. Most
1415 commands are available for both timelines and the agenda. The
1416 exceptions are marked.
1419 @tsubheading{View/GoTo org file}
1424 Display the original location of the item in another window.
1428 Display original location and recenter that window.
1434 Go to the original location of the item in another window.
1438 Go to the original location of the item and delete other windows.
1442 Toggle follow mode. In follow mode, as you move the cursor through
1443 the agenda buffer, the other window always shows the corresponding
1444 location in the org file.
1447 @tsubheading{Change display}
1450 Delete other windows.
1454 Toggle between weekly and daily view.
1458 Toggle the inclusion of diary entries. See @ref{Calendar/Diary integration}.
1462 Recreate the agenda buffer, for example to reflect the changes
1463 after modification of the time stamps of items with S-@key{left} and
1468 Display the following @code{org-agenda-ndays} days. For example, if
1469 the display covers a week, switch to the following week. With prefix
1470 arg, go forward that many times @code{org-agenda-ndays} days. Not
1471 available in timlines.
1475 Display the previous dates. Not available in timelines.
1481 @tsubheading{Remote editing}
1488 Change the TODO state of the item, both in the agenda and in the
1493 Set the priority for the current item. Org-mode prompts for the
1494 priority character. If you reply with @key{SPC}, the priority cookie
1495 is removed from the entry.
1499 Display weighted priority of current item.
1503 Increase the priority of the current item. The priority is changed in
1504 the original buffer, but the agenda is not resorted. Use the @kbd{r}
1509 Decrease the priority of the current item.
1511 @kindex S-@key{right}
1513 Change the time stamp associated with the current line by one day into
1514 the future. With prefix argument, change it by that many days. For
1515 example, @kbd{3 6 5 S-@key{right}} will change it by a year. The
1516 stamp is changed in the original org file, but the change is not
1517 directly reflected in the agenda buffer. Use the
1518 @kbd{r} key to update the buffer.
1520 @kindex S-@key{left}
1522 Change the time stamp associated with the current line by one day
1527 Change the time stamp associated with the current line to today.
1528 The key @kbd{>} has been chosen, because it is the same as @kbd{S-.}
1531 @cindex diary entries, creating from agenda
1534 Insert a new entry into the diary. Prompts for the type of entry
1535 (day, weekly, monthly, yearly, anniversary, cyclic) and creates a new
1536 entry in the diary, just like @kbd{i d} etc. would do in the calendar.
1537 The date is taken from the cursor position.
1539 @tsubheading{Quit and Exit}
1542 Quit Agenda, remove the agenda buffer.
1545 @cindex agenda files, removing buffers
1547 Exit agenda, remove the agenda buffer and all buffers loaded by Emacs
1548 for the compilation of the agenda. Buffers created by the user to
1549 visit org files will not be removed.
1553 @node Calendar/Diary integration, , Agenda commands, Timeline and Agenda
1554 @section Calendar/Diary integration
1555 @cindex calendar integration
1556 @cindex diary integration
1558 Emacs contains the calendar and diary by Edward M. Reingold. The
1559 calendar displays a three-month calendar with holidays from different
1560 countries and cultures. The diary allows to keep track of
1561 anniversaries, lunar phases, sunrise/set, recurrent appointments
1562 (weekly, monthly) and more. In this way, it is quite complementary to
1563 Org-mode. It can be very useful to combine output from Org-mode with
1566 The interaction between Org-mode and diary works both ways: You can
1567 list entries from the diary in the Org-mode agenda, or you can display
1568 entries from the org agenda in the Emacs diary.
1571 * Diary to agenda:: Agenda incorporates the diary
1572 * Agenda to diary:: Diary incorporates the agenda
1575 @node Diary to agenda, Agenda to diary, Calendar/Diary integration, Calendar/Diary integration
1576 @subsection Including the diary into the agenda
1577 @cindex diary to agenda
1579 In order to include entries from the Emacs diary into Org-mode's
1580 agenda, you only need to customize the variable
1583 (setq org-agenda-include-diary t)
1587 @noindent After that, everything will happen automatically.
1589 @node Agenda to diary, , Diary to agenda, Calendar/Diary integration
1590 @subsection Including the agenda into the diary
1592 If you prefer to use the Emacs diary as your main instrument and if
1593 you wish to include the Org-mode agenda into it, the following steps
1594 are necessary: Autoload the function @command{org-diary} as shown
1595 above under @ref{Installation}. You also need to use @emph{fancy
1596 diary display} by setting in @file{.emacs}:
1599 (add-hook 'diary-display-hook 'fancy-diary-display)
1602 Then include the following line into your @file{~/diary} file, in
1603 order to get the entries from all files listed in the variable
1604 @code{org-agenda-files}:
1610 You may also select specific files with
1613 &%%(org-diary) ~/path/to/some/org-file.org
1614 &%%(org-diary) ~/path/to/another/org-file.org
1617 If you now launch the calendar and press @kbd{d} to display a diary,
1618 the headlines of entries containing a timestamp, date range, schedule,
1619 or deadline referring to the selected date will be listed. Just like
1620 in Org-mode's agenda view, the diary for @emph{today} contains
1621 additional entries for overdue deadlines and scheduled items. See
1622 also the documentation of the @command{org-diary} function.
1624 @node Exporting, Miscellaneous, Timeline and Agenda, Top
1631 @cindex headline levels, for exporting
1632 For printing and sharing of notes, an Org-mode document can be
1633 exported as an ASCII file, or as HTML. In the exported version, the
1634 first 3 outline levels will become headlines, defining a general
1635 document structure. Additional levels will be exported as itemize
1636 lists. If you want that transition to occur at a different level,
1637 specify it with a prefix argument. For example,
1640 @kbd{M-1 M-x org-export-as-html}
1643 creates only top level headlines and does the rest as items.
1646 * Export commands:: Commands which export and display
1647 * HTML formatting:: Interpretation of the buffer content
1648 * Export options:: How to influence exports
1649 * Comment lines:: Lines which will not be exported
1652 @node Export commands, HTML formatting, Exporting, Exporting
1653 @section Export commands
1655 @cindex region, active
1656 @cindex active region
1657 @cindex transient-mark-mode
1661 Export as ASCII file. If there is an active region, only the region
1662 will be exported. For an org file @file{myfile.org}, the ASCII file
1663 will be @file{myfile.txt}. The file will be overwritten without
1667 Export as HTML file @file{myfile.html}.
1670 Export as HTML file and open it with a browser.
1673 Insert template with export options, see below.
1676 Toggle fixed-width for line or region, see below.
1679 @node HTML formatting, Export options, Export commands, Exporting
1680 @section HTML formatting
1682 Not all text is transferred literally to the exported HTML file. The
1683 exporter implements the following interpretation:
1686 @cindex underlined text
1690 You can make words @b{*bold*}, @i{/italic/}, and _underlined_
1692 @cindex @TeX{} interpretation
1694 Simple @TeX{}-like math constructs are interpreted:
1698 @samp{10^22} and @samp{J_n} are super- and subscripts. You can quote
1699 @samp{^} and @samp{_} with a backslash: @samp{\_} and @samp{\^}
1701 @samp{\alpha} indicates a Greek letter, @samp{\to} an arrow. You can
1702 use completion for these macros, just type @samp{\} and maybe a few
1703 letters, and press @kbd{M-@key{TAB}} to see possible completions.
1706 @cindex tables, export to HTML
1708 Tables are transformed into HTML tables.
1712 Lines starting with @samp{:} are typeset in a fixed-width font, to
1713 allow quoting of computer code etc.
1717 If you want to include HTML tags which should be interpreted as such,
1718 mark them with a @samp{@@} like in @samp{@@<b>bold text@@</b>}.
1719 Plain @samp{<} and @samp{>} are always transformed to @samp{<} and
1720 @samp{>} in HTML export.
1723 If these conversions conflict with your habits of typing ASCII text,
1724 they can all be turned off with corresponding variables.
1726 @node Export options, Comment lines, HTML formatting, Exporting
1727 @section Export options
1728 @cindex options, for export
1730 The exporter recognizes special lines in the buffer which provide
1731 additional information. These lines may be put anywhere in the file.
1732 The whole set of lines can be inserted into the buffer with @kbd{C-c
1733 C-x t}. For individual lines, a good way to make sure the keyword is
1734 correct it to type @samp{#+} and then use @kbd{M-@key{TAB}} completion
1735 (@pxref{Completion}).
1738 #+TITLE: the title to be shown (default is the buffer name)
1739 #+AUTHOR: the author (default taken from @code{user-full-name})
1740 #+EMAIL: his/her email address (default from @code{user-mail-address})
1741 #+LANGUAGE: language for HTML, e.g. @samp{en} (@code{org-export-default-language})
1742 #+TEXT: Some descriptive text to be inserted at the beginning.
1743 #+TEXT: Several lines may be given.
1744 #+OPTIONS: H:2 num:t toc:t \n:nil @:t ::t |:t ^:t *:nil TeX:t
1747 The OPTIONS line is a compact form to specify export settings. Here
1749 @cindex headline levels
1750 @cindex section-numbers
1751 @cindex table of contents
1752 @cindex linebreak-preservation
1753 @cindex quoted html tags
1754 @cindex fixed-width sections
1756 @cindex @TeX{}-like syntax for sub- and superscripts
1757 @cindex emphasized text
1758 @cindex @TeX{} macros
1760 H: @r{set the number of headline levels for export}
1761 num: @r{turn on/off section-numbers}
1762 toc: @r{turn on/off table of contents}
1763 \n: @r{turn on/off linebreak-preservation}
1764 @@: @r{turn on/off quoted html tags}
1765 :: @r{turn on/off fixed-width sections}
1766 |: @r{turn on/off tables}
1767 ^: @r{turn on/off @TeX{}-like syntax for sub- and superscripts.}
1768 *: @r{turn on/off emphasized text (bold, italic, underlined)}
1769 TeX: @r{turn on/off @TeX{} macros}
1772 @node Comment lines, , Export options, Exporting
1773 @section Comment lines
1774 @cindex comment lines
1775 @cindex exporting, not
1777 Lines starting with @samp{#} in column zero are treated as comments
1778 and will never be exported. Also entire subtrees starting with the
1779 word @samp{COMMENT} will never be exported. Finally, any text before
1780 the first headline will not be exported either.
1785 Toggle the COMMENT keyword at the beginning of an entry.
1788 @node Miscellaneous, Index, Exporting, Top
1789 @chapter Miscellaneous
1792 * Completion:: M-TAB knows what you need
1793 * Customization:: Adapting Org-mode to your taste
1794 * Tips and Tricks:: An author-imposed FAQ, sort of
1795 * Interaction:: Other Emacs packages
1796 * Acknowledgments:: These people provided feedback and more
1797 * Bugs:: Things which do not work perfectly
1800 @node Completion, Customization, Miscellaneous, Miscellaneous
1802 @cindex complete @TeX{} symbols
1803 @cindex complete TODO keywords
1804 @cindex complete dictionary words
1805 @cindex complete option keywords
1807 Org-mode supports in-buffer completion. This type of completion does
1808 not make use of the minibuffer. You simply type a few letters into
1809 the buffer and use the key to complete text right there.
1814 Complete word at point
1817 At the beginning of a headline, complete TODO keywords.
1819 After @samp{\}, complete @TeX{} symbols supported by the exporter.
1821 After @samp{#+}, complete the special keywords like @samp{TYP_TODO} or
1822 @samp{OPTIONS} which set file-specific options for Org-mode. When the
1823 option keyword is already complete, pressing @kbd{M-@key{TAB}} again
1824 will insert example settings for this keyword.
1826 Elsewhere, complete dictionary words using ispell.
1830 @node Customization, Tips and Tricks, Completion, Miscellaneous
1831 @section Customization
1832 @cindex customization
1833 @cindex options, for customization
1834 @cindex variables, for customization
1836 There is a large number of variables which can be used to customize
1837 Org-mode. For the sake of compactness of the manual, we are not
1838 describing the variables here. For an overview of customization
1839 variables, use @kbd{M-x org-customize}. Or select @code{Browse Org
1840 Group} from the @code{Org->Customization} menu.
1842 @node Tips and Tricks, Interaction, Customization, Miscellaneous
1843 @section Tips and Tricks
1846 @cindex README files
1848 I find Org-mode very useful for the many @file{README} files I have
1849 scattered through my directories. So I turn on @file{org-mode} for
1850 all @file{README} files with
1853 (add-to-list 'auto-mode-alist '("README$" . org-mode))
1857 @cindex files, adding automatically
1859 If you would like to add all org files you ever create to the list of
1860 agenda files@footnote{Think twice. Do you @emph{really} want this?},
1861 you could do so with
1864 (add-hook 'org-mode-hook 'org-add-file)
1867 If you would like to add only a selection, for example everything
1868 except the @file{README} files, this could be achieved in the
1872 (add-hook 'org-mode-hook
1874 (or (string-match "README\\'" (buffer-file-name))
1879 @cindex @code{make-indirect-buffer}
1880 @cindex indirect buffers
1882 It can be useful to have two different windows showing the same
1883 Org-mode file. However, a problem here is that changes to the
1884 visibility in one window immediately affect the other window. On
1885 Emacs (not on XEmacs because it uses the old outline-mode) a way out
1886 is the use of @emph{indirect buffers}, which visit the same file, but
1887 have separate settings, also for outline visibility. See the
1888 documentation on the command @code{make-indirect-buffer}.
1890 @cindex URL, paste into buffer
1892 Paste URLs into Org-mode whenever this seems useful. For example, if
1893 you are writing notes about a paper which is available on the web, put
1894 the corresponding URL there and a direct look at the paper is only a
1895 mouse click away. If you have a local copy of the paper, use a
1898 @cindex headline levels, for export
1900 If you plan to use ASCII or HTML export, make sure things you want to
1901 be exported as item lists are level 4 at least, even if that does mean
1902 there is a level jump. For example
1905 * Todays top priorities
1906 **** TODO write a letter to xyz
1907 **** TODO Finish the paper
1908 **** Pick up kids at the school
1911 Alternatively, if you need a specific value for the heading/item
1912 transition in a particular file, use the @samp{+OPTIONS} line to
1913 configure the @samp{H} switch.
1919 @cindex exporting a subtree
1921 If you want to export a subtree, mark the subtree as region and then
1922 export. Marking can be done with @kbd{C-c @@ C-x C-x}, for example.
1924 @cindex table, empty template
1926 To insert an empty table template, just type @samp{|-} and use
1930 In a table, to add a new column at the end, just type some text
1931 anywhere after the final @samp{|}. Upon the next re-align, a new
1932 column will be created.
1935 In tables, @key{TAB} creates new rows before horizontal separator lines. If
1936 the cursor is at @samp{Age} in the following table,
1939 | Name | Phone | Age |
1940 |-------+-------+-----|
1944 the next @key{TAB} would create a second header line. If you want
1945 instead to go to the first empty field below the horizontal line,
1946 press @key{down} (to get on the separator line) and then @key{TAB}.
1948 @cindex indentation, of tables
1950 To change the indentation of a table, just change the first line and
1951 realign with @key{TAB}.
1956 @node Interaction, Acknowledgments, Tips and Tricks, Miscellaneous
1957 @section Interaction with other packages
1958 @cindex packages, interaction with other
1959 @cindex @file{planner.el}
1960 @cindex @file{remember.el}
1961 @cindex @file{table.el}
1962 @file{Org.el} can cooperate with the following packages:
1965 @cindex @file{remember.el}
1966 @item @file{remember.el} by John Wiegley
1967 Org mode cooperates with remember, see @ref{Remember}.
1968 @cindex @file{plannner.el}
1969 @item @file{planner.el} by John Wiegley
1970 Planner is another tool to plan work and keep track of tasks. Planner
1971 uses a multi-file approach with project pages and day pages. Is based
1972 on Emacs-Wiki. It can be useful to display the agenda entries
1973 resulting from org files in day-pages of the planner. This can be
1974 done through the diary of the calendar: Integrate org files into the
1975 diary as described above, and then turn on the diary support of
1977 @cindex @file{table.el}
1978 @item @file{table.el} by Takaaki Ota
1979 Org mode cooperates with table.el, see @ref{table.el}.
1989 @node Acknowledgments, Bugs, Interaction, Miscellaneous
1990 @section Acknowledgments
1991 @cindex acknowledgments
1993 Org-mode was written by Carsten Dominik, who still maintains it at the
1995 @uref{http://www.astro.uva.nl/~dominik/Tools/org/}. The following
1996 people have helped the development along with ideas, suggestions and
2001 Matthias Rempe (Oelde) provided ideas and suggestions, a patch
2002 introducing Windows NT/2000 support, and quality control.
2004 Kevin Rogers contributed code to access VM files on remote hosts.
2006 Juergen Vollmer contributed code generating the table of contents
2007 in HTML output, and other export improvements.
2009 Christian Egli converted the documentation into TeXInfo format. He
2010 also showed me his plans for a multifile summary for Org-mode. Some of
2011 his ideas have found their way into the agenda.
2013 Philip Rooke created the Org-mode reference card and did some
2016 Linking to VM/BBDB/GNUS was inspired by Tom Shannon's
2017 @file{organizer-mode.el}.
2019 Scheduling TODO items was inspired by John Wiegley's @file{planner.el}.
2021 Sacha Chua, the current maintainer of Planner suggested to take some
2022 linking code from Planner, which I did (for RMAIL and Wanderlust).
2024 Oliver Oppitz sent several useful suggestions.
2026 Carsten Wimmer suggested some changes and helped fix a bug in linking
2030 @node Bugs, , Acknowledgments, Miscellaneous
2034 Here is a list of things which should work differently, but which I
2035 have found too hard to fix.
2039 When the application called by @kbd{C-c C-o} to open a file link fails
2040 (for example because the application does not exits or refuses to open
2041 the file), it does so silently. No error message is displayed.
2043 Under XEmacs, if Org-mode entries are included into the diary, it is
2044 not possible to jump back from the diary to the org file. Apparently,
2045 the text properties are lost when the fancy-diary-display is used.
2046 However, from Org-mode's agenda (created with @kbd{C-c C-r} or
2047 @kbd{M-x org-agenda}), things do work correctly.
2049 Linux should also have a default viewer application, using mailcap.
2050 Maybe we can use GNUS or VM mime code? Or dired's guessing commands?
2051 Any hints (or even patches) are appreciated.
2053 When you write @samp{x = a /b/ c}, b will be exported in italics.
2055 The exporters work well, but could be made more efficient.
2058 @node Index, Key Index, Miscellaneous, Top
2063 @node Key Index, , Index, Top
2072 arch-tag: 7893d1fe-cc57-4d13-b5e5-f494a1bcc7ac