Mercurial > emacs
annotate man/org.texi @ 60475:79a6a2fec394
*** empty log message ***
author | Nick Roberts <nickrob@snap.net.nz> |
---|---|
date | Mon, 07 Mar 2005 01:54:41 +0000 |
parents | fdada1e7ef51 |
children | 003dd96023ff |
rev | line source |
---|---|
58792 | 1 \input texinfo |
2 @c %**start of header | |
59542
fdada1e7ef51
Fixed typo in setfilename
Carsten Dominik <dominik@science.uva.nl>
parents:
59541
diff
changeset
|
3 @setfilename ../info/org |
58792 | 4 @settitle Org Mode Manual |
5 | |
59541 | 6 @set VERSION 3.04 |
58792 | 7 @set DATE December 2004 |
8 | |
9 @dircategory Emacs | |
10 @direntry | |
58848
99bd50b5d3ca
Fix @direntry file name.
Richard M. Stallman <rms@gnu.org>
parents:
58833
diff
changeset
|
11 * Org Mode: (org). Outline-based notes management and organizer |
58792 | 12 @end direntry |
13 | |
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} | |
19 @c %**end of header | |
20 @finalout | |
21 | |
22 @c Macro definitions | |
23 | |
24 @c Subheadings inside a table. Need a difference between info and the rest. | |
25 @macro tsubheading{text} | |
26 @ifinfo | |
27 @subsubheading \text\ | |
28 @end ifinfo | |
29 @ifnotinfo | |
30 @item @b{\text\} | |
31 @end ifnotinfo | |
32 @end macro | |
33 | |
34 @copying | |
35 This manual is for Org-mode (version @value{VERSION}). | |
36 | |
37 Copyright @copyright{} 2004 Free Software Foundation | |
38 | |
39 @quotation | |
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 | |
46 License.'' | |
47 | |
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.'' | |
51 @end quotation | |
52 @end copying | |
53 | |
54 @titlepage | |
55 @title Org Mode Manual | |
56 | |
57 @subtitle Release @value{VERSION} | |
58 @author by Carsten Dominik | |
59 | |
60 @c The following two commands start the copyright page. | |
61 @page | |
62 @vskip 0pt plus 1filll | |
63 @insertcopying | |
64 @end titlepage | |
65 | |
66 @c Output the table of contents at the beginning. | |
67 @contents | |
68 | |
69 @ifnottex | |
70 @node Top, Introduction, (dir), (dir) | |
71 @top Org Mode Manual | |
72 | |
73 @insertcopying | |
74 @end ifnottex | |
75 | |
76 @menu | |
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 | |
88 | |
89 @detailmenu | |
90 --- The Detailed Node Listing --- | |
91 | |
92 Introduction | |
93 | |
94 * Summary:: Brief summary of what Org-mode does | |
95 * Installation:: How to install Org-mode | |
96 | |
97 Document Structure | |
98 | |
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 | |
105 | |
106 TODO items | |
107 | |
108 * TODO basics:: Marking and displaying TODO entries | |
109 * Priorities:: Some things are more important than others | |
110 * TODO extensions:: Workflow and assignments | |
111 | |
112 Extended use of TODO keywords | |
113 | |
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 | |
117 | |
118 Tables | |
119 | |
120 * Built-in table editor:: Simple tables | |
121 * table.el:: Complex tables | |
59541 | 122 * orgtbl-mode:: The table editor as minor mode |
58792 | 123 |
124 Hyperlinks | |
125 | |
126 * Links:: URL-like links to the world | |
127 * Remember:: Org-trees store quick notes | |
128 | |
129 Timestamps | |
130 | |
131 * Time stamps:: Assigning a time to a tree entry | |
132 * Creating timestamps:: Commands which insert timestamps | |
133 | |
134 Timeline and Agenda | |
135 | |
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 | |
140 | |
141 Calendar/Diary integration | |
142 | |
143 * Diary to agenda:: Agenda incorporates the diary | |
144 * Agenda to diary:: Diary incorporates the agenda | |
145 | |
146 Exporting | |
147 | |
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 | |
152 | |
153 Miscellaneous | |
154 | |
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 | |
161 | |
162 @end detailmenu | |
163 @end menu | |
164 | |
165 @node Introduction, Document Structure, Top, Top | |
166 @chapter Introduction | |
167 @cindex introduction | |
168 | |
169 @menu | |
170 * Summary:: Brief summary of what Org-mode does | |
171 * Installation:: How to install Org-mode | |
172 @end menu | |
173 | |
174 @node Summary, Installation, Introduction, Introduction | |
175 @section Summary | |
176 @cindex summary | |
177 | |
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. | |
180 | |
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. | |
192 | |
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 | |
197 | |
198 @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} | |
204 @end example | |
205 | |
59541 | 206 The Org-mode table editor can be used integrated into any major mode |
207 by activating the minor Ortbl-mode. | |
208 | |
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/}. | |
213 | |
214 | |
215 @page | |
216 | |
58792 | 217 @node Installation, , Summary, Introduction |
218 @section Installation | |
219 @cindex installation | |
220 @cindex autoload | |
221 @cindex global keybindings | |
222 @cindex keybindings, global | |
223 | |
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. | |
228 | |
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 | |
232 org}. | |
233 | |
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. | |
237 | |
238 @lisp | |
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) | |
59541 | 243 (autoload 'orgtbl-mode "org" "Org tables as a minor mode" t) |
244 (autoload 'turn-on-orgtbl "org" "Org tables as a minor mode") | |
58792 | 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) | |
248 @end lisp | |
249 | |
250 @cindex org-mode, turning on | |
251 @noindent | |
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: | |
254 | |
255 @example | |
256 MY PROJECTS -*- mode: org; -*- | |
257 @end example | |
258 | |
259 @noindent which will select Org-mode for this buffer no matter what | |
260 the file's name is. | |
261 | |
262 @node Document Structure, TODO items, Introduction, Top | |
263 @chapter Document Structure | |
264 @cindex document structure | |
265 @cindex structure of document | |
266 | |
267 Org-mode is based on outline mode and provides flexible commands to | |
268 edit the structure of the document. | |
269 | |
270 @menu | |
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 | |
277 @end menu | |
278 | |
279 @node Outlines, Headlines, Document Structure, Document Structure | |
280 @section Outlines | |
281 @cindex outlines | |
282 @cindex outline-mode | |
283 | |
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} | |
292 key. | |
293 | |
294 @node Headlines, Visibility cycling, Outlines, Document Structure | |
295 @section Headlines | |
296 @cindex headlines | |
297 @cindex outline tree | |
298 | |
299 Headlines define the structure of an outline tree. The Headlines in | |
300 Org-mode start with one or more stars, for example | |
301 | |
302 @example | |
303 * Top level headline | |
304 ** Second level | |
305 *** 3rd level | |
306 some text | |
307 *** 3rd level | |
308 more text | |
309 * Another top level headline | |
310 @end example | |
311 | |
312 @node Visibility cycling, Motion, Headlines, Document Structure | |
313 @section Visibility cycling | |
314 @cindex visibility cycling | |
315 @cindex trees, visibility | |
316 | |
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. | |
320 | |
321 @cindex subtree visibility states | |
322 @cindex folded, subtree visibility state | |
323 @cindex children, subtree visibility state | |
324 @cindex subtree, subtree visibility state | |
325 @table @kbd | |
326 @kindex @key{TAB} | |
327 @item @key{TAB} | |
328 Rotate current subtree between the states | |
329 @example | |
330 ,-> FOLDED -> CHILDREN -> SUBTREE --. | |
331 '-----------------------------------' | |
332 @end example | |
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. | |
335 | |
336 @cindex global visibility states | |
337 @cindex overview, global visibility state | |
338 @cindex contents, global visibility state | |
339 @cindex show all, global visibility state | |
340 @kindex S-@key{TAB} | |
341 @item S-@key{TAB} | |
342 Rotate the entire buffer between the states | |
343 @example | |
344 ,-> OVERVIEW -> CONTENTS -> SHOW ALL --. | |
345 '--------------------------------------' | |
346 @end example | |
347 Note that inside tables, @kbd{S-@key{TAB}} jumps to the previous field. | |
348 | |
349 @cindex show all, command | |
350 @kindex C-c C-a | |
351 @item C-c C-a | |
352 Show all. | |
353 @end table | |
354 | |
355 @node Motion, Structure editing, Visibility cycling, Document Structure | |
356 @section Motion | |
357 @cindex motion, between headlines | |
358 @cindex jumping, to headlines | |
359 The following commands jump to other headlines in the buffer. | |
360 | |
361 @table @kbd | |
362 @kindex C-c C-n | |
363 @item C-c C-n | |
364 Next heading. | |
365 @kindex C-c C-p | |
366 @item C-c C-p | |
367 Previous heading. | |
368 @kindex C-c C-f | |
369 @item C-c C-f | |
370 Next heading same level. | |
371 @kindex C-c C-b | |
372 @item C-c C-b | |
373 Previous heading same level. | |
374 @kindex C-c C-u | |
375 @item C-c C-u | |
376 Backward to higher level heading. | |
377 @kindex C-c C-j | |
378 @item C-c C-j | |
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 | |
384 visible. | |
385 @end table | |
386 | |
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 | |
397 | |
398 @table @kbd | |
399 @kindex M-@key{RET} | |
400 @item M-@key{RET} | |
401 Insert new heading with same level as current | |
402 @kindex M-@key{left} | |
403 @item M-@key{left} | |
404 Promote current heading by one level | |
405 @kindex M-@key{right} | |
406 @item M-@key{right} | |
407 Demote current heading by one level | |
408 @kindex M-S-@key{left} | |
409 @item 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 | |
414 @kindex M-S-@key{up} | |
415 @item M-S-@key{up} | |
416 Move subtree up (swap with previous subtree of same level) | |
417 @kindex M-S-@key{down} | |
418 @item M-S-@key{down} | |
419 Move subtree down (swap with next subtree of same level) | |
420 @kindex C-c C-h C-w | |
421 @item C-c C-h C-w | |
422 Kill subtree, i.e. remove it from buffer but save in kill ring. | |
423 @kindex C-c C-h M-w | |
424 @item C-c C-h M-w | |
425 Copy subtree to kill ring. | |
426 @kindex C-c C-h C-y | |
427 @item C-c C-h C-y | |
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{****}. | |
432 @end table | |
433 | |
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 | |
443 functionality. | |
444 | |
445 @node Sparse trees, , Structure editing, Document Structure | |
446 @section Sparse trees | |
447 @cindex sparse trees | |
448 @cindex trees, sparse | |
449 @cindex folding, sparse trees | |
450 @cindex occur, command | |
451 | |
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. | |
458 | |
459 Org-mode contains several commands creating such trees. The most | |
460 basic one is @command{org-occur}: | |
461 | |
462 @table @kbd | |
463 @kindex C-c / | |
464 @item C-c / | |
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 | |
470 the match. | |
471 @end table | |
472 | |
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}). | |
475 | |
476 @node TODO items, Tables, Document Structure, Top | |
477 @chapter TODO items | |
478 @cindex TODO items | |
479 | |
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. | |
486 | |
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. | |
490 | |
491 @menu | |
492 * TODO basics:: Marking and displaying TODO entries | |
493 * Priorities:: Some things are more important than others | |
494 * TODO extensions:: Workflow and assignments | |
495 @end menu | |
496 | |
497 @node TODO basics, Priorities, TODO items, TODO items | |
498 @section Basic TODO functionality | |
499 | |
500 Any headline can become a TODO item by starting it with the word TODO, | |
501 for example | |
502 | |
503 @example | |
504 *** TODO Write letter to Sam Fortune | |
505 @end example | |
506 | |
507 @noindent | |
508 The most important commands to work with TODO entries are: | |
509 | |
510 @table @kbd | |
511 @kindex C-c C-t | |
512 @item C-c C-t | |
513 Rotate the TODO state of the current item between | |
514 @example | |
515 ,-> (unmarked) -> TODO -> DONE --. | |
516 '--------------------------------' | |
517 @end example | |
518 @kindex C-c C-v | |
519 @cindex sparse tree, for TODO | |
520 @item C-c C-v | |
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. | |
524 @end table | |
525 | |
526 @node Priorities, TODO extensions, TODO basics, TODO items | |
527 @section Priorities | |
528 @cindex priorities | |
529 | |
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 | |
533 headline, like this | |
534 | |
535 @example | |
536 *** TODO [#A] Write letter to Sam Fortune | |
537 @end example | |
538 | |
539 @noindent | |
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)}). | |
544 | |
545 @table @kbd | |
546 @kindex @kbd{C-c ,} | |
547 @item @kbd{C-c ,} | |
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. | |
551 @kindex S-@key{up} | |
552 @kindex S-@key{down} | |
553 @item S-@key{up} | |
554 @itemx S-@key{down} | |
555 Increase/decrease priority of current item. Note that these keys are | |
556 also used to modify time stamps (@pxref{Creating timestamps}). | |
557 @end table | |
558 | |
559 | |
560 @node TODO extensions, , Priorities, TODO items | |
561 @section Extended use of TODO keywords | |
562 @cindex extended TODO keywords | |
563 | |
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 | |
569 different org files. | |
570 | |
571 @menu | |
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 | |
575 @end menu | |
576 | |
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 | |
581 | |
582 You can use TODO keywords to indicate different states in the process | |
583 of working on an item, for example | |
584 | |
585 @lisp | |
586 (setq org-todo-keywords '("TODO" "FEEDBACK" "VERIFY" "DONE") | |
587 org-todo-interpretation 'sequence) | |
588 @end lisp | |
589 | |
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. | |
596 | |
597 @node TODO types, Per file keywords, Workflow states, TODO extensions | |
598 @subsection TODO keywords as types | |
599 @cindex TODO types | |
600 @cindex names as TODO keywords | |
601 @cindex types as TODO keywords | |
602 | |
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 | |
606 persons. | |
607 | |
608 @lisp | |
609 (setq org-todo-keywords '("Fred" "Sara" "Lucy" "Mike" "DONE") | |
610 org-todo-interpretation 'type) | |
611 @end lisp | |
612 | |
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. | |
620 | |
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 | |
625 | |
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 | |
631 the file: | |
632 | |
633 @example | |
634 #+SEQ_TODO: TODO FEEDBACK VERIFY DONE | |
635 #+TYP_TODO: Fred Sara Lucy Mike DONE | |
636 @end example | |
637 | |
638 @cindex Completing option keywords | |
639 @kindex M-@key{TAB} | |
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. | |
642 | |
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. | |
649 | |
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: | |
652 | |
653 @example | |
654 #+TYP_TODO: Fred Sara Lucy Mike | |
655 #+TYP_TODO: Luis George Jules Jessica | |
656 #+TYP_TODO: Kim Arnold Peter | |
657 #+TYP_TODO: DONE | |
658 @end example | |
659 | |
660 @node Tables, Hyperlinks, TODO items, Top | |
661 @chapter Tables | |
662 @cindex tables | |
663 | |
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. | |
668 | |
669 @menu | |
670 * Built-in table editor:: Simple tables | |
671 * table.el:: Complex tables | |
59541 | 672 * orgtbl-mode:: The table editor as minor mode |
58792 | 673 @end menu |
674 | |
675 @node Built-in table editor, table.el, Tables, Tables | |
676 @section The built-in table editor | |
677 @cindex table editor, builtin | |
678 | |
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 | |
682 like this: | |
683 | |
684 @example | |
685 | Name | Phone | Age | | |
686 |-------+-------+-----| | |
687 | Peter | 1234 | 17 | | |
688 | Anna | 4321 | 25 | | |
689 @end example | |
690 | |
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 | |
698 only type | |
699 | |
700 @example | |
701 |Name|Phone|Age | |
702 |- | |
703 @end example | |
704 | |
705 @noindent and then press @key{TAB} to align the table and start filling in | |
706 fields. | |
707 | |
708 @table @kbd | |
709 @tsubheading{Creation and conversion} | |
710 @kindex C-c C-c | |
711 @item C-c C-c | |
712 Recognize @file{table.el} table. Works when the cursor is in a | |
713 table.el table | |
714 | |
715 @kindex C-c C-c | |
716 @item C-c C-c | |
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). | |
723 | |
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}} | |
727 | |
728 @tsubheading{Re-aligning and field motion} | |
729 @kindex C-c C-c | |
730 @item C-c C-c | |
731 Re-align the table without moving the cursor. | |
732 | |
733 @kindex @key{TAB} | |
734 @item @key{TAB} | |
735 Re-align the table, move to the next field. Creates a new row if | |
736 necessary. | |
737 | |
738 @kindex S-@key{TAB} | |
739 @item S-@key{TAB} | |
740 Move to previous field. | |
741 | |
742 @kindex @key{RET} | |
743 @item @key{RET} | |
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. | |
747 | |
748 @kindex S-@key{RET} | |
749 @item S-@key{RET} | |
750 Copy from first non-empty | |
751 field above current field. | |
752 | |
753 @tsubheading{Column and row editing} | |
754 @kindex M-@key{left} | |
755 @kindex M-@key{right} | |
756 @item M-@key{left} | |
757 @itemx M-@key{right} | |
758 Move the current column left/right | |
759 | |
760 @kindex M-S-@key{left} | |
761 @item M-S-@key{left} | |
762 Kill the current column. | |
763 | |
764 @kindex M-S-@key{right} | |
765 @item M-S-@key{right} | |
766 Insert a new column to the left of the cursor position. | |
767 | |
768 @kindex M-@key{up} | |
769 @kindex M-@key{down} | |
770 @item M-@key{up} | |
771 @itemx M-@key{down} | |
772 Move the current row up/down | |
773 | |
774 @kindex M-S-@key{up} | |
775 @item M-S-@key{up} | |
776 Kill the current row or horizontal line. | |
777 | |
778 @kindex M-S-@key{down} | |
779 @item M-S-@key{down} | |
780 Insert a new row above (with arg: below) the current row. | |
781 | |
782 @kindex C-c - | |
783 @item C-c - | |
784 Insert a horizontal line below current row. With prefix arg, line is | |
785 created above the current line. | |
786 | |
787 @tsubheading{Regions} | |
788 @kindex C-c C-h M-w | |
789 @item C-c C-h M-w | |
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. | |
793 @kindex C-c C-h C-w | |
794 @item C-c C-h C-w | |
795 Copy an rectangular region from a table to a special clipboard, and | |
796 blank all fields in the rectangle. | |
797 @kindex C-c C-h C-y | |
798 @item C-c C-h C-y | |
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 | |
803 lines. | |
804 @kindex C-c C-q | |
805 @item C-c C-q | |
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 | |
814 above. | |
815 | |
816 @tsubheading{Calculations} | |
817 @kindex C-c ? | |
818 @item C-c ? | |
819 Which table column is the cursor in? Displays number >0 in echo | |
820 area. | |
821 | |
822 @cindex region, active | |
823 @cindex active region | |
824 @cindex transient-mark-mode | |
825 @kindex C-c + | |
826 @item C-c + | |
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}. | |
830 | |
831 @cindex formula, in tables | |
832 @cindex calculations, in tables | |
833 @kindex C-c = | |
834 @item C-c = | |
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}. | |
840 | |
841 @tsubheading{Miscellaneous} | |
842 @kindex C-c | | |
843 @item C-c | | |
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. | |
848 | |
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. | |
856 | |
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. | |
860 | |
861 @end table | |
862 | |
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 | |
865 it off with | |
866 @lisp | |
867 (setq org-enable-table-editor nil) | |
868 @end lisp | |
869 @noindent The only table command which then still works is | |
870 @kbd{C-c C-c} to do a manual re-align. | |
871 | |
59541 | 872 @node table.el, orgtbl-mode, Built-in table editor, Tables |
58792 | 873 @section The @file{table.el} package |
874 @kindex C-c C-c | |
875 @cindex table editor, table.el | |
876 @cindex @file{table.el} | |
877 | |
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. | |
885 | |
886 @table @kbd | |
887 @kindex C-c # | |
888 @item C-c # | |
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 | |
893 possible. | |
894 @end table | |
895 | |
59541 | 896 @node orgtbl-mode, , table.el, Tables |
897 @section The Orgtbl minor mode | |
898 @cindex orgtbl-mode | |
899 @cindex Minor mode for tables | |
900 | |
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 | |
906 @lisp | |
907 (add-hook 'mail-mode-hook 'turn-on-orgtbl) | |
908 @end lisp | |
909 | |
58792 | 910 @node Hyperlinks, Timestamps, Tables, Top |
911 @chapter Hyperlinks | |
912 @cindex hyperlinks | |
913 | |
914 Just like HMTL, Org-mode provides links to other files, usenet | |
915 articles, emails and much more. | |
916 | |
917 @menu | |
918 * Links:: URL-like links to the world | |
919 * Remember:: Org-trees store quick notes | |
920 @end menu | |
921 | |
922 @node Links, Remember, Hyperlinks, Hyperlinks | |
923 @section Links | |
924 @cindex links | |
925 @cindex GNUS links | |
926 @cindex BBDB links | |
927 @cindex VM links | |
928 @cindex RMAIL links | |
929 @cindex WANDERLUST links | |
930 @cindex USENET links | |
931 @cindex SHELL links | |
932 | |
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. | |
936 | |
937 @example | |
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} | |
955 @end example | |
956 | |
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}). | |
960 | |
961 @cindex storing links | |
962 @table @kbd | |
963 @kindex C-c l | |
964 @item C-c l | |
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 | |
972 @ref{Installation}. | |
973 | |
974 @kindex C-c C-l | |
975 @item C-c C-l | |
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 | |
983 the buffer. | |
984 | |
985 @cindex inserting links | |
986 @kindex C-c C-o | |
987 @item C-c C-o | |
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. | |
997 | |
998 @strong{IMPORTANT}: Be careful not to use any dangerous commands in a | |
999 shell link. | |
1000 | |
1001 @kindex mouse-2 | |
1002 @item mouse-2 | |
1003 On links, @kbd{mouse-2} will open the link just like @kbd{C-c C-o} would. | |
1004 | |
1005 @kindex mouse-3 | |
1006 @item mouse-3 | |
1007 Like @kbd{mouse-2}, but force file links to be opened with Emacs. | |
1008 @end table | |
1009 | |
1010 @node Remember, , Links, Hyperlinks | |
1011 @section Remember | |
1012 @cindex @file{remember.el} | |
1013 | |
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. | |
1024 | |
1025 | |
1026 @c FIXME: The autoload will not be necessary when Org-mode is part of Emacs | |
1027 @example | |
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)) | |
1034 @end example | |
1035 | |
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. | |
1045 | |
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. | |
1055 @end multitable | |
1056 | |
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. | |
1060 | |
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). | |
1067 | |
1068 @node Timestamps, Timeline and Agenda, Hyperlinks, Top | |
1069 @chapter Timestamps | |
1070 | |
1071 Items can be labeled with timestamps to make them useful for project | |
1072 planning. | |
1073 | |
1074 @menu | |
1075 * Time stamps:: Assigning a time to a tree entry | |
1076 * Creating timestamps:: Commands which insert timestamps | |
1077 @end menu | |
1078 | |
1079 | |
1080 @node Time stamps, Creating timestamps, Timestamps, Timestamps | |
1081 @section Time stamps, deadlines and scheduling | |
1082 @cindex time stamps | |
1083 @cindex deadlines | |
1084 @cindex scheduling | |
1085 | |
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: | |
1091 | |
1092 @table @var | |
1093 @cindex timestamp | |
1094 @item TIMESTAMP | |
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. | |
1098 | |
1099 @item TIMERANGE | |
1100 @cindex timerange | |
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 | |
1104 example: | |
1105 | |
1106 @example | |
1107 ** Meeting in Amsterdam | |
1108 <2004-08-23 Mon>--<2004-08-26 Thu> | |
1109 @end example | |
1110 | |
1111 @item DEADLINE | |
1112 @cindex deadline | |
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 | |
59541 | 1115 it will be listed then. In addition, the compilation for the |
58792 | 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: | |
1119 | |
1120 @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> | |
1124 @end example | |
1125 | |
1126 @item SCHEDULED | |
1127 @cindex scheduled | |
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. | |
1134 @end table | |
1135 | |
1136 @node Creating timestamps, , Time stamps, Timestamps | |
1137 @section Creating timestamps | |
1138 @cindex creating timestamps | |
1139 | |
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 | |
1142 format. | |
1143 | |
1144 @table @kbd | |
1145 @kindex C-c . | |
1146 @item C-c . | |
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. | |
1150 | |
1151 @kindex C-u C-c . | |
1152 @item C-u C-c . | |
1153 Like @kbd{C-c .}, but use the alternative format which contains date | |
1154 and time. | |
1155 | |
1156 @kindex C-c < | |
1157 @item C-c < | |
1158 Insert a time stamp corresponding to the cursor date in the Calendar. | |
1159 | |
1160 @kindex C-c > | |
1161 @item C-c > | |
1162 Access the Emacs calendar for the current date. If there is a | |
1163 timestamp in the current line, goto the corresponding date | |
1164 instead. | |
1165 | |
1166 @kindex C-c C-o | |
1167 @item C-c C-o | |
1168 Access the agenda for the date given by the time stamp at point | |
1169 (@pxref{Agenda (multiple files)}). | |
1170 | |
1171 @kindex C-c C-d | |
1172 @item C-c C-d | |
1173 Insert @samp{DEADLINE} keyword along with a stamp. | |
1174 @kindex C-c C-w | |
1175 @cindex sparse tree, for deadlines | |
1176 @item C-c C-w | |
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. | |
1182 | |
1183 @kindex C-c C-s | |
1184 @item C-c C-s | |
1185 Insert @samp{SCHEDULED} keyword along with a stamp. | |
1186 | |
1187 @kindex S-@key{left} | |
1188 @kindex S-@key{right} | |
1189 @item S-@key{left} | |
1190 @itemx S-@key{right} | |
1191 Change date at cursor by one day. | |
1192 | |
1193 @kindex S-@key{up} | |
1194 @kindex S-@key{down} | |
1195 @item S-@key{up} | |
1196 @itemx 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}). | |
1201 | |
1202 @kindex C-c C-y | |
1203 @cindex evaluate time range | |
1204 @item C-c C-y | |
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). | |
1208 @end table | |
1209 | |
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: | |
1219 | |
1220 @table @kbd | |
1221 @kindex < | |
1222 @item < | |
1223 Scroll calendar backwards by one month. | |
1224 @kindex > | |
1225 @item > | |
1226 Scroll calendar forwards by one month. | |
1227 @kindex mouse-1 | |
1228 @item mouse-1 | |
1229 Select date by clicking on it. | |
1230 @kindex S-@key{right} | |
1231 @item S-@key{right} | |
1232 One day forward. | |
1233 @kindex S-@key{left} | |
1234 @item S-@key{left} | |
1235 One day back. | |
1236 @kindex S-@key{down} | |
1237 @item S-@key{down} | |
1238 One week forward. | |
1239 @kindex S-@key{up} | |
1240 @item S-@key{up} | |
1241 One week back. | |
1242 @kindex M-S-@key{right} | |
1243 @item M-S-@key{right} | |
1244 One month forward. | |
1245 @kindex M-S-@key{left} | |
1246 @item M-S-@key{left} | |
1247 One month back. | |
1248 @kindex @key{RET} | |
1249 @item @key{RET} | |
1250 Choose date in calendar (only if nothing typed into minibuffer). | |
1251 @end table | |
1252 | |
1253 @node Timeline and Agenda, Exporting, Timestamps, Top | |
1254 @chapter Timeline and Agenda | |
1255 @cindex agenda | |
1256 | |
1257 We have already described three commands to filter important | |
1258 information in an org file into a sparse tree (@pxref{Sparse trees}): | |
1259 | |
1260 @cindex sparse trees | |
1261 @itemize @bullet | |
1262 @item | |
1263 The TODO tree, (@kbd{C-c C-v}), see @ref{TODO items}. | |
1264 @item | |
1265 The occur tree @kbd{C-c /}, see @ref{TODO items}. | |
1266 @item | |
1267 Checking upcoming deadlines with @kbd{C-c C-w}, see @ref{Creating | |
1268 timestamps}. | |
1269 @end itemize | |
1270 @noindent | |
1271 | |
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 | |
1277 appointments. | |
1278 | |
1279 @menu | |
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 | |
1284 @end menu | |
1285 | |
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 | |
1292 | |
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. | |
1296 | |
1297 @table @kbd | |
1298 @kindex C-c C-r | |
1299 @item C-c C-r | |
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. | |
1305 @end table | |
1306 @noindent | |
1307 | |
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 | |
1310 commands}. | |
1311 | |
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 | |
1315 | |
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. | |
1319 | |
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 | |
1323 following commands | |
1324 | |
1325 @cindex files, adding to agenda list | |
1326 @table @kbd | |
1327 @kindex C-c [ | |
1328 @item C-c [ | |
1329 Add current file to the list of agenda files | |
1330 @kindex C-c ] | |
1331 @item C-c ] | |
1332 Remove current file from the list of agenda files. | |
1333 @end table | |
1334 @noindent | |
1335 The Org menu contains the list of all files and can be used to quickly | |
1336 visit any of them. | |
1337 | |
1338 The global command @command{org-agenda} compiles the agenda from all | |
1339 listed files. | |
1340 | |
1341 @table @kbd | |
1342 @cindex org-agenda, command | |
1343 @kindex C-c a | |
1344 @item C-c a | |
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 | |
1351 @ref{Installation}. | |
1352 @end table | |
1353 | |
1354 The commands available in the Agenda buffer are listed in | |
1355 @ref{Agenda commands}. | |
1356 | |
1357 @subsection Categories | |
1358 | |
1359 @cindex category | |
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: | |
1364 | |
1365 @cindex file variables | |
1366 @example | |
1367 Planet Finder -*- mode: org; org-category: Cheops -*- | |
1368 @end example | |
1369 @noindent | |
1370 Or, like with TODO keywords (@pxref{Per file keywords}), you can | |
1371 insert a special line anywhere in the file: | |
1372 | |
1373 @example | |
1374 #+CATEGORY: Cheops | |
1375 @end example | |
1376 @noindent | |
1377 The display looks best if the category is no longer than 10 characters. | |
1378 | |
1379 | |
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}). | |
1389 | |
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 | |
1395 files. | |
1396 | |
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. | |
1400 | |
1401 Sorting can be customized using the variable | |
1402 @code{org-agenda-sorting-strategy}. | |
1403 | |
1404 @node Agenda commands, Calendar/Diary integration, Agenda (multiple files), Timeline and Agenda | |
1405 @section Commands in the agenda buffer | |
1406 | |
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. | |
1412 | |
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. | |
1417 | |
1418 @table @kbd | |
1419 @tsubheading{View/GoTo org file} | |
1420 @kindex mouse-3 | |
1421 @kindex @key{SPC} | |
1422 @item mouse-3 | |
1423 @itemx @key{SPC} | |
1424 Display the original location of the item in another window. | |
1425 | |
1426 @kindex l | |
1427 @item l | |
1428 Display original location and recenter that window. | |
1429 | |
1430 @kindex mouse-2 | |
1431 @kindex @key{TAB} | |
1432 @item mouse-2 | |
1433 @itemx @key{TAB} | |
1434 Go to the original location of the item in another window. | |
1435 | |
1436 @kindex @key{RET} | |
1437 @itemx @key{RET} | |
1438 Go to the original location of the item and delete other windows. | |
1439 | |
1440 @kindex f | |
1441 @item f | |
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. | |
1445 | |
1446 | |
1447 @tsubheading{Change display} | |
1448 @kindex o | |
1449 @item o | |
1450 Delete other windows. | |
1451 | |
1452 @kindex w | |
1453 @item w | |
1454 Toggle between weekly and daily view. | |
1455 | |
1456 @kindex d | |
1457 @item d | |
1458 Toggle the inclusion of diary entries. See @ref{Calendar/Diary integration}. | |
1459 | |
1460 @kindex r | |
1461 @item r | |
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 | |
1464 S-@key{right}. | |
1465 | |
1466 @kindex @key{right} | |
1467 @item @key{right} | |
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. | |
1472 | |
1473 @kindex @key{left} | |
1474 @item @key{left} | |
1475 Display the previous dates. Not available in timelines. | |
1476 | |
1477 @kindex . | |
1478 @item . | |
1479 Goto today. | |
1480 | |
1481 @tsubheading{Remote editing} | |
1482 | |
1483 @item 0-9 | |
1484 Digit argument. | |
1485 | |
1486 @kindex t | |
1487 @item t | |
1488 Change the TODO state of the item, both in the agenda and in the | |
1489 original org file. | |
1490 | |
1491 @kindex p | |
1492 @item p | |
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. | |
1496 | |
1497 @kindex P | |
1498 @item p | |
1499 Display weighted priority of current item. | |
1500 | |
1501 @kindex + | |
1502 @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} | |
1505 key for this. | |
1506 | |
1507 @kindex - | |
1508 @item - | |
1509 Decrease the priority of the current item. | |
1510 | |
1511 @kindex S-@key{right} | |
1512 @item 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. | |
1519 | |
1520 @kindex S-@key{left} | |
1521 @item S-@key{left} | |
1522 Change the time stamp associated with the current line by one day | |
1523 into the past. | |
1524 | |
1525 @kindex > | |
1526 @item > | |
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-.} | |
1529 on my keyboard. | |
1530 | |
1531 @cindex diary entries, creating from agenda | |
1532 @kindex i | |
1533 @item i | |
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. | |
1538 | |
1539 @tsubheading{Quit and Exit} | |
1540 @kindex q | |
1541 @item q | |
1542 Quit Agenda, remove the agenda buffer. | |
1543 | |
1544 @kindex x | |
1545 @cindex agenda files, removing buffers | |
1546 @item x | |
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. | |
1550 | |
1551 @end table | |
1552 | |
1553 @node Calendar/Diary integration, , Agenda commands, Timeline and Agenda | |
1554 @section Calendar/Diary integration | |
1555 @cindex calendar integration | |
1556 @cindex diary integration | |
1557 | |
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 | |
1564 the diary. | |
1565 | |
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. | |
1569 | |
1570 @menu | |
1571 * Diary to agenda:: Agenda incorporates the diary | |
1572 * Agenda to diary:: Diary incorporates the agenda | |
1573 @end menu | |
1574 | |
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 | |
1578 | |
1579 In order to include entries from the Emacs diary into Org-mode's | |
1580 agenda, you only need to customize the variable | |
1581 | |
1582 @lisp | |
1583 (setq org-agenda-include-diary t) | |
1584 @end lisp | |
1585 @noindent | |
1586 | |
1587 @noindent After that, everything will happen automatically. | |
1588 | |
1589 @node Agenda to diary, , Diary to agenda, Calendar/Diary integration | |
1590 @subsection Including the agenda into the diary | |
1591 | |
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}: | |
1597 | |
1598 @lisp | |
1599 (add-hook 'diary-display-hook 'fancy-diary-display) | |
1600 @end lisp | |
1601 | |
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}: | |
1605 | |
1606 @example | |
1607 &%%(org-diary) | |
1608 @end example | |
1609 @noindent | |
1610 You may also select specific files with | |
1611 | |
1612 @example | |
1613 &%%(org-diary) ~/path/to/some/org-file.org | |
1614 &%%(org-diary) ~/path/to/another/org-file.org | |
1615 @end example | |
1616 | |
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. | |
1623 | |
1624 @node Exporting, Miscellaneous, Timeline and Agenda, Top | |
1625 @chapter Exporting | |
1626 @cindex exporting | |
1627 @cindex ASCII file | |
1628 @cindex HTML | |
1629 | |
1630 | |
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, | |
1638 | |
1639 @example | |
1640 @kbd{M-1 M-x org-export-as-html} | |
1641 @end example | |
1642 @noindent | |
1643 creates only top level headlines and does the rest as items. | |
1644 | |
1645 @menu | |
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 | |
1650 @end menu | |
1651 | |
1652 @node Export commands, HTML formatting, Exporting, Exporting | |
1653 @section Export commands | |
1654 | |
1655 @cindex region, active | |
1656 @cindex active region | |
1657 @cindex transient-mark-mode | |
1658 @table @kbd | |
1659 @kindex C-c C-x a | |
1660 @item C-c C-x a | |
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 | |
1664 warning. | |
1665 @kindex C-c C-x h | |
1666 @item C-c C-x h | |
1667 Export as HTML file @file{myfile.html}. | |
1668 @kindex C-c C-x C-h | |
1669 @item C-c C-x C-h | |
1670 Export as HTML file and open it with a browser. | |
1671 @kindex C-c C-x t | |
1672 @item C-c C-x t | |
1673 Insert template with export options, see below. | |
1674 @kindex C-c : | |
1675 @item C-c : | |
1676 Toggle fixed-width for line or region, see below. | |
1677 @end table | |
1678 | |
1679 @node HTML formatting, Export options, Export commands, Exporting | |
1680 @section HTML formatting | |
1681 | |
1682 Not all text is transferred literally to the exported HTML file. The | |
1683 exporter implements the following interpretation: | |
1684 | |
1685 @itemize @bullet | |
1686 @cindex underlined text | |
1687 @cindex bold text | |
1688 @cindex italic text | |
1689 @item | |
1690 You can make words @b{*bold*}, @i{/italic/}, and _underlined_ | |
1691 | |
1692 @cindex @TeX{} interpretation | |
1693 @item | |
1694 Simple @TeX{}-like math constructs are interpreted: | |
1695 | |
1696 @itemize @minus | |
1697 @item | |
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{\^} | |
1700 @item | |
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. | |
1704 @end itemize | |
1705 | |
1706 @cindex tables, export to HTML | |
1707 @item | |
1708 Tables are transformed into HTML tables. | |
1709 | |
1710 @cindex fixed width | |
1711 @item | |
1712 Lines starting with @samp{:} are typeset in a fixed-width font, to | |
1713 allow quoting of computer code etc. | |
1714 | |
1715 @cindex HTML tags | |
1716 @item | |
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. | |
1721 @end itemize | |
1722 | |
1723 If these conversions conflict with your habits of typing ASCII text, | |
1724 they can all be turned off with corresponding variables. | |
1725 | |
1726 @node Export options, Comment lines, HTML formatting, Exporting | |
1727 @section Export options | |
1728 @cindex options, for export | |
1729 | |
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}). | |
1736 | |
1737 @example | |
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 | |
1745 @end example | |
1746 @noindent | |
1747 The OPTIONS line is a compact form to specify export settings. Here | |
1748 you can | |
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 | |
1755 @cindex tables | |
1756 @cindex @TeX{}-like syntax for sub- and superscripts | |
1757 @cindex emphasized text | |
1758 @cindex @TeX{} macros | |
1759 @example | |
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} | |
1770 @end example | |
1771 | |
1772 @node Comment lines, , Export options, Exporting | |
1773 @section Comment lines | |
1774 @cindex comment lines | |
1775 @cindex exporting, not | |
1776 | |
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. | |
1781 | |
1782 @table @kbd | |
1783 @kindex C-c ; | |
1784 @item C-c ; | |
1785 Toggle the COMMENT keyword at the beginning of an entry. | |
1786 @end table | |
1787 | |
1788 @node Miscellaneous, Index, Exporting, Top | |
1789 @chapter Miscellaneous | |
1790 | |
1791 @menu | |
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 | |
1798 @end menu | |
1799 | |
1800 @node Completion, Customization, Miscellaneous, Miscellaneous | |
1801 @section Completion | |
1802 @cindex complete @TeX{} symbols | |
1803 @cindex complete TODO keywords | |
1804 @cindex complete dictionary words | |
1805 @cindex complete option keywords | |
1806 | |
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. | |
1810 | |
1811 @table @kbd | |
1812 @kindex M-@key{TAB} | |
1813 @item M-@key{TAB} | |
1814 Complete word at point | |
1815 @itemize @bullet | |
1816 @item | |
1817 At the beginning of a headline, complete TODO keywords. | |
1818 @item | |
1819 After @samp{\}, complete @TeX{} symbols supported by the exporter. | |
1820 @item | |
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. | |
1825 @item | |
1826 Elsewhere, complete dictionary words using ispell. | |
1827 @end itemize | |
1828 @end table | |
1829 | |
1830 @node Customization, Tips and Tricks, Completion, Miscellaneous | |
1831 @section Customization | |
1832 @cindex customization | |
1833 @cindex options, for customization | |
1834 @cindex variables, for customization | |
1835 | |
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. | |
1841 | |
1842 @node Tips and Tricks, Interaction, Customization, Miscellaneous | |
1843 @section Tips and Tricks | |
1844 | |
1845 @itemize @bullet | |
1846 @cindex README files | |
1847 @item | |
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 | |
1851 | |
1852 @example | |
1853 (add-to-list 'auto-mode-alist '("README$" . org-mode)) | |
1854 @end example | |
1855 | |
1856 @ignore | |
1857 @cindex files, adding automatically | |
1858 @item | |
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 | |
1862 | |
1863 @lisp | |
1864 (add-hook 'org-mode-hook 'org-add-file) | |
1865 @end lisp | |
1866 | |
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 | |
1869 following way: | |
1870 | |
1871 @lisp | |
1872 (add-hook 'org-mode-hook | |
1873 (lambda () | |
1874 (or (string-match "README\\'" (buffer-file-name)) | |
1875 (org-add-file)))) | |
1876 @end lisp | |
1877 @end ignore | |
1878 | |
1879 @cindex @code{make-indirect-buffer} | |
1880 @cindex indirect buffers | |
1881 @item | |
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}. | |
1889 | |
1890 @cindex URL, paste into buffer | |
1891 @item | |
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 | |
1896 file:path link. | |
1897 | |
1898 @cindex headline levels, for export | |
1899 @item | |
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 | |
1903 | |
1904 @example | |
1905 * Todays top priorities | |
1906 **** TODO write a letter to xyz | |
1907 **** TODO Finish the paper | |
1908 **** Pick up kids at the school | |
1909 @end example | |
1910 | |
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. | |
1914 | |
1915 @example | |
1916 +OPTIONS: H:2; ... | |
1917 @end example | |
1918 | |
1919 @cindex exporting a subtree | |
1920 @item | |
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. | |
1923 | |
1924 @cindex table, empty template | |
1925 @item | |
1926 To insert an empty table template, just type @samp{|-} and use | |
1927 @key{TAB}. | |
1928 | |
1929 @item | |
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. | |
1933 | |
1934 @item | |
1935 In tables, @key{TAB} creates new rows before horizontal separator lines. If | |
1936 the cursor is at @samp{Age} in the following table, | |
1937 | |
1938 @example | |
1939 | Name | Phone | Age | | |
1940 |-------+-------+-----| | |
1941 | | | | | |
1942 @end example | |
1943 | |
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}. | |
1947 | |
1948 @cindex indentation, of tables | |
1949 @item | |
1950 To change the indentation of a table, just change the first line and | |
1951 realign with @key{TAB}. | |
1952 | |
1953 @end itemize | |
1954 | |
1955 | |
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: | |
1963 | |
1964 @table @asis | |
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 | |
1976 planner. | |
1977 @cindex @file{table.el} | |
1978 @item @file{table.el} by Takaaki Ota | |
1979 Org mode cooperates with table.el, see @ref{table.el}. | |
1980 @end table | |
1981 | |
1982 @c EmacsWiki | |
1983 @c organizer-mode | |
1984 @c todo-mode | |
1985 @c records mode | |
1986 | |
1987 @page @c FIXME | |
1988 | |
1989 @node Acknowledgments, Bugs, Interaction, Miscellaneous | |
1990 @section Acknowledgments | |
1991 @cindex acknowledgments | |
1992 | |
1993 Org-mode was written by Carsten Dominik, who still maintains it at the | |
1994 Org-mode homepage | |
1995 @uref{http://www.astro.uva.nl/~dominik/Tools/org/}. The following | |
1996 people have helped the development along with ideas, suggestions and | |
1997 patches. | |
1998 | |
1999 @itemize @bullet | |
2000 @item | |
2001 Matthias Rempe (Oelde) provided ideas and suggestions, a patch | |
2002 introducing Windows NT/2000 support, and quality control. | |
2003 @item | |
2004 Kevin Rogers contributed code to access VM files on remote hosts. | |
2005 @item | |
2006 Juergen Vollmer contributed code generating the table of contents | |
2007 in HTML output, and other export improvements. | |
2008 @item | |
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. | |
2012 @item | |
2013 Philip Rooke created the Org-mode reference card and did some | |
2014 beta-testing. | |
2015 @item | |
2016 Linking to VM/BBDB/GNUS was inspired by Tom Shannon's | |
2017 @file{organizer-mode.el}. | |
2018 @item | |
2019 Scheduling TODO items was inspired by John Wiegley's @file{planner.el}. | |
2020 @item | |
2021 Sacha Chua, the current maintainer of Planner suggested to take some | |
2022 linking code from Planner, which I did (for RMAIL and Wanderlust). | |
2023 @item | |
2024 Oliver Oppitz sent several useful suggestions. | |
2025 @item | |
2026 Carsten Wimmer suggested some changes and helped fix a bug in linking | |
2027 to GNUS. | |
2028 @end itemize | |
2029 | |
2030 @node Bugs, , Acknowledgments, Miscellaneous | |
2031 @section Bugs | |
2032 @cindex bugs | |
2033 | |
2034 Here is a list of things which should work differently, but which I | |
2035 have found too hard to fix. | |
2036 | |
2037 @itemize @bullet | |
2038 @item | |
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. | |
2042 @item | |
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. | |
2048 @item | |
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. | |
2052 @item | |
2053 When you write @samp{x = a /b/ c}, b will be exported in italics. | |
2054 @item | |
2055 The exporters work well, but could be made more efficient. | |
2056 @end itemize | |
2057 | |
2058 @node Index, Key Index, Miscellaneous, Top | |
2059 @chapter Index | |
2060 | |
2061 @printindex cp | |
2062 | |
2063 @node Key Index, , Index, Top | |
2064 @chapter Key Index | |
2065 | |
2066 @printindex ky | |
2067 | |
2068 @bye | |
2069 | |
2070 | |
58833
d97ebd9e30f6
Changes from arch/CVS synchronization
Miles Bader <miles@gnu.org>
parents:
58792
diff
changeset
|
2071 @ignore |
d97ebd9e30f6
Changes from arch/CVS synchronization
Miles Bader <miles@gnu.org>
parents:
58792
diff
changeset
|
2072 arch-tag: 7893d1fe-cc57-4d13-b5e5-f494a1bcc7ac |
d97ebd9e30f6
Changes from arch/CVS synchronization
Miles Bader <miles@gnu.org>
parents:
58792
diff
changeset
|
2073 @end ignore |