diff options
| author | Bastien Guerry | 2013-11-12 14:06:26 +0100 |
|---|---|---|
| committer | Bastien Guerry | 2013-11-12 14:06:26 +0100 |
| commit | 271672fad74cdbc9065d23d6e6cee1b8540f571b (patch) | |
| tree | d322b956ec0e74ee33b22354ef00839b23b1618d /doc | |
| parent | f201cf3a8143b0b34b07769fc7d73dd14761b87b (diff) | |
| download | emacs-271672fad74cdbc9065d23d6e6cee1b8540f571b.tar.gz emacs-271672fad74cdbc9065d23d6e6cee1b8540f571b.zip | |
Merge Org version 8.2.3a.
Diffstat (limited to 'doc')
| -rw-r--r-- | doc/misc/ChangeLog | 480 | ||||
| -rw-r--r-- | doc/misc/org.texi | 5495 |
2 files changed, 3814 insertions, 2161 deletions
diff --git a/doc/misc/ChangeLog b/doc/misc/ChangeLog index 1396fc12f43..976922a3978 100644 --- a/doc/misc/ChangeLog +++ b/doc/misc/ChangeLog | |||
| @@ -1,3 +1,483 @@ | |||
| 1 | 2013-11-12 Aaron Ecay <aaronecay@gmail.com> | ||
| 2 | |||
| 3 | * org.texi (Exporting code blocks): Document the 'inline-only | ||
| 4 | setting for `org-export-babel-evaluate'. Document how :var | ||
| 5 | introduces code block dependencies. | ||
| 6 | |||
| 7 | 2013-11-12 Achim Gratz <Stromeko@Stromeko.DE> | ||
| 8 | |||
| 9 | * org.texi (Header arguments): Document header-args[:lang] | ||
| 10 | properties and remove deprecated old-style properties from | ||
| 11 | documentation. | ||
| 12 | |||
| 13 | * org.texi (Agenda commands): Remove footnote from @tsubheading | ||
| 14 | and add a sentence with the reference instead. | ||
| 15 | |||
| 16 | 2013-11-12 Bastien Guerry <bzg@gnu.org> | ||
| 17 | |||
| 18 | * org.texi (Catching invisible edits): | ||
| 19 | * org.texi (Plain lists, Plain lists): | ||
| 20 | * org.texi (Advanced configuration): | ||
| 21 | * org.texi (Tag groups): | ||
| 22 | * org.texi (Conventions): | ||
| 23 | * org.texi (Checkboxes, Radio lists): | ||
| 24 | * org.texi (Top, Summary, Exporting): | ||
| 25 | * org.texi (In-buffer settings): Fix typos. | ||
| 26 | |||
| 27 | * org.texi (Refile and copy): Document `org-copy' and `C-3 C-c | ||
| 28 | C-w'. Add an index entry for `org-refile-keep'. | ||
| 29 | |||
| 30 | * org.texi (Plain lists): Add an index entry for sorting plain | ||
| 31 | list. Document sorting by checked status for check lists. | ||
| 32 | |||
| 33 | * org.texi (Publishing options): Fix old variable names. | ||
| 34 | |||
| 35 | * org.texi (Orgstruct mode): Fix suggested setting of | ||
| 36 | `orgstruct-heading-prefix-regexp'. | ||
| 37 | |||
| 38 | * org.texi (Export settings): Document | ||
| 39 | `org-export-allow-bind-keywords'. | ||
| 40 | |||
| 41 | * org.texi (History and Acknowledgments): Small rephrasing. | ||
| 42 | |||
| 43 | * org.texi (Template elements): Add a footnote about tags accepted | ||
| 44 | in a year datetree. | ||
| 45 | |||
| 46 | * org.texi (Beamer export, @LaTeX{} and PDF export) | ||
| 47 | (Header and sectioning, @LaTeX{} specific attributes): Enhance | ||
| 48 | style. | ||
| 49 | |||
| 50 | * org.texi (Agenda commands): Add a footnote about dragging agenda | ||
| 51 | lines: it does not persist and it does not change the .org files. | ||
| 52 | |||
| 53 | * org.texi (Agenda commands): Add a table heading for dragging | ||
| 54 | agenda lines forward/backward. | ||
| 55 | |||
| 56 | * org.texi (Agenda commands): Add documentation for | ||
| 57 | `org-agenda-bulk-toggle' and `org-agenda-bulk-toggle-all'. | ||
| 58 | |||
| 59 | * org.texi (Publishing options): Update the list of options. | ||
| 60 | (Simple example, Complex example): Fix the examples. | ||
| 61 | |||
| 62 | * org.texi (Formula syntax for Calc): Don't use a bold font the | ||
| 63 | warning. | ||
| 64 | |||
| 65 | * org.texi (Other built-in back-ends): New section. | ||
| 66 | |||
| 67 | * org.texi (Editing source code): Document | ||
| 68 | `org-edit-src-auto-save-idle-delay' and | ||
| 69 | `org-edit-src-turn-on-auto-save'. | ||
| 70 | |||
| 71 | * org.texi (External links): Document contributed link types | ||
| 72 | separately. | ||
| 73 | |||
| 74 | * org.texi (Closing items): Document | ||
| 75 | `org-closed-keep-when-no-todo'. | ||
| 76 | |||
| 77 | * org.texi (Export back-ends): Rename from "Export formats". | ||
| 78 | (The Export Dispatcher): Remove reference to | ||
| 79 | `org-export-run-in-background'. | ||
| 80 | (Export settings): Minor rewrites. | ||
| 81 | (ASCII/Latin-1/UTF-8 export): Update variable's name. | ||
| 82 | (In-buffer settings): Add #+HTML_HEAD_EXTRA. | ||
| 83 | |||
| 84 | * org.texi (Export in foreign buffers): New section. | ||
| 85 | (Exporting): Remove documentation about converting the selected | ||
| 86 | region. | ||
| 87 | |||
| 88 | * org.texi (Advanced configuration): Put the filter valid types in | ||
| 89 | a table. Use @lisp and @smalllisp. | ||
| 90 | |||
| 91 | * org.texi: Use @code{nil} instead of nil. Update the maintainer | ||
| 92 | contact info. | ||
| 93 | |||
| 94 | * org.texi (Exporting): Better introductory sentence. Add a note | ||
| 95 | about conversion commands. | ||
| 96 | (Feedback, Orgstruct mode, Built-in table editor) | ||
| 97 | (Built-in table editor, Orgtbl mode, Updating the table) | ||
| 98 | (Property syntax, Capturing column view, Capture) | ||
| 99 | (Agenda files, Agenda commands, CDLaTeX mode, CDLaTeX mode) | ||
| 100 | (Exporting, Extending ODT export) | ||
| 101 | (Working with @LaTeX{} math snippets, dir, Customization) | ||
| 102 | (Radio tables, A @LaTeX{} example, Pulling from MobileOrg): | ||
| 103 | Uniformly use @kbd{M-x command RET}. | ||
| 104 | |||
| 105 | * org.texi (Filtering/limiting agenda items): New subsection. | ||
| 106 | Document the use of `org-agenda-max-*' options and | ||
| 107 | `org-agenda-limit-interactively' from the agenda. | ||
| 108 | (Agenda commands): Move details about filtering commands to | ||
| 109 | the new section, only include a summary here. | ||
| 110 | (Customizing tables in ODT export) | ||
| 111 | (System-wide header arguments, Conflicts, Dynamic blocks): Use | ||
| 112 | spaces for indentation. | ||
| 113 | |||
| 114 | * org.texi (Emphasis and monospace): Mention `org-emphasis-alist'. | ||
| 115 | |||
| 116 | * org.texi (Links in HTML export, Images in HTML export) | ||
| 117 | (post): Fix syntax within #+ATTR_*. | ||
| 118 | (Tables in HTML export): Document `org-html-table-row-tags' | ||
| 119 | and use `org-html-table-default-attributes' instead of | ||
| 120 | `org-html-table-tag'. | ||
| 121 | |||
| 122 | * org.texi (Publishing action, Publishing options) | ||
| 123 | (Publishing links): Major rewrite. Enhance explanations for | ||
| 124 | `org-org-publish-to-org'. Remove reference to | ||
| 125 | `org-export-run-in-background'. | ||
| 126 | |||
| 127 | * org.texi: Fix many small typos. Use #+NAME instead of | ||
| 128 | #+TBLNAME. Use @smalllisp instead of @example. | ||
| 129 | (Special symbols): Add index? | ||
| 130 | (HTML preamble and postamble): Don't mention obsolete use of | ||
| 131 | opt-plist. | ||
| 132 | (JavaScript support): Don't mention the org-jsinfo.el file as it | ||
| 133 | has been merged with ox-html.el. | ||
| 134 | |||
| 135 | * org.texi (Installation, Feedback, Setting Options) | ||
| 136 | (Code evaluation security, org-crypt.el): Use @lisp instead of | ||
| 137 | @example. | ||
| 138 | (Agenda commands): Use @table instead of @example. | ||
| 139 | |||
| 140 | * org.texi (Adding hyperlink types): New appendix. | ||
| 141 | |||
| 142 | * org.texi (ODT export commands, Extending ODT export) | ||
| 143 | (Applying custom styles, Images in ODT export) | ||
| 144 | (Labels and captions in ODT export) | ||
| 145 | (Literal examples in ODT export) | ||
| 146 | (Configuring a document converter) | ||
| 147 | (Working with OpenDocument style files) | ||
| 148 | (Customizing tables in ODT export) | ||
| 149 | (Validating OpenDocument XML): Fix options names. | ||
| 150 | |||
| 151 | * org.texi (History and Acknowledgments): Update acknowledgments | ||
| 152 | to Nicolas. Add Nicolas Goaziou to the list of contributors. | ||
| 153 | |||
| 154 | * org.texi (System-wide header arguments): Don't use "customizing" | ||
| 155 | for setting a variable. Also remove comments. | ||
| 156 | |||
| 157 | * org.texi (Weekly/daily agenda): Add `org-agenda-start-day' and | ||
| 158 | `org-agenda-start-on-weekday' to the variable index and document | ||
| 159 | them. | ||
| 160 | |||
| 161 | * org.texi (Sparse trees, Agenda commands) | ||
| 162 | (@LaTeX{} fragments, Selective export, Export options) | ||
| 163 | (The export dispatcher, ASCII/Latin-1/UTF-8 export) | ||
| 164 | (HTML Export commands, @LaTeX{}/PDF export commands) | ||
| 165 | (iCalendar export, Publishing options, Triggering publication) | ||
| 166 | (In-buffer settings): Update to reflect changes from the new | ||
| 167 | export engine. | ||
| 168 | |||
| 169 | * org.texi (Matching tags and properties): More examples. Explain | ||
| 170 | group tags expansion as regular expressions. | ||
| 171 | |||
| 172 | * org.texi (Tag groups): New section. | ||
| 173 | |||
| 174 | * org.texi (Setting tags): Tiny formatting fixes. | ||
| 175 | |||
| 176 | * org.texi (Plain lists, Checkboxes): Use non-obsolete variable | ||
| 177 | names. | ||
| 178 | |||
| 179 | * org.texi (Storing searches): Add "agenda" and "agenda*" to the | ||
| 180 | concept index. Include example for these agenda views. | ||
| 181 | (Special agenda views): Mention the "agenda*" agenda view. | ||
| 182 | |||
| 183 | * org.texi (Repeated tasks): Document how to ignore a repeater | ||
| 184 | when using both a scheduled and a deadline timetamp. | ||
| 185 | |||
| 186 | * org.texi (Global and local cycling): Wrap in a new subsection. | ||
| 187 | (Initial visibility, Catching invisible edits): New subsections. | ||
| 188 | |||
| 189 | * org.texi (Visibility cycling): Mention that | ||
| 190 | `org-agenda-inhibit-startup' will prevent visibility setting when | ||
| 191 | the agenda opens an Org file for the first time. | ||
| 192 | |||
| 193 | * org.texi (Org syntax): New section. | ||
| 194 | |||
| 195 | * org.texi (Orgstruct mode): Document | ||
| 196 | `orgstruct-heading-prefix-regexp'. | ||
| 197 | |||
| 198 | * org.texi (Speeding up your agendas): New section. | ||
| 199 | |||
| 200 | * org.texi (Installation): When installing Org from ELPA, users | ||
| 201 | should do this from an Emacs session where no .org file has been | ||
| 202 | visited. | ||
| 203 | |||
| 204 | * org.texi (CSS support, In-buffer settings): Update HTML options | ||
| 205 | names. | ||
| 206 | |||
| 207 | * org.texi (Structure editing): Update documentation for | ||
| 208 | `org-insert-heading-or-item'. | ||
| 209 | (Plain lists, Relative timer): Update index entry. | ||
| 210 | |||
| 211 | * org.texi (JavaScript support): Update variable names. | ||
| 212 | |||
| 213 | * org.texi (comments): Minor formatting fix. | ||
| 214 | |||
| 215 | * org.texi (@LaTeX{} fragments): Minor enhancement. | ||
| 216 | |||
| 217 | * org.texi: Update the list contributions. | ||
| 218 | |||
| 219 | * org.texi (Agenda commands): Exporting the agenda to an .org file | ||
| 220 | will not copy the subtrees and the inherited tags. Document | ||
| 221 | `org-agenda-filter-by-regexp'. | ||
| 222 | |||
| 223 | * org.texi (Publishing action, Complex example): Fix names of | ||
| 224 | publishing functions. | ||
| 225 | |||
| 226 | * org.texi (Top, Exporting): Delete references to Freemind. | ||
| 227 | (Freemind export): Delete section. | ||
| 228 | |||
| 229 | * org.texi (Top, Exporting): Delete references to the XOXO export. | ||
| 230 | (XOXO export): Delete section. | ||
| 231 | |||
| 232 | * org.texi (Capture): Mention that org-remember.el is not | ||
| 233 | supported anymore. | ||
| 234 | |||
| 235 | * org.texi (Top, Exporting, Beamer class export): Delete | ||
| 236 | references to the TaskJuggler export. | ||
| 237 | (History and Acknowledgments): Mention that the TaskJuggler has | ||
| 238 | been rewritten by Nicolas and now lives in the contrib/ directory | ||
| 239 | of Org's distribution. Mention that Jambunathan rewrote the HTML | ||
| 240 | exporter. Remove Jambunathan from my own acknowledgments. | ||
| 241 | (TaskJuggler export): Delete. | ||
| 242 | |||
| 243 | * org.texi (HTML preamble and postamble) | ||
| 244 | (Tables in HTML export, Images in HTML export) | ||
| 245 | (Math formatting in HTML export, CSS support) | ||
| 246 | (@LaTeX{} and PDF export, Publishing options): Fix the names of | ||
| 247 | the HTML export and publishing options. | ||
| 248 | |||
| 249 | * org.texi (Literal examples, Export options) | ||
| 250 | (@LaTeX{} and PDF export, Header and sectioning) | ||
| 251 | (Publishing options): Fix LaTeX options names. | ||
| 252 | |||
| 253 | * org.texi (Export options, CSS support, In-buffer settings): Fix | ||
| 254 | references to HTML_LINK_* and HTML_STYLE keywords. | ||
| 255 | |||
| 256 | * org.texi (Export options, In-buffer settings): Fix references to | ||
| 257 | #+SELECT_TAGS and #+EXCLUDE_TAGS and remove reference to #+XSLT. | ||
| 258 | |||
| 259 | * org.texi (Top, Markup, Initial text, Images and tables) | ||
| 260 | (@LaTeX{} fragments, @LaTeX{} fragments, Exporting) | ||
| 261 | (Export options, JavaScript support, Beamer class export): Remove | ||
| 262 | references to the DocBook export, which has been deleted. | ||
| 263 | (History and Acknowledgments): Mention that DocBook has been | ||
| 264 | deleted, suggest to use the Texinfo exporter instead, then to | ||
| 265 | convert the .texi to DocBook with makeinfo. | ||
| 266 | (Links in ODT export, Tables in ODT export): Fix indices. | ||
| 267 | |||
| 268 | * org.texi (Deadlines and scheduling): Add a variable to the | ||
| 269 | index. Add documentation about delays for scheduled tasks. | ||
| 270 | |||
| 271 | * org.texi (Emphasis and monospace): Mention | ||
| 272 | `org-fontify-emphasized-text' and | ||
| 273 | `org-emphasis-regexp-components'. | ||
| 274 | |||
| 275 | * org.texi (References): Small enhancement. | ||
| 276 | |||
| 277 | * org.texi (Column width and alignment): Make the example visually | ||
| 278 | more clear. | ||
| 279 | |||
| 280 | * org.texi (The clock table): Document :mstart and :wstart as a | ||
| 281 | way to set the starting day of the week. | ||
| 282 | |||
| 283 | * org.texi (In-buffer settings): Document new startup keywords. | ||
| 284 | Thanks to John J Foerch for this idea. | ||
| 285 | |||
| 286 | * org.texi (Include files): Tiny formatting fix. | ||
| 287 | |||
| 288 | * org.texi (Activation): Point to the "Conflicts" section. | ||
| 289 | |||
| 290 | 2013-11-12 Carsten Dominik <carsten.dominik@gmail.com> | ||
| 291 | |||
| 292 | * org.texi (CSS support): Clarify this section. | ||
| 293 | |||
| 294 | * org.texi (@LaTeX{} specific attributes): Document that tabu and | ||
| 295 | tabularx packages are not in the default set of packages. | ||
| 296 | |||
| 297 | * org.texi (Agenda commands): Document fortnight view. | ||
| 298 | |||
| 299 | * org.texi: Document conflict with ecomplete.el. | ||
| 300 | |||
| 301 | * org.texi (History and Acknowledgments): Acknowledgements for | ||
| 302 | Jason Dunsmore and Rakcspace. | ||
| 303 | |||
| 304 | * org.texi: Rename org-crypt.el node to org-crypt. | ||
| 305 | |||
| 306 | * org.texi (A @LaTeX{} example): Fix typo in variable name. | ||
| 307 | |||
| 308 | * org.texi (MobileOrg): Mention the new iPhone developer. | ||
| 309 | |||
| 310 | * org.texi (Table of contents) Improve documentation of TOC | ||
| 311 | placement. | ||
| 312 | |||
| 313 | * org.texi: Explain that date/time information at read-date prompt | ||
| 314 | should start at the beginning, not anywhere in the middle of a | ||
| 315 | long string. | ||
| 316 | |||
| 317 | 2013-11-12 Christopher Schmidt <christopher@ch.ristopher.com> | ||
| 318 | |||
| 319 | * org.texi (Orgstruct mode): Fix wrong regexp. | ||
| 320 | |||
| 321 | 2013-11-12 Eric Abrahamsen <eric@ericabrahamsen.net> | ||
| 322 | |||
| 323 | * org.texi: Document export to (X)HTML flavors. | ||
| 324 | |||
| 325 | 2013-11-12 Eric Schulte <schulte.eric@gmail.com> | ||
| 326 | |||
| 327 | * org.texi (Extracting source code): Mention the prefix argument | ||
| 328 | to org-babel-tangle. | ||
| 329 | (noweb): Removed erroneous negative. | ||
| 330 | (Specific header arguments): Document new header arguments. | ||
| 331 | Documentation for new tangle-mode header argument. | ||
| 332 | (Top): Documentation for new tangle-mode header argument. | ||
| 333 | (rownames): Documentation for new tangle-mode header argument. | ||
| 334 | Mention elisp as special rowname case. | ||
| 335 | (tangle-mode): Documentation for new tangle-mode header argument. | ||
| 336 | (post): Documentation and an example of usage. | ||
| 337 | (var): Remove the "Alternate argument syntax" section from the | ||
| 338 | documentation. | ||
| 339 | (hlines): Note that :hline has no effect for Emacs Lisp code | ||
| 340 | blocks. | ||
| 341 | |||
| 342 | 2013-11-12 Feng Shu <tumashu@gmail.com> | ||
| 343 | |||
| 344 | * org.texi (@LaTeX{} fragments, Previewing @LaTeX{} fragments) | ||
| 345 | (Math formatting in HTML export) | ||
| 346 | (Working with @LaTeX{} math snippets): Add document about creating | ||
| 347 | formula image with imagemagick. | ||
| 348 | |||
| 349 | * org.texi (@LaTeX{} specific attributes): Document `:caption' | ||
| 350 | attribute of #+ATTR_LATEX. | ||
| 351 | |||
| 352 | 2013-11-12 Grégoire Jadi <gregoire.jadi@gmail.com> | ||
| 353 | |||
| 354 | * org.texi (Handling links): Fix a typo in | ||
| 355 | `org-startup-with-inline-images' documentation. | ||
| 356 | |||
| 357 | * org.texi (Previewing @LaTeX{} fragments): Document the startup | ||
| 358 | keywords to use for previewing LaTeX fragments or not. | ||
| 359 | (Summary of in-buffer settings): Improve formatting and add an | ||
| 360 | entry for the variable `org-startup-with-latex-preview'. | ||
| 361 | |||
| 362 | * org.texi (Property syntax): Recall the user to refresh the org | ||
| 363 | buffer when properties are set on a per-file basis. | ||
| 364 | |||
| 365 | 2013-11-12 Gustav Wikström <gustav.erik@gmail.com> (tiny change) | ||
| 366 | |||
| 367 | * org.texi (Matching tags and properties): Clarification. | ||
| 368 | |||
| 369 | 2013-11-12 Ippei Furuhashi <top.tuna+orgmode@gmail.com> | ||
| 370 | |||
| 371 | * org.texi (Editing and debugging formulas): Add an example when a | ||
| 372 | table has multiple #+TBLFM lines. | ||
| 373 | |||
| 374 | 2013-11-12 Ivan Vilata i Balaguer <ivan@selidor.net> (tiny change) | ||
| 375 | |||
| 376 | * org.texi (The clock table): Document acceptance of relative | ||
| 377 | times in tstart and tend, link to syntax description and provide | ||
| 378 | example. | ||
| 379 | |||
| 380 | 2013-11-12 Jarmo Hurri <jarmo.hurri@syk.fi> | ||
| 381 | |||
| 382 | * org.texi (The spreadsheet): Document lookup functions. | ||
| 383 | |||
| 384 | 2013-11-12 Kodi Arfer <git@arfer.net> (tiny change) | ||
| 385 | |||
| 386 | * org.text (CSS support): Mention .figure-number, .listing-number, | ||
| 387 | and .table-number. | ||
| 388 | |||
| 389 | 2013-11-12 Michael Brand <michael.ch.brand@gmail.com> | ||
| 390 | |||
| 391 | * org.texi | ||
| 392 | (Formula syntax for Calc, Emacs Lisp forms as formulas): Reformat | ||
| 393 | spreadsheet formula mode strings and some examples from @example | ||
| 394 | block with xy @r{yz} to @table. | ||
| 395 | |||
| 396 | * org.texi (Formula syntax for Calc): Improve the documentation of | ||
| 397 | empty fields in formulas for spreadsheet. Add explanation and | ||
| 398 | example for empty field. Extend explanations of format | ||
| 399 | specifiers. Add a sentence to mention Calc defmath. | ||
| 400 | |||
| 401 | * org.texi (Column formulas): Add a sentence to be more explicit | ||
| 402 | about when a table header is mandatory. | ||
| 403 | |||
| 404 | 2013-11-12 Nicolas Goaziou <n.goaziou@gmail.com> | ||
| 405 | |||
| 406 | * org.texi (Subscripts and superscripts): Remove reference to | ||
| 407 | quoted underscores until this mechanism is implemented again. | ||
| 408 | |||
| 409 | * org.texi (Beamer export): Be more accurate about BEAMER_OPT | ||
| 410 | property. | ||
| 411 | |||
| 412 | * org.texi (Document title): Subtree export is no longer triggered | ||
| 413 | by marking one as the region. | ||
| 414 | (Horizontal rules): LaTeX export doesn't use "\hrule" anymore, and | ||
| 415 | giving examples isn't very useful: "horizontal rule" is, at least, | ||
| 416 | as explicit as <hr/>. | ||
| 417 | |||
| 418 | * org.texi (HTML doctypes): Reflect keyword removal. | ||
| 419 | (CSS support): Reflect keyword removal. | ||
| 420 | |||
| 421 | * org.texi (@LaTeX{} specific attributes): Document new :float | ||
| 422 | values. | ||
| 423 | |||
| 424 | * org.texi (Export settings): Improve documentation. | ||
| 425 | |||
| 426 | * org.texi (Math formatting in HTML export): Fix OPTIONS item's name. | ||
| 427 | (Text areas in HTML export): Update text areas. | ||
| 428 | (HTML Export commands): Update export commands. | ||
| 429 | |||
| 430 | * org.texi (Header and sectioning): Add a footnote about the | ||
| 431 | different between LATEX_HEADER_EXTRA and LATEX_HEADER. | ||
| 432 | |||
| 433 | * org.texi (The Export Dispatcher): Document | ||
| 434 | `org-export-in-background'. | ||
| 435 | |||
| 436 | * org.texi (Footnotes): Export back-ends do not use | ||
| 437 | `org-footnote-normalize' anymore. | ||
| 438 | |||
| 439 | * org.texi: Document variable changes. | ||
| 440 | |||
| 441 | * org.texi (Export settings): Doument p: item in OPTIONS keyword. | ||
| 442 | |||
| 443 | * org.texi (Exporting): Massive rewrite of the first sections. | ||
| 444 | (Selective export): Delete. | ||
| 445 | (The Export Dispatcher): Rewrite. | ||
| 446 | (Export options): Rewrite as "Export settings". | ||
| 447 | |||
| 448 | * org.texi: Small changes to documentation for embedded LaTeX. | ||
| 449 | |||
| 450 | * org.texi (Internal links): Document #+NAME keyword and | ||
| 451 | cross-referencing during export. | ||
| 452 | |||
| 453 | * org.texi (Include files): Remove reference to :prefix1 | ||
| 454 | and :prefix. Give more details for :minlevel. | ||
| 455 | |||
| 456 | * org.texi (Macro replacement): Fix macro name. Update | ||
| 457 | documentation about possible locations and escaping mechanism. | ||
| 458 | |||
| 459 | * org.texi (Table of contents): Update documentation. Document | ||
| 460 | lists of listings and lists of tables. Add documentation for | ||
| 461 | optional title and #+TOC: keyword. | ||
| 462 | |||
| 463 | 2013-11-12 Rick Frankel <rick@rickster.com> | ||
| 464 | |||
| 465 | * org.texi (results): Add Format section, broken out of Type | ||
| 466 | section to match code. | ||
| 467 | (hlines, colnames): Remove incorrect Emacs Lisp exception. Note | ||
| 468 | that the actual default handling (at least for python and | ||
| 469 | emacs-lisp) does not seem to match the description. | ||
| 470 | |||
| 471 | 2013-11-12 Sacha Chua <sacha@sachachua.com> (tiny change) | ||
| 472 | |||
| 473 | * org.texi (The date/time prompt): Update the documentation to | ||
| 474 | reflect the new way `org-read-date-get-relative' handles weekdays. | ||
| 475 | |||
| 476 | 2013-11-12 Yasushi Shoji <yashi@atmark-techno.com> | ||
| 477 | |||
| 478 | * org.texi (Resolving idle time): Document | ||
| 479 | `org-clock-x11idle-program-name'. | ||
| 480 | |||
| 1 | 2013-10-24 Michael Albinus <michael.albinus@gmx.de> | 481 | 2013-10-24 Michael Albinus <michael.albinus@gmx.de> |
| 2 | 482 | ||
| 3 | * ert.texi (Running Tests Interactively): Adapt examle output. | 483 | * ert.texi (Running Tests Interactively): Adapt examle output. |
diff --git a/doc/misc/org.texi b/doc/misc/org.texi index 832976e9ea0..94f7ac30ac8 100644 --- a/doc/misc/org.texi +++ b/doc/misc/org.texi | |||
| @@ -2,7 +2,8 @@ | |||
| 2 | @c %**start of header | 2 | @c %**start of header |
| 3 | @setfilename ../../info/org | 3 | @setfilename ../../info/org |
| 4 | @settitle The Org Manual | 4 | @settitle The Org Manual |
| 5 | @set VERSION 7.9.3f (GNU Emacs 24.3) | 5 | |
| 6 | @include org-version.inc | ||
| 6 | 7 | ||
| 7 | @c Use proper quote and backtick for code sections in PDF output | 8 | @c Use proper quote and backtick for code sections in PDF output |
| 8 | @c Cf. Texinfo manual 14.2 | 9 | @c Cf. Texinfo manual 14.2 |
| @@ -10,7 +11,7 @@ | |||
| 10 | @set txicodequotebacktick | 11 | @set txicodequotebacktick |
| 11 | 12 | ||
| 12 | @c Version and Contact Info | 13 | @c Version and Contact Info |
| 13 | @set MAINTAINERSITE @uref{http://orgmode.org,maintainers webpage} | 14 | @set MAINTAINERSITE @uref{http://orgmode.org,maintainers web page} |
| 14 | @set AUTHOR Carsten Dominik | 15 | @set AUTHOR Carsten Dominik |
| 15 | @set MAINTAINER Carsten Dominik | 16 | @set MAINTAINER Carsten Dominik |
| 16 | @set MAINTAINEREMAIL @email{carsten at orgmode dot org} | 17 | @set MAINTAINEREMAIL @email{carsten at orgmode dot org} |
| @@ -287,7 +288,8 @@ modify this GNU manual.'' | |||
| 287 | 288 | ||
| 288 | @subtitle Release @value{VERSION} | 289 | @subtitle Release @value{VERSION} |
| 289 | @author by Carsten Dominik | 290 | @author by Carsten Dominik |
| 290 | with contributions by David O'Toole, Bastien Guerry, Philip Rooke, Dan Davison, Eric Schulte, Thomas Dye and Jambunathan K. | 291 | with contributions by David O'Toole, Bastien Guerry, Philip Rooke, Dan |
| 292 | Davison, Eric Schulte, Thomas Dye, Jambunathan K and Nicolas Goaziou. | ||
| 291 | 293 | ||
| 292 | @c The following two commands start the copyright page. | 294 | @c The following two commands start the copyright page. |
| 293 | @page | 295 | @page |
| @@ -320,7 +322,7 @@ with contributions by David O'Toole, Bastien Guerry, Philip Rooke, Dan Davison, | |||
| 320 | * Capture - Refile - Archive:: The ins and outs for projects | 322 | * Capture - Refile - Archive:: The ins and outs for projects |
| 321 | * Agenda Views:: Collecting information into views | 323 | * Agenda Views:: Collecting information into views |
| 322 | * Markup:: Prepare text for rich export | 324 | * Markup:: Prepare text for rich export |
| 323 | * Exporting:: Sharing and publishing of notes | 325 | * Exporting:: Sharing and publishing notes |
| 324 | * Publishing:: Create a web site of linked Org files | 326 | * Publishing:: Create a web site of linked Org files |
| 325 | * Working With Source Code:: Export, evaluate, and tangle code blocks | 327 | * Working With Source Code:: Export, evaluate, and tangle code blocks |
| 326 | * Miscellaneous:: All the rest which did not fit elsewhere | 328 | * Miscellaneous:: All the rest which did not fit elsewhere |
| @@ -357,6 +359,18 @@ Document structure | |||
| 357 | * Blocks:: Folding blocks | 359 | * Blocks:: Folding blocks |
| 358 | * Footnotes:: How footnotes are defined in Org's syntax | 360 | * Footnotes:: How footnotes are defined in Org's syntax |
| 359 | * Orgstruct mode:: Structure editing outside Org | 361 | * Orgstruct mode:: Structure editing outside Org |
| 362 | * Org syntax:: Formal description of Org's syntax | ||
| 363 | |||
| 364 | Visibility cycling | ||
| 365 | |||
| 366 | * Global and local cycling:: Cycling through various visibility states | ||
| 367 | * Initial visibility:: Setting the initial visibility state | ||
| 368 | * Catching invisible edits:: Preventing mistakes when editing invisible parts | ||
| 369 | |||
| 370 | Global and local cycling | ||
| 371 | |||
| 372 | * Initial visibility:: Setting the initial visibility state | ||
| 373 | * Catching invisible edits:: Preventing mistakes when editing invisible parts | ||
| 360 | 374 | ||
| 361 | Tables | 375 | Tables |
| 362 | 376 | ||
| @@ -375,6 +389,7 @@ The spreadsheet | |||
| 375 | * Durations and time values:: How to compute durations and time values | 389 | * Durations and time values:: How to compute durations and time values |
| 376 | * Field and range formulas:: Formula for specific (ranges of) fields | 390 | * Field and range formulas:: Formula for specific (ranges of) fields |
| 377 | * Column formulas:: Formulas valid for an entire column | 391 | * Column formulas:: Formulas valid for an entire column |
| 392 | * Lookup functions:: Lookup functions for searching tables | ||
| 378 | * Editing and debugging formulas:: Fixing formulas | 393 | * Editing and debugging formulas:: Fixing formulas |
| 379 | * Updating the table:: Recomputing all dependent fields | 394 | * Updating the table:: Recomputing all dependent fields |
| 380 | * Advanced features:: Field and column names, parameters and automatic recalc | 395 | * Advanced features:: Field and column names, parameters and automatic recalc |
| @@ -423,6 +438,7 @@ Tags | |||
| 423 | 438 | ||
| 424 | * Tag inheritance:: Tags use the tree structure of the outline | 439 | * Tag inheritance:: Tags use the tree structure of the outline |
| 425 | * Setting tags:: How to assign tags to a headline | 440 | * Setting tags:: How to assign tags to a headline |
| 441 | * Tag groups:: Use one tag to search for several tags | ||
| 426 | * Tag searches:: Searching for combinations of tags | 442 | * Tag searches:: Searching for combinations of tags |
| 427 | 443 | ||
| 428 | Properties and columns | 444 | Properties and columns |
| @@ -477,7 +493,7 @@ Capture - Refile - Archive | |||
| 477 | * Attachments:: Add files to tasks | 493 | * Attachments:: Add files to tasks |
| 478 | * RSS Feeds:: Getting input from RSS feeds | 494 | * RSS Feeds:: Getting input from RSS feeds |
| 479 | * Protocols:: External (e.g., Browser) access to Emacs and Org | 495 | * Protocols:: External (e.g., Browser) access to Emacs and Org |
| 480 | * Refiling notes:: Moving a tree from one place to another | 496 | * Refile and copy:: Moving/copying a tree from one place to another |
| 481 | * Archiving:: What to do with finished projects | 497 | * Archiving:: What to do with finished projects |
| 482 | 498 | ||
| 483 | Capture | 499 | Capture |
| @@ -521,7 +537,8 @@ Presentation and sorting | |||
| 521 | 537 | ||
| 522 | * Categories:: Not all tasks are equal | 538 | * Categories:: Not all tasks are equal |
| 523 | * Time-of-day specifications:: How the agenda knows the time | 539 | * Time-of-day specifications:: How the agenda knows the time |
| 524 | * Sorting of agenda items:: The order of things | 540 | * Sorting agenda items:: The order of things |
| 541 | * Filtering/limiting agenda items:: Dynamically narrow the agenda | ||
| 525 | 542 | ||
| 526 | Custom agenda views | 543 | Custom agenda views |
| 527 | 544 | ||
| @@ -532,19 +549,19 @@ Custom agenda views | |||
| 532 | Markup for rich export | 549 | Markup for rich export |
| 533 | 550 | ||
| 534 | * Structural markup elements:: The basic structure as seen by the exporter | 551 | * Structural markup elements:: The basic structure as seen by the exporter |
| 535 | * Images and tables:: Tables and Images will be included | 552 | * Images and tables:: Images, tables and caption mechanism |
| 536 | * Literal examples:: Source code examples with special formatting | 553 | * Literal examples:: Source code examples with special formatting |
| 537 | * Include files:: Include additional files into a document | 554 | * Include files:: Include additional files into a document |
| 538 | * Index entries:: Making an index | 555 | * Index entries:: Making an index |
| 539 | * Macro replacement:: Use macros to create complex output | 556 | * Macro replacement:: Use macros to create templates |
| 540 | * Embedded @LaTeX{}:: LaTeX can be freely used inside Org documents | 557 | * Embedded @LaTeX{}:: LaTeX can be freely used inside Org documents |
| 558 | * Special blocks:: Containers targeted at export back-ends | ||
| 541 | 559 | ||
| 542 | Structural markup elements | 560 | Structural markup elements |
| 543 | 561 | ||
| 544 | * Document title:: Where the title is taken from | 562 | * Document title:: Where the title is taken from |
| 545 | * Headings and sections:: The document structure as seen by the exporter | 563 | * Headings and sections:: The document structure as seen by the exporter |
| 546 | * Table of contents:: The if and where of the table of contents | 564 | * Table of contents:: The if and where of the table of contents |
| 547 | * Initial text:: Text before the first heading? | ||
| 548 | * Lists:: Lists | 565 | * Lists:: Lists |
| 549 | * Paragraphs:: Paragraphs | 566 | * Paragraphs:: Paragraphs |
| 550 | * Footnote markup:: Footnotes | 567 | * Footnote markup:: Footnotes |
| @@ -562,22 +579,24 @@ Embedded @LaTeX{} | |||
| 562 | 579 | ||
| 563 | Exporting | 580 | Exporting |
| 564 | 581 | ||
| 565 | * Selective export:: Using tags to select and exclude trees | 582 | * The Export Dispatcher:: The main exporter interface |
| 566 | * Export options:: Per-file export settings | 583 | * Export back-ends:: Built-in export formats |
| 567 | * The export dispatcher:: How to access exporter commands | 584 | * Export settings:: Generic export settings |
| 568 | * ASCII/Latin-1/UTF-8 export:: Exporting to flat files with encoding | 585 | * ASCII/Latin-1/UTF-8 export:: Exporting to flat files with encoding |
| 586 | * Beamer export:: Exporting as a Beamer presentation | ||
| 569 | * HTML export:: Exporting to HTML | 587 | * HTML export:: Exporting to HTML |
| 570 | * @LaTeX{} and PDF export:: Exporting to @LaTeX{}, and processing to PDF | 588 | * @LaTeX{} and PDF export:: Exporting to @LaTeX{}, and processing to PDF |
| 571 | * DocBook export:: Exporting to DocBook | 589 | * Markdown export:: Exporting to Markdown |
| 572 | * OpenDocument Text export:: Exporting to OpenDocument Text | 590 | * OpenDocument Text export:: Exporting to OpenDocument Text |
| 573 | * TaskJuggler export:: Exporting to TaskJuggler | 591 | * iCalendar export:: Exporting to iCalendar |
| 574 | * Freemind export:: Exporting to Freemind mind maps | 592 | * Other built-in back-ends:: Exporting to @code{Texinfo}, a man page, or Org |
| 575 | * XOXO export:: Exporting to XOXO | 593 | * Export in foreign buffers:: Author tables in lists in Org syntax |
| 576 | * iCalendar export:: Exporting in iCalendar format | 594 | * Advanced configuration:: Fine-tuning the export output |
| 577 | 595 | ||
| 578 | HTML export | 596 | HTML export |
| 579 | 597 | ||
| 580 | * HTML Export commands:: How to invoke HTML export | 598 | * HTML Export commands:: How to invoke HTML export |
| 599 | * HTML doctypes:: Org can export to various (X)HTML flavors | ||
| 581 | * HTML preamble and postamble:: How to insert a preamble and a postamble | 600 | * HTML preamble and postamble:: How to insert a preamble and a postamble |
| 582 | * Quoting HTML tags:: Using direct HTML in Org mode | 601 | * Quoting HTML tags:: Using direct HTML in Org mode |
| 583 | * Links in HTML export:: How links will be interpreted and formatted | 602 | * Links in HTML export:: How links will be interpreted and formatted |
| @@ -590,21 +609,10 @@ HTML export | |||
| 590 | 609 | ||
| 591 | @LaTeX{} and PDF export | 610 | @LaTeX{} and PDF export |
| 592 | 611 | ||
| 593 | * @LaTeX{}/PDF export commands:: | 612 | * @LaTeX{} export commands:: How to export to LaTeX and PDF |
| 594 | * Header and sectioning:: Setting up the export file structure | 613 | * Header and sectioning:: Setting up the export file structure |
| 595 | * Quoting @LaTeX{} code:: Incorporating literal @LaTeX{} code | 614 | * Quoting @LaTeX{} code:: Incorporating literal @LaTeX{} code |
| 596 | * Tables in @LaTeX{} export:: Options for exporting tables to @LaTeX{} | 615 | * @LaTeX{} specific attributes:: Controlling @LaTeX{} output |
| 597 | * Images in @LaTeX{} export:: How to insert figures into @LaTeX{} output | ||
| 598 | * Beamer class export:: Turning the file into a presentation | ||
| 599 | |||
| 600 | DocBook export | ||
| 601 | |||
| 602 | * DocBook export commands:: How to invoke DocBook export | ||
| 603 | * Quoting DocBook code:: Incorporating DocBook code in Org files | ||
| 604 | * Recursive sections:: Recursive sections in DocBook | ||
| 605 | * Tables in DocBook export:: Tables are exported as HTML tables | ||
| 606 | * Images in DocBook export:: How to insert figures into DocBook output | ||
| 607 | * Special characters:: How to handle special characters | ||
| 608 | 616 | ||
| 609 | OpenDocument Text export | 617 | OpenDocument Text export |
| 610 | 618 | ||
| @@ -680,8 +688,8 @@ Using header arguments | |||
| 680 | 688 | ||
| 681 | * System-wide header arguments:: Set global default values | 689 | * System-wide header arguments:: Set global default values |
| 682 | * Language-specific header arguments:: Set default values by language | 690 | * Language-specific header arguments:: Set default values by language |
| 683 | * Buffer-wide header arguments:: Set default values for a specific buffer | ||
| 684 | * Header arguments in Org mode properties:: Set default values for a buffer or heading | 691 | * Header arguments in Org mode properties:: Set default values for a buffer or heading |
| 692 | * Language-specific header arguments in Org mode properties:: Set langugage-specific default values for a buffer or heading | ||
| 685 | * Code block specific header arguments:: The most common way to set values | 693 | * Code block specific header arguments:: The most common way to set values |
| 686 | * Header arguments in function calls:: The most specific level | 694 | * Header arguments in function calls:: The most specific level |
| 687 | 695 | ||
| @@ -714,8 +722,12 @@ Specific header arguments | |||
| 714 | * colnames:: Handle column names in tables | 722 | * colnames:: Handle column names in tables |
| 715 | * rownames:: Handle row names in tables | 723 | * rownames:: Handle row names in tables |
| 716 | * shebang:: Make tangled files executable | 724 | * shebang:: Make tangled files executable |
| 725 | * tangle-mode:: Set permission of tangled files | ||
| 717 | * eval:: Limit evaluation of specific code blocks | 726 | * eval:: Limit evaluation of specific code blocks |
| 718 | * wrap:: Mark source block evaluation results | 727 | * wrap:: Mark source block evaluation results |
| 728 | * post:: Post processing of code block results | ||
| 729 | * prologue:: Text to prepend to code block body | ||
| 730 | * epilogue:: Text to append to code block body | ||
| 719 | 731 | ||
| 720 | Miscellaneous | 732 | Miscellaneous |
| 721 | 733 | ||
| @@ -729,7 +741,7 @@ Miscellaneous | |||
| 729 | * Clean view:: Getting rid of leading stars in the outline | 741 | * Clean view:: Getting rid of leading stars in the outline |
| 730 | * TTY keys:: Using Org on a tty | 742 | * TTY keys:: Using Org on a tty |
| 731 | * Interaction:: Other Emacs packages | 743 | * Interaction:: Other Emacs packages |
| 732 | * org-crypt.el:: Encrypting Org files | 744 | * org-crypt:: Encrypting Org files |
| 733 | 745 | ||
| 734 | Interaction with other packages | 746 | Interaction with other packages |
| 735 | 747 | ||
| @@ -741,11 +753,13 @@ Hacking | |||
| 741 | * Hooks:: How to reach into Org's internals | 753 | * Hooks:: How to reach into Org's internals |
| 742 | * Add-on packages:: Available extensions | 754 | * Add-on packages:: Available extensions |
| 743 | * Adding hyperlink types:: New custom link types | 755 | * Adding hyperlink types:: New custom link types |
| 756 | * Adding export back-ends:: How to write new export back-ends | ||
| 744 | * Context-sensitive commands:: How to add functionality to such commands | 757 | * Context-sensitive commands:: How to add functionality to such commands |
| 745 | * Tables in arbitrary syntax:: Orgtbl for @LaTeX{} and other programs | 758 | * Tables in arbitrary syntax:: Orgtbl for @LaTeX{} and other programs |
| 746 | * Dynamic blocks:: Automatically filled blocks | 759 | * Dynamic blocks:: Automatically filled blocks |
| 747 | * Special agenda views:: Customized views | 760 | * Special agenda views:: Customized views |
| 748 | * Extracting agenda information:: Postprocessing of agenda information | 761 | * Speeding up your agendas:: Tips on how to speed up your agendas |
| 762 | * Extracting agenda information:: Post-processing of agenda information | ||
| 749 | * Using the property API:: Writing programs that use entry properties | 763 | * Using the property API:: Writing programs that use entry properties |
| 750 | * Using the mapping API:: Mapping over all or selected entries | 764 | * Using the mapping API:: Mapping over all or selected entries |
| 751 | 765 | ||
| @@ -754,7 +768,7 @@ Tables and lists in arbitrary syntax | |||
| 754 | * Radio tables:: Sending and receiving radio tables | 768 | * Radio tables:: Sending and receiving radio tables |
| 755 | * A @LaTeX{} example:: Step by step, almost a tutorial | 769 | * A @LaTeX{} example:: Step by step, almost a tutorial |
| 756 | * Translator functions:: Copy and modify | 770 | * Translator functions:: Copy and modify |
| 757 | * Radio lists:: Doing the same for lists | 771 | * Radio lists:: Sending and receiving lists |
| 758 | 772 | ||
| 759 | MobileOrg | 773 | MobileOrg |
| 760 | 774 | ||
| @@ -794,7 +808,7 @@ timestamps, and scheduling. It dynamically compiles entries into an | |||
| 794 | agenda that utilizes and smoothly integrates much of the Emacs calendar | 808 | agenda that utilizes and smoothly integrates much of the Emacs calendar |
| 795 | and diary. Plain text URL-like links connect to websites, emails, | 809 | and diary. Plain text URL-like links connect to websites, emails, |
| 796 | Usenet messages, BBDB entries, and any files related to the projects. | 810 | Usenet messages, BBDB entries, and any files related to the projects. |
| 797 | For printing and sharing of notes, an Org file can be exported as a | 811 | For printing and sharing notes, an Org file can be exported as a |
| 798 | structured ASCII file, as HTML, or (TODO and agenda items only) as an | 812 | structured ASCII file, as HTML, or (TODO and agenda items only) as an |
| 799 | iCalendar file. It can also serve as a publishing tool for a set of | 813 | iCalendar file. It can also serve as a publishing tool for a set of |
| 800 | linked web pages. | 814 | linked web pages. |
| @@ -828,7 +842,7 @@ ends, for example: | |||
| 828 | @pindex GTD, Getting Things Done | 842 | @pindex GTD, Getting Things Done |
| 829 | @r{@bullet{} an environment in which to implement David Allen's GTD system} | 843 | @r{@bullet{} an environment in which to implement David Allen's GTD system} |
| 830 | @r{@bullet{} a simple hypertext system, with HTML and @LaTeX{} export} | 844 | @r{@bullet{} a simple hypertext system, with HTML and @LaTeX{} export} |
| 831 | @r{@bullet{} a publishing tool to create a set of interlinked webpages} | 845 | @r{@bullet{} a publishing tool to create a set of interlinked web pages} |
| 832 | @r{@bullet{} an environment for literate programming} | 846 | @r{@bullet{} an environment for literate programming} |
| 833 | @end example | 847 | @end example |
| 834 | 848 | ||
| @@ -867,10 +881,11 @@ We @b{strongly recommend} to stick to a single installation method. | |||
| 867 | 881 | ||
| 868 | Recent Emacs distributions include a packaging system which lets you install | 882 | Recent Emacs distributions include a packaging system which lets you install |
| 869 | Elisp libraries. You can install Org with @kbd{M-x package-install RET org}. | 883 | Elisp libraries. You can install Org with @kbd{M-x package-install RET org}. |
| 870 | To make sure your Org configuration is well taken into account, initialize | 884 | You need to do this in a session where no @code{.org} file has been visited. |
| 871 | the package system with @code{(package-initialize)} before setting any Org | 885 | Then, to make sure your Org configuration is taken into account, initialize |
| 872 | option. If you want to use Org's package repository, check out the | 886 | the package system with @code{(package-initialize)} in your @file{.emacs} |
| 873 | @uref{http://orgmode.org/elpa.html, Org ELPA page}. | 887 | before setting any Org option. If you want to use Org's package repository, |
| 888 | check out the @uref{http://orgmode.org/elpa.html, Org ELPA page}. | ||
| 874 | 889 | ||
| 875 | @subsubheading Downloading Org as an archive | 890 | @subsubheading Downloading Org as an archive |
| 876 | 891 | ||
| @@ -878,17 +893,17 @@ You can download Org latest release from @uref{http://orgmode.org/, Org's | |||
| 878 | website}. In this case, make sure you set the load-path correctly in your | 893 | website}. In this case, make sure you set the load-path correctly in your |
| 879 | @file{.emacs}: | 894 | @file{.emacs}: |
| 880 | 895 | ||
| 881 | @example | 896 | @lisp |
| 882 | (add-to-list 'load-path "~/path/to/orgdir/lisp") | 897 | (add-to-list 'load-path "~/path/to/orgdir/lisp") |
| 883 | @end example | 898 | @end lisp |
| 884 | 899 | ||
| 885 | The downloaded archive contains contributed libraries that are not included | 900 | The downloaded archive contains contributed libraries that are not included |
| 886 | in Emacs. If you want to use them, add the @file{contrib} directory to your | 901 | in Emacs. If you want to use them, add the @file{contrib} directory to your |
| 887 | load-path: | 902 | load-path: |
| 888 | 903 | ||
| 889 | @example | 904 | @lisp |
| 890 | (add-to-list 'load-path "~/path/to/orgdir/contrib/lisp" t) | 905 | (add-to-list 'load-path "~/path/to/orgdir/contrib/lisp" t) |
| 891 | @end example | 906 | @end lisp |
| 892 | 907 | ||
| 893 | Optionally, you can compile the files and/or install them in your system. | 908 | Optionally, you can compile the files and/or install them in your system. |
| 894 | Run @code{make help} to list compilation and installation options. | 909 | Run @code{make help} to list compilation and installation options. |
| @@ -1001,10 +1016,10 @@ version of Org available---if you are running an outdated version, it is | |||
| 1001 | quite possible that the bug has been fixed already. If the bug persists, | 1016 | quite possible that the bug has been fixed already. If the bug persists, |
| 1002 | prepare a report and provide as much information as possible, including the | 1017 | prepare a report and provide as much information as possible, including the |
| 1003 | version information of Emacs (@kbd{M-x emacs-version @key{RET}}) and Org | 1018 | version information of Emacs (@kbd{M-x emacs-version @key{RET}}) and Org |
| 1004 | (@kbd{M-x org-version @key{RET}}), as well as the Org related setup in | 1019 | (@kbd{M-x org-version RET}), as well as the Org related setup in |
| 1005 | @file{.emacs}. The easiest way to do this is to use the command | 1020 | @file{.emacs}. The easiest way to do this is to use the command |
| 1006 | @example | 1021 | @example |
| 1007 | @kbd{M-x org-submit-bug-report} | 1022 | @kbd{M-x org-submit-bug-report RET} |
| 1008 | @end example | 1023 | @end example |
| 1009 | @noindent which will put all this information into an Emacs mail buffer so | 1024 | @noindent which will put all this information into an Emacs mail buffer so |
| 1010 | that you only need to add your description. If you re not sending the Email | 1025 | that you only need to add your description. If you re not sending the Email |
| @@ -1025,7 +1040,7 @@ is not necessary. In that case it is sufficient to start Emacs as | |||
| 1025 | @code{emacs -Q}. The @code{minimal-org.el} setup file can have contents as | 1040 | @code{emacs -Q}. The @code{minimal-org.el} setup file can have contents as |
| 1026 | shown below. | 1041 | shown below. |
| 1027 | 1042 | ||
| 1028 | @example | 1043 | @lisp |
| 1029 | ;;; Minimal setup to load latest `org-mode' | 1044 | ;;; Minimal setup to load latest `org-mode' |
| 1030 | 1045 | ||
| 1031 | ;; activate debugging | 1046 | ;; activate debugging |
| @@ -1036,7 +1051,7 @@ shown below. | |||
| 1036 | ;; add latest org-mode to load path | 1051 | ;; add latest org-mode to load path |
| 1037 | (add-to-list 'load-path (expand-file-name "/path/to/org-mode/lisp")) | 1052 | (add-to-list 'load-path (expand-file-name "/path/to/org-mode/lisp")) |
| 1038 | (add-to-list 'load-path (expand-file-name "/path/to/org-mode/contrib/lisp" t)) | 1053 | (add-to-list 'load-path (expand-file-name "/path/to/org-mode/contrib/lisp" t)) |
| 1039 | @end example | 1054 | @end lisp |
| 1040 | 1055 | ||
| 1041 | If an error occurs, a backtrace can be very useful (see below on how to | 1056 | If an error occurs, a backtrace can be very useful (see below on how to |
| 1042 | create one). Often a small example file helps, along with clear information | 1057 | create one). Often a small example file helps, along with clear information |
| @@ -1064,7 +1079,7 @@ Reload uncompiled versions of all Org mode Lisp files. The backtrace | |||
| 1064 | contains much more information if it is produced with uncompiled code. | 1079 | contains much more information if it is produced with uncompiled code. |
| 1065 | To do this, use | 1080 | To do this, use |
| 1066 | @example | 1081 | @example |
| 1067 | C-u M-x org-reload RET | 1082 | @kbd{C-u M-x org-reload RET} |
| 1068 | @end example | 1083 | @end example |
| 1069 | @noindent | 1084 | @noindent |
| 1070 | or select @code{Org -> Refresh/Reload -> Reload Org uncompiled} from the | 1085 | or select @code{Org -> Refresh/Reload -> Reload Org uncompiled} from the |
| @@ -1109,7 +1124,7 @@ and @i{environment keywords} (like @code{#+BEGIN_HTML} to start a @code{HTML} | |||
| 1109 | environment). They are written in uppercase in the manual to enhance its | 1124 | environment). They are written in uppercase in the manual to enhance its |
| 1110 | readability, but you can use lowercase in your Org files@footnote{Easy | 1125 | readability, but you can use lowercase in your Org files@footnote{Easy |
| 1111 | templates insert lowercase keywords and Babel dynamically inserts | 1126 | templates insert lowercase keywords and Babel dynamically inserts |
| 1112 | @code{#+results}.} | 1127 | @code{#+results}.}. |
| 1113 | 1128 | ||
| 1114 | @subsubheading Keybindings and commands | 1129 | @subsubheading Keybindings and commands |
| 1115 | @kindex C-c a | 1130 | @kindex C-c a |
| @@ -1152,6 +1167,7 @@ edit the structure of the document. | |||
| 1152 | * Blocks:: Folding blocks | 1167 | * Blocks:: Folding blocks |
| 1153 | * Footnotes:: How footnotes are defined in Org's syntax | 1168 | * Footnotes:: How footnotes are defined in Org's syntax |
| 1154 | * Orgstruct mode:: Structure editing outside Org | 1169 | * Orgstruct mode:: Structure editing outside Org |
| 1170 | * Org syntax:: Formal description of Org's syntax | ||
| 1155 | @end menu | 1171 | @end menu |
| 1156 | 1172 | ||
| 1157 | @node Outlines, Headlines, Document Structure, Document Structure | 1173 | @node Outlines, Headlines, Document Structure, Document Structure |
| @@ -1213,6 +1229,15 @@ variable @code{org-cycle-separator-lines} to modify this behavior. | |||
| 1213 | @cindex show hidden text | 1229 | @cindex show hidden text |
| 1214 | @cindex hide text | 1230 | @cindex hide text |
| 1215 | 1231 | ||
| 1232 | @menu | ||
| 1233 | * Global and local cycling:: Cycling through various visibility states | ||
| 1234 | * Initial visibility:: Setting the initial visibility state | ||
| 1235 | * Catching invisible edits:: Preventing mistakes when editing invisible parts | ||
| 1236 | @end menu | ||
| 1237 | |||
| 1238 | @node Global and local cycling, Initial visibility, Visibility cycling, Visibility cycling | ||
| 1239 | @subsection Global and local cycling | ||
| 1240 | |||
| 1216 | Outlines make it possible to hide parts of the text in the buffer. | 1241 | Outlines make it possible to hide parts of the text in the buffer. |
| 1217 | Org uses just two commands, bound to @key{TAB} and | 1242 | Org uses just two commands, bound to @key{TAB} and |
| 1218 | @kbd{S-@key{TAB}} to change the visibility in the buffer. | 1243 | @kbd{S-@key{TAB}} to change the visibility in the buffer. |
| @@ -1295,6 +1320,15 @@ the previously used indirect buffer. | |||
| 1295 | Copy the @i{visible} text in the region into the kill ring. | 1320 | Copy the @i{visible} text in the region into the kill ring. |
| 1296 | @end table | 1321 | @end table |
| 1297 | 1322 | ||
| 1323 | @menu | ||
| 1324 | * Initial visibility:: Setting the initial visibility state | ||
| 1325 | * Catching invisible edits:: Preventing mistakes when editing invisible parts | ||
| 1326 | @end menu | ||
| 1327 | |||
| 1328 | @node Initial visibility, Catching invisible edits, Global and local cycling, Visibility cycling | ||
| 1329 | @subsection Initial visibility | ||
| 1330 | |||
| 1331 | @cindex visibility, initialize | ||
| 1298 | @vindex org-startup-folded | 1332 | @vindex org-startup-folded |
| 1299 | @vindex org-agenda-inhibit-startup | 1333 | @vindex org-agenda-inhibit-startup |
| 1300 | @cindex @code{overview}, STARTUP keyword | 1334 | @cindex @code{overview}, STARTUP keyword |
| @@ -1302,11 +1336,13 @@ Copy the @i{visible} text in the region into the kill ring. | |||
| 1302 | @cindex @code{showall}, STARTUP keyword | 1336 | @cindex @code{showall}, STARTUP keyword |
| 1303 | @cindex @code{showeverything}, STARTUP keyword | 1337 | @cindex @code{showeverything}, STARTUP keyword |
| 1304 | 1338 | ||
| 1305 | When Emacs first visits an Org file, the global state is set to | 1339 | When Emacs first visits an Org file, the global state is set to OVERVIEW, |
| 1306 | OVERVIEW, i.e., only the top level headlines are visible. This can be | 1340 | i.e., only the top level headlines are visible@footnote{When |
| 1307 | configured through the variable @code{org-startup-folded}, or on a | 1341 | @code{org-agenda-inhibit-startup} is non-@code{nil}, Org will not honor the default |
| 1308 | per-file basis by adding one of the following lines anywhere in the | 1342 | visibility state when first opening a file for the agenda (@pxref{Speeding up |
| 1309 | buffer: | 1343 | your agendas}).} This can be configured through the variable |
| 1344 | @code{org-startup-folded}, or on a per-file basis by adding one of the | ||
| 1345 | following lines anywhere in the buffer: | ||
| 1310 | 1346 | ||
| 1311 | @example | 1347 | @example |
| 1312 | #+STARTUP: overview | 1348 | #+STARTUP: overview |
| @@ -1317,7 +1353,7 @@ buffer: | |||
| 1317 | 1353 | ||
| 1318 | The startup visibility options are ignored when the file is open for the | 1354 | The startup visibility options are ignored when the file is open for the |
| 1319 | first time during the agenda generation: if you want the agenda to honor | 1355 | first time during the agenda generation: if you want the agenda to honor |
| 1320 | the startup visibility, set @code{org-agenda-inhibit-startup} to nil. | 1356 | the startup visibility, set @code{org-agenda-inhibit-startup} to @code{nil}. |
| 1321 | 1357 | ||
| 1322 | @cindex property, VISIBILITY | 1358 | @cindex property, VISIBILITY |
| 1323 | @noindent | 1359 | @noindent |
| @@ -1325,6 +1361,7 @@ Furthermore, any entries with a @samp{VISIBILITY} property (@pxref{Properties | |||
| 1325 | and Columns}) will get their visibility adapted accordingly. Allowed values | 1361 | and Columns}) will get their visibility adapted accordingly. Allowed values |
| 1326 | for this property are @code{folded}, @code{children}, @code{content}, and | 1362 | for this property are @code{folded}, @code{children}, @code{content}, and |
| 1327 | @code{all}. | 1363 | @code{all}. |
| 1364 | |||
| 1328 | @table @asis | 1365 | @table @asis |
| 1329 | @orgcmd{C-u C-u @key{TAB},org-set-startup-visibility} | 1366 | @orgcmd{C-u C-u @key{TAB},org-set-startup-visibility} |
| 1330 | Switch back to the startup visibility of the buffer, i.e., whatever is | 1367 | Switch back to the startup visibility of the buffer, i.e., whatever is |
| @@ -1332,6 +1369,17 @@ requested by startup options and @samp{VISIBILITY} properties in individual | |||
| 1332 | entries. | 1369 | entries. |
| 1333 | @end table | 1370 | @end table |
| 1334 | 1371 | ||
| 1372 | @node Catching invisible edits, , Initial visibility, Visibility cycling | ||
| 1373 | @subsection Catching invisible edits | ||
| 1374 | |||
| 1375 | @vindex org-catch-invisible-edits | ||
| 1376 | @cindex edits, catching invisible | ||
| 1377 | Sometimes you may inadvertently edit an invisible part of the buffer and be | ||
| 1378 | confused on what has been edited and how to undo the mistake. Setting | ||
| 1379 | @code{org-catch-invisible-edits} to non-@code{nil} will help prevent this. See the | ||
| 1380 | docstring of this option on how Org should catch invisible edits and process | ||
| 1381 | them. | ||
| 1382 | |||
| 1335 | @node Motion, Structure editing, Visibility cycling, Document Structure | 1383 | @node Motion, Structure editing, Visibility cycling, Document Structure |
| 1336 | @section Motion | 1384 | @section Motion |
| 1337 | @cindex motion, between headlines | 1385 | @cindex motion, between headlines |
| @@ -1369,7 +1417,7 @@ q @r{Quit} | |||
| 1369 | @end example | 1417 | @end example |
| 1370 | @vindex org-goto-interface | 1418 | @vindex org-goto-interface |
| 1371 | @noindent | 1419 | @noindent |
| 1372 | See also the variable @code{org-goto-interface}. | 1420 | See also the option @code{org-goto-interface}. |
| 1373 | @end table | 1421 | @end table |
| 1374 | 1422 | ||
| 1375 | @node Structure editing, Sparse trees, Motion, Document Structure | 1423 | @node Structure editing, Sparse trees, Motion, Document Structure |
| @@ -1388,17 +1436,20 @@ See also the variable @code{org-goto-interface}. | |||
| 1388 | @table @asis | 1436 | @table @asis |
| 1389 | @orgcmd{M-@key{RET},org-insert-heading} | 1437 | @orgcmd{M-@key{RET},org-insert-heading} |
| 1390 | @vindex org-M-RET-may-split-line | 1438 | @vindex org-M-RET-may-split-line |
| 1391 | Insert new heading with same level as current. If the cursor is in a plain | 1439 | Insert a new heading/item with the same level than the one at point. |
| 1392 | list item, a new item is created (@pxref{Plain lists}). To force creation of | 1440 | If the cursor is in a plain list item, a new item is created |
| 1393 | a new headline, use a prefix argument. When this command is used in the | 1441 | (@pxref{Plain lists}). To prevent this behavior in lists, call the |
| 1394 | middle of a line, the line is split and the rest of the line becomes the new | 1442 | command with a prefix argument. When this command is used in the |
| 1395 | headline@footnote{If you do not want the line to be split, customize the | 1443 | middle of a line, the line is split and the rest of the line becomes |
| 1396 | variable @code{org-M-RET-may-split-line}.}. If the command is used at the | 1444 | the new item or headline@footnote{If you do not want the line to be |
| 1397 | beginning of a headline, the new headline is created before the current line. | 1445 | split, customize the variable @code{org-M-RET-may-split-line}.}. If |
| 1398 | If at the beginning of any other line, the content of that line is made the | 1446 | the command is used at the @emph{beginning} of a headline, the new |
| 1399 | new heading. If the command is used at the end of a folded subtree (i.e., | 1447 | headline is created before the current line. If the command is used |
| 1400 | behind the ellipses at the end of a headline), then a headline like the | 1448 | at the @emph{end} of a folded subtree (i.e., behind the ellipses at |
| 1401 | current one will be inserted after the end of the subtree. | 1449 | the end of a headline), then a headline will be |
| 1450 | inserted after the end of the subtree. Calling this command with | ||
| 1451 | @kbd{C-u C-u} will unconditionally respect the headline's content and | ||
| 1452 | create a new item at the end of the parent subtree. | ||
| 1402 | @orgcmd{C-@key{RET},org-insert-heading-respect-content} | 1453 | @orgcmd{C-@key{RET},org-insert-heading-respect-content} |
| 1403 | Just like @kbd{M-@key{RET}}, except when adding a new heading below the | 1454 | Just like @kbd{M-@key{RET}}, except when adding a new heading below the |
| 1404 | current heading, the new heading is placed after the body instead of before | 1455 | current heading, the new heading is placed after the body instead of before |
| @@ -1450,7 +1501,7 @@ headline marker like @samp{****}. | |||
| 1450 | @orgcmd{C-y,org-yank} | 1501 | @orgcmd{C-y,org-yank} |
| 1451 | @vindex org-yank-adjusted-subtrees | 1502 | @vindex org-yank-adjusted-subtrees |
| 1452 | @vindex org-yank-folded-subtrees | 1503 | @vindex org-yank-folded-subtrees |
| 1453 | Depending on the variables @code{org-yank-adjusted-subtrees} and | 1504 | Depending on the options @code{org-yank-adjusted-subtrees} and |
| 1454 | @code{org-yank-folded-subtrees}, Org's internal @code{yank} command will | 1505 | @code{org-yank-folded-subtrees}, Org's internal @code{yank} command will |
| 1455 | paste subtrees folded and in a clever way, using the same command as @kbd{C-c | 1506 | paste subtrees folded and in a clever way, using the same command as @kbd{C-c |
| 1456 | C-x C-y}. With the default settings, no level adjustment will take place, | 1507 | C-x C-y}. With the default settings, no level adjustment will take place, |
| @@ -1468,7 +1519,7 @@ to create a number of tasks related to a series of lectures to prepare. For | |||
| 1468 | more details, see the docstring of the command | 1519 | more details, see the docstring of the command |
| 1469 | @code{org-clone-subtree-with-time-shift}. | 1520 | @code{org-clone-subtree-with-time-shift}. |
| 1470 | @orgcmd{C-c C-w,org-refile} | 1521 | @orgcmd{C-c C-w,org-refile} |
| 1471 | Refile entry or region to a different location. @xref{Refiling notes}. | 1522 | Refile entry or region to a different location. @xref{Refile and copy}. |
| 1472 | @orgcmd{C-c ^,org-sort} | 1523 | @orgcmd{C-c ^,org-sort} |
| 1473 | Sort same-level entries. When there is an active region, all entries in the | 1524 | Sort same-level entries. When there is an active region, all entries in the |
| 1474 | region will be sorted. Otherwise the children of the current headline are | 1525 | region will be sorted. Otherwise the children of the current headline are |
| @@ -1550,11 +1601,10 @@ Jump to the next sparse tree match in this buffer. | |||
| 1550 | Jump to the previous sparse tree match in this buffer. | 1601 | Jump to the previous sparse tree match in this buffer. |
| 1551 | @end table | 1602 | @end table |
| 1552 | 1603 | ||
| 1553 | |||
| 1554 | @noindent | 1604 | @noindent |
| 1555 | @vindex org-agenda-custom-commands | 1605 | @vindex org-agenda-custom-commands |
| 1556 | For frequently used sparse trees of specific search strings, you can | 1606 | For frequently used sparse trees of specific search strings, you can |
| 1557 | use the variable @code{org-agenda-custom-commands} to define fast | 1607 | use the option @code{org-agenda-custom-commands} to define fast |
| 1558 | keyboard access to specific sparse trees. These commands will then be | 1608 | keyboard access to specific sparse trees. These commands will then be |
| 1559 | accessible through the agenda dispatcher (@pxref{Agenda dispatcher}). | 1609 | accessible through the agenda dispatcher (@pxref{Agenda dispatcher}). |
| 1560 | For example: | 1610 | For example: |
| @@ -1570,15 +1620,15 @@ a sparse tree matching the string @samp{FIXME}. | |||
| 1570 | The other sparse tree commands select headings based on TODO keywords, | 1620 | The other sparse tree commands select headings based on TODO keywords, |
| 1571 | tags, or properties and will be discussed later in this manual. | 1621 | tags, or properties and will be discussed later in this manual. |
| 1572 | 1622 | ||
| 1573 | @kindex C-c C-e v | 1623 | @kindex C-c C-e C-v |
| 1574 | @cindex printing sparse trees | 1624 | @cindex printing sparse trees |
| 1575 | @cindex visible text, printing | 1625 | @cindex visible text, printing |
| 1576 | To print a sparse tree, you can use the Emacs command | 1626 | To print a sparse tree, you can use the Emacs command |
| 1577 | @code{ps-print-buffer-with-faces} which does not print invisible parts | 1627 | @code{ps-print-buffer-with-faces} which does not print invisible parts |
| 1578 | of the document @footnote{This does not work under XEmacs, because | 1628 | of the document @footnote{This does not work under XEmacs, because |
| 1579 | XEmacs uses selective display for outlining, not text properties.}. | 1629 | XEmacs uses selective display for outlining, not text properties.}. |
| 1580 | Or you can use the command @kbd{C-c C-e v} to export only the visible | 1630 | Or you can use @kbd{C-c C-e C-v} to export only the visible part of |
| 1581 | part of the document and print the resulting file. | 1631 | the document and print the resulting file. |
| 1582 | 1632 | ||
| 1583 | @node Plain lists, Drawers, Sparse trees, Document Structure | 1633 | @node Plain lists, Drawers, Sparse trees, Document Structure |
| 1584 | @section Plain lists | 1634 | @section Plain lists |
| @@ -1604,12 +1654,12 @@ is supported, it may be better to not use it for plain list items.} as | |||
| 1604 | bullets. | 1654 | bullets. |
| 1605 | @item | 1655 | @item |
| 1606 | @vindex org-plain-list-ordered-item-terminator | 1656 | @vindex org-plain-list-ordered-item-terminator |
| 1607 | @vindex org-alphabetical-lists | 1657 | @vindex org-list-allow-alphabetical |
| 1608 | @emph{Ordered} list items start with a numeral followed by either a period or | 1658 | @emph{Ordered} list items start with a numeral followed by either a period or |
| 1609 | a right parenthesis@footnote{You can filter out any of them by configuring | 1659 | a right parenthesis@footnote{You can filter out any of them by configuring |
| 1610 | @code{org-plain-list-ordered-item-terminator}.}, such as @samp{1.} or | 1660 | @code{org-plain-list-ordered-item-terminator}.}, such as @samp{1.} or |
| 1611 | @samp{1)}@footnote{You can also get @samp{a.}, @samp{A.}, @samp{a)} and | 1661 | @samp{1)}@footnote{You can also get @samp{a.}, @samp{A.}, @samp{a)} and |
| 1612 | @samp{A)} by configuring @code{org-alphabetical-lists}. To minimize | 1662 | @samp{A)} by configuring @code{org-list-allow-alphabetical}. To minimize |
| 1613 | confusion with normal text, those are limited to one character only. Beyond | 1663 | confusion with normal text, those are limited to one character only. Beyond |
| 1614 | that limit, bullets will automatically fallback to numbers.}. If you want a | 1664 | that limit, bullets will automatically fallback to numbers.}. If you want a |
| 1615 | list to start with a different value (e.g., 20), start the text of the item | 1665 | list to start with a different value (e.g., 20), start the text of the item |
| @@ -1629,11 +1679,11 @@ line. In particular, if an ordered list reaches number @samp{10.}, then the | |||
| 1629 | list. An item ends before the next line that is less or equally indented | 1679 | list. An item ends before the next line that is less or equally indented |
| 1630 | than its bullet/number. | 1680 | than its bullet/number. |
| 1631 | 1681 | ||
| 1632 | @vindex org-empty-line-terminates-plain-lists | 1682 | @vindex org-list-empty-line-terminates-plain-lists |
| 1633 | A list ends whenever every item has ended, which means before any line less | 1683 | A list ends whenever every item has ended, which means before any line less |
| 1634 | or equally indented than items at top level. It also ends before two blank | 1684 | or equally indented than items at top level. It also ends before two blank |
| 1635 | lines@footnote{See also @code{org-empty-line-terminates-plain-lists}.}. In | 1685 | lines@footnote{See also @code{org-list-empty-line-terminates-plain-lists}.}. |
| 1636 | that case, all items are closed. Here is an example: | 1686 | In that case, all items are closed. Here is an example: |
| 1637 | 1687 | ||
| 1638 | @example | 1688 | @example |
| 1639 | @group | 1689 | @group |
| @@ -1705,7 +1755,7 @@ one. | |||
| 1705 | 1755 | ||
| 1706 | @table @kbd | 1756 | @table @kbd |
| 1707 | @kindex M-S-@key{RET} | 1757 | @kindex M-S-@key{RET} |
| 1708 | @item M-S-RET | 1758 | @item M-S-@key{RET} |
| 1709 | Insert a new item with a checkbox (@pxref{Checkboxes}). | 1759 | Insert a new item with a checkbox (@pxref{Checkboxes}). |
| 1710 | @kindex S-@key{down} | 1760 | @kindex S-@key{down} |
| 1711 | @item S-up | 1761 | @item S-up |
| @@ -1724,7 +1774,7 @@ similar effect. | |||
| 1724 | @item M-up | 1774 | @item M-up |
| 1725 | @itemx M-down | 1775 | @itemx M-down |
| 1726 | Move the item including subitems up/down@footnote{See | 1776 | Move the item including subitems up/down@footnote{See |
| 1727 | @code{org-liste-use-circular-motion} for a cyclic behavior.} (swap with | 1777 | @code{org-list-use-circular-motion} for a cyclic behavior.} (swap with |
| 1728 | previous/next item of same indentation). If the list is ordered, renumbering | 1778 | previous/next item of same indentation). If the list is ordered, renumbering |
| 1729 | is automatic. | 1779 | is automatic. |
| 1730 | @kindex M-@key{left} | 1780 | @kindex M-@key{left} |
| @@ -1734,8 +1784,8 @@ is automatic. | |||
| 1734 | Decrease/increase the indentation of an item, leaving children alone. | 1784 | Decrease/increase the indentation of an item, leaving children alone. |
| 1735 | @kindex M-S-@key{left} | 1785 | @kindex M-S-@key{left} |
| 1736 | @kindex M-S-@key{right} | 1786 | @kindex M-S-@key{right} |
| 1737 | @item M-S-left | 1787 | @item M-S-@key{left} |
| 1738 | @itemx M-S-right | 1788 | @itemx M-S-@key{right} |
| 1739 | Decrease/increase the indentation of the item, including subitems. | 1789 | Decrease/increase the indentation of the item, including subitems. |
| 1740 | Initially, the item tree is selected based on current indentation. When | 1790 | Initially, the item tree is selected based on current indentation. When |
| 1741 | these commands are executed several times in direct succession, the initially | 1791 | these commands are executed several times in direct succession, the initially |
| @@ -1781,9 +1831,11 @@ This command also cycles bullet styles when the cursor in on the bullet or | |||
| 1781 | anywhere in an item line, details depending on | 1831 | anywhere in an item line, details depending on |
| 1782 | @code{org-support-shift-select}. | 1832 | @code{org-support-shift-select}. |
| 1783 | @kindex C-c ^ | 1833 | @kindex C-c ^ |
| 1834 | @cindex sorting, of plain list | ||
| 1784 | @item C-c ^ | 1835 | @item C-c ^ |
| 1785 | Sort the plain list. You will be prompted for the sorting method: | 1836 | Sort the plain list. You will be prompted for the sorting method: |
| 1786 | numerically, alphabetically, by time, or by custom function. | 1837 | numerically, alphabetically, by time, by checked status for check lists, |
| 1838 | or by a custom function. | ||
| 1787 | @end table | 1839 | @end table |
| 1788 | 1840 | ||
| 1789 | @node Drawers, Blocks, Plain lists, Document Structure | 1841 | @node Drawers, Blocks, Plain lists, Document Structure |
| @@ -1797,10 +1849,9 @@ numerically, alphabetically, by time, or by custom function. | |||
| 1797 | @kindex C-c C-x d | 1849 | @kindex C-c C-x d |
| 1798 | Sometimes you want to keep information associated with an entry, but you | 1850 | Sometimes you want to keep information associated with an entry, but you |
| 1799 | normally don't want to see it. For this, Org mode has @emph{drawers}. | 1851 | normally don't want to see it. For this, Org mode has @emph{drawers}. |
| 1800 | Drawers need to be configured with the variable | 1852 | Drawers need to be configured with the option @code{org-drawers}@footnote{You |
| 1801 | @code{org-drawers}@footnote{You can define additional drawers on a | 1853 | can define additional drawers on a per-file basis with a line like |
| 1802 | per-file basis with a line like @code{#+DRAWERS: HIDDEN STATE}}. Drawers | 1854 | @code{#+DRAWERS: HIDDEN STATE}}. Drawers look like this: |
| 1803 | look like this: | ||
| 1804 | 1855 | ||
| 1805 | @example | 1856 | @example |
| 1806 | ** This is a headline | 1857 | ** This is a headline |
| @@ -1833,6 +1884,12 @@ want to store a quick note in the LOGBOOK drawer, in a similar way to state chan | |||
| 1833 | Add a time-stamped note to the LOGBOOK drawer. | 1884 | Add a time-stamped note to the LOGBOOK drawer. |
| 1834 | @end table | 1885 | @end table |
| 1835 | 1886 | ||
| 1887 | @vindex org-export-with-drawers | ||
| 1888 | You can select the name of the drawers which should be exported with | ||
| 1889 | @code{org-export-with-drawers}. In that case, drawer contents will appear in | ||
| 1890 | export output. Property drawers are not affected by this variable and are | ||
| 1891 | never exported. | ||
| 1892 | |||
| 1836 | @node Blocks, Footnotes, Drawers, Document Structure | 1893 | @node Blocks, Footnotes, Drawers, Document Structure |
| 1837 | @section Blocks | 1894 | @section Blocks |
| 1838 | 1895 | ||
| @@ -1842,7 +1899,7 @@ Org mode uses begin...end blocks for various purposes from including source | |||
| 1842 | code examples (@pxref{Literal examples}) to capturing time logging | 1899 | code examples (@pxref{Literal examples}) to capturing time logging |
| 1843 | information (@pxref{Clocking work time}). These blocks can be folded and | 1900 | information (@pxref{Clocking work time}). These blocks can be folded and |
| 1844 | unfolded by pressing TAB in the begin line. You can also get all blocks | 1901 | unfolded by pressing TAB in the begin line. You can also get all blocks |
| 1845 | folded at startup by configuring the variable @code{org-hide-block-startup} | 1902 | folded at startup by configuring the option @code{org-hide-block-startup} |
| 1846 | or on a per-file basis by using | 1903 | or on a per-file basis by using |
| 1847 | 1904 | ||
| 1848 | @cindex @code{hideblocks}, STARTUP keyword | 1905 | @cindex @code{hideblocks}, STARTUP keyword |
| @@ -1857,13 +1914,13 @@ or on a per-file basis by using | |||
| 1857 | @cindex footnotes | 1914 | @cindex footnotes |
| 1858 | 1915 | ||
| 1859 | Org mode supports the creation of footnotes. In contrast to the | 1916 | Org mode supports the creation of footnotes. In contrast to the |
| 1860 | @file{footnote.el} package, Org mode's footnotes are designed for work on a | 1917 | @file{footnote.el} package, Org mode's footnotes are designed for work on |
| 1861 | larger document, not only for one-off documents like emails. The basic | 1918 | a larger document, not only for one-off documents like emails. |
| 1862 | syntax is similar to the one used by @file{footnote.el}, i.e., a footnote is | 1919 | |
| 1863 | defined in a paragraph that is started by a footnote marker in square | 1920 | A footnote is started by a footnote marker in square brackets in column 0, no |
| 1864 | brackets in column 0, no indentation allowed. If you need a paragraph break | 1921 | indentation allowed. It ends at the next footnote definition, headline, or |
| 1865 | inside a footnote, use the @LaTeX{} idiom @samp{\par}. The footnote reference | 1922 | after two consecutive empty lines. The footnote reference is simply the |
| 1866 | is simply the marker in square brackets, inside text. For example: | 1923 | marker in square brackets, inside text. For example: |
| 1867 | 1924 | ||
| 1868 | @example | 1925 | @example |
| 1869 | The Org homepage[fn:1] now looks a lot better than it used to. | 1926 | The Org homepage[fn:1] now looks a lot better than it used to. |
| @@ -1913,11 +1970,11 @@ is at a definition, jump to the (first) reference. | |||
| 1913 | @vindex org-footnote-define-inline | 1970 | @vindex org-footnote-define-inline |
| 1914 | @vindex org-footnote-section | 1971 | @vindex org-footnote-section |
| 1915 | @vindex org-footnote-auto-adjust | 1972 | @vindex org-footnote-auto-adjust |
| 1916 | Otherwise, create a new footnote. Depending on the variable | 1973 | Otherwise, create a new footnote. Depending on the option |
| 1917 | @code{org-footnote-define-inline}@footnote{The corresponding in-buffer | 1974 | @code{org-footnote-define-inline}@footnote{The corresponding in-buffer |
| 1918 | setting is: @code{#+STARTUP: fninline} or @code{#+STARTUP: nofninline}}, the | 1975 | setting is: @code{#+STARTUP: fninline} or @code{#+STARTUP: nofninline}}, the |
| 1919 | definition will be placed right into the text as part of the reference, or | 1976 | definition will be placed right into the text as part of the reference, or |
| 1920 | separately into the location determined by the variable | 1977 | separately into the location determined by the option |
| 1921 | @code{org-footnote-section}. | 1978 | @code{org-footnote-section}. |
| 1922 | 1979 | ||
| 1923 | When this command is called with a prefix argument, a menu of additional | 1980 | When this command is called with a prefix argument, a menu of additional |
| @@ -1928,17 +1985,16 @@ s @r{Sort the footnote definitions by reference sequence. During editing,} | |||
| 1928 | @r{sequence. If you want them sorted, use this command, which will} | 1985 | @r{sequence. If you want them sorted, use this command, which will} |
| 1929 | @r{also move entries according to @code{org-footnote-section}. Automatic} | 1986 | @r{also move entries according to @code{org-footnote-section}. Automatic} |
| 1930 | @r{sorting after each insertion/deletion can be configured using the} | 1987 | @r{sorting after each insertion/deletion can be configured using the} |
| 1931 | @r{variable @code{org-footnote-auto-adjust}.} | 1988 | @r{option @code{org-footnote-auto-adjust}.} |
| 1932 | r @r{Renumber the simple @code{fn:N} footnotes. Automatic renumbering} | 1989 | r @r{Renumber the simple @code{fn:N} footnotes. Automatic renumbering} |
| 1933 | @r{after each insertion/deletion can be configured using the variable} | 1990 | @r{after each insertion/deletion can be configured using the option} |
| 1934 | @r{@code{org-footnote-auto-adjust}.} | 1991 | @r{@code{org-footnote-auto-adjust}.} |
| 1935 | S @r{Short for first @code{r}, then @code{s} action.} | 1992 | S @r{Short for first @code{r}, then @code{s} action.} |
| 1936 | n @r{Normalize the footnotes by collecting all definitions (including} | 1993 | n @r{Normalize the footnotes by collecting all definitions (including} |
| 1937 | @r{inline definitions) into a special section, and then numbering them} | 1994 | @r{inline definitions) into a special section, and then numbering them} |
| 1938 | @r{in sequence. The references will then also be numbers. This is} | 1995 | @r{in sequence. The references will then also be numbers. This is} |
| 1939 | @r{meant to be the final step before finishing a document (e.g., sending} | 1996 | @r{meant to be the final step before finishing a document (e.g., sending} |
| 1940 | @r{off an email). The exporters do this automatically, and so could} | 1997 | @r{off an email).} |
| 1941 | @r{something like @code{message-send-hook}.} | ||
| 1942 | d @r{Delete the footnote at point, and all definitions of and references} | 1998 | d @r{Delete the footnote at point, and all definitions of and references} |
| 1943 | @r{to it.} | 1999 | @r{to it.} |
| 1944 | @end example | 2000 | @end example |
| @@ -1960,7 +2016,7 @@ Footnote labels are also links to the corresponding definition/reference, and | |||
| 1960 | you can use the usual commands to follow these links. | 2016 | you can use the usual commands to follow these links. |
| 1961 | @end table | 2017 | @end table |
| 1962 | 2018 | ||
| 1963 | @node Orgstruct mode, , Footnotes, Document Structure | 2019 | @node Orgstruct mode, Org syntax, Footnotes, Document Structure |
| 1964 | @section The Orgstruct minor mode | 2020 | @section The Orgstruct minor mode |
| 1965 | @cindex Orgstruct mode | 2021 | @cindex Orgstruct mode |
| 1966 | @cindex minor mode for structure editing | 2022 | @cindex minor mode for structure editing |
| @@ -1968,7 +2024,7 @@ you can use the usual commands to follow these links. | |||
| 1968 | If you like the intuitive way the Org mode structure editing and list | 2024 | If you like the intuitive way the Org mode structure editing and list |
| 1969 | formatting works, you might want to use these commands in other modes like | 2025 | formatting works, you might want to use these commands in other modes like |
| 1970 | Text mode or Mail mode as well. The minor mode @code{orgstruct-mode} makes | 2026 | Text mode or Mail mode as well. The minor mode @code{orgstruct-mode} makes |
| 1971 | this possible. Toggle the mode with @kbd{M-x orgstruct-mode}, or | 2027 | this possible. Toggle the mode with @kbd{M-x orgstruct-mode RET}, or |
| 1972 | turn it on by default, for example in Message mode, with one of: | 2028 | turn it on by default, for example in Message mode, with one of: |
| 1973 | 2029 | ||
| 1974 | @lisp | 2030 | @lisp |
| @@ -1980,10 +2036,42 @@ When this mode is active and the cursor is on a line that looks to Org like a | |||
| 1980 | headline or the first line of a list item, most structure editing commands | 2036 | headline or the first line of a list item, most structure editing commands |
| 1981 | will work, even if the same keys normally have different functionality in the | 2037 | will work, even if the same keys normally have different functionality in the |
| 1982 | major mode you are using. If the cursor is not in one of those special | 2038 | major mode you are using. If the cursor is not in one of those special |
| 1983 | lines, Orgstruct mode lurks silently in the shadows. When you use | 2039 | lines, Orgstruct mode lurks silently in the shadows. |
| 1984 | @code{orgstruct++-mode}, Org will also export indentation and autofill | 2040 | |
| 1985 | settings into that mode, and detect item context after the first line of an | 2041 | When you use @code{orgstruct++-mode}, Org will also export indentation and |
| 1986 | item. | 2042 | autofill settings into that mode, and detect item context after the first |
| 2043 | line of an item. | ||
| 2044 | |||
| 2045 | @vindex orgstruct-heading-prefix-regexp | ||
| 2046 | You can also use Org structure editing to fold and unfold headlines in | ||
| 2047 | @emph{any} file, provided you defined @code{orgstruct-heading-prefix-regexp}: | ||
| 2048 | the regular expression must match the local prefix to use before Org's | ||
| 2049 | headlines. For example, if you set this variable to @code{";; "} in Emacs | ||
| 2050 | Lisp files, you will be able to fold and unfold headlines in Emacs Lisp | ||
| 2051 | commented lines. Some commands like @code{org-demote} are disabled when the | ||
| 2052 | prefix is set, but folding/unfolding will work correctly. | ||
| 2053 | |||
| 2054 | @node Org syntax, , Orgstruct mode, Document Structure | ||
| 2055 | @section Org syntax | ||
| 2056 | @cindex Org syntax | ||
| 2057 | |||
| 2058 | A reference document providing a formal description of Org's syntax is | ||
| 2059 | available as @uref{http://orgmode.org/worg/dev/org-syntax.html, a draft on | ||
| 2060 | Worg}, written and maintained by Nicolas Goaziou. It defines Org's core | ||
| 2061 | internal concepts such as @code{headlines}, @code{sections}, @code{affiliated | ||
| 2062 | keywords}, @code{(greater) elements} and @code{objects}. Each part of an Org | ||
| 2063 | file falls into one of the categories above. | ||
| 2064 | |||
| 2065 | To explore the abstract structure of an Org buffer, run this in a buffer: | ||
| 2066 | |||
| 2067 | @lisp | ||
| 2068 | M-: (org-element-parse-buffer) RET | ||
| 2069 | @end lisp | ||
| 2070 | |||
| 2071 | It will output a list containing the buffer's content represented as an | ||
| 2072 | abstract structure. The export engine relies on the information stored in | ||
| 2073 | this list. Most interactive commands (e.g., for structure editing) also | ||
| 2074 | rely on the syntactic meaning of the surrounding context. | ||
| 1987 | 2075 | ||
| 1988 | @node Tables, Hyperlinks, Document Structure, Top | 2076 | @node Tables, Hyperlinks, Document Structure, Top |
| 1989 | @chapter Tables | 2077 | @chapter Tables |
| @@ -2046,7 +2134,7 @@ inserting and deleting avoids shifting other fields. Also, when | |||
| 2046 | typing @emph{immediately after the cursor was moved into a new field | 2134 | typing @emph{immediately after the cursor was moved into a new field |
| 2047 | with @kbd{@key{TAB}}, @kbd{S-@key{TAB}} or @kbd{@key{RET}}}, the | 2135 | with @kbd{@key{TAB}}, @kbd{S-@key{TAB}} or @kbd{@key{RET}}}, the |
| 2048 | field is automatically made blank. If this behavior is too | 2136 | field is automatically made blank. If this behavior is too |
| 2049 | unpredictable for you, configure the variables | 2137 | unpredictable for you, configure the options |
| 2050 | @code{org-enable-table-editor} and @code{org-table-auto-blank-field}. | 2138 | @code{org-enable-table-editor} and @code{org-table-auto-blank-field}. |
| 2051 | 2139 | ||
| 2052 | @table @kbd | 2140 | @table @kbd |
| @@ -2066,7 +2154,7 @@ table. But it is easier just to start typing, like | |||
| 2066 | 2154 | ||
| 2067 | @tsubheading{Re-aligning and field motion} | 2155 | @tsubheading{Re-aligning and field motion} |
| 2068 | @orgcmd{C-c C-c,org-table-align} | 2156 | @orgcmd{C-c C-c,org-table-align} |
| 2069 | Re-align the table without moving the cursor. | 2157 | Re-align the table and don't move to another field. |
| 2070 | @c | 2158 | @c |
| 2071 | @orgcmd{<TAB>,org-table-next-field} | 2159 | @orgcmd{<TAB>,org-table-next-field} |
| 2072 | Re-align the table, move to the next field. Creates a new row if | 2160 | Re-align the table, move to the next field. Creates a new row if |
| @@ -2165,7 +2253,7 @@ be inserted with @kbd{C-y}. | |||
| 2165 | @vindex org-table-copy-increment | 2253 | @vindex org-table-copy-increment |
| 2166 | When current field is empty, copy from first non-empty field above. When not | 2254 | When current field is empty, copy from first non-empty field above. When not |
| 2167 | empty, copy current field down to next row and move cursor along with it. | 2255 | empty, copy current field down to next row and move cursor along with it. |
| 2168 | Depending on the variable @code{org-table-copy-increment}, integer field | 2256 | Depending on the option @code{org-table-copy-increment}, integer field |
| 2169 | values will be incremented during copy. Integers that are too large will not | 2257 | values will be incremented during copy. Integers that are too large will not |
| 2170 | be incremented. Also, a @code{0} prefix argument temporarily disables the | 2258 | be incremented. Also, a @code{0} prefix argument temporarily disables the |
| 2171 | increment. This key is also used by shift-selection and related modes | 2259 | increment. This key is also used by shift-selection and related modes |
| @@ -2181,7 +2269,7 @@ window follow the cursor through the table and always show the current | |||
| 2181 | field. The follow mode exits automatically when the cursor leaves the table, | 2269 | field. The follow mode exits automatically when the cursor leaves the table, |
| 2182 | or when you repeat this command with @kbd{C-u C-u C-c `}. | 2270 | or when you repeat this command with @kbd{C-u C-u C-c `}. |
| 2183 | @c | 2271 | @c |
| 2184 | @item M-x org-table-import | 2272 | @item M-x org-table-import RET |
| 2185 | Import a file as a table. The table should be TAB or whitespace | 2273 | Import a file as a table. The table should be TAB or whitespace |
| 2186 | separated. Use, for example, to import a spreadsheet table or data | 2274 | separated. Use, for example, to import a spreadsheet table or data |
| 2187 | from a database, because these programs generally can write | 2275 | from a database, because these programs generally can write |
| @@ -2194,12 +2282,12 @@ Tables can also be imported by pasting tabular text into the Org | |||
| 2194 | buffer, selecting the pasted text with @kbd{C-x C-x} and then using the | 2282 | buffer, selecting the pasted text with @kbd{C-x C-x} and then using the |
| 2195 | @kbd{C-c |} command (see above under @i{Creation and conversion}). | 2283 | @kbd{C-c |} command (see above under @i{Creation and conversion}). |
| 2196 | @c | 2284 | @c |
| 2197 | @item M-x org-table-export | 2285 | @item M-x org-table-export RET |
| 2198 | @findex org-table-export | 2286 | @findex org-table-export |
| 2199 | @vindex org-table-export-default-format | 2287 | @vindex org-table-export-default-format |
| 2200 | Export the table, by default as a TAB-separated file. Use for data | 2288 | Export the table, by default as a TAB-separated file. Use for data |
| 2201 | exchange with, for example, spreadsheet or database programs. The format | 2289 | exchange with, for example, spreadsheet or database programs. The format |
| 2202 | used to export the file can be configured in the variable | 2290 | used to export the file can be configured in the option |
| 2203 | @code{org-table-export-default-format}. You may also use properties | 2291 | @code{org-table-export-default-format}. You may also use properties |
| 2204 | @code{TABLE_EXPORT_FILE} and @code{TABLE_EXPORT_FORMAT} to specify the file | 2292 | @code{TABLE_EXPORT_FILE} and @code{TABLE_EXPORT_FORMAT} to specify the file |
| 2205 | name and the format for table export in a subtree. Org supports quite | 2293 | name and the format for table export in a subtree. Org supports quite |
| @@ -2274,7 +2362,7 @@ If you would like to overrule the automatic alignment of number-rich columns | |||
| 2274 | to the right and of string-rich column to the left, you can use @samp{<r>}, | 2362 | to the right and of string-rich column to the left, you can use @samp{<r>}, |
| 2275 | @samp{<c>}@footnote{Centering does not work inside Emacs, but it does have an | 2363 | @samp{<c>}@footnote{Centering does not work inside Emacs, but it does have an |
| 2276 | effect when exporting to HTML.} or @samp{<l>} in a similar fashion. You may | 2364 | effect when exporting to HTML.} or @samp{<l>} in a similar fashion. You may |
| 2277 | also combine alignment and field width like this: @samp{<l10>}. | 2365 | also combine alignment and field width like this: @samp{<r10>}. |
| 2278 | 2366 | ||
| 2279 | Lines which only contain these formatting cookies will be removed | 2367 | Lines which only contain these formatting cookies will be removed |
| 2280 | automatically when exporting the document. | 2368 | automatically when exporting the document. |
| @@ -2323,7 +2411,7 @@ every vertical line you would like to have: | |||
| 2323 | If you like the intuitive way the Org table editor works, you | 2411 | If you like the intuitive way the Org table editor works, you |
| 2324 | might also want to use it in other modes like Text mode or Mail mode. | 2412 | might also want to use it in other modes like Text mode or Mail mode. |
| 2325 | The minor mode Orgtbl mode makes this possible. You can always toggle | 2413 | The minor mode Orgtbl mode makes this possible. You can always toggle |
| 2326 | the mode with @kbd{M-x orgtbl-mode}. To turn it on by default, for | 2414 | the mode with @kbd{M-x orgtbl-mode RET}. To turn it on by default, for |
| 2327 | example in Message mode, use | 2415 | example in Message mode, use |
| 2328 | 2416 | ||
| 2329 | @lisp | 2417 | @lisp |
| @@ -2359,6 +2447,7 @@ formula, moving these references by arrow keys | |||
| 2359 | * Durations and time values:: How to compute durations and time values | 2447 | * Durations and time values:: How to compute durations and time values |
| 2360 | * Field and range formulas:: Formula for specific (ranges of) fields | 2448 | * Field and range formulas:: Formula for specific (ranges of) fields |
| 2361 | * Column formulas:: Formulas valid for an entire column | 2449 | * Column formulas:: Formulas valid for an entire column |
| 2450 | * Lookup functions:: Lookup functions for searching tables | ||
| 2362 | * Editing and debugging formulas:: Fixing formulas | 2451 | * Editing and debugging formulas:: Fixing formulas |
| 2363 | * Updating the table:: Recomputing all dependent fields | 2452 | * Updating the table:: Recomputing all dependent fields |
| 2364 | * Advanced features:: Field and column names, parameters and automatic recalc | 2453 | * Advanced features:: Field and column names, parameters and automatic recalc |
| @@ -2384,8 +2473,8 @@ combination like @code{B3}, meaning the 2nd field in the 3rd row. | |||
| 2384 | @vindex org-table-use-standard-references | 2473 | @vindex org-table-use-standard-references |
| 2385 | However, Org prefers@footnote{Org will understand references typed by the | 2474 | However, Org prefers@footnote{Org will understand references typed by the |
| 2386 | user as @samp{B4}, but it will not use this syntax when offering a formula | 2475 | user as @samp{B4}, but it will not use this syntax when offering a formula |
| 2387 | for editing. You can customize this behavior using the variable | 2476 | for editing. You can customize this behavior using the option |
| 2388 | @code{org-table-use-standard-references}.} to use another, more general | 2477 | @code{org-table-use-standard-references}.} to use another, more general |
| 2389 | representation that looks like this: | 2478 | representation that looks like this: |
| 2390 | @example | 2479 | @example |
| 2391 | @@@var{row}$@var{column} | 2480 | @@@var{row}$@var{column} |
| @@ -2452,15 +2541,15 @@ $1..$3 @r{first three fields in the current row} | |||
| 2452 | $P..$Q @r{range, using column names (see under Advanced)} | 2541 | $P..$Q @r{range, using column names (see under Advanced)} |
| 2453 | $<<<..$>> @r{start in third column, continue to the one but last} | 2542 | $<<<..$>> @r{start in third column, continue to the one but last} |
| 2454 | @@2$1..@@4$3 @r{6 fields between these two fields (same as @code{A2..C4})} | 2543 | @@2$1..@@4$3 @r{6 fields between these two fields (same as @code{A2..C4})} |
| 2455 | @@-1$-2..@@-1 @r{in the first row up, 3 fields from 2 columns on the left} | 2544 | @@-1$-2..@@-1 @r{3 fields in the row above, starting from 2 columns on the left} |
| 2456 | @@I..II @r{between first and second hline, short for @code{@@I..@@II}} | 2545 | @@I..II @r{between first and second hline, short for @code{@@I..@@II}} |
| 2457 | @end example | 2546 | @end example |
| 2458 | 2547 | ||
| 2459 | @noindent Range references return a vector of values that can be fed | 2548 | @noindent Range references return a vector of values that can be fed |
| 2460 | into Calc vector functions. Empty fields in ranges are normally | 2549 | into Calc vector functions. Empty fields in ranges are normally suppressed, |
| 2461 | suppressed, so that the vector contains only the non-empty fields (but | 2550 | so that the vector contains only the non-empty fields. For other options |
| 2462 | see the @samp{E} mode switch below). If there are no non-empty fields, | 2551 | with the mode switches @samp{E}, @samp{N} and examples @pxref{Formula syntax |
| 2463 | @samp{[0]} is returned to avoid syntax errors in formulas. | 2552 | for Calc}. |
| 2464 | 2553 | ||
| 2465 | @subsubheading Field coordinates in formulas | 2554 | @subsubheading Field coordinates in formulas |
| 2466 | @cindex field coordinates | 2555 | @cindex field coordinates |
| @@ -2493,7 +2582,7 @@ number of rows. | |||
| 2493 | 2582 | ||
| 2494 | @vindex org-table-formula-constants | 2583 | @vindex org-table-formula-constants |
| 2495 | @samp{$name} is interpreted as the name of a column, parameter or | 2584 | @samp{$name} is interpreted as the name of a column, parameter or |
| 2496 | constant. Constants are defined globally through the variable | 2585 | constant. Constants are defined globally through the option |
| 2497 | @code{org-table-formula-constants}, and locally (for the file) through a | 2586 | @code{org-table-formula-constants}, and locally (for the file) through a |
| 2498 | line like | 2587 | line like |
| 2499 | 2588 | ||
| @@ -2526,7 +2615,7 @@ numbers. | |||
| 2526 | @cindex references, to a different table | 2615 | @cindex references, to a different table |
| 2527 | @cindex name, of column or field | 2616 | @cindex name, of column or field |
| 2528 | @cindex constants, in calculations | 2617 | @cindex constants, in calculations |
| 2529 | @cindex #+TBLNAME | 2618 | @cindex #+NAME, for table |
| 2530 | 2619 | ||
| 2531 | You may also reference constants, fields and ranges from a different table, | 2620 | You may also reference constants, fields and ranges from a different table, |
| 2532 | either in the current file or even in a different file. The syntax is | 2621 | either in the current file or even in a different file. The syntax is |
| @@ -2537,7 +2626,7 @@ remote(NAME-OR-ID,REF) | |||
| 2537 | 2626 | ||
| 2538 | @noindent | 2627 | @noindent |
| 2539 | where NAME can be the name of a table in the current file as set by a | 2628 | where NAME can be the name of a table in the current file as set by a |
| 2540 | @code{#+TBLNAME: NAME} line before the table. It can also be the ID of an | 2629 | @code{#+NAME: Name} line before the table. It can also be the ID of an |
| 2541 | entry, even in a different file, and the reference then refers to the first | 2630 | entry, even in a different file, and the reference then refers to the first |
| 2542 | table in that entry. REF is an absolute field or range reference as | 2631 | table in that entry. REF is an absolute field or range reference as |
| 2543 | described above for example @code{@@3$3} or @code{$somename}, valid in the | 2632 | described above for example @code{@@3$3} or @code{$somename}, valid in the |
| @@ -2548,14 +2637,13 @@ referenced table. | |||
| 2548 | @cindex formula syntax, Calc | 2637 | @cindex formula syntax, Calc |
| 2549 | @cindex syntax, of formulas | 2638 | @cindex syntax, of formulas |
| 2550 | 2639 | ||
| 2551 | A formula can be any algebraic expression understood by the Emacs | 2640 | A formula can be any algebraic expression understood by the Emacs @file{Calc} |
| 2552 | @file{Calc} package. @b{Note that @file{calc} has the | 2641 | package. Note that @file{calc} has the non-standard convention that @samp{/} |
| 2553 | non-standard convention that @samp{/} has lower precedence than | 2642 | has lower precedence than @samp{*}, so that @samp{a/b*c} is interpreted as |
| 2554 | @samp{*}, so that @samp{a/b*c} is interpreted as @samp{a/(b*c)}.} Before | 2643 | @samp{a/(b*c)}. Before evaluation by @code{calc-eval} (@pxref{Calling Calc |
| 2555 | evaluation by @code{calc-eval} (@pxref{Calling Calc from | 2644 | from Your Programs, calc-eval, Calling Calc from Your Lisp Programs, calc, |
| 2556 | Your Programs, calc-eval, Calling Calc from Your Lisp Programs, calc, GNU | 2645 | GNU Emacs Calc Manual}), variable substitution takes place according to the |
| 2557 | Emacs Calc Manual}), | 2646 | rules described above. |
| 2558 | variable substitution takes place according to the rules described above. | ||
| 2559 | @cindex vectors, in table calculations | 2647 | @cindex vectors, in table calculations |
| 2560 | The range vectors can be directly fed into the Calc vector functions | 2648 | The range vectors can be directly fed into the Calc vector functions |
| 2561 | like @samp{vmean} and @samp{vsum}. | 2649 | like @samp{vmean} and @samp{vsum}. |
| @@ -2568,33 +2656,52 @@ string consists of flags to influence Calc and other modes during | |||
| 2568 | execution. By default, Org uses the standard Calc modes (precision | 2656 | execution. By default, Org uses the standard Calc modes (precision |
| 2569 | 12, angular units degrees, fraction and symbolic modes off). The display | 2657 | 12, angular units degrees, fraction and symbolic modes off). The display |
| 2570 | format, however, has been changed to @code{(float 8)} to keep tables | 2658 | format, however, has been changed to @code{(float 8)} to keep tables |
| 2571 | compact. The default settings can be configured using the variable | 2659 | compact. The default settings can be configured using the option |
| 2572 | @code{org-calc-default-modes}. | 2660 | @code{org-calc-default-modes}. |
| 2573 | 2661 | ||
| 2574 | @example | 2662 | @noindent List of modes: |
| 2575 | p20 @r{set the internal Calc calculation precision to 20 digits} | 2663 | |
| 2576 | n3 s3 e2 f4 @r{Normal, scientific, engineering, or fixed} | 2664 | @table @asis |
| 2577 | @r{format of the result of Calc passed back to Org.} | 2665 | @item @code{p20} |
| 2578 | @r{Calc formatting is unlimited in precision as} | 2666 | Set the internal Calc calculation precision to 20 digits. |
| 2579 | @r{long as the Calc calculation precision is greater.} | 2667 | @item @code{n3}, @code{s3}, @code{e2}, @code{f4} |
| 2580 | D R @r{angle modes: degrees, radians} | 2668 | Normal, scientific, engineering or fixed format of the result of Calc passed |
| 2581 | F S @r{fraction and symbolic modes} | 2669 | back to Org. Calc formatting is unlimited in precision as long as the Calc |
| 2582 | N @r{interpret all fields as numbers, use 0 for non-numbers} | 2670 | calculation precision is greater. |
| 2583 | E @r{keep empty fields in ranges} | 2671 | @item @code{D}, @code{R} |
| 2584 | L @r{literal} | 2672 | Degree and radian angle modes of Calc. |
| 2585 | @end example | 2673 | @item @code{F}, @code{S} |
| 2674 | Fraction and symbolic modes of Calc. | ||
| 2675 | @item @code{T}, @code{t} | ||
| 2676 | Duration computations in Calc or Lisp, @pxref{Durations and time values}. | ||
| 2677 | @item @code{E} | ||
| 2678 | If and how to consider empty fields. Without @samp{E} empty fields in range | ||
| 2679 | references are suppressed so that the Calc vector or Lisp list contains only | ||
| 2680 | the non-empty fields. With @samp{E} the empty fields are kept. For empty | ||
| 2681 | fields in ranges or empty field references the value @samp{nan} (not a | ||
| 2682 | number) is used in Calc formulas and the empty string is used for Lisp | ||
| 2683 | formulas. Add @samp{N} to use 0 instead for both formula types. For the | ||
| 2684 | value of a field the mode @samp{N} has higher precedence than @samp{E}. | ||
| 2685 | @item @code{N} | ||
| 2686 | Interpret all fields as numbers, use 0 for non-numbers. See the next section | ||
| 2687 | to see how this is essential for computations with Lisp formulas. In Calc | ||
| 2688 | formulas it is used only occasionally because there number strings are | ||
| 2689 | already interpreted as numbers without @samp{N}. | ||
| 2690 | @item @code{L} | ||
| 2691 | Literal, for Lisp formulas only. See the next section. | ||
| 2692 | @end table | ||
| 2586 | 2693 | ||
| 2587 | @noindent | 2694 | @noindent |
| 2588 | Unless you use large integer numbers or high-precision-calculation | 2695 | Unless you use large integer numbers or high-precision-calculation and |
| 2589 | and -display for floating point numbers you may alternatively provide a | 2696 | -display for floating point numbers you may alternatively provide a |
| 2590 | @code{printf} format specifier to reformat the Calc result after it has been | 2697 | @samp{printf} format specifier to reformat the Calc result after it has been |
| 2591 | passed back to Org instead of letting Calc already do the | 2698 | passed back to Org instead of letting Calc already do the |
| 2592 | formatting@footnote{The @code{printf} reformatting is limited in precision | 2699 | formatting@footnote{The @samp{printf} reformatting is limited in precision |
| 2593 | because the value passed to it is converted into an @code{integer} or | 2700 | because the value passed to it is converted into an @samp{integer} or |
| 2594 | @code{double}. The @code{integer} is limited in size by truncating the | 2701 | @samp{double}. The @samp{integer} is limited in size by truncating the |
| 2595 | signed value to 32 bits. The @code{double} is limited in precision to 64 | 2702 | signed value to 32 bits. The @samp{double} is limited in precision to 64 |
| 2596 | bits overall which leaves approximately 16 significant decimal digits.}. | 2703 | bits overall which leaves approximately 16 significant decimal digits.}. A |
| 2597 | A few examples: | 2704 | few examples: |
| 2598 | 2705 | ||
| 2599 | @example | 2706 | @example |
| 2600 | $1+$2 @r{Sum of first and second field} | 2707 | $1+$2 @r{Sum of first and second field} |
| @@ -2605,19 +2712,38 @@ $0;%.1f @r{Reformat current cell to 1 decimal} | |||
| 2605 | $c/$1/$cm @r{Hz -> cm conversion, using @file{constants.el}} | 2712 | $c/$1/$cm @r{Hz -> cm conversion, using @file{constants.el}} |
| 2606 | tan($1);Dp3s1 @r{Compute in degrees, precision 3, display SCI 1} | 2713 | tan($1);Dp3s1 @r{Compute in degrees, precision 3, display SCI 1} |
| 2607 | sin($1);Dp3%.1e @r{Same, but use printf specifier for display} | 2714 | sin($1);Dp3%.1e @r{Same, but use printf specifier for display} |
| 2608 | vmean($2..$7) @r{Compute column range mean, using vector function} | ||
| 2609 | vmean($2..$7);EN @r{Same, but treat empty fields as 0} | ||
| 2610 | taylor($3,x=7,2) @r{Taylor series of $3, at x=7, second degree} | 2715 | taylor($3,x=7,2) @r{Taylor series of $3, at x=7, second degree} |
| 2611 | @end example | 2716 | @end example |
| 2612 | 2717 | ||
| 2613 | Calc also contains a complete set of logical operations. For example | 2718 | Calc also contains a complete set of logical operations, (@pxref{Logical |
| 2719 | Operations, , Logical Operations, calc, GNU Emacs Calc Manual}). For example | ||
| 2614 | 2720 | ||
| 2615 | @example | 2721 | @table @code |
| 2616 | if($1<20,teen,string("")) @r{"teen" if age $1 less than 20, else empty} | 2722 | @item if($1 < 20, teen, string("")) |
| 2617 | @end example | 2723 | "teen" if age $1 is less than 20, else the Org table result field is set to |
| 2724 | empty with the empty string. | ||
| 2725 | @item if("$1" == "nan" || "$2" == "nan", string(""), $1 + $2); E | ||
| 2726 | Sum of the first two columns. When at least one of the input fields is empty | ||
| 2727 | the Org table result field is set to empty. | ||
| 2728 | @item if(typeof(vmean($1..$7)) == 12, string(""), vmean($1..$7); E | ||
| 2729 | Mean value of a range unless there is any empty field. Every field in the | ||
| 2730 | range that is empty is replaced by @samp{nan} which lets @samp{vmean} result | ||
| 2731 | in @samp{nan}. Then @samp{typeof == 12} detects the @samp{nan} from | ||
| 2732 | @samp{vmean} and the Org table result field is set to empty. Use this when | ||
| 2733 | the sample set is expected to never have missing values. | ||
| 2734 | @item if("$1..$7" == "[]", string(""), vmean($1..$7)) | ||
| 2735 | Mean value of a range with empty fields skipped. Every field in the range | ||
| 2736 | that is empty is skipped. When all fields in the range are empty the mean | ||
| 2737 | value is not defined and the Org table result field is set to empty. Use | ||
| 2738 | this when the sample set can have a variable size. | ||
| 2739 | @item vmean($1..$7); EN | ||
| 2740 | To complete the example before: Mean value of a range with empty fields | ||
| 2741 | counting as samples with value 0. Use this only when incomplete sample sets | ||
| 2742 | should be padded with 0 to the full size. | ||
| 2743 | @end table | ||
| 2618 | 2744 | ||
| 2619 | Note that you can also use two org-specific flags @code{T} and @code{t} for | 2745 | You can add your own Calc functions defined in Emacs Lisp with @code{defmath} |
| 2620 | durations computations @ref{Durations and time values}. | 2746 | and use them in formula syntax for Calc. |
| 2621 | 2747 | ||
| 2622 | @node Formula syntax for Lisp, Durations and time values, Formula syntax for Calc, The spreadsheet | 2748 | @node Formula syntax for Lisp, Durations and time values, Formula syntax for Calc, The spreadsheet |
| 2623 | @subsection Emacs Lisp forms as formulas | 2749 | @subsection Emacs Lisp forms as formulas |
| @@ -2646,14 +2772,14 @@ fields, so you can embed them in list or vector syntax. | |||
| 2646 | Here are a few examples---note how the @samp{N} mode is used when we do | 2772 | Here are a few examples---note how the @samp{N} mode is used when we do |
| 2647 | computations in Lisp: | 2773 | computations in Lisp: |
| 2648 | 2774 | ||
| 2649 | @example | 2775 | @table @code |
| 2650 | @r{Swap the first two characters of the content of column 1} | 2776 | @item '(concat (substring $1 1 2) (substring $1 0 1) (substring $1 2)) |
| 2651 | '(concat (substring $1 1 2) (substring $1 0 1) (substring $1 2)) | 2777 | Swap the first two characters of the content of column 1. |
| 2652 | @r{Add columns 1 and 2, equivalent to Calc's @code{$1+$2}} | 2778 | @item '(+ $1 $2);N |
| 2653 | '(+ $1 $2);N | 2779 | Add columns 1 and 2, equivalent to Calc's @code{$1+$2}. |
| 2654 | @r{Compute the sum of columns 1--4, like Calc's @code{vsum($1..$4)}} | 2780 | @item '(apply '+ '($1..$4));N |
| 2655 | '(apply '+ '($1..$4));N | 2781 | Compute the sum of columns 1 to 4, like Calc's @code{vsum($1..$4)}. |
| 2656 | @end example | 2782 | @end table |
| 2657 | 2783 | ||
| 2658 | @node Durations and time values, Field and range formulas, Formula syntax for Lisp, The spreadsheet | 2784 | @node Durations and time values, Field and range formulas, Formula syntax for Lisp, The spreadsheet |
| 2659 | @subsection Durations and time values | 2785 | @subsection Durations and time values |
| @@ -2677,7 +2803,7 @@ formulas or Elisp formulas: | |||
| 2677 | Input duration values must be of the form @code{[HH:MM[:SS]}, where seconds | 2803 | Input duration values must be of the form @code{[HH:MM[:SS]}, where seconds |
| 2678 | are optional. With the @code{T} flag, computed durations will be displayed | 2804 | are optional. With the @code{T} flag, computed durations will be displayed |
| 2679 | as @code{HH:MM:SS} (see the first formula above). With the @code{t} flag, | 2805 | as @code{HH:MM:SS} (see the first formula above). With the @code{t} flag, |
| 2680 | computed durations will be displayed according to the value of the variable | 2806 | computed durations will be displayed according to the value of the option |
| 2681 | @code{org-table-duration-custom-format}, which defaults to @code{'hours} and | 2807 | @code{org-table-duration-custom-format}, which defaults to @code{'hours} and |
| 2682 | will display the result as a fraction of hours (see the second formula in the | 2808 | will display the result as a fraction of hours (see the second formula in the |
| 2683 | example above). | 2809 | example above). |
| @@ -2741,7 +2867,7 @@ can also be used to assign a formula to some but not all fields in a row. | |||
| 2741 | Named field, see @ref{Advanced features}. | 2867 | Named field, see @ref{Advanced features}. |
| 2742 | @end table | 2868 | @end table |
| 2743 | 2869 | ||
| 2744 | @node Column formulas, Editing and debugging formulas, Field and range formulas, The spreadsheet | 2870 | @node Column formulas, Lookup functions, Field and range formulas, The spreadsheet |
| 2745 | @subsection Column formulas | 2871 | @subsection Column formulas |
| 2746 | @cindex column formula | 2872 | @cindex column formula |
| 2747 | @cindex formula, for table column | 2873 | @cindex formula, for table column |
| @@ -2749,10 +2875,13 @@ Named field, see @ref{Advanced features}. | |||
| 2749 | When you assign a formula to a simple column reference like @code{$3=}, the | 2875 | When you assign a formula to a simple column reference like @code{$3=}, the |
| 2750 | same formula will be used in all fields of that column, with the following | 2876 | same formula will be used in all fields of that column, with the following |
| 2751 | very convenient exceptions: (i) If the table contains horizontal separator | 2877 | very convenient exceptions: (i) If the table contains horizontal separator |
| 2752 | hlines, everything before the first such line is considered part of the table | 2878 | hlines with rows above and below, everything before the first such hline is |
| 2753 | @emph{header} and will not be modified by column formulas. (ii) Fields that | 2879 | considered part of the table @emph{header} and will not be modified by column |
| 2754 | already get a value from a field/range formula will be left alone by column | 2880 | formulas. Therefore a header is mandatory when you use column formulas and |
| 2755 | formulas. These conditions make column formulas very easy to use. | 2881 | want to add hlines to group rows, like for example to separate a total row at |
| 2882 | the bottom from the summand rows above. (ii) Fields that already get a value | ||
| 2883 | from a field/range formula will be left alone by column formulas. These | ||
| 2884 | conditions make column formulas very easy to use. | ||
| 2756 | 2885 | ||
| 2757 | To assign a formula to a column, type it directly into any field in the | 2886 | To assign a formula to a column, type it directly into any field in the |
| 2758 | column, preceded by an equal sign, like @samp{=$1+$2}. When you press | 2887 | column, preceded by an equal sign, like @samp{=$1+$2}. When you press |
| @@ -2777,19 +2906,62 @@ stores it. With a numeric prefix argument(e.g., @kbd{C-5 C-c =}) the command | |||
| 2777 | will apply it to that many consecutive fields in the current column. | 2906 | will apply it to that many consecutive fields in the current column. |
| 2778 | @end table | 2907 | @end table |
| 2779 | 2908 | ||
| 2780 | @node Editing and debugging formulas, Updating the table, Column formulas, The spreadsheet | 2909 | @node Lookup functions, Editing and debugging formulas, Column formulas, The spreadsheet |
| 2910 | @subsection Lookup functions | ||
| 2911 | @cindex lookup functions in tables | ||
| 2912 | @cindex table lookup functions | ||
| 2913 | |||
| 2914 | Org has three predefined Emacs Lisp functions for lookups in tables. | ||
| 2915 | @table @code | ||
| 2916 | @item (org-lookup-first VAL S-LIST R-LIST &optional PREDICATE) | ||
| 2917 | @findex org-lookup-first | ||
| 2918 | Searches for the first element @code{S} in list @code{S-LIST} for which | ||
| 2919 | @lisp | ||
| 2920 | (PREDICATE VAL S) | ||
| 2921 | @end lisp | ||
| 2922 | is @code{t}; returns the value from the corresponding position in list | ||
| 2923 | @code{R-LIST}. The default @code{PREDICATE} is @code{equal}. Note that the | ||
| 2924 | parameters @code{VAL} and @code{S} are passed to @code{PREDICATE} in the same | ||
| 2925 | order as the corresponding parameters are in the call to | ||
| 2926 | @code{org-lookup-first}, where @code{VAL} precedes @code{S-LIST}. If | ||
| 2927 | @code{R-LIST} is @code{nil}, the matching element @code{S} of @code{S-LIST} | ||
| 2928 | is returned. | ||
| 2929 | @item (org-lookup-last VAL S-LIST R-LIST &optional PREDICATE) | ||
| 2930 | @findex org-lookup-last | ||
| 2931 | Similar to @code{org-lookup-first} above, but searches for the @i{last} | ||
| 2932 | element for which @code{PREDICATE} is @code{t}. | ||
| 2933 | @item (org-lookup-all VAL S-LIST R-LIST &optional PREDICATE) | ||
| 2934 | @findex org-lookup-all | ||
| 2935 | Similar to @code{org-lookup-first}, but searches for @i{all} elements for | ||
| 2936 | which @code{PREDICATE} is @code{t}, and returns @i{all} corresponding | ||
| 2937 | values. This function can not be used by itself in a formula, because it | ||
| 2938 | returns a list of values. However, powerful lookups can be built when this | ||
| 2939 | function is combined with other Emacs Lisp functions. | ||
| 2940 | @end table | ||
| 2941 | |||
| 2942 | If the ranges used in these functions contain empty fields, the @code{E} mode | ||
| 2943 | for the formula should usually be specified: otherwise empty fields will not be | ||
| 2944 | included in @code{S-LIST} and/or @code{R-LIST} which can, for example, result | ||
| 2945 | in an incorrect mapping from an element of @code{S-LIST} to the corresponding | ||
| 2946 | element of @code{R-LIST}. | ||
| 2947 | |||
| 2948 | These three functions can be used to implement associative arrays, count | ||
| 2949 | matching cells, rank results, group data etc. For practical examples | ||
| 2950 | see @uref{http://orgmode.org/worg/org-tutorials/org-lookups.html, this | ||
| 2951 | tutorial on Worg}. | ||
| 2952 | |||
| 2953 | @node Editing and debugging formulas, Updating the table, Lookup functions, The spreadsheet | ||
| 2781 | @subsection Editing and debugging formulas | 2954 | @subsection Editing and debugging formulas |
| 2782 | @cindex formula editing | 2955 | @cindex formula editing |
| 2783 | @cindex editing, of table formulas | 2956 | @cindex editing, of table formulas |
| 2784 | 2957 | ||
| 2785 | @vindex org-table-use-standard-references | 2958 | @vindex org-table-use-standard-references |
| 2786 | You can edit individual formulas in the minibuffer or directly in the | 2959 | You can edit individual formulas in the minibuffer or directly in the field. |
| 2787 | field. Org can also prepare a special buffer with all active | 2960 | Org can also prepare a special buffer with all active formulas of a table. |
| 2788 | formulas of a table. When offering a formula for editing, Org | 2961 | When offering a formula for editing, Org converts references to the standard |
| 2789 | converts references to the standard format (like @code{B3} or @code{D&}) | 2962 | format (like @code{B3} or @code{D&}) if possible. If you prefer to only work |
| 2790 | if possible. If you prefer to only work with the internal format (like | 2963 | with the internal format (like @code{@@3$2} or @code{$4}), configure the |
| 2791 | @code{@@3$2} or @code{$4}), configure the variable | 2964 | option @code{org-table-use-standard-references}. |
| 2792 | @code{org-table-use-standard-references}. | ||
| 2793 | 2965 | ||
| 2794 | @table @kbd | 2966 | @table @kbd |
| 2795 | @orgcmdkkc{C-c =,C-u C-c =,org-table-eval-formula} | 2967 | @orgcmdkkc{C-c =,C-u C-c =,org-table-eval-formula} |
| @@ -2821,6 +2993,7 @@ active formula, the cursor in the formula editor will mark it. | |||
| 2821 | While inside the special buffer, Org will automatically highlight | 2993 | While inside the special buffer, Org will automatically highlight |
| 2822 | any field or range reference at the cursor position. You may edit, | 2994 | any field or range reference at the cursor position. You may edit, |
| 2823 | remove and add formulas, and use the following commands: | 2995 | remove and add formulas, and use the following commands: |
| 2996 | |||
| 2824 | @table @kbd | 2997 | @table @kbd |
| 2825 | @orgcmdkkc{C-c C-c,C-x C-s,org-table-fedit-finish} | 2998 | @orgcmdkkc{C-c C-c,C-x C-s,org-table-fedit-finish} |
| 2826 | Exit the formula editor and store the modified formulas. With @kbd{C-u} | 2999 | Exit the formula editor and store the modified formulas. With @kbd{C-u} |
| @@ -2872,6 +3045,52 @@ You may edit the @samp{#+TBLFM} directly and re-apply the changed | |||
| 2872 | equations with @kbd{C-c C-c} in that line or with the normal | 3045 | equations with @kbd{C-c C-c} in that line or with the normal |
| 2873 | recalculation commands in the table. | 3046 | recalculation commands in the table. |
| 2874 | 3047 | ||
| 3048 | @anchor{Using multiple #+TBLFM lines} | ||
| 3049 | @subsubheading Using multiple #+TBLFM lines | ||
| 3050 | @cindex #+TBLFM line, multiple | ||
| 3051 | @cindex #+TBLFM | ||
| 3052 | @cindex #+TBLFM, switching | ||
| 3053 | @kindex C-c C-c | ||
| 3054 | |||
| 3055 | You may apply the formula temporarily. This is useful when you | ||
| 3056 | switch the formula. Place multiple @samp{#+TBLFM} lines right | ||
| 3057 | after the table, and then press @kbd{C-c C-c} on the formula to | ||
| 3058 | apply. Here is an example: | ||
| 3059 | |||
| 3060 | @example | ||
| 3061 | | x | y | | ||
| 3062 | |---+---| | ||
| 3063 | | 1 | | | ||
| 3064 | | 2 | | | ||
| 3065 | #+TBLFM: $2=$1*1 | ||
| 3066 | #+TBLFM: $2=$1*2 | ||
| 3067 | @end example | ||
| 3068 | |||
| 3069 | @noindent | ||
| 3070 | Pressing @kbd{C-c C-c} in the line of @samp{#+TBLFM: $2=$1*2} yields: | ||
| 3071 | |||
| 3072 | @example | ||
| 3073 | | x | y | | ||
| 3074 | |---+---| | ||
| 3075 | | 1 | 2 | | ||
| 3076 | | 2 | 4 | | ||
| 3077 | #+TBLFM: $2=$1*1 | ||
| 3078 | #+TBLFM: $2=$1*2 | ||
| 3079 | @end example | ||
| 3080 | |||
| 3081 | @noindent | ||
| 3082 | Note: If you recalculate this table (with @kbd{C-u C-c *}, for example), you | ||
| 3083 | will get the following result of applying only the first @samp{#+TBLFM} line. | ||
| 3084 | |||
| 3085 | @example | ||
| 3086 | | x | y | | ||
| 3087 | |---+---| | ||
| 3088 | | 1 | 1 | | ||
| 3089 | | 2 | 2 | | ||
| 3090 | #+TBLFM: $2=$1*1 | ||
| 3091 | #+TBLFM: $2=$1*2 | ||
| 3092 | @end example | ||
| 3093 | |||
| 2875 | @subsubheading Debugging formulas | 3094 | @subsubheading Debugging formulas |
| 2876 | @cindex formula debugging | 3095 | @cindex formula debugging |
| 2877 | @cindex debugging, of table formulas | 3096 | @cindex debugging, of table formulas |
| @@ -2910,10 +3129,10 @@ hline are left alone, assuming that these are part of the table header. | |||
| 2910 | Iterate the table by recomputing it until no further changes occur. | 3129 | Iterate the table by recomputing it until no further changes occur. |
| 2911 | This may be necessary if some computed fields use the value of other | 3130 | This may be necessary if some computed fields use the value of other |
| 2912 | fields that are computed @i{later} in the calculation sequence. | 3131 | fields that are computed @i{later} in the calculation sequence. |
| 2913 | @item M-x org-table-recalculate-buffer-tables | 3132 | @item M-x org-table-recalculate-buffer-tables RET |
| 2914 | @findex org-table-recalculate-buffer-tables | 3133 | @findex org-table-recalculate-buffer-tables |
| 2915 | Recompute all tables in the current buffer. | 3134 | Recompute all tables in the current buffer. |
| 2916 | @item M-x org-table-iterate-buffer-tables | 3135 | @item M-x org-table-iterate-buffer-tables RET |
| 2917 | @findex org-table-iterate-buffer-tables | 3136 | @findex org-table-iterate-buffer-tables |
| 2918 | Iterate all tables in the current buffer, in order to converge table-to-table | 3137 | Iterate all tables in the current buffer, in order to converge table-to-table |
| 2919 | dependencies. | 3138 | dependencies. |
| @@ -2966,6 +3185,7 @@ empty first field. | |||
| 2966 | 3185 | ||
| 2967 | @cindex marking characters, tables | 3186 | @cindex marking characters, tables |
| 2968 | The marking characters have the following meaning: | 3187 | The marking characters have the following meaning: |
| 3188 | |||
| 2969 | @table @samp | 3189 | @table @samp |
| 2970 | @item ! | 3190 | @item ! |
| 2971 | The fields in this line define names for the columns, so that you may | 3191 | The fields in this line define names for the columns, so that you may |
| @@ -3167,10 +3387,8 @@ internal structure of all links, use the menu entry | |||
| 3167 | If the link does not look like a URL, it is considered to be internal in the | 3387 | If the link does not look like a URL, it is considered to be internal in the |
| 3168 | current file. The most important case is a link like | 3388 | current file. The most important case is a link like |
| 3169 | @samp{[[#my-custom-id]]} which will link to the entry with the | 3389 | @samp{[[#my-custom-id]]} which will link to the entry with the |
| 3170 | @code{CUSTOM_ID} property @samp{my-custom-id}. Such custom IDs are very good | 3390 | @code{CUSTOM_ID} property @samp{my-custom-id}. You are responsible yourself |
| 3171 | for HTML export (@pxref{HTML export}) where they produce pretty section | 3391 | to make sure these custom IDs are unique in a file. |
| 3172 | links. You are responsible yourself to make sure these custom IDs are unique | ||
| 3173 | in a file. | ||
| 3174 | 3392 | ||
| 3175 | Links such as @samp{[[My Target]]} or @samp{[[My Target][Find my target]]} | 3393 | Links such as @samp{[[My Target]]} or @samp{[[My Target][Find my target]]} |
| 3176 | lead to a text search in the current file. | 3394 | lead to a text search in the current file. |
| @@ -3178,27 +3396,48 @@ lead to a text search in the current file. | |||
| 3178 | The link can be followed with @kbd{C-c C-o} when the cursor is on the link, | 3396 | The link can be followed with @kbd{C-c C-o} when the cursor is on the link, |
| 3179 | or with a mouse click (@pxref{Handling links}). Links to custom IDs will | 3397 | or with a mouse click (@pxref{Handling links}). Links to custom IDs will |
| 3180 | point to the corresponding headline. The preferred match for a text link is | 3398 | point to the corresponding headline. The preferred match for a text link is |
| 3181 | a @i{dedicated target}: the same string in double angular brackets. Targets | 3399 | a @i{dedicated target}: the same string in double angular brackets, like |
| 3182 | may be located anywhere; sometimes it is convenient to put them into a | 3400 | @samp{<<My Target>>}. |
| 3183 | comment line. For example | 3401 | |
| 3402 | @cindex #+NAME | ||
| 3403 | If no dedicated target exists, the link will then try to match the exact name | ||
| 3404 | of an element within the buffer. Naming is done with the @code{#+NAME} | ||
| 3405 | keyword, which has to be put the line before the element it refers to, as in | ||
| 3406 | the following example | ||
| 3184 | 3407 | ||
| 3185 | @example | 3408 | @example |
| 3186 | # <<My Target>> | 3409 | #+NAME: My Target |
| 3410 | | a | table | | ||
| 3411 | |----+------------| | ||
| 3412 | | of | four cells | | ||
| 3187 | @end example | 3413 | @end example |
| 3188 | 3414 | ||
| 3189 | @noindent In HTML export (@pxref{HTML export}), such targets will become | 3415 | If none of the above succeeds, Org will search for a headline that is exactly |
| 3190 | named anchors for direct access through @samp{http} links@footnote{Note that | ||
| 3191 | text before the first headline is usually not exported, so the first such | ||
| 3192 | target should be after the first headline, or in the line directly before the | ||
| 3193 | first headline.}. | ||
| 3194 | |||
| 3195 | If no dedicated target exists, Org will search for a headline that is exactly | ||
| 3196 | the link text but may also include a TODO keyword and tags@footnote{To insert | 3416 | the link text but may also include a TODO keyword and tags@footnote{To insert |
| 3197 | a link targeting a headline, in-buffer completion can be used. Just type a | 3417 | a link targeting a headline, in-buffer completion can be used. Just type |
| 3198 | star followed by a few optional letters into the buffer and press | 3418 | a star followed by a few optional letters into the buffer and press |
| 3199 | @kbd{M-@key{TAB}}. All headlines in the current buffer will be offered as | 3419 | @kbd{M-@key{TAB}}. All headlines in the current buffer will be offered as |
| 3200 | completions.}. In non-Org files, the search will look for the words in the | 3420 | completions.}. |
| 3201 | link text. In the above example the search would be for @samp{my target}. | 3421 | |
| 3422 | During export, internal links will be used to mark objects and assign them | ||
| 3423 | a number. Marked objects will then be referenced by links pointing to them. | ||
| 3424 | In particular, links without a description will appear as the number assigned | ||
| 3425 | to the marked object@footnote{When targeting a @code{#+NAME} keyword, | ||
| 3426 | @code{#+CAPTION} keyword is mandatory in order to get proper numbering | ||
| 3427 | (@pxref{Images and tables}).}. In the following excerpt from an Org buffer | ||
| 3428 | |||
| 3429 | @example | ||
| 3430 | - one item | ||
| 3431 | - <<target>>another item | ||
| 3432 | Here we refer to item [[target]]. | ||
| 3433 | @end example | ||
| 3434 | |||
| 3435 | @noindent | ||
| 3436 | The last sentence will appear as @samp{Here we refer to item 2} when | ||
| 3437 | exported. | ||
| 3438 | |||
| 3439 | In non-Org files, the search will look for the words in the link text. In | ||
| 3440 | the above example the search would be for @samp{my target}. | ||
| 3202 | 3441 | ||
| 3203 | Following a link pushes a mark onto Org's own mark ring. You can | 3442 | Following a link pushes a mark onto Org's own mark ring. You can |
| 3204 | return to the previous position with @kbd{C-c &}. Using this command | 3443 | return to the previous position with @kbd{C-c &}. Using this command |
| @@ -3229,26 +3468,23 @@ cursor on or at a target. | |||
| 3229 | @section External links | 3468 | @section External links |
| 3230 | @cindex links, external | 3469 | @cindex links, external |
| 3231 | @cindex external links | 3470 | @cindex external links |
| 3232 | @cindex links, external | ||
| 3233 | @cindex Gnus links | 3471 | @cindex Gnus links |
| 3234 | @cindex BBDB links | 3472 | @cindex BBDB links |
| 3235 | @cindex IRC links | 3473 | @cindex IRC links |
| 3236 | @cindex URL links | 3474 | @cindex URL links |
| 3237 | @cindex file links | 3475 | @cindex file links |
| 3238 | @cindex VM links | ||
| 3239 | @cindex RMAIL links | 3476 | @cindex RMAIL links |
| 3240 | @cindex WANDERLUST links | ||
| 3241 | @cindex MH-E links | 3477 | @cindex MH-E links |
| 3242 | @cindex USENET links | 3478 | @cindex USENET links |
| 3243 | @cindex SHELL links | 3479 | @cindex SHELL links |
| 3244 | @cindex Info links | 3480 | @cindex Info links |
| 3245 | @cindex Elisp links | 3481 | @cindex Elisp links |
| 3246 | 3482 | ||
| 3247 | Org supports links to files, websites, Usenet and email messages, | 3483 | Org supports links to files, websites, Usenet and email messages, BBDB |
| 3248 | BBDB database entries and links to both IRC conversations and their | 3484 | database entries and links to both IRC conversations and their logs. |
| 3249 | logs. External links are URL-like locators. They start with a short | 3485 | External links are URL-like locators. They start with a short identifying |
| 3250 | identifying string followed by a colon. There can be no space after | 3486 | string followed by a colon. There can be no space after the colon. The |
| 3251 | the colon. The following list shows examples for each link type. | 3487 | following list shows examples for each link type. |
| 3252 | 3488 | ||
| 3253 | @example | 3489 | @example |
| 3254 | http://www.astro.uva.nl/~dominik @r{on the web} | 3490 | http://www.astro.uva.nl/~dominik @r{on the web} |
| @@ -3263,8 +3499,8 @@ file:sometextfile::NNN @r{file, jump to line number} | |||
| 3263 | file:projects.org @r{another Org file} | 3499 | file:projects.org @r{another Org file} |
| 3264 | file:projects.org::some words @r{text search in Org file}@footnote{ | 3500 | file:projects.org::some words @r{text search in Org file}@footnote{ |
| 3265 | The actual behavior of the search will depend on the value of | 3501 | The actual behavior of the search will depend on the value of |
| 3266 | the variable @code{org-link-search-must-match-exact-headline}. If its value | 3502 | the option @code{org-link-search-must-match-exact-headline}. If its value |
| 3267 | is nil, then a fuzzy text search will be done. If it is t, then only the | 3503 | is @code{nil}, then a fuzzy text search will be done. If it is t, then only the |
| 3268 | exact headline will be matched. If the value is @code{'query-to-create}, | 3504 | exact headline will be matched. If the value is @code{'query-to-create}, |
| 3269 | then an exact headline will be searched; if it is not found, then the user | 3505 | then an exact headline will be searched; if it is not found, then the user |
| 3270 | will be queried to create it.} | 3506 | will be queried to create it.} |
| @@ -3275,13 +3511,6 @@ docview:papers/last.pdf::NNN @r{open in doc-view mode at page} | |||
| 3275 | id:B7423F4D-2E8A-471B-8810-C40F074717E9 @r{Link to heading by ID} | 3511 | id:B7423F4D-2E8A-471B-8810-C40F074717E9 @r{Link to heading by ID} |
| 3276 | news:comp.emacs @r{Usenet link} | 3512 | news:comp.emacs @r{Usenet link} |
| 3277 | mailto:adent@@galaxy.net @r{Mail link} | 3513 | mailto:adent@@galaxy.net @r{Mail link} |
| 3278 | vm:folder @r{VM folder link} | ||
| 3279 | vm:folder#id @r{VM message link} | ||
| 3280 | vm://myself@@some.where.org/folder#id @r{VM on remote machine} | ||
| 3281 | vm-imap:account:folder @r{VM IMAP folder link} | ||
| 3282 | vm-imap:account:folder#id @r{VM IMAP message link} | ||
| 3283 | wl:folder @r{WANDERLUST folder link} | ||
| 3284 | wl:folder#id @r{WANDERLUST message link} | ||
| 3285 | mhe:folder @r{MH-E folder link} | 3514 | mhe:folder @r{MH-E folder link} |
| 3286 | mhe:folder#id @r{MH-E message link} | 3515 | mhe:folder#id @r{MH-E message link} |
| 3287 | rmail:folder @r{RMAIL folder link} | 3516 | rmail:folder @r{RMAIL folder link} |
| @@ -3296,11 +3525,27 @@ elisp:org-agenda @r{Interactive Elisp command} | |||
| 3296 | elisp:(find-file-other-frame "Elisp.org") @r{Elisp form to evaluate} | 3525 | elisp:(find-file-other-frame "Elisp.org") @r{Elisp form to evaluate} |
| 3297 | @end example | 3526 | @end example |
| 3298 | 3527 | ||
| 3528 | @cindex VM links | ||
| 3529 | @cindex WANDERLUST links | ||
| 3530 | On top of these built-in link types, some are available through the | ||
| 3531 | @code{contrib/} directory (@pxref{Installation}). For example, these links | ||
| 3532 | to VM or Wanderlust messages are available when you load the corresponding | ||
| 3533 | libraries from the @code{contrib/} directory: | ||
| 3534 | |||
| 3535 | @example | ||
| 3536 | vm:folder @r{VM folder link} | ||
| 3537 | vm:folder#id @r{VM message link} | ||
| 3538 | vm://myself@@some.where.org/folder#id @r{VM on remote machine} | ||
| 3539 | vm-imap:account:folder @r{VM IMAP folder link} | ||
| 3540 | vm-imap:account:folder#id @r{VM IMAP message link} | ||
| 3541 | wl:folder @r{WANDERLUST folder link} | ||
| 3542 | wl:folder#id @r{WANDERLUST message link} | ||
| 3543 | @end example | ||
| 3544 | |||
| 3299 | For customizing Org to add new link types @ref{Adding hyperlink types}. | 3545 | For customizing Org to add new link types @ref{Adding hyperlink types}. |
| 3300 | 3546 | ||
| 3301 | A link should be enclosed in double brackets and may contain a | 3547 | A link should be enclosed in double brackets and may contain a descriptive |
| 3302 | descriptive text to be displayed instead of the URL (@pxref{Link | 3548 | text to be displayed instead of the URL (@pxref{Link format}), for example: |
| 3303 | format}), for example: | ||
| 3304 | 3549 | ||
| 3305 | @example | 3550 | @example |
| 3306 | [[http://www.gnu.org/software/emacs/][GNU Emacs]] | 3551 | [[http://www.gnu.org/software/emacs/][GNU Emacs]] |
| @@ -3349,14 +3594,13 @@ timestamp in the headline.}. | |||
| 3349 | If the headline has a @code{CUSTOM_ID} property, a link to this custom ID | 3594 | If the headline has a @code{CUSTOM_ID} property, a link to this custom ID |
| 3350 | will be stored. In addition or alternatively (depending on the value of | 3595 | will be stored. In addition or alternatively (depending on the value of |
| 3351 | @code{org-id-link-to-org-use-id}), a globally unique @code{ID} property will | 3596 | @code{org-id-link-to-org-use-id}), a globally unique @code{ID} property will |
| 3352 | be created and/or used to construct a link@footnote{The library @code{org-id} | 3597 | be created and/or used to construct a link@footnote{The library |
| 3353 | must first be loaded, either through @code{org-customize} by enabling | 3598 | @file{org-id.el} must first be loaded, either through @code{org-customize} by |
| 3354 | @code{id} in @code{org-modules} , or by adding @code{(require 'org-id)} in | 3599 | enabling @code{org-id} in @code{org-modules}, or by adding @code{(require |
| 3355 | your @file{.emacs}.}. So using this command in Org | 3600 | 'org-id)} in your @file{.emacs}.}. So using this command in Org buffers will |
| 3356 | buffers will potentially create two links: a human-readable from the custom | 3601 | potentially create two links: a human-readable from the custom ID, and one |
| 3357 | ID, and one that is globally unique and works even if the entry is moved from | 3602 | that is globally unique and works even if the entry is moved from file to |
| 3358 | file to file. Later, when inserting the link, you need to decide which one | 3603 | file. Later, when inserting the link, you need to decide which one to use. |
| 3359 | to use. | ||
| 3360 | 3604 | ||
| 3361 | @b{Email/News clients: VM, Rmail, Wanderlust, MH-E, Gnus}@* | 3605 | @b{Email/News clients: VM, Rmail, Wanderlust, MH-E, Gnus}@* |
| 3362 | Pretty much all Emacs mail clients are supported. The link will point to the | 3606 | Pretty much all Emacs mail clients are supported. The link will point to the |
| @@ -3371,10 +3615,10 @@ Links created in a BBDB buffer will point to the current entry. | |||
| 3371 | 3615 | ||
| 3372 | @b{Chat: IRC}@* | 3616 | @b{Chat: IRC}@* |
| 3373 | @vindex org-irc-link-to-logs | 3617 | @vindex org-irc-link-to-logs |
| 3374 | For IRC links, if you set the variable @code{org-irc-link-to-logs} to | 3618 | For IRC links, if you set the option @code{org-irc-link-to-logs} to @code{t}, |
| 3375 | @code{t}, a @samp{file:/} style link to the relevant point in the logs for | 3619 | a @samp{file:/} style link to the relevant point in the logs for the current |
| 3376 | the current conversation is created. Otherwise an @samp{irc:/} style link to | 3620 | conversation is created. Otherwise an @samp{irc:/} style link to the |
| 3377 | the user/channel/server under the point will be stored. | 3621 | user/channel/server under the point will be stored. |
| 3378 | 3622 | ||
| 3379 | @b{Other files}@* | 3623 | @b{Other files}@* |
| 3380 | For any other files, the link will point to the file, with a search string | 3624 | For any other files, the link will point to the file, with a search string |
| @@ -3476,7 +3720,7 @@ would. Under Emacs 22 and later, @kbd{mouse-1} will also follow a link. | |||
| 3476 | @vindex org-display-internal-link-with-indirect-buffer | 3720 | @vindex org-display-internal-link-with-indirect-buffer |
| 3477 | Like @kbd{mouse-2}, but force file links to be opened with Emacs, and | 3721 | Like @kbd{mouse-2}, but force file links to be opened with Emacs, and |
| 3478 | internal links to be displayed in another window@footnote{See the | 3722 | internal links to be displayed in another window@footnote{See the |
| 3479 | variable @code{org-display-internal-link-with-indirect-buffer}}. | 3723 | option @code{org-display-internal-link-with-indirect-buffer}}. |
| 3480 | @c | 3724 | @c |
| 3481 | @orgcmd{C-c C-x C-v,org-toggle-inline-images} | 3725 | @orgcmd{C-c C-x C-v,org-toggle-inline-images} |
| 3482 | @cindex inlining images | 3726 | @cindex inlining images |
| @@ -3490,7 +3734,7 @@ be inlined during export. When called with a prefix argument, also display | |||
| 3490 | images that do have a link description. You can ask for inline images to be | 3734 | images that do have a link description. You can ask for inline images to be |
| 3491 | displayed at startup by configuring the variable | 3735 | displayed at startup by configuring the variable |
| 3492 | @code{org-startup-with-inline-images}@footnote{with corresponding | 3736 | @code{org-startup-with-inline-images}@footnote{with corresponding |
| 3493 | @code{#+STARTUP} keywords @code{inlineimages} and @code{inlineimages}}. | 3737 | @code{#+STARTUP} keywords @code{inlineimages} and @code{noinlineimages}}. |
| 3494 | @orgcmd{C-c %,org-mark-ring-push} | 3738 | @orgcmd{C-c %,org-mark-ring-push} |
| 3495 | @cindex mark ring | 3739 | @cindex mark ring |
| 3496 | Push the current position onto the mark ring, to be able to return | 3740 | Push the current position onto the mark ring, to be able to return |
| @@ -3728,7 +3972,7 @@ Rotate the TODO state of the current item among | |||
| 3728 | If TODO keywords have fast access keys (see @ref{Fast access to TODO | 3972 | If TODO keywords have fast access keys (see @ref{Fast access to TODO |
| 3729 | states}), you will be prompted for a TODO keyword through the fast selection | 3973 | states}), you will be prompted for a TODO keyword through the fast selection |
| 3730 | interface; this is the default behavior when | 3974 | interface; this is the default behavior when |
| 3731 | @var{org-use-fast-todo-selection} is @code{non-nil}. | 3975 | @code{org-use-fast-todo-selection} is non-@code{nil}. |
| 3732 | 3976 | ||
| 3733 | The same rotation can also be done ``remotely'' from the timeline and agenda | 3977 | The same rotation can also be done ``remotely'' from the timeline and agenda |
| 3734 | buffers with the @kbd{t} command key (@pxref{Agenda commands}). | 3978 | buffers with the @kbd{t} command key (@pxref{Agenda commands}). |
| @@ -3736,7 +3980,7 @@ buffers with the @kbd{t} command key (@pxref{Agenda commands}). | |||
| 3736 | @orgkey{C-u C-c C-t} | 3980 | @orgkey{C-u C-c C-t} |
| 3737 | When TODO keywords have no selection keys, select a specific keyword using | 3981 | When TODO keywords have no selection keys, select a specific keyword using |
| 3738 | completion; otherwise force cycling through TODO states with no prompt. When | 3982 | completion; otherwise force cycling through TODO states with no prompt. When |
| 3739 | @var{org-use-fast-todo-selection} is set to @code{prefix}, use the fast | 3983 | @code{org-use-fast-todo-selection} is set to @code{prefix}, use the fast |
| 3740 | selection interface. | 3984 | selection interface. |
| 3741 | 3985 | ||
| 3742 | @kindex S-@key{right} | 3986 | @kindex S-@key{right} |
| @@ -3754,12 +3998,11 @@ with @code{shift-selection-mode}. See also the variable | |||
| 3754 | View TODO items in a @emph{sparse tree} (@pxref{Sparse trees}). Folds the | 3998 | View TODO items in a @emph{sparse tree} (@pxref{Sparse trees}). Folds the |
| 3755 | entire buffer, but shows all TODO items (with not-DONE state) and the | 3999 | entire buffer, but shows all TODO items (with not-DONE state) and the |
| 3756 | headings hierarchy above them. With a prefix argument (or by using @kbd{C-c | 4000 | headings hierarchy above them. With a prefix argument (or by using @kbd{C-c |
| 3757 | / T}), search for a specific TODO@. You will be prompted for the keyword, and | 4001 | / T}), search for a specific TODO@. You will be prompted for the keyword, |
| 3758 | you can also give a list of keywords like @code{KWD1|KWD2|...} to list | 4002 | and you can also give a list of keywords like @code{KWD1|KWD2|...} to list |
| 3759 | entries that match any one of these keywords. With a numeric prefix argument | 4003 | entries that match any one of these keywords. With a numeric prefix argument |
| 3760 | N, show the tree for the Nth keyword in the variable | 4004 | N, show the tree for the Nth keyword in the option @code{org-todo-keywords}. |
| 3761 | @code{org-todo-keywords}. With two prefix arguments, find all TODO states, | 4005 | With two prefix arguments, find all TODO states, both un-done and done. |
| 3762 | both un-done and done. | ||
| 3763 | @orgcmd{C-c a t,org-todo-list} | 4006 | @orgcmd{C-c a t,org-todo-list} |
| 3764 | Show the global TODO list. Collects the TODO items (with not-DONE states) | 4007 | Show the global TODO list. Collects the TODO items (with not-DONE states) |
| 3765 | from all agenda files (@pxref{Agenda Views}) into a single buffer. The new | 4008 | from all agenda files (@pxref{Agenda Views}) into a single buffer. The new |
| @@ -3930,7 +4173,7 @@ each keyword, in parentheses@footnote{All characters are allowed except | |||
| 3930 | @vindex org-fast-tag-selection-include-todo | 4173 | @vindex org-fast-tag-selection-include-todo |
| 3931 | If you then press @kbd{C-c C-t} followed by the selection key, the entry | 4174 | If you then press @kbd{C-c C-t} followed by the selection key, the entry |
| 3932 | will be switched to this state. @kbd{SPC} can be used to remove any TODO | 4175 | will be switched to this state. @kbd{SPC} can be used to remove any TODO |
| 3933 | keyword from an entry.@footnote{Check also the variable | 4176 | keyword from an entry.@footnote{Check also the option |
| 3934 | @code{org-fast-tag-selection-include-todo}, it allows you to change the TODO | 4177 | @code{org-fast-tag-selection-include-todo}, it allows you to change the TODO |
| 3935 | state through the tags interface (@pxref{Setting tags}), in case you like to | 4178 | state through the tags interface (@pxref{Setting tags}), in case you like to |
| 3936 | mingle the two concepts. Note that this means you need to come up with | 4179 | mingle the two concepts. Note that this means you need to come up with |
| @@ -3994,7 +4237,7 @@ Org mode highlights TODO keywords with special faces: @code{org-todo} | |||
| 3994 | for keywords indicating that an item still has to be acted upon, and | 4237 | for keywords indicating that an item still has to be acted upon, and |
| 3995 | @code{org-done} for keywords indicating that an item is finished. If | 4238 | @code{org-done} for keywords indicating that an item is finished. If |
| 3996 | you are using more than 2 different states, you might want to use | 4239 | you are using more than 2 different states, you might want to use |
| 3997 | special faces for some of them. This can be done using the variable | 4240 | special faces for some of them. This can be done using the option |
| 3998 | @code{org-todo-keyword-faces}. For example: | 4241 | @code{org-todo-keyword-faces}. For example: |
| 3999 | 4242 | ||
| 4000 | @lisp | 4243 | @lisp |
| @@ -4007,7 +4250,7 @@ special faces for some of them. This can be done using the variable | |||
| 4007 | 4250 | ||
| 4008 | While using a list with face properties as shown for CANCELED @emph{should} | 4251 | While using a list with face properties as shown for CANCELED @emph{should} |
| 4009 | work, this does not always seem to be the case. If necessary, define a | 4252 | work, this does not always seem to be the case. If necessary, define a |
| 4010 | special face and use that. A string is interpreted as a color. The variable | 4253 | special face and use that. A string is interpreted as a color. The option |
| 4011 | @code{org-faces-easy-properties} determines if that color is interpreted as a | 4254 | @code{org-faces-easy-properties} determines if that color is interpreted as a |
| 4012 | foreground or a background color. | 4255 | foreground or a background color. |
| 4013 | 4256 | ||
| @@ -4023,7 +4266,7 @@ dependencies. Usually, a parent TODO task should not be marked DONE until | |||
| 4023 | all subtasks (defined as children tasks) are marked as DONE@. And sometimes | 4266 | all subtasks (defined as children tasks) are marked as DONE@. And sometimes |
| 4024 | there is a logical sequence to a number of (sub)tasks, so that one task | 4267 | there is a logical sequence to a number of (sub)tasks, so that one task |
| 4025 | cannot be acted upon before all siblings above it are done. If you customize | 4268 | cannot be acted upon before all siblings above it are done. If you customize |
| 4026 | the variable @code{org-enforce-todo-dependencies}, Org will block entries | 4269 | the option @code{org-enforce-todo-dependencies}, Org will block entries |
| 4027 | from changing state to DONE while they have children that are not DONE@. | 4270 | from changing state to DONE while they have children that are not DONE@. |
| 4028 | Furthermore, if an entry has a property @code{ORDERED}, each of its children | 4271 | Furthermore, if an entry has a property @code{ORDERED}, each of its children |
| 4029 | will be blocked until all earlier siblings are marked DONE@. Here is an | 4272 | will be blocked until all earlier siblings are marked DONE@. Here is an |
| @@ -4050,21 +4293,21 @@ example: | |||
| 4050 | Toggle the @code{ORDERED} property of the current entry. A property is used | 4293 | Toggle the @code{ORDERED} property of the current entry. A property is used |
| 4051 | for this behavior because this should be local to the current entry, not | 4294 | for this behavior because this should be local to the current entry, not |
| 4052 | inherited like a tag. However, if you would like to @i{track} the value of | 4295 | inherited like a tag. However, if you would like to @i{track} the value of |
| 4053 | this property with a tag for better visibility, customize the variable | 4296 | this property with a tag for better visibility, customize the option |
| 4054 | @code{org-track-ordered-property-with-tag}. | 4297 | @code{org-track-ordered-property-with-tag}. |
| 4055 | @orgkey{C-u C-u C-u C-c C-t} | 4298 | @orgkey{C-u C-u C-u C-c C-t} |
| 4056 | Change TODO state, circumventing any state blocking. | 4299 | Change TODO state, circumventing any state blocking. |
| 4057 | @end table | 4300 | @end table |
| 4058 | 4301 | ||
| 4059 | @vindex org-agenda-dim-blocked-tasks | 4302 | @vindex org-agenda-dim-blocked-tasks |
| 4060 | If you set the variable @code{org-agenda-dim-blocked-tasks}, TODO entries | 4303 | If you set the option @code{org-agenda-dim-blocked-tasks}, TODO entries |
| 4061 | that cannot be closed because of such dependencies will be shown in a dimmed | 4304 | that cannot be closed because of such dependencies will be shown in a dimmed |
| 4062 | font or even made invisible in agenda views (@pxref{Agenda Views}). | 4305 | font or even made invisible in agenda views (@pxref{Agenda Views}). |
| 4063 | 4306 | ||
| 4064 | @cindex checkboxes and TODO dependencies | 4307 | @cindex checkboxes and TODO dependencies |
| 4065 | @vindex org-enforce-todo-dependencies | 4308 | @vindex org-enforce-todo-dependencies |
| 4066 | You can also block changes of TODO states by looking at checkboxes | 4309 | You can also block changes of TODO states by looking at checkboxes |
| 4067 | (@pxref{Checkboxes}). If you set the variable | 4310 | (@pxref{Checkboxes}). If you set the option |
| 4068 | @code{org-enforce-todo-checkbox-dependencies}, an entry that has unchecked | 4311 | @code{org-enforce-todo-checkbox-dependencies}, an entry that has unchecked |
| 4069 | checkboxes will be blocked from switching to DONE. | 4312 | checkboxes will be blocked from switching to DONE. |
| 4070 | 4313 | ||
| @@ -4102,13 +4345,17 @@ in-buffer setting is: @code{#+STARTUP: logdone}} | |||
| 4102 | (setq org-log-done 'time) | 4345 | (setq org-log-done 'time) |
| 4103 | @end lisp | 4346 | @end lisp |
| 4104 | 4347 | ||
| 4348 | @vindex org-closed-keep-when-no-todo | ||
| 4105 | @noindent | 4349 | @noindent |
| 4106 | Then each time you turn an entry from a TODO (not-done) state into any | 4350 | Then each time you turn an entry from a TODO (not-done) state into any of the |
| 4107 | of the DONE states, a line @samp{CLOSED: [timestamp]} will be inserted | 4351 | DONE states, a line @samp{CLOSED: [timestamp]} will be inserted just after |
| 4108 | just after the headline. If you turn the entry back into a TODO item | 4352 | the headline. If you turn the entry back into a TODO item through further |
| 4109 | through further state cycling, that line will be removed again. If you | 4353 | state cycling, that line will be removed again. If you turn the entry back |
| 4110 | want to record a note along with the timestamp, use@footnote{The | 4354 | to a non-TODO state (by pressing @key{C-c C-t SPC} for example), that line |
| 4111 | corresponding in-buffer setting is: @code{#+STARTUP: lognotedone}} | 4355 | will also be removed, unless you set @code{org-closed-keep-when-no-todo} to |
| 4356 | non-@code{nil}. If you want to record a note along with the timestamp, | ||
| 4357 | use@footnote{The corresponding in-buffer setting is: @code{#+STARTUP: | ||
| 4358 | lognotedone}.} | ||
| 4112 | 4359 | ||
| 4113 | @lisp | 4360 | @lisp |
| 4114 | (setq org-log-done 'note) | 4361 | (setq org-log-done 'note) |
| @@ -4134,11 +4381,11 @@ When TODO keywords are used as workflow states (@pxref{Workflow states}), you | |||
| 4134 | might want to keep track of when a state change occurred and maybe take a | 4381 | might want to keep track of when a state change occurred and maybe take a |
| 4135 | note about this change. You can either record just a timestamp, or a | 4382 | note about this change. You can either record just a timestamp, or a |
| 4136 | time-stamped note for a change. These records will be inserted after the | 4383 | time-stamped note for a change. These records will be inserted after the |
| 4137 | headline as an itemized list, newest first@footnote{See the variable | 4384 | headline as an itemized list, newest first@footnote{See the option |
| 4138 | @code{org-log-states-order-reversed}}. When taking a lot of notes, you might | 4385 | @code{org-log-states-order-reversed}}. When taking a lot of notes, you might |
| 4139 | want to get the notes out of the way into a drawer (@pxref{Drawers}). | 4386 | want to get the notes out of the way into a drawer (@pxref{Drawers}). |
| 4140 | Customize the variable @code{org-log-into-drawer} to get this behavior---the | 4387 | Customize @code{org-log-into-drawer} to get this behavior---the recommended |
| 4141 | recommended drawer for this is called @code{LOGBOOK}@footnote{Note that the | 4388 | drawer for this is called @code{LOGBOOK}@footnote{Note that the |
| 4142 | @code{LOGBOOK} drawer is unfolded when pressing @key{SPC} in the agenda to | 4389 | @code{LOGBOOK} drawer is unfolded when pressing @key{SPC} in the agenda to |
| 4143 | show an entry---use @key{C-u SPC} to keep it folded here}. You can also | 4390 | show an entry---use @key{C-u SPC} to keep it folded here}. You can also |
| 4144 | overrule the setting of this variable for a subtree by setting a | 4391 | overrule the setting of this variable for a subtree by setting a |
| @@ -4186,7 +4433,7 @@ to a buffer: | |||
| 4186 | @cindex property, LOGGING | 4433 | @cindex property, LOGGING |
| 4187 | In order to define logging settings that are local to a subtree or a | 4434 | In order to define logging settings that are local to a subtree or a |
| 4188 | single item, define a LOGGING property in this entry. Any non-empty | 4435 | single item, define a LOGGING property in this entry. Any non-empty |
| 4189 | LOGGING property resets all logging settings to nil. You may then turn | 4436 | LOGGING property resets all logging settings to @code{nil}. You may then turn |
| 4190 | on logging for this specific tree using STARTUP keywords like | 4437 | on logging for this specific tree using STARTUP keywords like |
| 4191 | @code{lognotedone} or @code{logrepeat}, as well as adding state specific | 4438 | @code{lognotedone} or @code{logrepeat}, as well as adding state specific |
| 4192 | settings like @code{TODO(!)}. For example | 4439 | settings like @code{TODO(!)}. For example |
| @@ -4215,8 +4462,7 @@ called ``habits''. A habit has the following properties: | |||
| 4215 | 4462 | ||
| 4216 | @enumerate | 4463 | @enumerate |
| 4217 | @item | 4464 | @item |
| 4218 | You have enabled the @code{habits} module by customizing the variable | 4465 | You have enabled the @code{habits} module by customizing @code{org-modules}. |
| 4219 | @code{org-modules}. | ||
| 4220 | @item | 4466 | @item |
| 4221 | The habit is a TODO item, with a TODO keyword representing an open state. | 4467 | The habit is a TODO item, with a TODO keyword representing an open state. |
| 4222 | @item | 4468 | @item |
| @@ -4298,7 +4544,7 @@ The amount of history, in days before today, to appear in consistency graphs. | |||
| 4298 | @item org-habit-following-days | 4544 | @item org-habit-following-days |
| 4299 | The number of days after today that will appear in consistency graphs. | 4545 | The number of days after today that will appear in consistency graphs. |
| 4300 | @item org-habit-show-habits-only-for-today | 4546 | @item org-habit-show-habits-only-for-today |
| 4301 | If non-nil, only show habits in today's agenda view. This is set to true by | 4547 | If non-@code{nil}, only show habits in today's agenda view. This is set to true by |
| 4302 | default. | 4548 | default. |
| 4303 | @end table | 4549 | @end table |
| 4304 | 4550 | ||
| @@ -4326,7 +4572,7 @@ By default, Org mode supports three priorities: @samp{A}, @samp{B}, and | |||
| 4326 | treated just like priority @samp{B}. Priorities make a difference only for | 4572 | treated just like priority @samp{B}. Priorities make a difference only for |
| 4327 | sorting in the agenda (@pxref{Weekly/daily agenda}); outside the agenda, they | 4573 | sorting in the agenda (@pxref{Weekly/daily agenda}); outside the agenda, they |
| 4328 | have no inherent meaning to Org mode. The cookies can be highlighted with | 4574 | have no inherent meaning to Org mode. The cookies can be highlighted with |
| 4329 | special faces by customizing the variable @code{org-priority-faces}. | 4575 | special faces by customizing @code{org-priority-faces}. |
| 4330 | 4576 | ||
| 4331 | Priorities can be attached to any outline node; they do not need to be TODO | 4577 | Priorities can be attached to any outline node; they do not need to be TODO |
| 4332 | items. | 4578 | items. |
| @@ -4353,7 +4599,7 @@ also used to modify timestamps (@pxref{Creating timestamps}). See also | |||
| 4353 | @vindex org-highest-priority | 4599 | @vindex org-highest-priority |
| 4354 | @vindex org-lowest-priority | 4600 | @vindex org-lowest-priority |
| 4355 | @vindex org-default-priority | 4601 | @vindex org-default-priority |
| 4356 | You can change the range of allowed priorities by setting the variables | 4602 | You can change the range of allowed priorities by setting the options |
| 4357 | @code{org-highest-priority}, @code{org-lowest-priority}, and | 4603 | @code{org-highest-priority}, @code{org-lowest-priority}, and |
| 4358 | @code{org-default-priority}. For an individual buffer, you may set | 4604 | @code{org-default-priority}. For an individual buffer, you may set |
| 4359 | these values (highest, lowest, default) like this (please make sure that | 4605 | these values (highest, lowest, default) like this (please make sure that |
| @@ -4397,7 +4643,7 @@ this issue. | |||
| 4397 | 4643 | ||
| 4398 | @vindex org-hierarchical-todo-statistics | 4644 | @vindex org-hierarchical-todo-statistics |
| 4399 | If you would like to have the statistics cookie count any TODO entries in the | 4645 | If you would like to have the statistics cookie count any TODO entries in the |
| 4400 | subtree (not just direct children), configure the variable | 4646 | subtree (not just direct children), configure |
| 4401 | @code{org-hierarchical-todo-statistics}. To do this for a single subtree, | 4647 | @code{org-hierarchical-todo-statistics}. To do this for a single subtree, |
| 4402 | include the word @samp{recursive} into the value of the @code{COOKIE_DATA} | 4648 | include the word @samp{recursive} into the value of the @code{COOKIE_DATA} |
| 4403 | property. | 4649 | property. |
| @@ -4462,15 +4708,15 @@ checked. | |||
| 4462 | @cindex statistics, for checkboxes | 4708 | @cindex statistics, for checkboxes |
| 4463 | @cindex checkbox statistics | 4709 | @cindex checkbox statistics |
| 4464 | @cindex property, COOKIE_DATA | 4710 | @cindex property, COOKIE_DATA |
| 4465 | @vindex org-hierarchical-checkbox-statistics | 4711 | @vindex org-checkbox-hierarchical-statistics |
| 4466 | The @samp{[2/4]} and @samp{[1/3]} in the first and second line are cookies | 4712 | The @samp{[2/4]} and @samp{[1/3]} in the first and second line are cookies |
| 4467 | indicating how many checkboxes present in this entry have been checked off, | 4713 | indicating how many checkboxes present in this entry have been checked off, |
| 4468 | and the total number of checkboxes present. This can give you an idea on how | 4714 | and the total number of checkboxes present. This can give you an idea on how |
| 4469 | many checkboxes remain, even without opening a folded entry. The cookies can | 4715 | many checkboxes remain, even without opening a folded entry. The cookies can |
| 4470 | be placed into a headline or into (the first line of) a plain list item. | 4716 | be placed into a headline or into (the first line of) a plain list item. |
| 4471 | Each cookie covers checkboxes of direct children structurally below the | 4717 | Each cookie covers checkboxes of direct children structurally below the |
| 4472 | headline/item on which the cookie appears@footnote{Set the variable | 4718 | headline/item on which the cookie appears@footnote{Set the option |
| 4473 | @code{org-hierarchical-checkbox-statistics} if you want such cookies to | 4719 | @code{org-checkbox-hierarchical-statistics} if you want such cookies to |
| 4474 | count all checkboxes below the cookie, not just those belonging to direct | 4720 | count all checkboxes below the cookie, not just those belonging to direct |
| 4475 | children.}. You have to insert the cookie yourself by typing either | 4721 | children.}. You have to insert the cookie yourself by typing either |
| 4476 | @samp{[/]} or @samp{[%]}. With @samp{[/]} you get an @samp{n out of m} | 4722 | @samp{[/]} or @samp{[%]}. With @samp{[/]} you get an @samp{n out of m} |
| @@ -4522,8 +4768,7 @@ Toggle the @code{ORDERED} property of the entry, to toggle if checkboxes must | |||
| 4522 | be checked off in sequence. A property is used for this behavior because | 4768 | be checked off in sequence. A property is used for this behavior because |
| 4523 | this should be local to the current entry, not inherited like a tag. | 4769 | this should be local to the current entry, not inherited like a tag. |
| 4524 | However, if you would like to @i{track} the value of this property with a tag | 4770 | However, if you would like to @i{track} the value of this property with a tag |
| 4525 | for better visibility, customize the variable | 4771 | for better visibility, customize @code{org-track-ordered-property-with-tag}. |
| 4526 | @code{org-track-ordered-property-with-tag}. | ||
| 4527 | @orgcmd{C-c #,org-update-statistics-cookies} | 4772 | @orgcmd{C-c #,org-update-statistics-cookies} |
| 4528 | Update the statistics cookie in the current outline entry. When called with | 4773 | Update the statistics cookie in the current outline entry. When called with |
| 4529 | a @kbd{C-u} prefix, update the entire file. Checkbox statistic cookies are | 4774 | a @kbd{C-u} prefix, update the entire file. Checkbox statistic cookies are |
| @@ -4550,13 +4795,14 @@ headline. Tags are normal words containing letters, numbers, @samp{_}, and | |||
| 4550 | @samp{@@}. Tags must be preceded and followed by a single colon, e.g., | 4795 | @samp{@@}. Tags must be preceded and followed by a single colon, e.g., |
| 4551 | @samp{:work:}. Several tags can be specified, as in @samp{:work:urgent:}. | 4796 | @samp{:work:}. Several tags can be specified, as in @samp{:work:urgent:}. |
| 4552 | Tags will by default be in bold face with the same color as the headline. | 4797 | Tags will by default be in bold face with the same color as the headline. |
| 4553 | You may specify special faces for specific tags using the variable | 4798 | You may specify special faces for specific tags using the option |
| 4554 | @code{org-tag-faces}, in much the same way as you can for TODO keywords | 4799 | @code{org-tag-faces}, in much the same way as you can for TODO keywords |
| 4555 | (@pxref{Faces for TODO keywords}). | 4800 | (@pxref{Faces for TODO keywords}). |
| 4556 | 4801 | ||
| 4557 | @menu | 4802 | @menu |
| 4558 | * Tag inheritance:: Tags use the tree structure of the outline | 4803 | * Tag inheritance:: Tags use the tree structure of the outline |
| 4559 | * Setting tags:: How to assign tags to a headline | 4804 | * Setting tags:: How to assign tags to a headline |
| 4805 | * Tag groups:: Use one tag to search for several tags | ||
| 4560 | * Tag searches:: Searching for combinations of tags | 4806 | * Tag searches:: Searching for combinations of tags |
| 4561 | @end menu | 4807 | @end menu |
| 4562 | 4808 | ||
| @@ -4602,8 +4848,8 @@ on, all the sublevels in the same tree will (for a simple match form) match | |||
| 4602 | as well@footnote{This is only true if the search does not involve more | 4848 | as well@footnote{This is only true if the search does not involve more |
| 4603 | complex tests including properties (@pxref{Property searches}).}. The list | 4849 | complex tests including properties (@pxref{Property searches}).}. The list |
| 4604 | of matches may then become very long. If you only want to see the first tags | 4850 | of matches may then become very long. If you only want to see the first tags |
| 4605 | match in a subtree, configure the variable | 4851 | match in a subtree, configure @code{org-tags-match-list-sublevels} (not |
| 4606 | @code{org-tags-match-list-sublevels} (not recommended). | 4852 | recommended). |
| 4607 | 4853 | ||
| 4608 | @vindex org-agenda-use-tag-inheritance | 4854 | @vindex org-agenda-use-tag-inheritance |
| 4609 | Tag inheritance is relevant when the agenda search tries to match a tag, | 4855 | Tag inheritance is relevant when the agenda search tries to match a tag, |
| @@ -4611,10 +4857,10 @@ either in the @code{tags} or @code{tags-todo} agenda types. In other agenda | |||
| 4611 | types, @code{org-use-tag-inheritance} has no effect. Still, you may want to | 4857 | types, @code{org-use-tag-inheritance} has no effect. Still, you may want to |
| 4612 | have your tags correctly set in the agenda, so that tag filtering works fine, | 4858 | have your tags correctly set in the agenda, so that tag filtering works fine, |
| 4613 | with inherited tags. Set @code{org-agenda-use-tag-inheritance} to control | 4859 | with inherited tags. Set @code{org-agenda-use-tag-inheritance} to control |
| 4614 | this: the default value includes all agenda types, but setting this to nil | 4860 | this: the default value includes all agenda types, but setting this to @code{nil} |
| 4615 | can really speed up agenda generation. | 4861 | can really speed up agenda generation. |
| 4616 | 4862 | ||
| 4617 | @node Setting tags, Tag searches, Tag inheritance, Tags | 4863 | @node Setting tags, Tag groups, Tag inheritance, Tags |
| 4618 | @section Setting tags | 4864 | @section Setting tags |
| 4619 | @cindex setting tags | 4865 | @cindex setting tags |
| 4620 | @cindex tags, setting | 4866 | @cindex tags, setting |
| @@ -4635,6 +4881,7 @@ to @code{org-tags-column}. When called with a @kbd{C-u} prefix, all | |||
| 4635 | tags in the current buffer will be aligned to that column, just to make | 4881 | tags in the current buffer will be aligned to that column, just to make |
| 4636 | things look nice. TAGS are automatically realigned after promotion, | 4882 | things look nice. TAGS are automatically realigned after promotion, |
| 4637 | demotion, and TODO state changes (@pxref{TODO basics}). | 4883 | demotion, and TODO state changes (@pxref{TODO basics}). |
| 4884 | |||
| 4638 | @orgcmd{C-c C-c,org-set-tags-command} | 4885 | @orgcmd{C-c C-c,org-set-tags-command} |
| 4639 | When the cursor is in a headline, this does the same as @kbd{C-c C-q}. | 4886 | When the cursor is in a headline, this does the same as @kbd{C-c C-q}. |
| 4640 | @end table | 4887 | @end table |
| @@ -4722,7 +4969,7 @@ and @samp{@@tennisclub} should be selected. Multiple such groups are allowed. | |||
| 4722 | these lines to activate any changes. | 4969 | these lines to activate any changes. |
| 4723 | 4970 | ||
| 4724 | @noindent | 4971 | @noindent |
| 4725 | To set these mutually exclusive groups in the variable @code{org-tags-alist}, | 4972 | To set these mutually exclusive groups in the variable @code{org-tag-alist}, |
| 4726 | you must use the dummy tags @code{:startgroup} and @code{:endgroup} instead | 4973 | you must use the dummy tags @code{:startgroup} and @code{:endgroup} instead |
| 4727 | of the braces. Similarly, you can use @code{:newline} to indicate a line | 4974 | of the braces. Similarly, you can use @code{:newline} to indicate a line |
| 4728 | break. The previous example would be set globally by the following | 4975 | break. The previous example would be set globally by the following |
| @@ -4785,17 +5032,58 @@ alternatively with @kbd{C-c C-c C-c w}. Adding the non-predefined tag | |||
| 4785 | 5032 | ||
| 4786 | @vindex org-fast-tag-selection-single-key | 5033 | @vindex org-fast-tag-selection-single-key |
| 4787 | If you find that most of the time you need only a single key press to | 5034 | If you find that most of the time you need only a single key press to |
| 4788 | modify your list of tags, set the variable | 5035 | modify your list of tags, set @code{org-fast-tag-selection-single-key}. |
| 4789 | @code{org-fast-tag-selection-single-key}. Then you no longer have to | 5036 | Then you no longer have to press @key{RET} to exit fast tag selection---it |
| 4790 | press @key{RET} to exit fast tag selection---it will immediately exit | 5037 | will immediately exit after the first change. If you then occasionally |
| 4791 | after the first change. If you then occasionally need more keys, press | 5038 | need more keys, press @kbd{C-c} to turn off auto-exit for the current tag |
| 4792 | @kbd{C-c} to turn off auto-exit for the current tag selection process | 5039 | selection process (in effect: start selection with @kbd{C-c C-c C-c} |
| 4793 | (in effect: start selection with @kbd{C-c C-c C-c} instead of @kbd{C-c | 5040 | instead of @kbd{C-c C-c}). If you set the variable to the value |
| 4794 | C-c}). If you set the variable to the value @code{expert}, the special | 5041 | @code{expert}, the special window is not even shown for single-key tag |
| 4795 | window is not even shown for single-key tag selection, it comes up only | 5042 | selection, it comes up only when you press an extra @kbd{C-c}. |
| 4796 | when you press an extra @kbd{C-c}. | 5043 | |
| 4797 | 5044 | @node Tag groups, Tag searches, Setting tags, Tags | |
| 4798 | @node Tag searches, , Setting tags, Tags | 5045 | @section Tag groups |
| 5046 | |||
| 5047 | @cindex group tags | ||
| 5048 | @cindex tags, groups | ||
| 5049 | In a set of mutually exclusive tags, the first tag can be defined as a | ||
| 5050 | @emph{group tag}. When you search for a group tag, it will return matches | ||
| 5051 | for all members in the group. In an agenda view, filtering by a group tag | ||
| 5052 | will display headlines tagged with at least one of the members of the | ||
| 5053 | group. This makes tag searches and filters even more flexible. | ||
| 5054 | |||
| 5055 | You can set group tags by inserting a colon between the group tag and other | ||
| 5056 | tags---beware that all whitespaces are mandatory so that Org can parse this | ||
| 5057 | line correctly: | ||
| 5058 | |||
| 5059 | @example | ||
| 5060 | #+TAGS: @{ @@read : @@read_book @@read_ebook @} | ||
| 5061 | @end example | ||
| 5062 | |||
| 5063 | In this example, @samp{@@read} is a @emph{group tag} for a set of three | ||
| 5064 | tags: @samp{@@read}, @samp{@@read_book} and @samp{@@read_ebook}. | ||
| 5065 | |||
| 5066 | You can also use the @code{:grouptags} keyword directly when setting | ||
| 5067 | @code{org-tag-alist}: | ||
| 5068 | |||
| 5069 | @lisp | ||
| 5070 | (setq org-tag-alist '((:startgroup . nil) | ||
| 5071 | ("@@read" . nil) | ||
| 5072 | (:grouptags . nil) | ||
| 5073 | ("@@read_book" . nil) | ||
| 5074 | ("@@read_ebook" . nil) | ||
| 5075 | (:endgroup . nil))) | ||
| 5076 | @end lisp | ||
| 5077 | |||
| 5078 | You cannot nest group tags or use a group tag as a tag in another group. | ||
| 5079 | |||
| 5080 | @kindex C-c C-x q | ||
| 5081 | @vindex org-group-tags | ||
| 5082 | If you want to ignore group tags temporarily, toggle group tags support | ||
| 5083 | with @command{org-toggle-tags-groups}, bound to @kbd{C-c C-x q}. If you | ||
| 5084 | want to disable tag groups completely, set @code{org-group-tags} to @code{nil}. | ||
| 5085 | |||
| 5086 | @node Tag searches, , Tag groups, Tags | ||
| 4799 | @section Tag searches | 5087 | @section Tag searches |
| 4800 | @cindex tag searches | 5088 | @cindex tag searches |
| 4801 | @cindex searching for tags | 5089 | @cindex searching for tags |
| @@ -4805,15 +5093,16 @@ information into special lists. | |||
| 4805 | 5093 | ||
| 4806 | @table @kbd | 5094 | @table @kbd |
| 4807 | @orgcmdkkc{C-c / m,C-c \\,org-match-sparse-tree} | 5095 | @orgcmdkkc{C-c / m,C-c \\,org-match-sparse-tree} |
| 4808 | Create a sparse tree with all headlines matching a tags search. With a | 5096 | Create a sparse tree with all headlines matching a tags/property/TODO search. |
| 4809 | @kbd{C-u} prefix argument, ignore headlines that are not a TODO line. | 5097 | With a @kbd{C-u} prefix argument, ignore headlines that are not a TODO line. |
| 4810 | @orgcmd{C-c a m,org-tags-view} | ||
| 4811 | Create a global list of tag matches from all agenda files. | ||
| 4812 | @xref{Matching tags and properties}. | 5098 | @xref{Matching tags and properties}. |
| 5099 | @orgcmd{C-c a m,org-tags-view} | ||
| 5100 | Create a global list of tag matches from all agenda files. @xref{Matching | ||
| 5101 | tags and properties}. | ||
| 4813 | @orgcmd{C-c a M,org-tags-view} | 5102 | @orgcmd{C-c a M,org-tags-view} |
| 4814 | @vindex org-tags-match-list-sublevels | 5103 | @vindex org-tags-match-list-sublevels |
| 4815 | Create a global list of tag matches from all agenda files, but check | 5104 | Create a global list of tag matches from all agenda files, but check |
| 4816 | only TODO items and force checking subitems (see variable | 5105 | only TODO items and force checking subitems (see the option |
| 4817 | @code{org-tags-match-list-sublevels}). | 5106 | @code{org-tags-match-list-sublevels}). |
| 4818 | @end table | 5107 | @end table |
| 4819 | 5108 | ||
| @@ -4908,6 +5197,9 @@ file, use a line like | |||
| 4908 | #+PROPERTY: NDisks_ALL 1 2 3 4 | 5197 | #+PROPERTY: NDisks_ALL 1 2 3 4 |
| 4909 | @end example | 5198 | @end example |
| 4910 | 5199 | ||
| 5200 | Contrary to properties set from a special drawer, you have to refresh the | ||
| 5201 | buffer with @kbd{C-c C-c} to activate this changes. | ||
| 5202 | |||
| 4911 | If you want to add to the value of an existing property, append a @code{+} to | 5203 | If you want to add to the value of an existing property, append a @code{+} to |
| 4912 | the property name. The following results in the property @code{var} having | 5204 | the property name. The following results in the property @code{var} having |
| 4913 | the value ``foo=1 bar=2''. | 5205 | the value ``foo=1 bar=2''. |
| @@ -4954,7 +5246,7 @@ in the current file will be offered as possible completions. | |||
| 4954 | @orgcmd{C-c C-x p,org-set-property} | 5246 | @orgcmd{C-c C-x p,org-set-property} |
| 4955 | Set a property. This prompts for a property name and a value. If | 5247 | Set a property. This prompts for a property name and a value. If |
| 4956 | necessary, the property drawer is created as well. | 5248 | necessary, the property drawer is created as well. |
| 4957 | @item C-u M-x org-insert-drawer | 5249 | @item C-u M-x org-insert-drawer RET |
| 4958 | @cindex org-insert-drawer | 5250 | @cindex org-insert-drawer |
| 4959 | Insert a property drawer into the current entry. The drawer will be | 5251 | Insert a property drawer into the current entry. The drawer will be |
| 4960 | inserted early in the entry, but after the lines with planning | 5252 | inserted early in the entry, but after the lines with planning |
| @@ -5033,6 +5325,7 @@ FILE @r{The filename the entry is located in.} | |||
| 5033 | 5325 | ||
| 5034 | To create sparse trees and special lists with selection based on properties, | 5326 | To create sparse trees and special lists with selection based on properties, |
| 5035 | the same commands are used as for tag searches (@pxref{Tag searches}). | 5327 | the same commands are used as for tag searches (@pxref{Tag searches}). |
| 5328 | |||
| 5036 | @table @kbd | 5329 | @table @kbd |
| 5037 | @orgcmdkkc{C-c / m,C-c \\,org-match-sparse-tree} | 5330 | @orgcmdkkc{C-c / m,C-c \\,org-match-sparse-tree} |
| 5038 | Create a sparse tree with all matching entries. With a | 5331 | Create a sparse tree with all matching entries. With a |
| @@ -5043,7 +5336,7 @@ Create a global list of tag/property matches from all agenda files. | |||
| 5043 | @orgcmd{C-c a M,org-tags-view} | 5336 | @orgcmd{C-c a M,org-tags-view} |
| 5044 | @vindex org-tags-match-list-sublevels | 5337 | @vindex org-tags-match-list-sublevels |
| 5045 | Create a global list of tag matches from all agenda files, but check | 5338 | Create a global list of tag matches from all agenda files, but check |
| 5046 | only TODO items and force checking of subitems (see variable | 5339 | only TODO items and force checking of subitems (see the option |
| 5047 | @code{org-tags-match-list-sublevels}). | 5340 | @code{org-tags-match-list-sublevels}). |
| 5048 | @end table | 5341 | @end table |
| 5049 | 5342 | ||
| @@ -5077,7 +5370,7 @@ useful, you can turn it on by setting the variable | |||
| 5077 | @code{org-use-property-inheritance}. It may be set to @code{t} to make | 5370 | @code{org-use-property-inheritance}. It may be set to @code{t} to make |
| 5078 | all properties inherited from the parent, to a list of properties | 5371 | all properties inherited from the parent, to a list of properties |
| 5079 | that should be inherited, or to a regular expression that matches | 5372 | that should be inherited, or to a regular expression that matches |
| 5080 | inherited properties. If a property has the value @samp{nil}, this is | 5373 | inherited properties. If a property has the value @code{nil}, this is |
| 5081 | interpreted as an explicit undefine of the property, so that inheritance | 5374 | interpreted as an explicit undefine of the property, so that inheritance |
| 5082 | search will stop at this value and return @code{nil}. | 5375 | search will stop at this value and return @code{nil}. |
| 5083 | 5376 | ||
| @@ -5351,7 +5644,7 @@ global @r{make a global view, including all headings in the file} | |||
| 5351 | @r{run column view at the top of this file} | 5644 | @r{run column view at the top of this file} |
| 5352 | "@var{ID}" @r{call column view in the tree that has an @code{:ID:}} | 5645 | "@var{ID}" @r{call column view in the tree that has an @code{:ID:}} |
| 5353 | @r{property with the value @i{label}. You can use} | 5646 | @r{property with the value @i{label}. You can use} |
| 5354 | @r{@kbd{M-x org-id-copy} to create a globally unique ID for} | 5647 | @r{@kbd{M-x org-id-copy RET} to create a globally unique ID for} |
| 5355 | @r{the current entry and copy it to the kill-ring.} | 5648 | @r{the current entry and copy it to the kill-ring.} |
| 5356 | @end example | 5649 | @end example |
| 5357 | @item :hlines | 5650 | @item :hlines |
| @@ -5604,10 +5897,9 @@ the following column). | |||
| 5604 | @vindex org-read-date-prefer-future | 5897 | @vindex org-read-date-prefer-future |
| 5605 | When Org mode prompts for a date/time, the default is shown in default | 5898 | When Org mode prompts for a date/time, the default is shown in default |
| 5606 | date/time format, and the prompt therefore seems to ask for a specific | 5899 | date/time format, and the prompt therefore seems to ask for a specific |
| 5607 | format. But it will in fact accept any string containing some date and/or | 5900 | format. But it will in fact accept date/time information in a variety of |
| 5608 | time information, and it is really smart about interpreting your input. You | 5901 | formats. Generally, the information should start at the beginning of the |
| 5609 | can, for example, use @kbd{C-y} to paste a (possibly multi-line) string | 5902 | string. Org mode will find whatever information is in |
| 5610 | copied from an email message. Org mode will find whatever information is in | ||
| 5611 | there and derive anything you have not specified from the @emph{default date | 5903 | there and derive anything you have not specified from the @emph{default date |
| 5612 | and time}. The default is usually the current date and time, but when | 5904 | and time}. The default is usually the current date and time, but when |
| 5613 | modifying an existing timestamp, or when entering the second stamp of a | 5905 | modifying an existing timestamp, or when entering the second stamp of a |
| @@ -5630,7 +5922,7 @@ in @b{bold}. | |||
| 5630 | 14 @result{} @b{2006}-@b{06}-14 | 5922 | 14 @result{} @b{2006}-@b{06}-14 |
| 5631 | 12 @result{} @b{2006}-@b{07}-12 | 5923 | 12 @result{} @b{2006}-@b{07}-12 |
| 5632 | 2/5 @result{} @b{2007}-02-05 | 5924 | 2/5 @result{} @b{2007}-02-05 |
| 5633 | Fri @result{} nearest Friday (default date or later) | 5925 | Fri @result{} nearest Friday after the default date |
| 5634 | sep 15 @result{} @b{2006}-09-15 | 5926 | sep 15 @result{} @b{2006}-09-15 |
| 5635 | feb 15 @result{} @b{2007}-02-15 | 5927 | feb 15 @result{} @b{2007}-02-15 |
| 5636 | sep 12 9 @result{} 2009-09-12 | 5928 | sep 12 9 @result{} 2009-09-12 |
| @@ -5641,13 +5933,12 @@ w4 @result{} ISO week for of the current year @b{2006} | |||
| 5641 | 2012-w04-5 @result{} Same as above | 5933 | 2012-w04-5 @result{} Same as above |
| 5642 | @end example | 5934 | @end example |
| 5643 | 5935 | ||
| 5644 | Furthermore you can specify a relative date by giving, as the | 5936 | Furthermore you can specify a relative date by giving, as the @emph{first} |
| 5645 | @emph{first} thing in the input: a plus/minus sign, a number and a | 5937 | thing in the input: a plus/minus sign, a number and a letter ([hdwmy]) to |
| 5646 | letter ([dwmy]) to indicate change in days, weeks, months, or years. With a | 5938 | indicate change in hours, days, weeks, months, or years. With a single plus |
| 5647 | single plus or minus, the date is always relative to today. With a | 5939 | or minus, the date is always relative to today. With a double plus or minus, |
| 5648 | double plus or minus, it is relative to the default date. If instead of | 5940 | it is relative to the default date. If instead of a single letter, you use |
| 5649 | a single letter, you use the abbreviation of day name, the date will be | 5941 | the abbreviation of day name, the date will be the Nth such day, e.g.: |
| 5650 | the Nth such day, e.g.: | ||
| 5651 | 5942 | ||
| 5652 | @example | 5943 | @example |
| 5653 | +0 @result{} today | 5944 | +0 @result{} today |
| @@ -5656,7 +5947,8 @@ the Nth such day, e.g.: | |||
| 5656 | +4 @result{} same as above | 5947 | +4 @result{} same as above |
| 5657 | +2w @result{} two weeks from today | 5948 | +2w @result{} two weeks from today |
| 5658 | ++5 @result{} five days from default date | 5949 | ++5 @result{} five days from default date |
| 5659 | +2tue @result{} second Tuesday from now. | 5950 | +2tue @result{} second Tuesday from now |
| 5951 | -wed @result{} last Wednesday | ||
| 5660 | @end example | 5952 | @end example |
| 5661 | 5953 | ||
| 5662 | @vindex parse-time-months | 5954 | @vindex parse-time-months |
| @@ -5720,7 +6012,7 @@ The actions of the date/time prompt may seem complex, but I assure you they | |||
| 5720 | will grow on you, and you will start getting annoyed by pretty much any other | 6012 | will grow on you, and you will start getting annoyed by pretty much any other |
| 5721 | way of entering a date/time out there. To help you understand what is going | 6013 | way of entering a date/time out there. To help you understand what is going |
| 5722 | on, the current interpretation of your input will be displayed live in the | 6014 | on, the current interpretation of your input will be displayed live in the |
| 5723 | minibuffer@footnote{If you find this distracting, turn the display of with | 6015 | minibuffer@footnote{If you find this distracting, turn the display off with |
| 5724 | @code{org-read-date-display-live}.}. | 6016 | @code{org-read-date-display-live}.}. |
| 5725 | 6017 | ||
| 5726 | @node Custom time format, , The date/time prompt, Creating timestamps | 6018 | @node Custom time format, , The date/time prompt, Creating timestamps |
| @@ -5734,7 +6026,7 @@ minibuffer@footnote{If you find this distracting, turn the display of with | |||
| 5734 | Org mode uses the standard ISO notation for dates and times as it is | 6026 | Org mode uses the standard ISO notation for dates and times as it is |
| 5735 | defined in ISO 8601. If you cannot get used to this and require another | 6027 | defined in ISO 8601. If you cannot get used to this and require another |
| 5736 | representation of date and time to keep you happy, you can get it by | 6028 | representation of date and time to keep you happy, you can get it by |
| 5737 | customizing the variables @code{org-display-custom-times} and | 6029 | customizing the options @code{org-display-custom-times} and |
| 5738 | @code{org-time-stamp-custom-formats}. | 6030 | @code{org-time-stamp-custom-formats}. |
| 5739 | 6031 | ||
| 5740 | @table @kbd | 6032 | @table @kbd |
| @@ -5784,6 +6076,7 @@ Meaning: the task (most likely a TODO item, though not necessarily) is supposed | |||
| 5784 | to be finished on that date. | 6076 | to be finished on that date. |
| 5785 | 6077 | ||
| 5786 | @vindex org-deadline-warning-days | 6078 | @vindex org-deadline-warning-days |
| 6079 | @vindex org-agenda-skip-deadline-prewarning-if-scheduled | ||
| 5787 | On the deadline date, the task will be listed in the agenda. In | 6080 | On the deadline date, the task will be listed in the agenda. In |
| 5788 | addition, the agenda for @emph{today} will carry a warning about the | 6081 | addition, the agenda for @emph{today} will carry a warning about the |
| 5789 | approaching or missed deadline, starting | 6082 | approaching or missed deadline, starting |
| @@ -5798,7 +6091,9 @@ until the entry is marked DONE@. An example: | |||
| 5798 | 6091 | ||
| 5799 | You can specify a different lead time for warnings for a specific | 6092 | You can specify a different lead time for warnings for a specific |
| 5800 | deadlines using the following syntax. Here is an example with a warning | 6093 | deadlines using the following syntax. Here is an example with a warning |
| 5801 | period of 5 days @code{DEADLINE: <2004-02-29 Sun -5d>}. | 6094 | period of 5 days @code{DEADLINE: <2004-02-29 Sun -5d>}. This warning is |
| 6095 | deactivated if the task get scheduled and you set | ||
| 6096 | @code{org-agenda-skip-deadline-prewarning-if-scheduled} to @code{t}. | ||
| 5802 | 6097 | ||
| 5803 | @item SCHEDULED | 6098 | @item SCHEDULED |
| 5804 | @cindex SCHEDULED keyword | 6099 | @cindex SCHEDULED keyword |
| @@ -5819,6 +6114,17 @@ the task will automatically be forwarded until completed. | |||
| 5819 | SCHEDULED: <2004-12-25 Sat> | 6114 | SCHEDULED: <2004-12-25 Sat> |
| 5820 | @end example | 6115 | @end example |
| 5821 | 6116 | ||
| 6117 | @vindex org-scheduled-delay-days | ||
| 6118 | @vindex org-agenda-skip-scheduled-delay-if-deadline | ||
| 6119 | If you want to @emph{delay} the display of this task in the agenda, use | ||
| 6120 | @code{SCHEDULED: <2004-12-25 Sat -2d>}: the task is still scheduled on the | ||
| 6121 | 25th but will appear two days later. In case the task contains a repeater, | ||
| 6122 | the delay is considered to affect all occurrences; if you want the delay to | ||
| 6123 | only affect the first scheduled occurrence of the task, use @code{--2d} | ||
| 6124 | instead. See @code{org-scheduled-delay-days} and | ||
| 6125 | @code{org-agenda-skip-scheduled-delay-if-deadline} for details on how to | ||
| 6126 | control this globally or per agenda. | ||
| 6127 | |||
| 5822 | @noindent | 6128 | @noindent |
| 5823 | @b{Important:} Scheduling an item in Org mode should @i{not} be | 6129 | @b{Important:} Scheduling an item in Org mode should @i{not} be |
| 5824 | understood in the same way that we understand @i{scheduling a meeting}. | 6130 | understood in the same way that we understand @i{scheduling a meeting}. |
| @@ -5979,8 +6285,14 @@ special repeaters @samp{++} and @samp{.+}. For example: | |||
| 5979 | today. | 6285 | today. |
| 5980 | @end example | 6286 | @end example |
| 5981 | 6287 | ||
| 5982 | You may have both scheduling and deadline information for a specific | 6288 | @vindex org-agenda-skip-scheduled-if-deadline-is-shown |
| 5983 | task---just make sure that the repeater intervals on both are the same. | 6289 | You may have both scheduling and deadline information for a specific task. |
| 6290 | If the repeater is set for the scheduling information only, you probably want | ||
| 6291 | the repeater to be ignored after the deadline. If so, set the variable | ||
| 6292 | @code{org-agenda-skip-scheduled-if-deadline-is-shown} to | ||
| 6293 | @code{repeated-after-deadline}. If you want both scheduling and deadline | ||
| 6294 | information to repeat after the same interval, set the same repeater for both | ||
| 6295 | timestamps. | ||
| 5984 | 6296 | ||
| 5985 | An alternative to using a repeater is to create a number of copies of a task | 6297 | An alternative to using a repeater is to create a number of copies of a task |
| 5986 | subtree, with dates shifted in each copy. The command @kbd{C-c C-x c} was | 6298 | subtree, with dates shifted in each copy. The command @kbd{C-c C-x c} was |
| @@ -6192,7 +6504,14 @@ be selected: | |||
| 6192 | thisyear, lastyear, thisyear-@var{N} @r{a relative year} | 6504 | thisyear, lastyear, thisyear-@var{N} @r{a relative year} |
| 6193 | @r{Use @kbd{S-@key{left}/@key{right}} keys to shift the time interval.} | 6505 | @r{Use @kbd{S-@key{left}/@key{right}} keys to shift the time interval.} |
| 6194 | :tstart @r{A time string specifying when to start considering times.} | 6506 | :tstart @r{A time string specifying when to start considering times.} |
| 6507 | @r{Relative times like @code{"<-2w>"} can also be used. See} | ||
| 6508 | @r{@ref{Matching tags and properties} for relative time syntax.} | ||
| 6195 | :tend @r{A time string specifying when to stop considering times.} | 6509 | :tend @r{A time string specifying when to stop considering times.} |
| 6510 | @r{Relative times like @code{"<now>"} can also be used. See} | ||
| 6511 | @r{@ref{Matching tags and properties} for relative time syntax.} | ||
| 6512 | :wstart @r{The starting day of the week. The default is 1 for monday.} | ||
| 6513 | :mstart @r{The starting day of the month. The default 1 is for the first} | ||
| 6514 | @r{day of the month.} | ||
| 6196 | :step @r{@code{week} or @code{day}, to split the table into chunks.} | 6515 | :step @r{@code{week} or @code{day}, to split the table into chunks.} |
| 6197 | @r{To use this, @code{:block} or @code{:tstart}, @code{:tend} are needed.} | 6516 | @r{To use this, @code{:block} or @code{:tstart}, @code{:tend} are needed.} |
| 6198 | :stepskip0 @r{Do not show steps that have zero time.} | 6517 | :stepskip0 @r{Do not show steps that have zero time.} |
| @@ -6243,6 +6562,11 @@ only to fit it into the manual.} | |||
| 6243 | :tend "<2006-08-10 Thu 12:00>" | 6562 | :tend "<2006-08-10 Thu 12:00>" |
| 6244 | #+END: clocktable | 6563 | #+END: clocktable |
| 6245 | @end example | 6564 | @end example |
| 6565 | A range starting a week ago and ending right now could be written as | ||
| 6566 | @example | ||
| 6567 | #+BEGIN: clocktable :tstart "<-1w>" :tend "<now>" | ||
| 6568 | #+END: clocktable | ||
| 6569 | @end example | ||
| 6246 | A summary of the current subtree with % times would be | 6570 | A summary of the current subtree with % times would be |
| 6247 | @example | 6571 | @example |
| 6248 | #+BEGIN: clocktable :scope subtree :link t :formula % | 6572 | #+BEGIN: clocktable :scope subtree :link t :formula % |
| @@ -6260,6 +6584,7 @@ would be | |||
| 6260 | 6584 | ||
| 6261 | @subsubheading Resolving idle time | 6585 | @subsubheading Resolving idle time |
| 6262 | @cindex resolve idle time | 6586 | @cindex resolve idle time |
| 6587 | @vindex org-clock-x11idle-program-name | ||
| 6263 | 6588 | ||
| 6264 | @cindex idle, resolve, dangling | 6589 | @cindex idle, resolve, dangling |
| 6265 | If you clock in on a work item, and then walk away from your | 6590 | If you clock in on a work item, and then walk away from your |
| @@ -6273,12 +6598,14 @@ as 10 or 15, Emacs can alert you when you get back to your computer after | |||
| 6273 | being idle for that many minutes@footnote{On computers using Mac OS X, | 6598 | being idle for that many minutes@footnote{On computers using Mac OS X, |
| 6274 | idleness is based on actual user idleness, not just Emacs' idle time. For | 6599 | idleness is based on actual user idleness, not just Emacs' idle time. For |
| 6275 | X11, you can install a utility program @file{x11idle.c}, available in the | 6600 | X11, you can install a utility program @file{x11idle.c}, available in the |
| 6276 | @code{contrib/scripts} directory of the Org git distribution, to get the same | 6601 | @code{contrib/scripts} directory of the Org git distribution, or install the |
| 6277 | general treatment of idleness. On other systems, idle time refers to Emacs | 6602 | @file{xprintidle} package and set it to the variable |
| 6278 | idle time only.}, and ask what you want to do with the idle time. There will | 6603 | @code{org-clock-x11idle-program-name} if you are running Debian, to get the |
| 6279 | be a question waiting for you when you get back, indicating how much idle | 6604 | same general treatment of idleness. On other systems, idle time refers to |
| 6280 | time has passed (constantly updated with the current amount), as well as a | 6605 | Emacs idle time only.}, and ask what you want to do with the idle time. |
| 6281 | set of choices to correct the discrepancy: | 6606 | There will be a question waiting for you when you get back, indicating how |
| 6607 | much idle time has passed (constantly updated with the current amount), as | ||
| 6608 | well as a set of choices to correct the discrepancy: | ||
| 6282 | 6609 | ||
| 6283 | @table @kbd | 6610 | @table @kbd |
| 6284 | @item k | 6611 | @item k |
| @@ -6470,7 +6797,7 @@ trees to an archive file keeps the system compact and fast. | |||
| 6470 | * Attachments:: Add files to tasks | 6797 | * Attachments:: Add files to tasks |
| 6471 | * RSS Feeds:: Getting input from RSS feeds | 6798 | * RSS Feeds:: Getting input from RSS feeds |
| 6472 | * Protocols:: External (e.g., Browser) access to Emacs and Org | 6799 | * Protocols:: External (e.g., Browser) access to Emacs and Org |
| 6473 | * Refiling notes:: Moving a tree from one place to another | 6800 | * Refile and copy:: Moving/copying a tree from one place to another |
| 6474 | * Archiving:: What to do with finished projects | 6801 | * Archiving:: What to do with finished projects |
| 6475 | @end menu | 6802 | @end menu |
| 6476 | 6803 | ||
| @@ -6478,25 +6805,22 @@ trees to an archive file keeps the system compact and fast. | |||
| 6478 | @section Capture | 6805 | @section Capture |
| 6479 | @cindex capture | 6806 | @cindex capture |
| 6480 | 6807 | ||
| 6481 | Org's method for capturing new items is heavily inspired by John Wiegley | 6808 | Capture lets you quickly store notes with little interruption of your work |
| 6482 | excellent remember package. Up to version 6.36 Org used a special setup | 6809 | flow. Org's method for capturing new items is heavily inspired by John |
| 6483 | for @file{remember.el}. @file{org-remember.el} is still part of Org mode for | 6810 | Wiegley excellent @file{remember.el} package. Up to version 6.36, Org |
| 6484 | backward compatibility with existing setups. You can find the documentation | 6811 | used a special setup for @file{remember.el}, then replaced it with |
| 6485 | for org-remember at @url{http://orgmode.org/org-remember.pdf}. | 6812 | @file{org-remember.el}. As of version 8.0, @file{org-remember.el} has |
| 6813 | been completely replaced by @file{org-capture.el}. | ||
| 6486 | 6814 | ||
| 6487 | The new capturing setup described here is preferred and should be used by new | 6815 | If your configuration depends on @file{org-remember.el}, you need to update |
| 6488 | users. To convert your @code{org-remember-templates}, run the command | 6816 | it and use the setup described below. To convert your |
| 6817 | @code{org-remember-templates}, run the command | ||
| 6489 | @example | 6818 | @example |
| 6490 | @kbd{M-x org-capture-import-remember-templates @key{RET}} | 6819 | @kbd{M-x org-capture-import-remember-templates RET} |
| 6491 | @end example | 6820 | @end example |
| 6492 | @noindent and then customize the new variable with @kbd{M-x | 6821 | @noindent and then customize the new variable with @kbd{M-x |
| 6493 | customize-variable org-capture-templates}, check the result, and save the | 6822 | customize-variable org-capture-templates}, check the result, and save the |
| 6494 | customization. You can then use both remember and capture until | 6823 | customization. |
| 6495 | you are familiar with the new mechanism. | ||
| 6496 | |||
| 6497 | Capture lets you quickly store notes with little interruption of your work | ||
| 6498 | flow. The basic process of capturing is very similar to remember, but Org | ||
| 6499 | does enhance it with templates and more. | ||
| 6500 | 6824 | ||
| 6501 | @menu | 6825 | @menu |
| 6502 | * Setting up capture:: Where notes will be stored | 6826 | * Setting up capture:: Where notes will be stored |
| @@ -6512,10 +6836,12 @@ a global key@footnote{Please select your own key, @kbd{C-c c} is only a | |||
| 6512 | suggestion.} for capturing new material. | 6836 | suggestion.} for capturing new material. |
| 6513 | 6837 | ||
| 6514 | @vindex org-default-notes-file | 6838 | @vindex org-default-notes-file |
| 6515 | @example | 6839 | @smalllisp |
| 6840 | @group | ||
| 6516 | (setq org-default-notes-file (concat org-directory "/notes.org")) | 6841 | (setq org-default-notes-file (concat org-directory "/notes.org")) |
| 6517 | (define-key global-map "\C-cc" 'org-capture) | 6842 | (define-key global-map "\C-cc" 'org-capture) |
| 6518 | @end example | 6843 | @end group |
| 6844 | @end smalllisp | ||
| 6519 | 6845 | ||
| 6520 | @node Using capture, Capture templates, Setting up capture, Capture | 6846 | @node Using capture, Capture templates, Setting up capture, Capture |
| 6521 | @subsection Using capture | 6847 | @subsection Using capture |
| @@ -6537,7 +6863,7 @@ so that you can resume your work without further distraction. When called | |||
| 6537 | with a prefix arg, finalize and then jump to the captured item. | 6863 | with a prefix arg, finalize and then jump to the captured item. |
| 6538 | 6864 | ||
| 6539 | @orgcmd{C-c C-w,org-capture-refile} | 6865 | @orgcmd{C-c C-w,org-capture-refile} |
| 6540 | Finalize the capture process by refiling (@pxref{Refiling notes}) the note to | 6866 | Finalize the capture process by refiling (@pxref{Refile and copy}) the note to |
| 6541 | a different place. Please realize that this is a normal refiling command | 6867 | a different place. Please realize that this is a normal refiling command |
| 6542 | that will be executed---so the cursor position at the moment you run this | 6868 | that will be executed---so the cursor position at the moment you run this |
| 6543 | command is important. If you have inserted a tree with a parent and | 6869 | command is important. If you have inserted a tree with a parent and |
| @@ -6594,13 +6920,15 @@ your file @file{~/org/gtd.org}. Also, a date tree in the file | |||
| 6594 | @file{journal.org} should capture journal entries. A possible configuration | 6920 | @file{journal.org} should capture journal entries. A possible configuration |
| 6595 | would look like: | 6921 | would look like: |
| 6596 | 6922 | ||
| 6597 | @example | 6923 | @smalllisp |
| 6924 | @group | ||
| 6598 | (setq org-capture-templates | 6925 | (setq org-capture-templates |
| 6599 | '(("t" "Todo" entry (file+headline "~/org/gtd.org" "Tasks") | 6926 | '(("t" "Todo" entry (file+headline "~/org/gtd.org" "Tasks") |
| 6600 | "* TODO %?\n %i\n %a") | 6927 | "* TODO %?\n %i\n %a") |
| 6601 | ("j" "Journal" entry (file+datetree "~/org/journal.org") | 6928 | ("j" "Journal" entry (file+datetree "~/org/journal.org") |
| 6602 | "* %?\nEntered on %U\n %i\n %a"))) | 6929 | "* %?\nEntered on %U\n %i\n %a"))) |
| 6603 | @end example | 6930 | @end group |
| 6931 | @end smalllisp | ||
| 6604 | 6932 | ||
| 6605 | @noindent If you then press @kbd{C-c c t}, Org will prepare the template | 6933 | @noindent If you then press @kbd{C-c c t}, Org will prepare the template |
| 6606 | for you like this: | 6934 | for you like this: |
| @@ -6613,7 +6941,7 @@ for you like this: | |||
| 6613 | During expansion of the template, @code{%a} has been replaced by a link to | 6941 | During expansion of the template, @code{%a} has been replaced by a link to |
| 6614 | the location from where you called the capture command. This can be | 6942 | the location from where you called the capture command. This can be |
| 6615 | extremely useful for deriving tasks from emails, for example. You fill in | 6943 | extremely useful for deriving tasks from emails, for example. You fill in |
| 6616 | the task definition, press @code{C-c C-c} and Org returns you to the same | 6944 | the task definition, press @kbd{C-c C-c} and Org returns you to the same |
| 6617 | place where you started the capture process. | 6945 | place where you started the capture process. |
| 6618 | 6946 | ||
| 6619 | To define special keys to capture to a particular template without going | 6947 | To define special keys to capture to a particular template without going |
| @@ -6645,9 +6973,9 @@ single key, or @code{"bt"} for selection with two keys. When using | |||
| 6645 | several keys, keys using the same prefix key must be sequential | 6973 | several keys, keys using the same prefix key must be sequential |
| 6646 | in the list and preceded by a 2-element entry explaining the | 6974 | in the list and preceded by a 2-element entry explaining the |
| 6647 | prefix key, for example | 6975 | prefix key, for example |
| 6648 | @example | 6976 | @smalllisp |
| 6649 | ("b" "Templates for marking stuff to buy") | 6977 | ("b" "Templates for marking stuff to buy") |
| 6650 | @end example | 6978 | @end smalllisp |
| 6651 | @noindent If you do not define a template for the @kbd{C} key, this key will | 6979 | @noindent If you do not define a template for the @kbd{C} key, this key will |
| 6652 | be used to open the customize buffer for this complex variable. | 6980 | be used to open the customize buffer for this complex variable. |
| 6653 | 6981 | ||
| @@ -6657,6 +6985,7 @@ selection. | |||
| 6657 | 6985 | ||
| 6658 | @item type | 6986 | @item type |
| 6659 | The type of entry, a symbol. Valid values are: | 6987 | The type of entry, a symbol. Valid values are: |
| 6988 | |||
| 6660 | @table @code | 6989 | @table @code |
| 6661 | @item entry | 6990 | @item entry |
| 6662 | An Org mode node, with a headline. Will be filed as the child of the target | 6991 | An Org mode node, with a headline. Will be filed as the child of the target |
| @@ -6685,6 +7014,7 @@ the empty string, it defaults to @code{org-default-notes-file}. A file can | |||
| 6685 | also be given as a variable, function, or Emacs Lisp form. | 7014 | also be given as a variable, function, or Emacs Lisp form. |
| 6686 | 7015 | ||
| 6687 | Valid values are: | 7016 | Valid values are: |
| 7017 | |||
| 6688 | @table @code | 7018 | @table @code |
| 6689 | @item (file "path/to/file") | 7019 | @item (file "path/to/file") |
| 6690 | Text will be placed at the beginning or end of that file. | 7020 | Text will be placed at the beginning or end of that file. |
| @@ -6702,7 +7032,10 @@ For non-unique headings, the full path is safer. | |||
| 6702 | Use a regular expression to position the cursor. | 7032 | Use a regular expression to position the cursor. |
| 6703 | 7033 | ||
| 6704 | @item (file+datetree "path/to/file") | 7034 | @item (file+datetree "path/to/file") |
| 6705 | Will create a heading in a date tree for today's date. | 7035 | Will create a heading in a date tree for today's date@footnote{Datetree |
| 7036 | headlines for years accept tags, so if you use both @code{* 2013 :noexport:} | ||
| 7037 | and @code{* 2013} in your file, the capture will refile the note to the first | ||
| 7038 | one matched.}. | ||
| 6706 | 7039 | ||
| 6707 | @item (file+datetree+prompt "path/to/file") | 7040 | @item (file+datetree+prompt "path/to/file") |
| 6708 | Will create a heading in a date tree, but will prompt for the date. | 7041 | Will create a heading in a date tree, but will prompt for the date. |
| @@ -6729,6 +7062,7 @@ more details. | |||
| 6729 | @item properties | 7062 | @item properties |
| 6730 | The rest of the entry is a property list of additional options. | 7063 | The rest of the entry is a property list of additional options. |
| 6731 | Recognized properties are: | 7064 | Recognized properties are: |
| 7065 | |||
| 6732 | @table @code | 7066 | @table @code |
| 6733 | @item :prepend | 7067 | @item :prepend |
| 6734 | Normally new captured information will be appended at | 7068 | Normally new captured information will be appended at |
| @@ -6782,7 +7116,9 @@ dynamic insertion of content. The templates are expanded in the order given her | |||
| 6782 | @smallexample | 7116 | @smallexample |
| 6783 | %[@var{file}] @r{Insert the contents of the file given by @var{file}.} | 7117 | %[@var{file}] @r{Insert the contents of the file given by @var{file}.} |
| 6784 | %(@var{sexp}) @r{Evaluate Elisp @var{sexp} and replace with the result.} | 7118 | %(@var{sexp}) @r{Evaluate Elisp @var{sexp} and replace with the result.} |
| 6785 | @r{The sexp must return a string.} | 7119 | @r{For convenience, %:keyword (see below) placeholders} |
| 7120 | @r{within the expression will be expanded prior to this.} | ||
| 7121 | @r{The sexp must return a string.} | ||
| 6786 | %<...> @r{The result of format-time-string on the ... format specification.} | 7122 | %<...> @r{The result of format-time-string on the ... format specification.} |
| 6787 | %t @r{Timestamp, date only.} | 7123 | %t @r{Timestamp, date only.} |
| 6788 | %T @r{Timestamp, with date and time.} | 7124 | %T @r{Timestamp, with date and time.} |
| @@ -6855,22 +7191,22 @@ To place the cursor after template expansion use: | |||
| 6855 | 7191 | ||
| 6856 | @vindex org-capture-templates-contexts | 7192 | @vindex org-capture-templates-contexts |
| 6857 | To control whether a capture template should be accessible from a specific | 7193 | To control whether a capture template should be accessible from a specific |
| 6858 | context, you can customize @var{org-capture-templates-contexts}. Let's say | 7194 | context, you can customize @code{org-capture-templates-contexts}. Let's say |
| 6859 | for example that you have a capture template @code{"p"} for storing Gnus | 7195 | for example that you have a capture template @code{"p"} for storing Gnus |
| 6860 | emails containing patches. Then you would configure this option like this: | 7196 | emails containing patches. Then you would configure this option like this: |
| 6861 | 7197 | ||
| 6862 | @example | 7198 | @smalllisp |
| 6863 | (setq org-capture-templates-contexts | 7199 | (setq org-capture-templates-contexts |
| 6864 | '(("p" (in-mode . "message-mode")))) | 7200 | '(("p" (in-mode . "message-mode")))) |
| 6865 | @end example | 7201 | @end smalllisp |
| 6866 | 7202 | ||
| 6867 | You can also tell that the command key @code{"p"} should refer to another | 7203 | You can also tell that the command key @code{"p"} should refer to another |
| 6868 | template. In that case, add this command key like this: | 7204 | template. In that case, add this command key like this: |
| 6869 | 7205 | ||
| 6870 | @example | 7206 | @smalllisp |
| 6871 | (setq org-capture-templates-contexts | 7207 | (setq org-capture-templates-contexts |
| 6872 | '(("p" "q" (in-mode . "message-mode")))) | 7208 | '(("p" "q" (in-mode . "message-mode")))) |
| 6873 | @end example | 7209 | @end smalllisp |
| 6874 | 7210 | ||
| 6875 | See the docstring of the variable for more information. | 7211 | See the docstring of the variable for more information. |
| 6876 | 7212 | ||
| @@ -6901,7 +7237,6 @@ directory. | |||
| 6901 | @noindent The following commands deal with attachments: | 7237 | @noindent The following commands deal with attachments: |
| 6902 | 7238 | ||
| 6903 | @table @kbd | 7239 | @table @kbd |
| 6904 | |||
| 6905 | @orgcmd{C-c C-a,org-attach} | 7240 | @orgcmd{C-c C-a,org-attach} |
| 6906 | The dispatcher for commands related to the attachment system. After these | 7241 | The dispatcher for commands related to the attachment system. After these |
| 6907 | keys, a list of commands is displayed and you must press an additional key | 7242 | keys, a list of commands is displayed and you must press an additional key |
| @@ -6975,12 +7310,14 @@ web to import tasks into Org. To access feeds, configure the variable | |||
| 6975 | @code{org-feed-alist}. The docstring of this variable has detailed | 7310 | @code{org-feed-alist}. The docstring of this variable has detailed |
| 6976 | information. Here is just an example: | 7311 | information. Here is just an example: |
| 6977 | 7312 | ||
| 6978 | @example | 7313 | @smalllisp |
| 7314 | @group | ||
| 6979 | (setq org-feed-alist | 7315 | (setq org-feed-alist |
| 6980 | '(("Slashdot" | 7316 | '(("Slashdot" |
| 6981 | "http://rss.slashdot.org/Slashdot/slashdot" | 7317 | "http://rss.slashdot.org/Slashdot/slashdot" |
| 6982 | "~/txt/org/feeds.org" "Slashdot Entries"))) | 7318 | "~/txt/org/feeds.org" "Slashdot Entries"))) |
| 6983 | @end example | 7319 | @end group |
| 7320 | @end smalllisp | ||
| 6984 | 7321 | ||
| 6985 | @noindent | 7322 | @noindent |
| 6986 | will configure that new items from the feed provided by | 7323 | will configure that new items from the feed provided by |
| @@ -7009,7 +7346,7 @@ list of drawers in that file: | |||
| 7009 | For more information, including how to read atom feeds, see | 7346 | For more information, including how to read atom feeds, see |
| 7010 | @file{org-feed.el} and the docstring of @code{org-feed-alist}. | 7347 | @file{org-feed.el} and the docstring of @code{org-feed-alist}. |
| 7011 | 7348 | ||
| 7012 | @node Protocols, Refiling notes, RSS Feeds, Capture - Refile - Archive | 7349 | @node Protocols, Refile and copy, RSS Feeds, Capture - Refile - Archive |
| 7013 | @section Protocols for external access | 7350 | @section Protocols for external access |
| 7014 | @cindex protocols, for external access | 7351 | @cindex protocols, for external access |
| 7015 | @cindex emacsserver | 7352 | @cindex emacsserver |
| @@ -7023,17 +7360,22 @@ a remote website you are looking at with the browser. See | |||
| 7023 | @uref{http://orgmode.org/worg/org-contrib/org-protocol.php} for detailed | 7360 | @uref{http://orgmode.org/worg/org-contrib/org-protocol.php} for detailed |
| 7024 | documentation and setup instructions. | 7361 | documentation and setup instructions. |
| 7025 | 7362 | ||
| 7026 | @node Refiling notes, Archiving, Protocols, Capture - Refile - Archive | 7363 | @node Refile and copy, Archiving, Protocols, Capture - Refile - Archive |
| 7027 | @section Refiling notes | 7364 | @section Refile and copy |
| 7028 | @cindex refiling notes | 7365 | @cindex refiling notes |
| 7366 | @cindex copying notes | ||
| 7029 | 7367 | ||
| 7030 | When reviewing the captured data, you may want to refile some of the entries | 7368 | When reviewing the captured data, you may want to refile or to copy some of |
| 7031 | into a different list, for example into a project. Cutting, finding the | 7369 | the entries into a different list, for example into a project. Cutting, |
| 7032 | right location, and then pasting the note is cumbersome. To simplify this | 7370 | finding the right location, and then pasting the note is cumbersome. To |
| 7033 | process, you can use the following special command: | 7371 | simplify this process, you can use the following special command: |
| 7034 | 7372 | ||
| 7035 | @table @kbd | 7373 | @table @kbd |
| 7374 | @orgcmd{C-c M-w,org-copy} | ||
| 7375 | @findex org-copy | ||
| 7376 | Copying works like refiling, except that the original note is not deleted. | ||
| 7036 | @orgcmd{C-c C-w,org-refile} | 7377 | @orgcmd{C-c C-w,org-refile} |
| 7378 | @findex org-refile | ||
| 7037 | @vindex org-reverse-note-order | 7379 | @vindex org-reverse-note-order |
| 7038 | @vindex org-refile-targets | 7380 | @vindex org-refile-targets |
| 7039 | @vindex org-refile-use-outline-path | 7381 | @vindex org-refile-use-outline-path |
| @@ -7041,6 +7383,7 @@ process, you can use the following special command: | |||
| 7041 | @vindex org-refile-allow-creating-parent-nodes | 7383 | @vindex org-refile-allow-creating-parent-nodes |
| 7042 | @vindex org-log-refile | 7384 | @vindex org-log-refile |
| 7043 | @vindex org-refile-use-cache | 7385 | @vindex org-refile-use-cache |
| 7386 | @vindex org-refile-keep | ||
| 7044 | Refile the entry or region at point. This command offers possible locations | 7387 | Refile the entry or region at point. This command offers possible locations |
| 7045 | for refiling the entry and lets you select one with completion. The item (or | 7388 | for refiling the entry and lets you select one with completion. The item (or |
| 7046 | all items in the region) is filed below the target heading as a subitem. | 7389 | all items in the region) is filed below the target heading as a subitem. |
| @@ -7064,13 +7407,17 @@ Use the refile interface to jump to a heading. | |||
| 7064 | Jump to the location where @code{org-refile} last moved a tree to. | 7407 | Jump to the location where @code{org-refile} last moved a tree to. |
| 7065 | @item C-2 C-c C-w | 7408 | @item C-2 C-c C-w |
| 7066 | Refile as the child of the item currently being clocked. | 7409 | Refile as the child of the item currently being clocked. |
| 7410 | @item C-3 C-c C-w | ||
| 7411 | Refile and keep the entry in place. Also see @code{org-refile-keep} to make | ||
| 7412 | this the default behavior, and beware that this may result in duplicated | ||
| 7413 | @code{ID} properties. | ||
| 7067 | @orgcmdtkc{C-0 C-c C-w @ @r{or} @ C-u C-u C-u C-c C-w,C-0 C-c C-w,org-refile-cache-clear} | 7414 | @orgcmdtkc{C-0 C-c C-w @ @r{or} @ C-u C-u C-u C-c C-w,C-0 C-c C-w,org-refile-cache-clear} |
| 7068 | Clear the target cache. Caching of refile targets can be turned on by | 7415 | Clear the target cache. Caching of refile targets can be turned on by |
| 7069 | setting @code{org-refile-use-cache}. To make the command see new possible | 7416 | setting @code{org-refile-use-cache}. To make the command see new possible |
| 7070 | targets, you have to clear the cache with this command. | 7417 | targets, you have to clear the cache with this command. |
| 7071 | @end table | 7418 | @end table |
| 7072 | 7419 | ||
| 7073 | @node Archiving, , Refiling notes, Capture - Refile - Archive | 7420 | @node Archiving, , Refile and copy, Capture - Refile - Archive |
| 7074 | @section Archiving | 7421 | @section Archiving |
| 7075 | @cindex archiving | 7422 | @cindex archiving |
| 7076 | 7423 | ||
| @@ -7307,7 +7654,7 @@ Remove current file from the list of agenda files. | |||
| 7307 | @itemx C-, | 7654 | @itemx C-, |
| 7308 | Cycle through agenda file list, visiting one file after the other. | 7655 | Cycle through agenda file list, visiting one file after the other. |
| 7309 | @kindex M-x org-iswitchb | 7656 | @kindex M-x org-iswitchb |
| 7310 | @item M-x org-iswitchb | 7657 | @item M-x org-iswitchb RET |
| 7311 | Command to use an @code{iswitchb}-like interface to switch to and between Org | 7658 | Command to use an @code{iswitchb}-like interface to switch to and between Org |
| 7312 | buffers. | 7659 | buffers. |
| 7313 | @end table | 7660 | @end table |
| @@ -7338,6 +7685,7 @@ Remove the permanent restriction created by @kbd{C-c C-x <}. | |||
| 7338 | @noindent | 7685 | @noindent |
| 7339 | When working with @file{speedbar.el}, you can use the following commands in | 7686 | When working with @file{speedbar.el}, you can use the following commands in |
| 7340 | the Speedbar frame: | 7687 | the Speedbar frame: |
| 7688 | |||
| 7341 | @table @kbd | 7689 | @table @kbd |
| 7342 | @orgcmdtkc{< @r{in the speedbar frame},<,org-speedbar-set-agenda-restriction} | 7690 | @orgcmdtkc{< @r{in the speedbar frame},<,org-speedbar-set-agenda-restriction} |
| 7343 | Permanently restrict the agenda to the item---either an Org file or a subtree | 7691 | Permanently restrict the agenda to the item---either an Org file or a subtree |
| @@ -7358,6 +7706,7 @@ following we will assume that @kbd{C-c a} is indeed how the dispatcher | |||
| 7358 | is accessed and list keyboard access to commands accordingly. After | 7706 | is accessed and list keyboard access to commands accordingly. After |
| 7359 | pressing @kbd{C-c a}, an additional letter is required to execute a | 7707 | pressing @kbd{C-c a}, an additional letter is required to execute a |
| 7360 | command. The dispatcher offers the following default commands: | 7708 | command. The dispatcher offers the following default commands: |
| 7709 | |||
| 7361 | @table @kbd | 7710 | @table @kbd |
| 7362 | @item a | 7711 | @item a |
| 7363 | Create the calendar-like agenda (@pxref{Weekly/daily agenda}). | 7712 | Create the calendar-like agenda (@pxref{Weekly/daily agenda}). |
| @@ -7446,11 +7795,16 @@ C-c a a}) you may set the number of days to be displayed. | |||
| 7446 | 7795 | ||
| 7447 | @vindex org-agenda-span | 7796 | @vindex org-agenda-span |
| 7448 | @vindex org-agenda-ndays | 7797 | @vindex org-agenda-ndays |
| 7798 | @vindex org-agenda-start-day | ||
| 7799 | @vindex org-agenda-start-on-weekday | ||
| 7449 | The default number of days displayed in the agenda is set by the variable | 7800 | The default number of days displayed in the agenda is set by the variable |
| 7450 | @code{org-agenda-span} (or the obsolete @code{org-agenda-ndays}). This | 7801 | @code{org-agenda-span} (or the obsolete @code{org-agenda-ndays}). This |
| 7451 | variable can be set to any number of days you want to see by default in the | 7802 | variable can be set to any number of days you want to see by default in the |
| 7452 | agenda, or to a span name, such a @code{day}, @code{week}, @code{month} or | 7803 | agenda, or to a span name, such as @code{day}, @code{week}, @code{month} or |
| 7453 | @code{year}. | 7804 | @code{year}. For weekly agendas, the default is to start on the previous |
| 7805 | monday (see @code{org-agenda-start-on-weekday}). You can also set the start | ||
| 7806 | date using a date shift: @code{(setq org-agenda-start-day "+10d")} will | ||
| 7807 | start the agenda ten days from today in the future. | ||
| 7454 | 7808 | ||
| 7455 | Remote editing from the agenda buffer means, for example, that you can | 7809 | Remote editing from the agenda buffer means, for example, that you can |
| 7456 | change the dates of deadlines and appointments from the agenda buffer. | 7810 | change the dates of deadlines and appointments from the agenda buffer. |
| @@ -7656,16 +8010,21 @@ commands}. | |||
| 7656 | @subsubheading Match syntax | 8010 | @subsubheading Match syntax |
| 7657 | 8011 | ||
| 7658 | @cindex Boolean logic, for tag/property searches | 8012 | @cindex Boolean logic, for tag/property searches |
| 7659 | A search string can use Boolean operators @samp{&} for AND and @samp{|} for | 8013 | A search string can use Boolean operators @samp{&} for @code{AND} and |
| 7660 | OR@. @samp{&} binds more strongly than @samp{|}. Parentheses are currently | 8014 | @samp{|} for @code{OR}@. @samp{&} binds more strongly than @samp{|}. |
| 7661 | not implemented. Each element in the search is either a tag, a regular | 8015 | Parentheses are not implemented. Each element in the search is either a |
| 7662 | expression matching tags, or an expression like @code{PROPERTY OPERATOR | 8016 | tag, a regular expression matching tags, or an expression like |
| 7663 | VALUE} with a comparison operator, accessing a property value. Each element | 8017 | @code{PROPERTY OPERATOR VALUE} with a comparison operator, accessing a |
| 7664 | may be preceded by @samp{-}, to select against it, and @samp{+} is syntactic | 8018 | property value. Each element may be preceded by @samp{-}, to select |
| 7665 | sugar for positive selection. The AND operator @samp{&} is optional when | 8019 | against it, and @samp{+} is syntactic sugar for positive selection. The |
| 7666 | @samp{+} or @samp{-} is present. Here are some examples, using only tags. | 8020 | @code{AND} operator @samp{&} is optional when @samp{+} or @samp{-} is |
| 8021 | present. Here are some examples, using only tags. | ||
| 7667 | 8022 | ||
| 7668 | @table @samp | 8023 | @table @samp |
| 8024 | @item work | ||
| 8025 | Select headlines tagged @samp{:work:}. | ||
| 8026 | @item work&boss | ||
| 8027 | Select headlines tagged @samp{:work:} and @samp{:boss:}. | ||
| 7669 | @item +work-boss | 8028 | @item +work-boss |
| 7670 | Select headlines tagged @samp{:work:}, but discard those also tagged | 8029 | Select headlines tagged @samp{:work:}, but discard those also tagged |
| 7671 | @samp{:boss:}. | 8030 | @samp{:boss:}. |
| @@ -7682,6 +8041,13 @@ braces. For example, | |||
| 7682 | @samp{work+@{^boss.*@}} matches headlines that contain the tag | 8041 | @samp{work+@{^boss.*@}} matches headlines that contain the tag |
| 7683 | @samp{:work:} and any tag @i{starting} with @samp{boss}. | 8042 | @samp{:work:} and any tag @i{starting} with @samp{boss}. |
| 7684 | 8043 | ||
| 8044 | @cindex group tags, as regular expressions | ||
| 8045 | Group tags (@pxref{Tag groups}) are expanded as regular expressions. E.g., | ||
| 8046 | if @samp{:work:} is a group tag for the group @samp{:work:lab:conf:}, then | ||
| 8047 | searching for @samp{work} will search for @samp{@{\(?:work\|lab\|conf\)@}} | ||
| 8048 | and searching for @samp{-work} will search for all headlines but those with | ||
| 8049 | one of the tag in the group (i.e., @samp{-@{\(?:work\|lab\|conf\)@}}). | ||
| 8050 | |||
| 7685 | @cindex TODO keyword matching, with tags search | 8051 | @cindex TODO keyword matching, with tags search |
| 7686 | @cindex level, require for tags/property match | 8052 | @cindex level, require for tags/property match |
| 7687 | @cindex category, require for tags/property match | 8053 | @cindex category, require for tags/property match |
| @@ -7690,16 +8056,20 @@ You may also test for properties (@pxref{Properties and Columns}) at the same | |||
| 7690 | time as matching tags. The properties may be real properties, or special | 8056 | time as matching tags. The properties may be real properties, or special |
| 7691 | properties that represent other metadata (@pxref{Special properties}). For | 8057 | properties that represent other metadata (@pxref{Special properties}). For |
| 7692 | example, the ``property'' @code{TODO} represents the TODO keyword of the | 8058 | example, the ``property'' @code{TODO} represents the TODO keyword of the |
| 7693 | entry. Or, the ``property'' @code{LEVEL} represents the level of an entry. | 8059 | entry and the ``propety'' @code{PRIORITY} represents the PRIORITY keyword of |
| 7694 | So a search @samp{+LEVEL=3+boss-TODO="DONE"} lists all level three headlines | 8060 | the entry. The ITEM special property cannot currently be used in tags/property |
| 7695 | that have the tag @samp{boss} and are @emph{not} marked with the TODO keyword | ||
| 7696 | DONE@. In buffers with @code{org-odd-levels-only} set, @samp{LEVEL} does not | ||
| 7697 | count the number of stars, but @samp{LEVEL=2} will correspond to 3 stars etc. | ||
| 7698 | The ITEM special property cannot currently be used in tags/property | ||
| 7699 | searches@footnote{But @pxref{x-agenda-skip-entry-regexp, | 8061 | searches@footnote{But @pxref{x-agenda-skip-entry-regexp, |
| 7700 | ,skipping entries based on regexp}.}. | 8062 | ,skipping entries based on regexp}.}. |
| 7701 | 8063 | ||
| 8064 | Except the @pxref{Special properties}, one other ``property'' can also be | ||
| 8065 | used. @code{LEVEL} represents the level of an entry. So a search | ||
| 8066 | @samp{+LEVEL=3+boss-TODO="DONE"} lists all level three headlines that have | ||
| 8067 | the tag @samp{boss} and are @emph{not} marked with the TODO keyword DONE@. | ||
| 8068 | In buffers with @code{org-odd-levels-only} set, @samp{LEVEL} does not count | ||
| 8069 | the number of stars, but @samp{LEVEL=2} will correspond to 3 stars etc. | ||
| 8070 | |||
| 7702 | Here are more examples: | 8071 | Here are more examples: |
| 8072 | |||
| 7703 | @table @samp | 8073 | @table @samp |
| 7704 | @item work+TODO="WAITING" | 8074 | @item work+TODO="WAITING" |
| 7705 | Select @samp{:work:}-tagged TODO lines with the specific TODO | 8075 | Select @samp{:work:}-tagged TODO lines with the specific TODO |
| @@ -7899,7 +8269,8 @@ associated with the item. | |||
| 7899 | @menu | 8269 | @menu |
| 7900 | * Categories:: Not all tasks are equal | 8270 | * Categories:: Not all tasks are equal |
| 7901 | * Time-of-day specifications:: How the agenda knows the time | 8271 | * Time-of-day specifications:: How the agenda knows the time |
| 7902 | * Sorting of agenda items:: The order of things | 8272 | * Sorting agenda items:: The order of things |
| 8273 | * Filtering/limiting agenda items:: Dynamically narrow the agenda | ||
| 7903 | @end menu | 8274 | @end menu |
| 7904 | 8275 | ||
| 7905 | @node Categories, Time-of-day specifications, Presentation and sorting, Presentation and sorting | 8276 | @node Categories, Time-of-day specifications, Presentation and sorting, Presentation and sorting |
| @@ -7936,7 +8307,7 @@ longer than 10 characters. | |||
| 7936 | You can set up icons for category by customizing the | 8307 | You can set up icons for category by customizing the |
| 7937 | @code{org-agenda-category-icon-alist} variable. | 8308 | @code{org-agenda-category-icon-alist} variable. |
| 7938 | 8309 | ||
| 7939 | @node Time-of-day specifications, Sorting of agenda items, Categories, Presentation and sorting | 8310 | @node Time-of-day specifications, Sorting agenda items, Categories, Presentation and sorting |
| 7940 | @subsection Time-of-day specifications | 8311 | @subsection Time-of-day specifications |
| 7941 | @cindex time-of-day specification | 8312 | @cindex time-of-day specification |
| 7942 | 8313 | ||
| @@ -7987,8 +8358,8 @@ The time grid can be turned on and off with the variable | |||
| 7987 | @code{org-agenda-use-time-grid}, and can be configured with | 8358 | @code{org-agenda-use-time-grid}, and can be configured with |
| 7988 | @code{org-agenda-time-grid}. | 8359 | @code{org-agenda-time-grid}. |
| 7989 | 8360 | ||
| 7990 | @node Sorting of agenda items, , Time-of-day specifications, Presentation and sorting | 8361 | @node Sorting agenda items, Filtering/limiting agenda items, Time-of-day specifications, Presentation and sorting |
| 7991 | @subsection Sorting of agenda items | 8362 | @subsection Sorting agenda items |
| 7992 | @cindex sorting, of agenda items | 8363 | @cindex sorting, of agenda items |
| 7993 | @cindex priorities, of agenda items | 8364 | @cindex priorities, of agenda items |
| 7994 | Before being inserted into a view, the items are sorted. How this is | 8365 | Before being inserted into a view, the items are sorted. How this is |
| @@ -8021,6 +8392,189 @@ Sorting can be customized using the variable | |||
| 8021 | @code{org-agenda-sorting-strategy}, and may also include criteria based on | 8392 | @code{org-agenda-sorting-strategy}, and may also include criteria based on |
| 8022 | the estimated effort of an entry (@pxref{Effort estimates}). | 8393 | the estimated effort of an entry (@pxref{Effort estimates}). |
| 8023 | 8394 | ||
| 8395 | @node Filtering/limiting agenda items, , Sorting agenda items, Presentation and sorting | ||
| 8396 | @subsection Filtering/limiting agenda items | ||
| 8397 | |||
| 8398 | Agenda built-in or customized commands are statically defined. Agenda | ||
| 8399 | filters and limits provide two ways of dynamically narrowing down the list of | ||
| 8400 | agenda entries: @emph{fitlers} and @emph{limits}. Filters only act on the | ||
| 8401 | display of the items, while limits take effect before the list of agenda | ||
| 8402 | entries is built. Filter are more often used interactively, while limits are | ||
| 8403 | mostly useful when defined as local variables within custom agenda commands. | ||
| 8404 | |||
| 8405 | @subsubheading Filtering in the agenda | ||
| 8406 | @cindex filtering, by tag, category, top headline and effort, in agenda | ||
| 8407 | @cindex tag filtering, in agenda | ||
| 8408 | @cindex category filtering, in agenda | ||
| 8409 | @cindex top headline filtering, in agenda | ||
| 8410 | @cindex effort filtering, in agenda | ||
| 8411 | @cindex query editing, in agenda | ||
| 8412 | |||
| 8413 | @table @kbd | ||
| 8414 | @orgcmd{/,org-agenda-filter-by-tag} | ||
| 8415 | @vindex org-agenda-tag-filter-preset | ||
| 8416 | Filter the agenda view with respect to a tag and/or effort estimates. The | ||
| 8417 | difference between this and a custom agenda command is that filtering is very | ||
| 8418 | fast, so that you can switch quickly between different filters without having | ||
| 8419 | to recreate the agenda.@footnote{Custom commands can preset a filter by | ||
| 8420 | binding the variable @code{org-agenda-tag-filter-preset} as an option. This | ||
| 8421 | filter will then be applied to the view and persist as a basic filter through | ||
| 8422 | refreshes and more secondary filtering. The filter is a global property of | ||
| 8423 | the entire agenda view---in a block agenda, you should only set this in the | ||
| 8424 | global options section, not in the section of an individual block.} | ||
| 8425 | |||
| 8426 | You will be prompted for a tag selection letter; @key{SPC} will mean any tag at | ||
| 8427 | all. Pressing @key{TAB} at that prompt will offer use completion to select a | ||
| 8428 | tag (including any tags that do not have a selection character). The command | ||
| 8429 | then hides all entries that do not contain or inherit this tag. When called | ||
| 8430 | with prefix arg, remove the entries that @emph{do} have the tag. A second | ||
| 8431 | @kbd{/} at the prompt will turn off the filter and unhide any hidden entries. | ||
| 8432 | If the first key you press is either @kbd{+} or @kbd{-}, the previous filter | ||
| 8433 | will be narrowed by requiring or forbidding the selected additional tag. | ||
| 8434 | Instead of pressing @kbd{+} or @kbd{-} after @kbd{/}, you can also | ||
| 8435 | immediately use the @kbd{\} command. | ||
| 8436 | |||
| 8437 | @vindex org-sort-agenda-noeffort-is-high | ||
| 8438 | In order to filter for effort estimates, you should set up allowed | ||
| 8439 | efforts globally, for example | ||
| 8440 | @lisp | ||
| 8441 | (setq org-global-properties | ||
| 8442 | '(("Effort_ALL". "0 0:10 0:30 1:00 2:00 3:00 4:00"))) | ||
| 8443 | @end lisp | ||
| 8444 | You can then filter for an effort by first typing an operator, one of | ||
| 8445 | @kbd{<}, @kbd{>}, and @kbd{=}, and then the one-digit index of an effort | ||
| 8446 | estimate in your array of allowed values, where @kbd{0} means the 10th value. | ||
| 8447 | The filter will then restrict to entries with effort smaller-or-equal, equal, | ||
| 8448 | or larger-or-equal than the selected value. If the digits 0--9 are not used | ||
| 8449 | as fast access keys to tags, you can also simply press the index digit | ||
| 8450 | directly without an operator. In this case, @kbd{<} will be assumed. For | ||
| 8451 | application of the operator, entries without a defined effort will be treated | ||
| 8452 | according to the value of @code{org-sort-agenda-noeffort-is-high}. To filter | ||
| 8453 | for tasks without effort definition, press @kbd{?} as the operator. | ||
| 8454 | |||
| 8455 | Org also supports automatic, context-aware tag filtering. If the variable | ||
| 8456 | @code{org-agenda-auto-exclude-function} is set to a user-defined function, | ||
| 8457 | that function can decide which tags should be excluded from the agenda | ||
| 8458 | automatically. Once this is set, the @kbd{/} command then accepts @kbd{RET} | ||
| 8459 | as a sub-option key and runs the auto exclusion logic. For example, let's | ||
| 8460 | say you use a @code{Net} tag to identify tasks which need network access, an | ||
| 8461 | @code{Errand} tag for errands in town, and a @code{Call} tag for making phone | ||
| 8462 | calls. You could auto-exclude these tags based on the availability of the | ||
| 8463 | Internet, and outside of business hours, with something like this: | ||
| 8464 | |||
| 8465 | @smalllisp | ||
| 8466 | @group | ||
| 8467 | (defun org-my-auto-exclude-function (tag) | ||
| 8468 | (and (cond | ||
| 8469 | ((string= tag "Net") | ||
| 8470 | (/= 0 (call-process "/sbin/ping" nil nil nil | ||
| 8471 | "-c1" "-q" "-t1" "mail.gnu.org"))) | ||
| 8472 | ((or (string= tag "Errand") (string= tag "Call")) | ||
| 8473 | (let ((hour (nth 2 (decode-time)))) | ||
| 8474 | (or (< hour 8) (> hour 21))))) | ||
| 8475 | (concat "-" tag))) | ||
| 8476 | |||
| 8477 | (setq org-agenda-auto-exclude-function 'org-my-auto-exclude-function) | ||
| 8478 | @end group | ||
| 8479 | @end smalllisp | ||
| 8480 | |||
| 8481 | @orgcmd{\\,org-agenda-filter-by-tag-refine} | ||
| 8482 | Narrow the current agenda filter by an additional condition. When called with | ||
| 8483 | prefix arg, remove the entries that @emph{do} have the tag, or that do match | ||
| 8484 | the effort criterion. You can achieve the same effect by pressing @kbd{+} or | ||
| 8485 | @kbd{-} as the first key after the @kbd{/} command. | ||
| 8486 | |||
| 8487 | @c | ||
| 8488 | @kindex [ | ||
| 8489 | @kindex ] | ||
| 8490 | @kindex @{ | ||
| 8491 | @kindex @} | ||
| 8492 | @item [ ] @{ @} | ||
| 8493 | @table @i | ||
| 8494 | @item @r{in} search view | ||
| 8495 | add new search words (@kbd{[} and @kbd{]}) or new regular expressions | ||
| 8496 | (@kbd{@{} and @kbd{@}}) to the query string. The opening bracket/brace will | ||
| 8497 | add a positive search term prefixed by @samp{+}, indicating that this search | ||
| 8498 | term @i{must} occur/match in the entry. The closing bracket/brace will add a | ||
| 8499 | negative search term which @i{must not} occur/match in the entry for it to be | ||
| 8500 | selected. | ||
| 8501 | @end table | ||
| 8502 | |||
| 8503 | @orgcmd{<,org-agenda-filter-by-category} | ||
| 8504 | @vindex org-agenda-category-filter-preset | ||
| 8505 | |||
| 8506 | Filter the current agenda view with respect to the category of the item at | ||
| 8507 | point. Pressing @code{<} another time will remove this filter. You can add | ||
| 8508 | a filter preset through the option @code{org-agenda-category-filter-preset} | ||
| 8509 | (see below.) | ||
| 8510 | |||
| 8511 | @orgcmd{^,org-agenda-filter-by-top-headline} | ||
| 8512 | Filter the current agenda view and only display the siblings and the parent | ||
| 8513 | headline of the one at point. | ||
| 8514 | |||
| 8515 | @orgcmd{=,org-agenda-filter-by-regexp} | ||
| 8516 | @vindex org-agenda-regexp-filter-preset | ||
| 8517 | |||
| 8518 | Filter the agenda view by a regular expression: only show agenda entries | ||
| 8519 | matching the regular expression the user entered. When called with a prefix | ||
| 8520 | argument, it will filter @emph{out} entries matching the regexp. With two | ||
| 8521 | universal prefix arguments, it will remove all the regexp filters, which can | ||
| 8522 | be accumulated. You can add a filter preset through the option | ||
| 8523 | @code{org-agenda-category-filter-preset} (see below.) | ||
| 8524 | |||
| 8525 | @orgcmd{|,org-agenda-filter-remove-all} | ||
| 8526 | Remove all filters in the current agenda view. | ||
| 8527 | @end table | ||
| 8528 | |||
| 8529 | @subsubheading Setting limits for the agenda | ||
| 8530 | @cindex limits, in agenda | ||
| 8531 | @vindex org-agenda-max-entries | ||
| 8532 | @vindex org-agenda-max-effort | ||
| 8533 | @vindex org-agenda-max-todos | ||
| 8534 | @vindex org-agenda-max-tags | ||
| 8535 | |||
| 8536 | Here is a list of options that you can set, either globally, or locally in | ||
| 8537 | your custom agenda views@pxref{Custom agenda views}. | ||
| 8538 | |||
| 8539 | @table @var | ||
| 8540 | @item org-agenda-max-entries | ||
| 8541 | Limit the number of entries. | ||
| 8542 | @item org-agenda-max-effort | ||
| 8543 | Limit the duration of accumulated efforts (as minutes). | ||
| 8544 | @item org-agenda-max-todos | ||
| 8545 | Limit the number of entries with TODO keywords. | ||
| 8546 | @item org-agenda-max-tags | ||
| 8547 | Limit the number of tagged entries. | ||
| 8548 | @end table | ||
| 8549 | |||
| 8550 | When set to a positive integer, each option will exclude entries from other | ||
| 8551 | catogories: for example, @code{(setq org-agenda-max-effort 100)} will limit | ||
| 8552 | the agenda to 100 minutes of effort and exclude any entry that as no effort | ||
| 8553 | property. If you want to include entries with no effort property, use a | ||
| 8554 | negative value for @code{org-agenda-max-effort}. | ||
| 8555 | |||
| 8556 | One useful setup is to use @code{org-agenda-max-entries} locally in a custom | ||
| 8557 | command. For example, this custom command will display the next five entries | ||
| 8558 | with a @code{NEXT} TODO keyword. | ||
| 8559 | |||
| 8560 | @smalllisp | ||
| 8561 | (setq org-agenda-custom-commands | ||
| 8562 | '(("n" todo "NEXT" | ||
| 8563 | ((org-agenda-max-entries 5))))) | ||
| 8564 | @end smalllisp | ||
| 8565 | |||
| 8566 | Once you mark one of these five entry as @code{DONE}, rebuilding the agenda | ||
| 8567 | will again the next five entries again, including the first entry that was | ||
| 8568 | excluded so far. | ||
| 8569 | |||
| 8570 | You can also dynamically set temporary limits@footnote{Those temporary limits | ||
| 8571 | are lost when rebuilding the agenda.}: | ||
| 8572 | |||
| 8573 | @table @kbd | ||
| 8574 | @orgcmd{~,org-agenda-limit-interactively} | ||
| 8575 | This prompts for the type of limit to apply and its value. | ||
| 8576 | @end table | ||
| 8577 | |||
| 8024 | @node Agenda commands, Custom agenda views, Presentation and sorting, Agenda Views | 8578 | @node Agenda commands, Custom agenda views, Presentation and sorting, Agenda Views |
| 8025 | @section Commands in the agenda buffer | 8579 | @section Commands in the agenda buffer |
| 8026 | @cindex commands, in agenda buffer | 8580 | @cindex commands, in agenda buffer |
| @@ -8088,6 +8642,7 @@ Delete other windows. | |||
| 8088 | @c | 8642 | @c |
| 8089 | @orgcmdkskc{v d,d,org-agenda-day-view} | 8643 | @orgcmdkskc{v d,d,org-agenda-day-view} |
| 8090 | @xorgcmdkskc{v w,w,org-agenda-week-view} | 8644 | @xorgcmdkskc{v w,w,org-agenda-week-view} |
| 8645 | @xorgcmd{v t,org-agenda-fortnight-view} | ||
| 8091 | @xorgcmd{v m,org-agenda-month-view} | 8646 | @xorgcmd{v m,org-agenda-month-view} |
| 8092 | @xorgcmd{v y,org-agenda-year-view} | 8647 | @xorgcmd{v y,org-agenda-year-view} |
| 8093 | @xorgcmd{v SPC,org-agenda-reset-view} | 8648 | @xorgcmd{v SPC,org-agenda-reset-view} |
| @@ -8134,7 +8689,7 @@ entries that have been clocked on that day. You can configure the entry | |||
| 8134 | types that should be included in log mode using the variable | 8689 | types that should be included in log mode using the variable |
| 8135 | @code{org-agenda-log-mode-items}. When called with a @kbd{C-u} prefix, show | 8690 | @code{org-agenda-log-mode-items}. When called with a @kbd{C-u} prefix, show |
| 8136 | all possible logbook entries, including state changes. When called with two | 8691 | all possible logbook entries, including state changes. When called with two |
| 8137 | prefix args @kbd{C-u C-u}, show only logging information, nothing else. | 8692 | prefix arguments @kbd{C-u C-u}, show only logging information, nothing else. |
| 8138 | @kbd{v L} is equivalent to @kbd{C-u v l}. | 8693 | @kbd{v L} is equivalent to @kbd{C-u v l}. |
| 8139 | @c | 8694 | @c |
| 8140 | @orgcmdkskc{v [,[,org-agenda-manipulate-query-add} | 8695 | @orgcmdkskc{v [,[,org-agenda-manipulate-query-add} |
| @@ -8152,7 +8707,7 @@ press @kbd{v a} again. | |||
| 8152 | @vindex org-agenda-start-with-clockreport-mode | 8707 | @vindex org-agenda-start-with-clockreport-mode |
| 8153 | @vindex org-clock-report-include-clocking-task | 8708 | @vindex org-clock-report-include-clocking-task |
| 8154 | Toggle Clockreport mode. In Clockreport mode, the daily/weekly agenda will | 8709 | Toggle Clockreport mode. In Clockreport mode, the daily/weekly agenda will |
| 8155 | always show a table with the clocked times for the timespan and file scope | 8710 | always show a table with the clocked times for the time span and file scope |
| 8156 | covered by the current agenda view. The initial setting for this mode in new | 8711 | covered by the current agenda view. The initial setting for this mode in new |
| 8157 | agenda buffers can be set with the variable | 8712 | agenda buffers can be set with the variable |
| 8158 | @code{org-agenda-start-with-clockreport-mode}. By using a prefix argument | 8713 | @code{org-agenda-start-with-clockreport-mode}. By using a prefix argument |
| @@ -8212,108 +8767,39 @@ Remove the restriction lock on the agenda, if it is currently restricted to a | |||
| 8212 | file or subtree (@pxref{Agenda files}). | 8767 | file or subtree (@pxref{Agenda files}). |
| 8213 | 8768 | ||
| 8214 | @tsubheading{Secondary filtering and query editing} | 8769 | @tsubheading{Secondary filtering and query editing} |
| 8215 | @cindex filtering, by tag category and effort, in agenda | ||
| 8216 | @cindex tag filtering, in agenda | ||
| 8217 | @cindex category filtering, in agenda | ||
| 8218 | @cindex effort filtering, in agenda | ||
| 8219 | @cindex query editing, in agenda | ||
| 8220 | 8770 | ||
| 8221 | @orgcmd{<,org-agenda-filter-by-category} | 8771 | For a detailed description of these commands, see @pxref{Filtering/limiting |
| 8222 | @vindex org-agenda-category-filter-preset | 8772 | agenda items}. |
| 8223 | |||
| 8224 | Filter the current agenda view with respect to the category of the item at | ||
| 8225 | point. Pressing @code{<} another time will remove this filter. You can add | ||
| 8226 | a filter preset through the option @code{org-agenda-category-filter-preset} | ||
| 8227 | (see below.) | ||
| 8228 | 8773 | ||
| 8229 | @orgcmd{/,org-agenda-filter-by-tag} | 8774 | @orgcmd{/,org-agenda-filter-by-tag} |
| 8230 | @vindex org-agenda-tag-filter-preset | 8775 | @vindex org-agenda-tag-filter-preset |
| 8231 | Filter the current agenda view with respect to a tag and/or effort estimates. | 8776 | Filter the agenda view with respect to a tag and/or effort estimates. |
| 8232 | The difference between this and a custom agenda command is that filtering is | ||
| 8233 | very fast, so that you can switch quickly between different filters without | ||
| 8234 | having to recreate the agenda.@footnote{Custom commands can preset a filter by | ||
| 8235 | binding the variable @code{org-agenda-tag-filter-preset} as an option. This | ||
| 8236 | filter will then be applied to the view and persist as a basic filter through | ||
| 8237 | refreshes and more secondary filtering. The filter is a global property of | ||
| 8238 | the entire agenda view---in a block agenda, you should only set this in the | ||
| 8239 | global options section, not in the section of an individual block.} | ||
| 8240 | 8777 | ||
| 8241 | You will be prompted for a tag selection letter; @key{SPC} will mean any tag at | 8778 | @orgcmd{\\,org-agenda-filter-by-tag-refine} |
| 8242 | all. Pressing @key{TAB} at that prompt will offer use completion to select a | 8779 | Narrow the current agenda filter by an additional condition. |
| 8243 | tag (including any tags that do not have a selection character). The command | ||
| 8244 | then hides all entries that do not contain or inherit this tag. When called | ||
| 8245 | with prefix arg, remove the entries that @emph{do} have the tag. A second | ||
| 8246 | @kbd{/} at the prompt will turn off the filter and unhide any hidden entries. | ||
| 8247 | If the first key you press is either @kbd{+} or @kbd{-}, the previous filter | ||
| 8248 | will be narrowed by requiring or forbidding the selected additional tag. | ||
| 8249 | Instead of pressing @kbd{+} or @kbd{-} after @kbd{/}, you can also | ||
| 8250 | immediately use the @kbd{\} command. | ||
| 8251 | 8780 | ||
| 8252 | @vindex org-sort-agenda-noeffort-is-high | 8781 | @orgcmd{<,org-agenda-filter-by-category} |
| 8253 | In order to filter for effort estimates, you should set up allowed | 8782 | @vindex org-agenda-category-filter-preset |
| 8254 | efforts globally, for example | ||
| 8255 | @lisp | ||
| 8256 | (setq org-global-properties | ||
| 8257 | '(("Effort_ALL". "0 0:10 0:30 1:00 2:00 3:00 4:00"))) | ||
| 8258 | @end lisp | ||
| 8259 | You can then filter for an effort by first typing an operator, one of | ||
| 8260 | @kbd{<}, @kbd{>}, and @kbd{=}, and then the one-digit index of an effort | ||
| 8261 | estimate in your array of allowed values, where @kbd{0} means the 10th value. | ||
| 8262 | The filter will then restrict to entries with effort smaller-or-equal, equal, | ||
| 8263 | or larger-or-equal than the selected value. If the digits 0--9 are not used | ||
| 8264 | as fast access keys to tags, you can also simply press the index digit | ||
| 8265 | directly without an operator. In this case, @kbd{<} will be assumed. For | ||
| 8266 | application of the operator, entries without a defined effort will be treated | ||
| 8267 | according to the value of @code{org-sort-agenda-noeffort-is-high}. To filter | ||
| 8268 | for tasks without effort definition, press @kbd{?} as the operator. | ||
| 8269 | 8783 | ||
| 8270 | Org also supports automatic, context-aware tag filtering. If the variable | 8784 | Filter the current agenda view with respect to the category of the item at |
| 8271 | @code{org-agenda-auto-exclude-function} is set to a user-defined function, | 8785 | point. Pressing @code{<} another time will remove this filter. |
| 8272 | that function can decide which tags should be excluded from the agenda | ||
| 8273 | automatically. Once this is set, the @kbd{/} command then accepts @kbd{RET} | ||
| 8274 | as a sub-option key and runs the auto exclusion logic. For example, let's | ||
| 8275 | say you use a @code{Net} tag to identify tasks which need network access, an | ||
| 8276 | @code{Errand} tag for errands in town, and a @code{Call} tag for making phone | ||
| 8277 | calls. You could auto-exclude these tags based on the availability of the | ||
| 8278 | Internet, and outside of business hours, with something like this: | ||
| 8279 | 8786 | ||
| 8280 | @lisp | 8787 | @orgcmd{^,org-agenda-filter-by-top-headline} |
| 8281 | @group | 8788 | Filter the current agenda view and only display the siblings and the parent |
| 8282 | (defun org-my-auto-exclude-function (tag) | 8789 | headline of the one at point. |
| 8283 | (and (cond | ||
| 8284 | ((string= tag "Net") | ||
| 8285 | (/= 0 (call-process "/sbin/ping" nil nil nil | ||
| 8286 | "-c1" "-q" "-t1" "mail.gnu.org"))) | ||
| 8287 | ((or (string= tag "Errand") (string= tag "Call")) | ||
| 8288 | (let ((hour (nth 2 (decode-time)))) | ||
| 8289 | (or (< hour 8) (> hour 21))))) | ||
| 8290 | (concat "-" tag))) | ||
| 8291 | 8790 | ||
| 8292 | (setq org-agenda-auto-exclude-function 'org-my-auto-exclude-function) | 8791 | @orgcmd{=,org-agenda-filter-by-regexp} |
| 8293 | @end group | 8792 | @vindex org-agenda-regexp-filter-preset |
| 8294 | @end lisp | ||
| 8295 | 8793 | ||
| 8296 | @orgcmd{\\,org-agenda-filter-by-tag-refine} | 8794 | Filter the agenda view by a regular expression: only show agenda entries |
| 8297 | Narrow the current agenda filter by an additional condition. When called with | 8795 | matching the regular expression the user entered. When called with a prefix |
| 8298 | prefix arg, remove the entries that @emph{do} have the tag, or that do match | 8796 | argument, it will filter @emph{out} entries matching the regexp. With two |
| 8299 | the effort criterion. You can achieve the same effect by pressing @kbd{+} or | 8797 | universal prefix arguments, it will remove all the regexp filters, which can |
| 8300 | @kbd{-} as the first key after the @kbd{/} command. | 8798 | be accumulated. You can add a filter preset through the option |
| 8799 | @code{org-agenda-category-filter-preset} (see below.) | ||
| 8301 | 8800 | ||
| 8302 | @c | 8801 | @orgcmd{|,org-agenda-filter-remove-all} |
| 8303 | @kindex [ | 8802 | Remove all filters in the current agenda view. |
| 8304 | @kindex ] | ||
| 8305 | @kindex @{ | ||
| 8306 | @kindex @} | ||
| 8307 | @item [ ] @{ @} | ||
| 8308 | @table @i | ||
| 8309 | @item @r{in} search view | ||
| 8310 | add new search words (@kbd{[} and @kbd{]}) or new regular expressions | ||
| 8311 | (@kbd{@{} and @kbd{@}}) to the query string. The opening bracket/brace will | ||
| 8312 | add a positive search term prefixed by @samp{+}, indicating that this search | ||
| 8313 | term @i{must} occur/match in the entry. The closing bracket/brace will add a | ||
| 8314 | negative search term which @i{must not} occur/match in the entry for it to be | ||
| 8315 | selected. | ||
| 8316 | @end table | ||
| 8317 | 8803 | ||
| 8318 | @tsubheading{Remote editing} | 8804 | @tsubheading{Remote editing} |
| 8319 | @cindex remote editing, from agenda | 8805 | @cindex remote editing, from agenda |
| @@ -8440,29 +8926,50 @@ Jump to the running clock in another window. | |||
| 8440 | @c | 8926 | @c |
| 8441 | @orgcmd{k,org-agenda-capture} | 8927 | @orgcmd{k,org-agenda-capture} |
| 8442 | Like @code{org-capture}, but use the date at point as the default date for | 8928 | Like @code{org-capture}, but use the date at point as the default date for |
| 8443 | the capture template. See @var{org-capture-use-agenda-date} to make this | 8929 | the capture template. See @code{org-capture-use-agenda-date} to make this |
| 8444 | the default behavior of @code{org-capture}. | 8930 | the default behavior of @code{org-capture}. |
| 8445 | @cindex capturing, from agenda | 8931 | @cindex capturing, from agenda |
| 8446 | @vindex org-capture-use-agenda-date | 8932 | @vindex org-capture-use-agenda-date |
| 8447 | 8933 | ||
| 8934 | @tsubheading{Dragging agenda lines forward/backward} | ||
| 8935 | @cindex dragging, agenda lines | ||
| 8936 | |||
| 8937 | @orgcmd{M-<up>,org-agenda-drag-line-backward} | ||
| 8938 | Drag the line at point backward one line@footnote{Moving agenda lines does | ||
| 8939 | not persist after an agenda refresh and does not modify the contributing | ||
| 8940 | @file{.org} files}. With a numeric prefix argument, drag backward by that | ||
| 8941 | many lines. | ||
| 8942 | |||
| 8943 | @orgcmd{M-<down>,org-agenda-drag-line-forward} | ||
| 8944 | Drag the line at point forward one line. With a numeric prefix argument, | ||
| 8945 | drag forward by that many lines. | ||
| 8946 | |||
| 8448 | @tsubheading{Bulk remote editing selected entries} | 8947 | @tsubheading{Bulk remote editing selected entries} |
| 8449 | @cindex remote editing, bulk, from agenda | 8948 | @cindex remote editing, bulk, from agenda |
| 8450 | @vindex org-agenda-bulk-persistent-marks | ||
| 8451 | @vindex org-agenda-bulk-custom-functions | 8949 | @vindex org-agenda-bulk-custom-functions |
| 8452 | 8950 | ||
| 8453 | @orgcmd{m,org-agenda-bulk-mark} | 8951 | @orgcmd{m,org-agenda-bulk-mark} |
| 8454 | Mark the entry at point for bulk action. With prefix arg, mark that many | 8952 | Mark the entry at point for bulk action. With numeric prefix argument, mark |
| 8455 | successive entries. | 8953 | that many successive entries. |
| 8456 | @c | 8954 | @c |
| 8457 | @orgcmd{%,org-agenda-bulk-mark-regexp} | 8955 | @orgcmd{*,org-agenda-bulk-mark-all} |
| 8458 | Mark entries matching a regular expression for bulk action. | 8956 | Mark all visible agenda entries for bulk action. |
| 8459 | @c | 8957 | @c |
| 8460 | @orgcmd{u,org-agenda-bulk-unmark} | 8958 | @orgcmd{u,org-agenda-bulk-unmark} |
| 8461 | Unmark entry for bulk action. | 8959 | Unmark entry at point for bulk action. |
| 8462 | @c | 8960 | @c |
| 8463 | @orgcmd{U,org-agenda-bulk-remove-all-marks} | 8961 | @orgcmd{U,org-agenda-bulk-remove-all-marks} |
| 8464 | Unmark all marked entries for bulk action. | 8962 | Unmark all marked entries for bulk action. |
| 8465 | @c | 8963 | @c |
| 8964 | @orgcmd{M-m,org-agenda-bulk-toggle} | ||
| 8965 | Toggle mark of the entry at point for bulk action. | ||
| 8966 | @c | ||
| 8967 | @orgcmd{M-*,org-agenda-bulk-toggle-all} | ||
| 8968 | Toggle marks of all visible entries for bulk action. | ||
| 8969 | @c | ||
| 8970 | @orgcmd{%,org-agenda-bulk-mark-regexp} | ||
| 8971 | Mark entries matching a regular expression for bulk action. | ||
| 8972 | @c | ||
| 8466 | @orgcmd{B,org-agenda-bulk-action} | 8973 | @orgcmd{B,org-agenda-bulk-action} |
| 8467 | Bulk action: act on all marked entries in the agenda. This will prompt for | 8974 | Bulk action: act on all marked entries in the agenda. This will prompt for |
| 8468 | another key to select the action to be applied. The prefix arg to @kbd{B} | 8975 | another key to select the action to be applied. The prefix arg to @kbd{B} |
| @@ -8471,40 +8978,55 @@ these special timestamps. By default, marks are removed after the bulk. If | |||
| 8471 | you want them to persist, set @code{org-agenda-bulk-persistent-marks} to | 8978 | you want them to persist, set @code{org-agenda-bulk-persistent-marks} to |
| 8472 | @code{t} or hit @kbd{p} at the prompt. | 8979 | @code{t} or hit @kbd{p} at the prompt. |
| 8473 | 8980 | ||
| 8474 | @example | 8981 | @table @kbd |
| 8475 | * @r{Toggle persistent marks.} | 8982 | @item * |
| 8476 | $ @r{Archive all selected entries.} | 8983 | Toggle persistent marks. |
| 8477 | A @r{Archive entries by moving them to their respective archive siblings.} | 8984 | @item $ |
| 8478 | t @r{Change TODO state. This prompts for a single TODO keyword and} | 8985 | Archive all selected entries. |
| 8479 | @r{changes the state of all selected entries, bypassing blocking and} | 8986 | @item A |
| 8480 | @r{suppressing logging notes (but not timestamps).} | 8987 | Archive entries by moving them to their respective archive siblings. |
| 8481 | + @r{Add a tag to all selected entries.} | 8988 | @item t |
| 8482 | - @r{Remove a tag from all selected entries.} | 8989 | Change TODO state. This prompts for a single TODO keyword and changes the |
| 8483 | s @r{Schedule all items to a new date. To shift existing schedule dates} | 8990 | state of all selected entries, bypassing blocking and suppressing logging |
| 8484 | @r{by a fixed number of days, use something starting with double plus} | 8991 | notes (but not timestamps). |
| 8485 | @r{at the prompt, for example @samp{++8d} or @samp{++2w}.} | 8992 | @item + |
| 8486 | d @r{Set deadline to a specific date.} | 8993 | Add a tag to all selected entries. |
| 8487 | r @r{Prompt for a single refile target and move all entries. The entries} | 8994 | @item - |
| 8488 | @r{will no longer be in the agenda; refresh (@kbd{g}) to bring them back.} | 8995 | Remove a tag from all selected entries. |
| 8489 | S @r{Reschedule randomly into the coming N days. N will be prompted for.} | 8996 | @item s |
| 8490 | @r{With prefix arg (@kbd{C-u B S}), scatter only across weekdays.} | 8997 | Schedule all items to a new date. To shift existing schedule dates by a |
| 8491 | f @r{Apply a function@footnote{You can also create persistent custom functions through@code{org-agenda-bulk-custom-functions}.} to marked entries.} | 8998 | fixed number of days, use something starting with double plus at the prompt, |
| 8492 | @r{For example, the function below sets the CATEGORY property of the} | 8999 | for example @samp{++8d} or @samp{++2w}. |
| 8493 | @r{entries to web.} | 9000 | @item d |
| 8494 | @r{(defun set-category ()} | 9001 | Set deadline to a specific date. |
| 8495 | @r{ (interactive "P")} | 9002 | @item r |
| 8496 | @r{ (let* ((marker (or (org-get-at-bol 'org-hd-marker)} | 9003 | Prompt for a single refile target and move all entries. The entries will no |
| 8497 | @r{ (org-agenda-error)))} | 9004 | longer be in the agenda; refresh (@kbd{g}) to bring them back. |
| 8498 | @r{ (buffer (marker-buffer marker)))} | 9005 | @item S |
| 8499 | @r{ (with-current-buffer buffer} | 9006 | Reschedule randomly into the coming N days. N will be prompted for. With |
| 8500 | @r{ (save-excursion} | 9007 | prefix arg (@kbd{C-u B S}), scatter only across weekdays. |
| 8501 | @r{ (save-restriction} | 9008 | @item f |
| 8502 | @r{ (widen)} | 9009 | Apply a function@footnote{You can also create persistent custom functions |
| 8503 | @r{ (goto-char marker)} | 9010 | through @code{org-agenda-bulk-custom-functions}.} to marked entries. For |
| 8504 | @r{ (org-back-to-heading t)} | 9011 | example, the function below sets the CATEGORY property of the entries to web. |
| 8505 | @r{ (org-set-property "CATEGORY" "web"))))))} | ||
| 8506 | @end example | ||
| 8507 | 9012 | ||
| 9013 | @lisp | ||
| 9014 | @group | ||
| 9015 | (defun set-category () | ||
| 9016 | (interactive "P") | ||
| 9017 | (let* ((marker (or (org-get-at-bol 'org-hd-marker) | ||
| 9018 | (org-agenda-error))) | ||
| 9019 | (buffer (marker-buffer marker))) | ||
| 9020 | (with-current-buffer buffer | ||
| 9021 | (save-excursion | ||
| 9022 | (save-restriction | ||
| 9023 | (widen) | ||
| 9024 | (goto-char marker) | ||
| 9025 | (org-back-to-heading t) | ||
| 9026 | (org-set-property "CATEGORY" "web")))))) | ||
| 9027 | @end group | ||
| 9028 | @end lisp | ||
| 9029 | @end table | ||
| 8508 | 9030 | ||
| 8509 | @tsubheading{Calendar commands} | 9031 | @tsubheading{Calendar commands} |
| 8510 | @cindex calendar commands, from agenda | 9032 | @cindex calendar commands, from agenda |
| @@ -8551,7 +9073,7 @@ calendars. | |||
| 8551 | @orgcmd{H,org-agenda-holidays} | 9073 | @orgcmd{H,org-agenda-holidays} |
| 8552 | Show holidays for three months around the cursor date. | 9074 | Show holidays for three months around the cursor date. |
| 8553 | 9075 | ||
| 8554 | @item M-x org-export-icalendar-combine-agenda-files | 9076 | @item M-x org-icalendar-combine-agenda-files RET |
| 8555 | Export a single iCalendar file containing entries from all agenda files. | 9077 | Export a single iCalendar file containing entries from all agenda files. |
| 8556 | This is a globally available command, and also available in the agenda menu. | 9078 | This is a globally available command, and also available in the agenda menu. |
| 8557 | 9079 | ||
| @@ -8561,12 +9083,13 @@ This is a globally available command, and also available in the agenda menu. | |||
| 8561 | @cindex agenda views, exporting | 9083 | @cindex agenda views, exporting |
| 8562 | @vindex org-agenda-exporter-settings | 9084 | @vindex org-agenda-exporter-settings |
| 8563 | Write the agenda view to a file. Depending on the extension of the selected | 9085 | Write the agenda view to a file. Depending on the extension of the selected |
| 8564 | file name, the view will be exported as HTML (extension @file{.html} or | 9086 | file name, the view will be exported as HTML (@file{.html} or @file{.htm}), |
| 8565 | @file{.htm}), Postscript (extension @file{.ps}), PDF (extension @file{.pdf}), | 9087 | Postscript (@file{.ps}), PDF (@file{.pdf}), Org (@file{.org}) and plain text |
| 8566 | and plain text (any other extension). When called with a @kbd{C-u} prefix | 9088 | (any other extension). When exporting to Org, only the body of original |
| 8567 | argument, immediately open the newly created file. Use the variable | 9089 | headlines are exported, not subtrees or inherited tags. When called with a |
| 8568 | @code{org-agenda-exporter-settings} to set options for @file{ps-print} and | 9090 | @kbd{C-u} prefix argument, immediately open the newly created file. Use the |
| 8569 | for @file{htmlize} to be used during export. | 9091 | variable @code{org-agenda-exporter-settings} to set options for |
| 9092 | @file{ps-print} and for @file{htmlize} to be used during export. | ||
| 8570 | 9093 | ||
| 8571 | @tsubheading{Quit and Exit} | 9094 | @tsubheading{Quit and Exit} |
| 8572 | @orgcmd{q,org-agenda-quit} | 9095 | @orgcmd{q,org-agenda-quit} |
| @@ -8606,6 +9129,8 @@ buffer). | |||
| 8606 | @kindex C-c a C | 9129 | @kindex C-c a C |
| 8607 | @vindex org-agenda-custom-commands | 9130 | @vindex org-agenda-custom-commands |
| 8608 | @cindex agenda views, main example | 9131 | @cindex agenda views, main example |
| 9132 | @cindex agenda, as an agenda views | ||
| 9133 | @cindex agenda*, as an agenda views | ||
| 8609 | @cindex tags, as an agenda view | 9134 | @cindex tags, as an agenda view |
| 8610 | @cindex todo, as an agenda view | 9135 | @cindex todo, as an agenda view |
| 8611 | @cindex tags-todo | 9136 | @cindex tags-todo |
| @@ -8616,13 +9141,15 @@ buffer). | |||
| 8616 | Custom commands are configured in the variable | 9141 | Custom commands are configured in the variable |
| 8617 | @code{org-agenda-custom-commands}. You can customize this variable, for | 9142 | @code{org-agenda-custom-commands}. You can customize this variable, for |
| 8618 | example by pressing @kbd{C-c a C}. You can also directly set it with Emacs | 9143 | example by pressing @kbd{C-c a C}. You can also directly set it with Emacs |
| 8619 | Lisp in @file{.emacs}. The following example contains all valid search | 9144 | Lisp in @file{.emacs}. The following example contains all valid agenda |
| 8620 | types: | 9145 | views: |
| 8621 | 9146 | ||
| 8622 | @lisp | 9147 | @lisp |
| 8623 | @group | 9148 | @group |
| 8624 | (setq org-agenda-custom-commands | 9149 | (setq org-agenda-custom-commands |
| 8625 | '(("w" todo "WAITING") | 9150 | '(("x" agenda) |
| 9151 | ("y" agenda*) | ||
| 9152 | ("w" todo "WAITING") | ||
| 8626 | ("W" todo-tree "WAITING") | 9153 | ("W" todo-tree "WAITING") |
| 8627 | ("u" tags "+boss-urgent") | 9154 | ("u" tags "+boss-urgent") |
| 8628 | ("v" tags-todo "+boss-urgent") | 9155 | ("v" tags-todo "+boss-urgent") |
| @@ -8648,6 +9175,15 @@ expression to be used for the matching. The example above will | |||
| 8648 | therefore define: | 9175 | therefore define: |
| 8649 | 9176 | ||
| 8650 | @table @kbd | 9177 | @table @kbd |
| 9178 | @item C-c a x | ||
| 9179 | as a global search for agenda entries planned@footnote{@emph{Planned} means | ||
| 9180 | here that these entries have some planning information attached to them, like | ||
| 9181 | a time-stamp, a scheduled or a deadline string. See | ||
| 9182 | @code{org-agenda-entry-types} on how to set what planning information will be | ||
| 9183 | taken into account.} this week/day. | ||
| 9184 | @item C-c a y | ||
| 9185 | as a global search for agenda entries planned this week/day, but only those | ||
| 9186 | with an hour specification like @code{[h]h:mm}---think of them as appointments. | ||
| 8651 | @item C-c a w | 9187 | @item C-c a w |
| 8652 | as a global search for TODO entries with @samp{WAITING} as the TODO | 9188 | as a global search for TODO entries with @samp{WAITING} as the TODO |
| 8653 | keyword | 9189 | keyword |
| @@ -8782,23 +9318,23 @@ yourself. | |||
| 8782 | 9318 | ||
| 8783 | @vindex org-agenda-custom-commands-contexts | 9319 | @vindex org-agenda-custom-commands-contexts |
| 8784 | To control whether an agenda command should be accessible from a specific | 9320 | To control whether an agenda command should be accessible from a specific |
| 8785 | context, you can customize @var{org-agenda-custom-commands-contexts}. Let's | 9321 | context, you can customize @code{org-agenda-custom-commands-contexts}. Let's |
| 8786 | say for example that you have an agenda commands @code{"o"} displaying a view | 9322 | say for example that you have an agenda commands @code{"o"} displaying a view |
| 8787 | that you only need when reading emails. Then you would configure this option | 9323 | that you only need when reading emails. Then you would configure this option |
| 8788 | like this: | 9324 | like this: |
| 8789 | 9325 | ||
| 8790 | @example | 9326 | @lisp |
| 8791 | (setq org-agenda-custom-commands-contexts | 9327 | (setq org-agenda-custom-commands-contexts |
| 8792 | '(("o" (in-mode . "message-mode")))) | 9328 | '(("o" (in-mode . "message-mode")))) |
| 8793 | @end example | 9329 | @end lisp |
| 8794 | 9330 | ||
| 8795 | You can also tell that the command key @code{"o"} should refer to another | 9331 | You can also tell that the command key @code{"o"} should refer to another |
| 8796 | command key @code{"r"}. In that case, add this command key like this: | 9332 | command key @code{"r"}. In that case, add this command key like this: |
| 8797 | 9333 | ||
| 8798 | @example | 9334 | @lisp |
| 8799 | (setq org-agenda-custom-commands-contexts | 9335 | (setq org-agenda-custom-commands-contexts |
| 8800 | '(("o" "r" (in-mode . "message-mode")))) | 9336 | '(("o" "r" (in-mode . "message-mode")))) |
| 8801 | @end example | 9337 | @end lisp |
| 8802 | 9338 | ||
| 8803 | See the docstring of the variable for more information. | 9339 | See the docstring of the variable for more information. |
| 8804 | 9340 | ||
| @@ -9009,19 +9545,20 @@ spent (via @code{CLOCKSUM}) and with the planned total effort for it. | |||
| 9009 | @chapter Markup for rich export | 9545 | @chapter Markup for rich export |
| 9010 | 9546 | ||
| 9011 | When exporting Org mode documents, the exporter tries to reflect the | 9547 | When exporting Org mode documents, the exporter tries to reflect the |
| 9012 | structure of the document as accurately as possible in the backend. Since | 9548 | structure of the document as accurately as possible in the back-end. Since |
| 9013 | export targets like HTML, @LaTeX{}, or DocBook allow much richer formatting, | 9549 | export targets like HTML, @LaTeX{} allow much richer formatting, Org mode has |
| 9014 | Org mode has rules on how to prepare text for rich export. This section | 9550 | rules on how to prepare text for rich export. This section summarizes the |
| 9015 | summarizes the markup rules used in an Org mode buffer. | 9551 | markup rules used in an Org mode buffer. |
| 9016 | 9552 | ||
| 9017 | @menu | 9553 | @menu |
| 9018 | * Structural markup elements:: The basic structure as seen by the exporter | 9554 | * Structural markup elements:: The basic structure as seen by the exporter |
| 9019 | * Images and tables:: Tables and Images will be included | 9555 | * Images and tables:: Images, tables and caption mechanism |
| 9020 | * Literal examples:: Source code examples with special formatting | 9556 | * Literal examples:: Source code examples with special formatting |
| 9021 | * Include files:: Include additional files into a document | 9557 | * Include files:: Include additional files into a document |
| 9022 | * Index entries:: Making an index | 9558 | * Index entries:: Making an index |
| 9023 | * Macro replacement:: Use macros to create complex output | 9559 | * Macro replacement:: Use macros to create templates |
| 9024 | * Embedded @LaTeX{}:: LaTeX can be freely used inside Org documents | 9560 | * Embedded @LaTeX{}:: LaTeX can be freely used inside Org documents |
| 9561 | * Special blocks:: Containers targeted at export back-ends | ||
| 9025 | @end menu | 9562 | @end menu |
| 9026 | 9563 | ||
| 9027 | @node Structural markup elements, Images and tables, Markup, Markup | 9564 | @node Structural markup elements, Images and tables, Markup, Markup |
| @@ -9031,7 +9568,6 @@ summarizes the markup rules used in an Org mode buffer. | |||
| 9031 | * Document title:: Where the title is taken from | 9568 | * Document title:: Where the title is taken from |
| 9032 | * Headings and sections:: The document structure as seen by the exporter | 9569 | * Headings and sections:: The document structure as seen by the exporter |
| 9033 | * Table of contents:: The if and where of the table of contents | 9570 | * Table of contents:: The if and where of the table of contents |
| 9034 | * Initial text:: Text before the first heading? | ||
| 9035 | * Lists:: Lists | 9571 | * Lists:: Lists |
| 9036 | * Paragraphs:: Paragraphs | 9572 | * Paragraphs:: Paragraphs |
| 9037 | * Footnote markup:: Footnotes | 9573 | * Footnote markup:: Footnotes |
| @@ -9053,15 +9589,13 @@ The title of the exported document is taken from the special line | |||
| 9053 | @end example | 9589 | @end example |
| 9054 | 9590 | ||
| 9055 | @noindent | 9591 | @noindent |
| 9056 | If this line does not exist, the title is derived from the first non-empty, | 9592 | If this line does not exist, the title will be the name of the file |
| 9057 | non-comment line in the buffer. If no such line exists, or if you have | 9593 | associated to buffer, without extension, or the buffer name. |
| 9058 | turned off exporting of the text before the first headline (see below), the | ||
| 9059 | title will be the file name without extension. | ||
| 9060 | 9594 | ||
| 9061 | @cindex property, EXPORT_TITLE | 9595 | @cindex property, EXPORT_TITLE |
| 9062 | If you are exporting only a subtree by marking is as the region, the heading | 9596 | If you are exporting only a subtree, its heading will become the title of the |
| 9063 | of the subtree will become the title of the document. If the subtree has a | 9597 | document. If the subtree has a property @code{EXPORT_TITLE}, that will take |
| 9064 | property @code{EXPORT_TITLE}, that will take precedence. | 9598 | precedence. |
| 9065 | 9599 | ||
| 9066 | @node Headings and sections, Table of contents, Document title, Structural markup elements | 9600 | @node Headings and sections, Table of contents, Document title, Structural markup elements |
| 9067 | @subheading Headings and sections | 9601 | @subheading Headings and sections |
| @@ -9081,58 +9615,55 @@ per-file basis with a line | |||
| 9081 | #+OPTIONS: H:4 | 9615 | #+OPTIONS: H:4 |
| 9082 | @end example | 9616 | @end example |
| 9083 | 9617 | ||
| 9084 | @node Table of contents, Initial text, Headings and sections, Structural markup elements | 9618 | @node Table of contents, Lists, Headings and sections, Structural markup elements |
| 9085 | @subheading Table of contents | 9619 | @subheading Table of contents |
| 9086 | @cindex table of contents, markup rules | 9620 | @cindex table of contents, markup rules |
| 9087 | 9621 | ||
| 9622 | @cindex #+TOC | ||
| 9088 | @vindex org-export-with-toc | 9623 | @vindex org-export-with-toc |
| 9089 | The table of contents is normally inserted directly before the first headline | 9624 | The table of contents is normally inserted directly before the first headline |
| 9090 | of the file. If you would like to get it to a different location, insert the | 9625 | of the file. The depth of the table is by default the same as the number of |
| 9091 | string @code{[TABLE-OF-CONTENTS]} on a line by itself at the desired | 9626 | headline levels, but you can choose a smaller number, or turn off the table |
| 9092 | location. The depth of the table of contents is by default the same as the | 9627 | of contents entirely, by configuring the variable @code{org-export-with-toc}, |
| 9093 | number of headline levels, but you can choose a smaller number, or turn off | 9628 | or on a per-file basis with a line like |
| 9094 | the table of contents entirely, by configuring the variable | ||
| 9095 | @code{org-export-with-toc}, or on a per-file basis with a line like | ||
| 9096 | 9629 | ||
| 9097 | @example | 9630 | @example |
| 9098 | #+OPTIONS: toc:2 (only to two levels in TOC) | 9631 | #+OPTIONS: toc:2 (only to two levels in TOC) |
| 9099 | #+OPTIONS: toc:nil (no TOC at all) | 9632 | #+OPTIONS: toc:nil (no default TOC at all) |
| 9100 | @end example | 9633 | @end example |
| 9101 | 9634 | ||
| 9102 | @node Initial text, Lists, Table of contents, Structural markup elements | 9635 | If you would like to move the table of contents to a different location, you |
| 9103 | @subheading Text before the first headline | 9636 | should turn off the detault table using @code{org-export-with-toc} or |
| 9104 | @cindex text before first headline, markup rules | 9637 | @code{#+OPTIONS} and insert @code{#+TOC: headlines N} at the desired |
| 9105 | @cindex #+TEXT | 9638 | location(s). |
| 9106 | |||
| 9107 | Org mode normally exports the text before the first headline, and even uses | ||
| 9108 | the first line as the document title. The text will be fully marked up. If | ||
| 9109 | you need to include literal HTML, @LaTeX{}, or DocBook code, use the special | ||
| 9110 | constructs described below in the sections for the individual exporters. | ||
| 9111 | 9639 | ||
| 9112 | @vindex org-export-skip-text-before-1st-heading | 9640 | @example |
| 9113 | Some people like to use the space before the first headline for setup and | 9641 | #+OPTIONS: toc:nil (no default TOC) |
| 9114 | internal links and therefore would like to control the exported text before | 9642 | ... |
| 9115 | the first headline in a different way. You can do so by setting the variable | 9643 | #+TOC: headlines 2 (insert TOC here, with two headline levels) |
| 9116 | @code{org-export-skip-text-before-1st-heading} to @code{t}. On a per-file | 9644 | @end example |
| 9117 | basis, you can get the same effect with @samp{#+OPTIONS: skip:t}. | ||
| 9118 | 9645 | ||
| 9119 | @noindent | 9646 | Multiple @code{#+TOC: headline} lines are allowed. The same @code{TOC} |
| 9120 | If you still want to have some text before the first headline, use the | 9647 | keyword can also generate a list of all tables (resp.@: all listings) with a |
| 9121 | @code{#+TEXT} construct: | 9648 | caption in the buffer. |
| 9122 | 9649 | ||
| 9123 | @example | 9650 | @example |
| 9124 | #+OPTIONS: skip:t | 9651 | #+TOC: listings (build a list of listings) |
| 9125 | #+TEXT: This text will go before the *first* headline. | 9652 | #+TOC: tables (build a list of tables) |
| 9126 | #+TEXT: [TABLE-OF-CONTENTS] | ||
| 9127 | #+TEXT: This goes between the table of contents and the *first* headline | ||
| 9128 | @end example | 9653 | @end example |
| 9129 | 9654 | ||
| 9130 | @node Lists, Paragraphs, Initial text, Structural markup elements | 9655 | @cindex property, ALT_TITLE |
| 9656 | The headline's title usually determines its corresponding entry in a table of | ||
| 9657 | contents. However, it is possible to specify an alternative title by | ||
| 9658 | setting @code{ALT_TITLE} property accordingly. It will then be used when | ||
| 9659 | building the table. | ||
| 9660 | |||
| 9661 | @node Lists, Paragraphs, Table of contents, Structural markup elements | ||
| 9131 | @subheading Lists | 9662 | @subheading Lists |
| 9132 | @cindex lists, markup rules | 9663 | @cindex lists, markup rules |
| 9133 | 9664 | ||
| 9134 | Plain lists as described in @ref{Plain lists}, are translated to the backend's | 9665 | Plain lists as described in @ref{Plain lists}, are translated to the back-end's |
| 9135 | syntax for such lists. Most backends support unordered, ordered, and | 9666 | syntax for such lists. Most back-ends support unordered, ordered, and |
| 9136 | description lists. | 9667 | description lists. |
| 9137 | 9668 | ||
| 9138 | @node Paragraphs, Footnote markup, Lists, Structural markup elements | 9669 | @node Paragraphs, Footnote markup, Lists, Structural markup elements |
| @@ -9184,7 +9715,7 @@ but not any simpler | |||
| 9184 | @cindex @file{footnote.el} | 9715 | @cindex @file{footnote.el} |
| 9185 | 9716 | ||
| 9186 | Footnotes defined in the way described in @ref{Footnotes}, will be exported | 9717 | Footnotes defined in the way described in @ref{Footnotes}, will be exported |
| 9187 | by all backends. Org allows multiple references to the same note, and | 9718 | by all back-ends. Org allows multiple references to the same note, and |
| 9188 | multiple footnotes side by side. | 9719 | multiple footnotes side by side. |
| 9189 | 9720 | ||
| 9190 | @node Emphasis and monospace, Horizontal rules, Footnote markup, Structural markup elements | 9721 | @node Emphasis and monospace, Horizontal rules, Footnote markup, Structural markup elements |
| @@ -9196,16 +9727,27 @@ multiple footnotes side by side. | |||
| 9196 | @cindex verbatim text, markup rules | 9727 | @cindex verbatim text, markup rules |
| 9197 | @cindex code text, markup rules | 9728 | @cindex code text, markup rules |
| 9198 | @cindex strike-through text, markup rules | 9729 | @cindex strike-through text, markup rules |
| 9730 | @vindex org-fontify-emphasized-text | ||
| 9731 | @vindex org-emphasis-regexp-components | ||
| 9732 | @vindex org-emphasis-alist | ||
| 9199 | You can make words @b{*bold*}, @i{/italic/}, _underlined_, @code{=code=} | 9733 | You can make words @b{*bold*}, @i{/italic/}, _underlined_, @code{=code=} |
| 9200 | and @code{~verbatim~}, and, if you must, @samp{+strike-through+}. Text | 9734 | and @code{~verbatim~}, and, if you must, @samp{+strike-through+}. Text |
| 9201 | in the code and verbatim string is not processed for Org mode specific | 9735 | in the code and verbatim string is not processed for Org mode specific |
| 9202 | syntax; it is exported verbatim. | 9736 | syntax, it is exported verbatim. |
| 9737 | |||
| 9738 | To turn off fontification for marked up text, you can set | ||
| 9739 | @code{org-fontify-emphasized-text} to @code{nil}. To narrow down the list of | ||
| 9740 | available markup syntax, you can customize @code{org-emphasis-alist}. To fine | ||
| 9741 | tune what characters are allowed before and after the markup characters, you | ||
| 9742 | can tweak @code{org-emphasis-regexp-components}. Beware that changing one of | ||
| 9743 | the above variables will no take effect until you reload Org, for which you | ||
| 9744 | may need to restart Emacs. | ||
| 9203 | 9745 | ||
| 9204 | @node Horizontal rules, Comment lines, Emphasis and monospace, Structural markup elements | 9746 | @node Horizontal rules, Comment lines, Emphasis and monospace, Structural markup elements |
| 9205 | @subheading Horizontal rules | 9747 | @subheading Horizontal rules |
| 9206 | @cindex horizontal rules, markup rules | 9748 | @cindex horizontal rules, markup rules |
| 9207 | A line consisting of only dashes, and at least 5 of them, will be exported as | 9749 | A line consisting of only dashes, and at least 5 of them, will be exported as |
| 9208 | a horizontal line (@samp{<hr/>} in HTML and @code{\hrule} in @LaTeX{}). | 9750 | a horizontal line. |
| 9209 | 9751 | ||
| 9210 | @node Comment lines, , Horizontal rules, Structural markup elements | 9752 | @node Comment lines, , Horizontal rules, Structural markup elements |
| 9211 | @subheading Comment lines | 9753 | @subheading Comment lines |
| @@ -9231,45 +9773,48 @@ Toggle the COMMENT keyword at the beginning of an entry. | |||
| 9231 | 9773 | ||
| 9232 | @cindex tables, markup rules | 9774 | @cindex tables, markup rules |
| 9233 | @cindex #+CAPTION | 9775 | @cindex #+CAPTION |
| 9234 | @cindex #+LABEL | 9776 | @cindex #+NAME |
| 9235 | Both the native Org mode tables (@pxref{Tables}) and tables formatted with | 9777 | Both the native Org mode tables (@pxref{Tables}) and tables formatted with |
| 9236 | the @file{table.el} package will be exported properly. For Org mode tables, | 9778 | the @file{table.el} package will be exported properly. For Org mode tables, |
| 9237 | the lines before the first horizontal separator line will become table header | 9779 | the lines before the first horizontal separator line will become table header |
| 9238 | lines. You can use the following lines somewhere before the table to assign | 9780 | lines. You can use the following lines somewhere before the table to assign |
| 9239 | a caption and a label for cross references, and in the text you can refer to | 9781 | a caption and a label for cross references, and in the text you can refer to |
| 9240 | the object with @code{\ref@{tab:basic-data@}}: | 9782 | the object with @code{[[tab:basic-data]]} (@pxref{Internal links}): |
| 9241 | 9783 | ||
| 9242 | @example | 9784 | @example |
| 9243 | #+CAPTION: This is the caption for the next table (or link) | 9785 | #+CAPTION: This is the caption for the next table (or link) |
| 9244 | #+LABEL: tab:basic-data | 9786 | #+NAME: tab:basic-data |
| 9245 | | ... | ...| | 9787 | | ... | ...| |
| 9246 | |-----|----| | 9788 | |-----|----| |
| 9247 | @end example | 9789 | @end example |
| 9248 | 9790 | ||
| 9249 | Optionally, the caption can take the form: | 9791 | Optionally, the caption can take the form: |
| 9250 | @example | 9792 | @example |
| 9251 | #+CAPTION: [Caption for list of figures]@{Caption for table (or link).@} | 9793 | #+CAPTION[Caption for list of tables]: Caption for table. |
| 9252 | @end example | 9794 | @end example |
| 9253 | 9795 | ||
| 9254 | @cindex inlined images, markup rules | 9796 | @cindex inlined images, markup rules |
| 9255 | Some backends (HTML, @LaTeX{}, and DocBook) allow you to directly include | 9797 | Some back-ends allow you to directly include images into the exported |
| 9256 | images into the exported document. Org does this, if a link to an image | 9798 | document. Org does this, if a link to an image files does not have |
| 9257 | files does not have a description part, for example @code{[[./img/a.jpg]]}. | 9799 | a description part, for example @code{[[./img/a.jpg]]}. If you wish to |
| 9258 | If you wish to define a caption for the image and maybe a label for internal | 9800 | define a caption for the image and maybe a label for internal cross |
| 9259 | cross references, make sure that the link is on a line by itself and precede | 9801 | references, make sure that the link is on a line by itself and precede it |
| 9260 | it with @code{#+CAPTION} and @code{#+LABEL} as follows: | 9802 | with @code{#+CAPTION} and @code{#+NAME} as follows: |
| 9261 | 9803 | ||
| 9262 | @example | 9804 | @example |
| 9263 | #+CAPTION: This is the caption for the next figure link (or table) | 9805 | #+CAPTION: This is the caption for the next figure link (or table) |
| 9264 | #+LABEL: fig:SED-HR4049 | 9806 | #+NAME: fig:SED-HR4049 |
| 9265 | [[./img/a.jpg]] | 9807 | [[./img/a.jpg]] |
| 9266 | @end example | 9808 | @end example |
| 9267 | 9809 | ||
| 9268 | You may also define additional attributes for the figure. As this is | 9810 | @noindent |
| 9269 | backend-specific, see the sections about the individual backends for more | 9811 | Such images can be displayed within the buffer. @xref{Handling links,the |
| 9270 | information. | 9812 | discussion of image links}. |
| 9271 | 9813 | ||
| 9272 | @xref{Handling links,the discussion of image links}. | 9814 | Even though images and tables are prominent examples of captioned structures, |
| 9815 | the same caption mechanism can apply to many others (e.g., @LaTeX{} | ||
| 9816 | equations, source code blocks). Depending on the export back-end, those may | ||
| 9817 | or may not be handled. | ||
| 9273 | 9818 | ||
| 9274 | @node Literal examples, Include files, Images and tables, Markup | 9819 | @node Literal examples, Include files, Images and tables, Markup |
| 9275 | @section Literal examples | 9820 | @section Literal examples |
| @@ -9302,11 +9847,11 @@ Here is an example | |||
| 9302 | If the example is source code from a programming language, or any other text | 9847 | If the example is source code from a programming language, or any other text |
| 9303 | that can be marked up by font-lock in Emacs, you can ask for the example to | 9848 | that can be marked up by font-lock in Emacs, you can ask for the example to |
| 9304 | look like the fontified Emacs buffer@footnote{This works automatically for | 9849 | look like the fontified Emacs buffer@footnote{This works automatically for |
| 9305 | the HTML backend (it requires version 1.34 of the @file{htmlize.el} package, | 9850 | the HTML back-end (it requires version 1.34 of the @file{htmlize.el} package, |
| 9306 | which is distributed with Org). Fontified code chunks in @LaTeX{} can be | 9851 | which is distributed with Org). Fontified code chunks in @LaTeX{} can be |
| 9307 | achieved using either the listings or the | 9852 | achieved using either the listings or the |
| 9308 | @url{http://code.google.com/p/minted, minted,} package. Refer to | 9853 | @url{http://code.google.com/p/minted, minted,} package. Refer to |
| 9309 | @code{org-export-latex-listings} documentation for details.}. This is done | 9854 | @code{org-latex-listings} documentation for details.}. This is done |
| 9310 | with the @samp{src} block, where you also need to specify the name of the | 9855 | with the @samp{src} block, where you also need to specify the name of the |
| 9311 | major mode that should be used to fontify the example@footnote{Code in | 9856 | major mode that should be used to fontify the example@footnote{Code in |
| 9312 | @samp{src} blocks may also be evaluated either interactively or on export. | 9857 | @samp{src} blocks may also be evaluated either interactively or on export. |
| @@ -9398,20 +9943,24 @@ include your @file{.emacs} file, you could use: | |||
| 9398 | @example | 9943 | @example |
| 9399 | #+INCLUDE: "~/.emacs" src emacs-lisp | 9944 | #+INCLUDE: "~/.emacs" src emacs-lisp |
| 9400 | @end example | 9945 | @end example |
| 9946 | |||
| 9401 | @noindent | 9947 | @noindent |
| 9402 | The optional second and third parameter are the markup (e.g., @samp{quote}, | 9948 | The optional second and third parameter are the markup (e.g., @samp{quote}, |
| 9403 | @samp{example}, or @samp{src}), and, if the markup is @samp{src}, the | 9949 | @samp{example}, or @samp{src}), and, if the markup is @samp{src}, the |
| 9404 | language for formatting the contents. The markup is optional; if it is not | 9950 | language for formatting the contents. The markup is optional; if it is not |
| 9405 | given, the text will be assumed to be in Org mode format and will be | 9951 | given, the text will be assumed to be in Org mode format and will be |
| 9406 | processed normally. The include line will also allow additional keyword | 9952 | processed normally. |
| 9407 | parameters @code{:prefix1} and @code{:prefix} to specify prefixes for the | 9953 | |
| 9408 | first line and for each following line, @code{:minlevel} in order to get | 9954 | Contents of the included file will belong to the same structure (headline, |
| 9409 | Org mode content demoted to a specified level, as well as any options | 9955 | item) containing the @code{INCLUDE} keyword. In particular, headlines within |
| 9410 | accepted by the selected markup. For example, to include a file as an item, | 9956 | the file will become children of the current section. That behaviour can be |
| 9411 | use | 9957 | changed by providing an additional keyword parameter, @code{:minlevel}. In |
| 9958 | that case, all headlines in the included file will be shifted so the one with | ||
| 9959 | the lowest level reaches that specified level. For example, to make a file | ||
| 9960 | become a sibling of the current top-level headline, use | ||
| 9412 | 9961 | ||
| 9413 | @example | 9962 | @example |
| 9414 | #+INCLUDE: "~/snippets/xx" :prefix1 " + " :prefix " " | 9963 | #+INCLUDE: "~/my-book/chapter2.org" :minlevel 1 |
| 9415 | @end example | 9964 | @end example |
| 9416 | 9965 | ||
| 9417 | You can also include a portion of a file by specifying a lines range using | 9966 | You can also include a portion of a file by specifying a lines range using |
| @@ -9460,21 +10009,24 @@ You can define text snippets with | |||
| 9460 | #+MACRO: name replacement text $1, $2 are arguments | 10009 | #+MACRO: name replacement text $1, $2 are arguments |
| 9461 | @end example | 10010 | @end example |
| 9462 | 10011 | ||
| 9463 | @noindent which can be referenced anywhere in the document (even in | 10012 | @noindent which can be referenced in |
| 9464 | code examples) with @code{@{@{@{name(arg1,arg2)@}@}@}}. In addition to | 10013 | paragraphs, verse blocks, table cells and some keywords with |
| 9465 | defined macros, @code{@{@{@{title@}@}@}}, @code{@{@{@{author@}@}@}}, etc., | 10014 | @code{@{@{@{name(arg1,arg2)@}@}@}}@footnote{Since commas separate arguments, |
| 9466 | will reference information set by the @code{#+TITLE:}, @code{#+AUTHOR:}, and | 10015 | commas within arguments have to be escaped with a backslash character. |
| 9467 | similar lines. Also, @code{@{@{@{date(@var{FORMAT})@}@}@}} and | 10016 | Conversely, backslash characters before a comma, and only them, need to be |
| 10017 | escaped with another backslash character.}. In addition to defined macros, | ||
| 10018 | @code{@{@{@{title@}@}@}}, @code{@{@{@{author@}@}@}}, etc., will reference | ||
| 10019 | information set by the @code{#+TITLE:}, @code{#+AUTHOR:}, and similar lines. | ||
| 10020 | Also, @code{@{@{@{time(@var{FORMAT})@}@}@}} and | ||
| 9468 | @code{@{@{@{modification-time(@var{FORMAT})@}@}@}} refer to current date time | 10021 | @code{@{@{@{modification-time(@var{FORMAT})@}@}@}} refer to current date time |
| 9469 | and to the modification time of the file being exported, respectively. | 10022 | and to the modification time of the file being exported, respectively. |
| 9470 | @var{FORMAT} should be a format string understood by | 10023 | @var{FORMAT} should be a format string understood by |
| 9471 | @code{format-time-string}. | 10024 | @code{format-time-string}. |
| 9472 | 10025 | ||
| 9473 | Macro expansion takes place during export, and some people use it to | 10026 | Macro expansion takes place during export. |
| 9474 | construct complex HTML code. | ||
| 9475 | 10027 | ||
| 9476 | 10028 | ||
| 9477 | @node Embedded @LaTeX{}, , Macro replacement, Markup | 10029 | @node Embedded @LaTeX{}, Special blocks, Macro replacement, Markup |
| 9478 | @section Embedded @LaTeX{} | 10030 | @section Embedded @LaTeX{} |
| 9479 | @cindex @TeX{} interpretation | 10031 | @cindex @TeX{} interpretation |
| 9480 | @cindex @LaTeX{} interpretation | 10032 | @cindex @LaTeX{} interpretation |
| @@ -9487,7 +10039,7 @@ Donald E. Knuth's @TeX{} system. Many of the features described here as | |||
| 9487 | distinction.} is widely used to typeset scientific documents. Org mode | 10039 | distinction.} is widely used to typeset scientific documents. Org mode |
| 9488 | supports embedding @LaTeX{} code into its files, because many academics are | 10040 | supports embedding @LaTeX{} code into its files, because many academics are |
| 9489 | used to writing and reading @LaTeX{} source code, and because it can be | 10041 | used to writing and reading @LaTeX{} source code, and because it can be |
| 9490 | readily processed to produce pretty output for a number of export backends. | 10042 | readily processed to produce pretty output for a number of export back-ends. |
| 9491 | 10043 | ||
| 9492 | @menu | 10044 | @menu |
| 9493 | * Special symbols:: Greek letters and other symbols | 10045 | * Special symbols:: Greek letters and other symbols |
| @@ -9506,11 +10058,11 @@ readily processed to produce pretty output for a number of export backends. | |||
| 9506 | @cindex HTML entities | 10058 | @cindex HTML entities |
| 9507 | @cindex @LaTeX{} entities | 10059 | @cindex @LaTeX{} entities |
| 9508 | 10060 | ||
| 9509 | You can use @LaTeX{} macros to insert special symbols like @samp{\alpha} to | 10061 | You can use @LaTeX{}-like syntax to insert special symbols like @samp{\alpha} |
| 9510 | indicate the Greek letter, or @samp{\to} to indicate an arrow. Completion | 10062 | to indicate the Greek letter, or @samp{\to} to indicate an arrow. Completion |
| 9511 | for these macros is available, just type @samp{\} and maybe a few letters, | 10063 | for these symbols is available, just type @samp{\} and maybe a few letters, |
| 9512 | and press @kbd{M-@key{TAB}} to see possible completions. Unlike @LaTeX{} | 10064 | and press @kbd{M-@key{TAB}} to see possible completions. Unlike @LaTeX{} |
| 9513 | code, Org mode allows these macros to be present without surrounding math | 10065 | code, Org mode allows these symbols to be present without surrounding math |
| 9514 | delimiters, for example: | 10066 | delimiters, for example: |
| 9515 | 10067 | ||
| 9516 | @example | 10068 | @example |
| @@ -9519,7 +10071,7 @@ Angles are written as Greek letters \alpha, \beta and \gamma. | |||
| 9519 | 10071 | ||
| 9520 | @vindex org-entities | 10072 | @vindex org-entities |
| 9521 | During export, these symbols will be transformed into the native format of | 10073 | During export, these symbols will be transformed into the native format of |
| 9522 | the exporter backend. Strings like @code{\alpha} will be exported as | 10074 | the exporter back-end. Strings like @code{\alpha} will be exported as |
| 9523 | @code{α} in the HTML output, and as @code{$\alpha$} in the @LaTeX{} | 10075 | @code{α} in the HTML output, and as @code{$\alpha$} in the @LaTeX{} |
| 9524 | output. Similarly, @code{\nbsp} will become @code{ } in HTML and | 10076 | output. Similarly, @code{\nbsp} will become @code{ } in HTML and |
| 9525 | @code{~} in @LaTeX{}. If you need such a symbol inside a word, terminate it | 10077 | @code{~} in @LaTeX{}. If you need such a symbol inside a word, terminate it |
| @@ -9531,12 +10083,13 @@ A large number of entities is provided, with names taken from both HTML and | |||
| 9531 | @samp{...} are all converted into special commands creating hyphens of | 10083 | @samp{...} are all converted into special commands creating hyphens of |
| 9532 | different lengths or a compact set of dots. | 10084 | different lengths or a compact set of dots. |
| 9533 | 10085 | ||
| 9534 | If you would like to see entities displayed as UTF8 characters, use the | 10086 | If you would like to see entities displayed as UTF-8 characters, use the |
| 9535 | following command@footnote{You can turn this on by default by setting the | 10087 | following command@footnote{You can turn this on by default by setting the |
| 9536 | variable @code{org-pretty-entities}, or on a per-file base with the | 10088 | variable @code{org-pretty-entities}, or on a per-file base with the |
| 9537 | @code{#+STARTUP} option @code{entitiespretty}.}: | 10089 | @code{#+STARTUP} option @code{entitiespretty}.}: |
| 9538 | 10090 | ||
| 9539 | @table @kbd | 10091 | @table @kbd |
| 10092 | @cindex @code{entitiespretty}, STARTUP keyword | ||
| 9540 | @kindex C-c C-x \ | 10093 | @kindex C-c C-x \ |
| 9541 | @item C-c C-x \ | 10094 | @item C-c C-x \ |
| 9542 | Toggle display of entities as UTF-8 characters. This does not change the | 10095 | Toggle display of entities as UTF-8 characters. This does not change the |
| @@ -9549,31 +10102,23 @@ for display purposes only. | |||
| 9549 | @cindex subscript | 10102 | @cindex subscript |
| 9550 | @cindex superscript | 10103 | @cindex superscript |
| 9551 | 10104 | ||
| 9552 | Just like in @LaTeX{}, @samp{^} and @samp{_} are used to indicate super- | 10105 | Just like in @LaTeX{}, @samp{^} and @samp{_} are used to indicate super- and |
| 9553 | and subscripts. Again, these can be used without embedding them in | 10106 | subscripts. Again, these can be used without embedding them in math-mode |
| 9554 | math-mode delimiters. To increase the readability of ASCII text, it is | 10107 | delimiters. To increase the readability of ASCII text, it is not necessary |
| 9555 | not necessary (but OK) to surround multi-character sub- and superscripts | 10108 | (but OK) to surround multi-character sub- and superscripts with curly braces. |
| 9556 | with curly braces. For example | 10109 | For example |
| 9557 | 10110 | ||
| 9558 | @example | 10111 | @example |
| 9559 | The mass of the sun is M_sun = 1.989 x 10^30 kg. The radius of | 10112 | The mass of the sun is M_sun = 1.989 x 10^30 kg. The radius of |
| 9560 | the sun is R_@{sun@} = 6.96 x 10^8 m. | 10113 | the sun is R_@{sun@} = 6.96 x 10^8 m. |
| 9561 | @end example | 10114 | @end example |
| 9562 | 10115 | ||
| 9563 | @vindex org-export-with-sub-superscripts | 10116 | @vindex org-use-sub-superscripts |
| 9564 | To avoid interpretation as raised or lowered text, you can quote @samp{^} and | 10117 | If you write a text where the underscore is often used in a different |
| 9565 | @samp{_} with a backslash: @samp{\^} and @samp{\_}. If you write a text | 10118 | context, Org's convention to always interpret these as subscripts can get in |
| 9566 | where the underscore is often used in a different context, Org's convention | 10119 | your way. Configure the variable @code{org-use-sub-superscripts} to change |
| 9567 | to always interpret these as subscripts can get in your way. Configure the | 10120 | this convention. For example, when setting this variable to @code{@{@}}, |
| 9568 | variable @code{org-export-with-sub-superscripts} to globally change this | 10121 | @samp{a_b} will not be interpreted as a subscript, but @samp{a_@{b@}} will. |
| 9569 | convention, or use, on a per-file basis: | ||
| 9570 | |||
| 9571 | @example | ||
| 9572 | #+OPTIONS: ^:@{@} | ||
| 9573 | @end example | ||
| 9574 | |||
| 9575 | @noindent With this setting, @samp{a_b} will not be interpreted as a | ||
| 9576 | subscript, but @samp{a_@{b@}} will. | ||
| 9577 | 10122 | ||
| 9578 | @table @kbd | 10123 | @table @kbd |
| 9579 | @kindex C-c C-x \ | 10124 | @kindex C-c C-x \ |
| @@ -9589,31 +10134,31 @@ format sub- and superscripts in a WYSIWYM way. | |||
| 9589 | @vindex org-format-latex-header | 10134 | @vindex org-format-latex-header |
| 9590 | Going beyond symbols and sub- and superscripts, a full formula language is | 10135 | Going beyond symbols and sub- and superscripts, a full formula language is |
| 9591 | needed. Org mode can contain @LaTeX{} math fragments, and it supports ways | 10136 | needed. Org mode can contain @LaTeX{} math fragments, and it supports ways |
| 9592 | to process these for several export backends. When exporting to @LaTeX{}, | 10137 | to process these for several export back-ends. When exporting to @LaTeX{}, |
| 9593 | the code is obviously left as it is. When exporting to HTML, Org invokes the | 10138 | the code is obviously left as it is. When exporting to HTML, Org invokes the |
| 9594 | @uref{http://www.mathjax.org, MathJax library} (@pxref{Math formatting in | 10139 | @uref{http://www.mathjax.org, MathJax library} (@pxref{Math formatting in |
| 9595 | HTML export}) to process and display the math@footnote{If you plan to use | 10140 | HTML export}) to process and display the math@footnote{If you plan to use |
| 9596 | this regularly or on pages with significant page views, you should install | 10141 | this regularly or on pages with significant page views, you should install |
| 9597 | @file{MathJax} on your own | 10142 | @file{MathJax} on your own server in order to limit the load of our server.}. |
| 9598 | server in order to limit the load of our server.}. Finally, it can also | 10143 | Finally, it can also process the mathematical expressions into |
| 9599 | process the mathematical expressions into images@footnote{For this to work | 10144 | images@footnote{For this to work you need to be on a system with a working |
| 9600 | you need to be on a system with a working @LaTeX{} installation. You also | 10145 | @LaTeX{} installation. You also need the @file{dvipng} program or the |
| 9601 | need the @file{dvipng} program or the @file{convert}, respectively available | 10146 | @file{convert}, respectively available at |
| 9602 | at @url{http://sourceforge.net/projects/dvipng/} and from the | 10147 | @url{http://sourceforge.net/projects/dvipng/} and from the @file{imagemagick} |
| 9603 | @file{imagemagick} suite. The @LaTeX{} header that will be used when | 10148 | suite. The @LaTeX{} header that will be used when processing a fragment can |
| 9604 | processing a fragment can be configured with the variable | 10149 | be configured with the variable @code{org-format-latex-header}.} that can be |
| 9605 | @code{org-format-latex-header}.} that can be displayed in a browser or in | 10150 | displayed in a browser. |
| 9606 | DocBook documents. | ||
| 9607 | 10151 | ||
| 9608 | @LaTeX{} fragments don't need any special marking at all. The following | 10152 | @LaTeX{} fragments don't need any special marking at all. The following |
| 9609 | snippets will be identified as @LaTeX{} source code: | 10153 | snippets will be identified as @LaTeX{} source code: |
| 9610 | @itemize @bullet | 10154 | @itemize @bullet |
| 9611 | @item | 10155 | @item |
| 9612 | Environments of any kind@footnote{When @file{MathJax} is used, only the | 10156 | Environments of any kind@footnote{When @file{MathJax} is used, only the |
| 9613 | environment recognized by @file{MathJax} will be processed. When | 10157 | environments recognized by @file{MathJax} will be processed. When |
| 9614 | @file{dvipng} is used to create images, any @LaTeX{} environments will be | 10158 | @file{dvipng} program or @file{imagemagick} suite is used to create images, |
| 9615 | handled.}. The only requirement is that the @code{\begin} statement appears | 10159 | any @LaTeX{} environment will be handled.}. The only requirement is that the |
| 9616 | on a new line, preceded by only whitespace. | 10160 | @code{\begin} and @code{\end} statements appear on a new line, at the |
| 10161 | beginning of the line or after whitespaces only. | ||
| 9617 | @item | 10162 | @item |
| 9618 | Text within the usual @LaTeX{} math delimiters. To avoid conflicts with | 10163 | Text within the usual @LaTeX{} math delimiters. To avoid conflicts with |
| 9619 | currency specifications, single @samp{$} characters are only recognized as | 10164 | currency specifications, single @samp{$} characters are only recognized as |
| @@ -9627,40 +10172,44 @@ For the other delimiters, there is no such restriction, so when in doubt, use | |||
| 9627 | @noindent For example: | 10172 | @noindent For example: |
| 9628 | 10173 | ||
| 9629 | @example | 10174 | @example |
| 9630 | \begin@{equation@} % arbitrary environments, | 10175 | \begin@{equation@} |
| 9631 | x=\sqrt@{b@} % even tables, figures | 10176 | x=\sqrt@{b@} |
| 9632 | \end@{equation@} % etc | 10177 | \end@{equation@} |
| 9633 | 10178 | ||
| 9634 | If $a^2=b$ and \( b=2 \), then the solution must be | 10179 | If $a^2=b$ and \( b=2 \), then the solution must be |
| 9635 | either $$ a=+\sqrt@{2@} $$ or \[ a=-\sqrt@{2@} \]. | 10180 | either $$ a=+\sqrt@{2@} $$ or \[ a=-\sqrt@{2@} \]. |
| 9636 | @end example | 10181 | @end example |
| 9637 | 10182 | ||
| 9638 | @noindent | 10183 | @c FIXME |
| 9639 | @vindex org-format-latex-options | 10184 | @c @noindent |
| 9640 | If you need any of the delimiter ASCII sequences for other purposes, you | 10185 | @c @vindex org-format-latex-options |
| 9641 | can configure the option @code{org-format-latex-options} to deselect the | 10186 | @c If you need any of the delimiter ASCII sequences for other purposes, you |
| 9642 | ones you do not wish to have interpreted by the @LaTeX{} converter. | 10187 | @c can configure the option @code{org-format-latex-options} to deselect the |
| 10188 | @c ones you do not wish to have interpreted by the @LaTeX{} converter. | ||
| 9643 | 10189 | ||
| 9644 | @vindex org-export-with-LaTeX-fragments | 10190 | @vindex org-export-with-latex |
| 9645 | @LaTeX{} processing can be configured with the variable | 10191 | @LaTeX{} processing can be configured with the variable |
| 9646 | @code{org-export-with-LaTeX-fragments}. The default setting is @code{t} | 10192 | @code{org-export-with-latex}. The default setting is @code{t} which means |
| 9647 | which means @file{MathJax} for HTML, and no processing for DocBook, ASCII and | 10193 | @file{MathJax} for HTML, and no processing for ASCII and @LaTeX{} back-ends. |
| 9648 | @LaTeX{} backends. You can also set this variable on a per-file basis using one | 10194 | You can also set this variable on a per-file basis using one of these |
| 9649 | of these lines: | 10195 | lines: |
| 9650 | 10196 | ||
| 9651 | @example | 10197 | @example |
| 9652 | #+OPTIONS: LaTeX:t @r{Do the right thing automatically (MathJax)} | 10198 | #+OPTIONS: tex:t @r{Do the right thing automatically (MathJax)} |
| 9653 | #+OPTIONS: LaTeX:dvipng @r{Force using dvipng images} | 10199 | #+OPTIONS: tex:nil @r{Do not process @LaTeX{} fragments at all} |
| 9654 | #+OPTIONS: LaTeX:nil @r{Do not process @LaTeX{} fragments at all} | 10200 | #+OPTIONS: tex:verbatim @r{Verbatim export, for jsMath or so} |
| 9655 | #+OPTIONS: LaTeX:verbatim @r{Verbatim export, for jsMath or so} | ||
| 9656 | @end example | 10201 | @end example |
| 9657 | 10202 | ||
| 9658 | @node Previewing @LaTeX{} fragments, CDLaTeX mode, @LaTeX{} fragments, Embedded @LaTeX{} | 10203 | @node Previewing @LaTeX{} fragments, CDLaTeX mode, @LaTeX{} fragments, Embedded @LaTeX{} |
| 9659 | @subsection Previewing @LaTeX{} fragments | 10204 | @subsection Previewing @LaTeX{} fragments |
| 9660 | @cindex @LaTeX{} fragments, preview | 10205 | @cindex @LaTeX{} fragments, preview |
| 9661 | 10206 | ||
| 9662 | If you have @file{dvipng} installed, @LaTeX{} fragments can be processed to | 10207 | @vindex org-latex-create-formula-image-program |
| 9663 | produce preview images of the typeset expressions: | 10208 | If you have @file{dvipng} or @file{imagemagick} installed@footnote{Choose the |
| 10209 | converter by setting the variable | ||
| 10210 | @code{org-latex-create-formula-image-program} accordingly.}, @LaTeX{} | ||
| 10211 | fragments can be processed to produce preview images of the typeset | ||
| 10212 | expressions: | ||
| 9664 | 10213 | ||
| 9665 | @table @kbd | 10214 | @table @kbd |
| 9666 | @kindex C-c C-x C-l | 10215 | @kindex C-c C-x C-l |
| @@ -9682,6 +10231,19 @@ some aspects of the preview. In particular, the @code{:scale} (and for HTML | |||
| 9682 | export, @code{:html-scale}) property can be used to adjust the size of the | 10231 | export, @code{:html-scale}) property can be used to adjust the size of the |
| 9683 | preview images. | 10232 | preview images. |
| 9684 | 10233 | ||
| 10234 | @vindex org-startup-with-latex-preview | ||
| 10235 | You can turn on the previewing of all @LaTeX{} fragments in a file with | ||
| 10236 | |||
| 10237 | @example | ||
| 10238 | #+STARTUP: latexpreview | ||
| 10239 | @end example | ||
| 10240 | |||
| 10241 | To disable it, simply use | ||
| 10242 | |||
| 10243 | @example | ||
| 10244 | #+STARTUP: nolatexpreview | ||
| 10245 | @end example | ||
| 10246 | |||
| 9685 | @node CDLaTeX mode, , Previewing @LaTeX{} fragments, Embedded @LaTeX{} | 10247 | @node CDLaTeX mode, , Previewing @LaTeX{} fragments, Embedded @LaTeX{} |
| 9686 | @subsection Using CD@LaTeX{} to enter math | 10248 | @subsection Using CD@LaTeX{} to enter math |
| 9687 | @cindex CD@LaTeX{} | 10249 | @cindex CD@LaTeX{} |
| @@ -9694,7 +10256,7 @@ some of the features of CD@LaTeX{} mode. You need to install | |||
| 9694 | AUC@TeX{}) from @url{http://www.astro.uva.nl/~dominik/Tools/cdlatex}. | 10256 | AUC@TeX{}) from @url{http://www.astro.uva.nl/~dominik/Tools/cdlatex}. |
| 9695 | Don't use CD@LaTeX{} mode itself under Org mode, but use the light | 10257 | Don't use CD@LaTeX{} mode itself under Org mode, but use the light |
| 9696 | version @code{org-cdlatex-mode} that comes as part of Org mode. Turn it | 10258 | version @code{org-cdlatex-mode} that comes as part of Org mode. Turn it |
| 9697 | on for the current buffer with @code{M-x org-cdlatex-mode}, or for all | 10259 | on for the current buffer with @kbd{M-x org-cdlatex-mode RET}, or for all |
| 9698 | Org files with | 10260 | Org files with |
| 9699 | 10261 | ||
| 9700 | @lisp | 10262 | @lisp |
| @@ -9719,7 +10281,7 @@ the second brace. Even outside fragments, @key{TAB} will expand | |||
| 9719 | environment abbreviations at the beginning of a line. For example, if | 10281 | environment abbreviations at the beginning of a line. For example, if |
| 9720 | you write @samp{equ} at the beginning of a line and press @key{TAB}, | 10282 | you write @samp{equ} at the beginning of a line and press @key{TAB}, |
| 9721 | this abbreviation will be expanded to an @code{equation} environment. | 10283 | this abbreviation will be expanded to an @code{equation} environment. |
| 9722 | To get a list of all abbreviations, type @kbd{M-x cdlatex-command-help}. | 10284 | To get a list of all abbreviations, type @kbd{M-x cdlatex-command-help RET}. |
| 9723 | @item | 10285 | @item |
| 9724 | @kindex _ | 10286 | @kindex _ |
| 9725 | @kindex ^ | 10287 | @kindex ^ |
| @@ -9743,235 +10305,394 @@ modification will work only inside @LaTeX{} fragments; outside the quote | |||
| 9743 | is normal. | 10305 | is normal. |
| 9744 | @end itemize | 10306 | @end itemize |
| 9745 | 10307 | ||
| 10308 | @node Special blocks, , Embedded @LaTeX{}, Markup | ||
| 10309 | @section Special blocks | ||
| 10310 | @cindex Special blocks | ||
| 10311 | |||
| 10312 | Org syntax includes pre-defined blocks (@pxref{Paragraphs} and @ref{Literal | ||
| 10313 | examples}). It is also possible to create blocks containing raw code | ||
| 10314 | targeted at a specific back-ends (e.g., @samp{#+BEGIN_LATEX}). | ||
| 10315 | |||
| 10316 | Any other block is a @emph{special block}. Each export back-end decides if | ||
| 10317 | they should be exported, and how. When the block is ignored, its contents | ||
| 10318 | are still exported, as if the block were not there. For example, when | ||
| 10319 | exporting a @samp{#+BEGIN_TEST} block, HTML back-end wraps its contents | ||
| 10320 | within @samp{<div name="test">} tag. Refer to back-end specific | ||
| 10321 | documentation for more information. | ||
| 10322 | |||
| 9746 | @node Exporting, Publishing, Markup, Top | 10323 | @node Exporting, Publishing, Markup, Top |
| 9747 | @chapter Exporting | 10324 | @chapter Exporting |
| 9748 | @cindex exporting | 10325 | @cindex exporting |
| 9749 | 10326 | ||
| 9750 | Org mode documents can be exported into a variety of other formats. For | 10327 | The Org mode export facilities can be used to export Org documents or parts |
| 9751 | printing and sharing of notes, ASCII export produces a readable and simple | 10328 | of Org documents to a variety of other formats. In addition, these |
| 9752 | version of an Org file. HTML export allows you to publish a notes file on | 10329 | facilities can be used with @code{orgtbl-mode} and/or @code{orgstruct-mode} |
| 9753 | the web, while the XOXO format provides a solid base for exchange with a | 10330 | in foreign buffers so you can author tables and lists in Org syntax and |
| 9754 | broad range of other applications. @LaTeX{} export lets you use Org mode and | 10331 | convert them in place to the target language. |
| 9755 | its structured editing functions to easily create @LaTeX{} files. DocBook | 10332 | |
| 9756 | export makes it possible to convert Org files to many other formats using | 10333 | ASCII export produces a readable and simple version of an Org file for |
| 9757 | DocBook tools. OpenDocument Text (ODT) export allows seamless | 10334 | printing and sharing notes. HTML export allows you to easily publish notes |
| 9758 | collaboration across organizational boundaries. For project management you | 10335 | on the web, or to build full-fledged websites. @LaTeX{} export lets you use |
| 9759 | can create gantt and resource charts by using TaskJuggler export. To | 10336 | Org mode and its structured editing functions to create arbitrarily complex |
| 9760 | incorporate entries with associated times like deadlines or appointments into | 10337 | @LaTeX{} files for any kind of document. OpenDocument Text (ODT) export |
| 9761 | a desktop calendar program like iCal, Org mode can also produce extracts in | 10338 | allows seamless collaboration across organizational boundaries. Markdown |
| 9762 | the iCalendar format. Currently, Org mode only supports export, not import of | 10339 | export lets you seamlessly collaborate with other developers. Finally, iCal |
| 9763 | these different formats. | 10340 | export can extract entries with deadlines or appointments to produce a file |
| 9764 | 10341 | in the iCalendar format. | |
| 9765 | Org supports export of selected regions when @code{transient-mark-mode} is | ||
| 9766 | enabled (default in Emacs 23). | ||
| 9767 | 10342 | ||
| 9768 | @menu | 10343 | @menu |
| 9769 | * Selective export:: Using tags to select and exclude trees | 10344 | * The Export Dispatcher:: The main exporter interface |
| 9770 | * Export options:: Per-file export settings | 10345 | * Export back-ends:: Built-in export formats |
| 9771 | * The export dispatcher:: How to access exporter commands | 10346 | * Export settings:: Generic export settings |
| 9772 | * ASCII/Latin-1/UTF-8 export:: Exporting to flat files with encoding | 10347 | * ASCII/Latin-1/UTF-8 export:: Exporting to flat files with encoding |
| 10348 | * Beamer export:: Exporting as a Beamer presentation | ||
| 9773 | * HTML export:: Exporting to HTML | 10349 | * HTML export:: Exporting to HTML |
| 9774 | * @LaTeX{} and PDF export:: Exporting to @LaTeX{}, and processing to PDF | 10350 | * @LaTeX{} and PDF export:: Exporting to @LaTeX{}, and processing to PDF |
| 9775 | * DocBook export:: Exporting to DocBook | 10351 | * Markdown export:: Exporting to Markdown |
| 9776 | * OpenDocument Text export:: Exporting to OpenDocument Text | 10352 | * OpenDocument Text export:: Exporting to OpenDocument Text |
| 9777 | * TaskJuggler export:: Exporting to TaskJuggler | 10353 | * iCalendar export:: Exporting to iCalendar |
| 9778 | * Freemind export:: Exporting to Freemind mind maps | 10354 | * Other built-in back-ends:: Exporting to @code{Texinfo}, a man page, or Org |
| 9779 | * XOXO export:: Exporting to XOXO | 10355 | * Export in foreign buffers:: Author tables in lists in Org syntax |
| 9780 | * iCalendar export:: Exporting in iCalendar format | 10356 | * Advanced configuration:: Fine-tuning the export output |
| 9781 | @end menu | 10357 | @end menu |
| 9782 | 10358 | ||
| 9783 | @node Selective export, Export options, Exporting, Exporting | 10359 | @node The Export Dispatcher, Export back-ends, Exporting, Exporting |
| 9784 | @section Selective export | 10360 | @section The Export Dispatcher |
| 9785 | @cindex export, selective by tags or TODO keyword | 10361 | @vindex org-export-dispatch-use-expert-ui |
| 10362 | @cindex Export, dispatcher | ||
| 10363 | |||
| 10364 | The main entry point for export related tasks is the dispatcher, a | ||
| 10365 | hierarchical menu from which it is possible to select an export format and | ||
| 10366 | toggle export options@footnote{It is also possible to use a less intrusive | ||
| 10367 | interface by setting @code{org-export-dispatch-use-expert-ui} to a | ||
| 10368 | non-@code{nil} value. In that case, only a prompt is visible from the | ||
| 10369 | minibuffer. From there one can still switch back to regular menu by pressing | ||
| 10370 | @key{?}.} from which it is possible to select an export format and to toggle | ||
| 10371 | export options. | ||
| 10372 | |||
| 10373 | @c @quotation | ||
| 10374 | @table @asis | ||
| 10375 | @orgcmd{C-c C-e,org-export-dispatch} | ||
| 9786 | 10376 | ||
| 9787 | @vindex org-export-select-tags | 10377 | Dispatch for export and publishing commands. When called with a @kbd{C-u} |
| 9788 | @vindex org-export-exclude-tags | 10378 | prefix argument, repeat the last export command on the current buffer while |
| 9789 | @cindex org-export-with-tasks | 10379 | preserving toggled options. If the current buffer hasn't changed and subtree |
| 9790 | You may use tags to select the parts of a document that should be exported, | 10380 | export was activated, the command will affect that same subtree. |
| 9791 | or to exclude parts from export. This behavior is governed by two variables: | 10381 | @end table |
| 9792 | @code{org-export-select-tags} and @code{org-export-exclude-tags}, | 10382 | @c @end quotation |
| 9793 | respectively defaulting to @code{'(:export:)} and @code{'(:noexport:)}. | ||
| 9794 | 10383 | ||
| 9795 | @enumerate | 10384 | Normally the entire buffer is exported, but if there is an active region |
| 9796 | @item | 10385 | only that part of the buffer will be exported. |
| 9797 | Org first checks if any of the @emph{select} tags is present in the | ||
| 9798 | buffer. If yes, all trees that do not carry one of these tags will be | ||
| 9799 | excluded. If a selected tree is a subtree, the heading hierarchy above it | ||
| 9800 | will also be selected for export, but not the text below those headings. | ||
| 9801 | 10386 | ||
| 9802 | @item | 10387 | Several export options (@pxref{Export settings}) can be toggled from the |
| 9803 | If none of the select tags is found, the whole buffer will be selected for | 10388 | export dispatcher with the following key combinations: |
| 9804 | export. | ||
| 9805 | 10389 | ||
| 9806 | @item | 10390 | @table @kbd |
| 9807 | Finally, all subtrees that are marked by any of the @emph{exclude} tags will | 10391 | @item C-a |
| 9808 | be removed from the export buffer. | 10392 | @vindex org-export-async-init-file |
| 9809 | @end enumerate | 10393 | Toggle asynchronous export. Asynchronous export uses an external Emacs |
| 10394 | process that is configured with a specified initialization file. | ||
| 9810 | 10395 | ||
| 9811 | The variable @code{org-export-with-tasks} can be configured to select which | 10396 | While exporting asynchronously, the output is not displayed. It is stored in |
| 9812 | kind of tasks should be included for export. See the docstring of the | 10397 | a list called ``the export stack'', and can be viewed from there. The stack |
| 9813 | variable for more information. | 10398 | can be reached by calling the dispatcher with a double @kbd{C-u} prefix |
| 10399 | argument, or with @kbd{&} key from the dispatcher. | ||
| 9814 | 10400 | ||
| 9815 | @node Export options, The export dispatcher, Selective export, Exporting | 10401 | @vindex org-export-in-background |
| 9816 | @section Export options | 10402 | To make this behaviour the default, customize the variable |
| 9817 | @cindex options, for export | 10403 | @code{org-export-in-background}. |
| 9818 | 10404 | ||
| 9819 | @cindex completion, of option keywords | 10405 | @item C-b |
| 9820 | The exporter recognizes special lines in the buffer which provide | 10406 | Toggle body-only export. Its effect depends on the back-end used. |
| 9821 | additional information. These lines may be put anywhere in the file. | 10407 | Typically, if the back-end has a header section (like @code{<head>...</head>} |
| 9822 | The whole set of lines can be inserted into the buffer with @kbd{C-c | 10408 | in the HTML back-end), a body-only export will not include this header. |
| 9823 | C-e t}. For individual lines, a good way to make sure the keyword is | 10409 | |
| 9824 | correct is to type @samp{#+} and then use @kbd{M-@key{TAB}} completion | 10410 | @item C-s |
| 9825 | (@pxref{Completion}). For a summary of other in-buffer settings not | 10411 | @vindex org-export-initial-scope |
| 9826 | specifically related to export, see @ref{In-buffer settings}. | 10412 | Toggle subtree export. The top heading becomes the document title. |
| 9827 | In particular, note that you can place commonly-used (export) options in | 10413 | |
| 9828 | a separate file which can be included using @code{#+SETUPFILE}. | 10414 | You can change the default state of this option by setting |
| 10415 | @code{org-export-initial-scope}. | ||
| 10416 | |||
| 10417 | @item C-v | ||
| 10418 | Toggle visible-only export. Only export the text that is currently | ||
| 10419 | visible, i.e. not hidden by outline visibility in the buffer. | ||
| 9829 | 10420 | ||
| 9830 | @table @kbd | ||
| 9831 | @orgcmd{C-c C-e t,org-insert-export-options-template} | ||
| 9832 | Insert template with export options, see example below. | ||
| 9833 | @end table | 10421 | @end table |
| 9834 | 10422 | ||
| 9835 | @cindex #+TITLE | 10423 | @vindex org-export-copy-to-kill-ring |
| 9836 | @cindex #+AUTHOR | 10424 | With the exception of asynchronous export, a successful export process writes |
| 9837 | @cindex #+DATE | 10425 | its output to the kill-ring. You can configure this behavior by altering the |
| 9838 | @cindex #+EMAIL | 10426 | option @code{org-export-copy-to-kill-ring}. |
| 9839 | @cindex #+DESCRIPTION | 10427 | |
| 9840 | @cindex #+KEYWORDS | 10428 | @node Export back-ends, Export settings, The Export Dispatcher, Exporting |
| 9841 | @cindex #+LANGUAGE | 10429 | @section Export back-ends |
| 9842 | @cindex #+TEXT | 10430 | @cindex Export, back-ends |
| 9843 | @cindex #+OPTIONS | 10431 | |
| 9844 | @cindex #+BIND | 10432 | An export back-end is a library that translates Org syntax into a foreign |
| 9845 | @cindex #+LINK_UP | 10433 | format. An export format is not available until the proper back-end has been |
| 9846 | @cindex #+LINK_HOME | 10434 | loaded. |
| 9847 | @cindex #+EXPORT_SELECT_TAGS | 10435 | |
| 9848 | @cindex #+EXPORT_EXCLUDE_TAGS | 10436 | @vindex org-export-backends |
| 9849 | @cindex #+XSLT | 10437 | By default, the following four back-ends are loaded: @code{ascii}, |
| 9850 | @cindex #+LaTeX_HEADER | 10438 | @code{html}, @code{icalendar} and @code{latex}. It is possible to add more |
| 10439 | (or remove some) by customizing @code{org-export-backends}. | ||
| 10440 | |||
| 10441 | Built-in back-ends include: | ||
| 10442 | |||
| 10443 | @itemize | ||
| 10444 | @item ascii (ASCII format) | ||
| 10445 | @item beamer (@LaTeX{} Beamer format) | ||
| 10446 | @item html (HTML format) | ||
| 10447 | @item icalendar (iCalendar format) | ||
| 10448 | @item latex (@LaTeX{} format) | ||
| 10449 | @item man (Man page format) | ||
| 10450 | @item md (Markdown format) | ||
| 10451 | @item odt (OpenDocument Text format) | ||
| 10452 | @item texinfo (Texinfo format) | ||
| 10453 | @end itemize | ||
| 10454 | |||
| 10455 | Other back-ends might be found in the @code{contrib/} directory | ||
| 10456 | (@pxref{Installation}). | ||
| 10457 | |||
| 10458 | @node Export settings, ASCII/Latin-1/UTF-8 export, Export back-ends, Exporting | ||
| 10459 | @section Export settings | ||
| 10460 | @cindex Export, settings | ||
| 10461 | |||
| 10462 | Export options can be set: globally with variables; for an individual file by | ||
| 10463 | making variables buffer-local with in-buffer settings (@pxref{In-buffer | ||
| 10464 | settings}), by setting individual keywords, or by specifying them in a | ||
| 10465 | compact form with the @code{#+OPTIONS} keyword; or for a tree by setting | ||
| 10466 | properties (@pxref{Properties and Columns}). Options set at a specific level | ||
| 10467 | override options set at a more general level. | ||
| 10468 | |||
| 10469 | @cindex #+SETUPFILE | ||
| 10470 | In-buffer settings may appear anywhere in the file, either directly or | ||
| 10471 | indirectly through a file included using @samp{#+SETUPFILE: filename} syntax. | ||
| 10472 | Option keyword sets tailored to a particular back-end can be inserted from | ||
| 10473 | the export dispatcher (@pxref{The Export Dispatcher}) using the @code{Insert | ||
| 10474 | template} command by pressing @key{#}. To insert keywords individually, | ||
| 10475 | a good way to make sure the keyword is correct is to type @code{#+} and then | ||
| 10476 | to use @kbd{M-<TAB>} for completion. | ||
| 10477 | |||
| 10478 | The export keywords available for every back-end, and their equivalent global | ||
| 10479 | variables, include: | ||
| 10480 | |||
| 10481 | @table @samp | ||
| 10482 | @item AUTHOR | ||
| 9851 | @vindex user-full-name | 10483 | @vindex user-full-name |
| 10484 | The document author (@code{user-full-name}). | ||
| 10485 | |||
| 10486 | @item CREATOR | ||
| 10487 | @vindex org-export-creator-string | ||
| 10488 | Entity responsible for output generation (@code{org-export-creator-string}). | ||
| 10489 | |||
| 10490 | @item DATE | ||
| 10491 | @vindex org-export-date-timestamp-format | ||
| 10492 | A date or a time-stamp@footnote{The variable | ||
| 10493 | @code{org-export-date-timestamp-format} defines how this time-stamp will be | ||
| 10494 | exported.}. | ||
| 10495 | |||
| 10496 | @item DESCRIPTION | ||
| 10497 | The document description. Back-ends handle it as they see fit (e.g., for the | ||
| 10498 | XHTML meta tag), if at all. You can use several such keywords for long | ||
| 10499 | descriptions. | ||
| 10500 | |||
| 10501 | @item EMAIL | ||
| 9852 | @vindex user-mail-address | 10502 | @vindex user-mail-address |
| 10503 | The email address (@code{user-mail-address}). | ||
| 10504 | |||
| 10505 | @item KEYWORDS | ||
| 10506 | The keywords defining the contents of the document. Back-ends handle it as | ||
| 10507 | they see fit (e.g., for the XHTML meta tag), if at all. You can use several | ||
| 10508 | such keywords if the list is long. | ||
| 10509 | |||
| 10510 | @item LANGUAGE | ||
| 9853 | @vindex org-export-default-language | 10511 | @vindex org-export-default-language |
| 9854 | @vindex org-export-date-timestamp-format | 10512 | The language used for translating some strings |
| 9855 | @example | 10513 | (@code{org-export-default-language}). E.g., @samp{#+LANGUAGE: fr} will tell |
| 9856 | #+TITLE: the title to be shown (default is the buffer name) | 10514 | Org to translate @emph{File} (english) into @emph{Fichier} (french) in the |
| 9857 | #+AUTHOR: the author (default taken from @code{user-full-name}) | 10515 | clocktable. |
| 9858 | #+DATE: a date, an Org timestamp@footnote{@code{org-export-date-timestamp-format} defines how this timestamp will be exported.}, or a format string for @code{format-time-string} | ||
| 9859 | #+EMAIL: his/her email address (default from @code{user-mail-address}) | ||
| 9860 | #+DESCRIPTION: the page description, e.g., for the XHTML meta tag | ||
| 9861 | #+KEYWORDS: the page keywords, e.g., for the XHTML meta tag | ||
| 9862 | #+LANGUAGE: language for HTML, e.g., @samp{en} (@code{org-export-default-language}) | ||
| 9863 | #+TEXT: Some descriptive text to be inserted at the beginning. | ||
| 9864 | #+TEXT: Several lines may be given. | ||
| 9865 | #+OPTIONS: H:2 num:t toc:t \n:nil @@:t ::t |:t ^:t f:t TeX:t ... | ||
| 9866 | #+BIND: lisp-var lisp-val, e.g., @code{org-export-latex-low-levels itemize} | ||
| 9867 | @r{You need to confirm using these, or configure @code{org-export-allow-BIND}} | ||
| 9868 | #+LINK_UP: the ``up'' link of an exported page | ||
| 9869 | #+LINK_HOME: the ``home'' link of an exported page | ||
| 9870 | #+LaTeX_HEADER: extra line(s) for the @LaTeX{} header, like \usepackage@{xyz@} | ||
| 9871 | #+EXPORT_SELECT_TAGS: Tags that select a tree for export | ||
| 9872 | #+EXPORT_EXCLUDE_TAGS: Tags that exclude a tree from export | ||
| 9873 | #+XSLT: the XSLT stylesheet used by DocBook exporter to generate FO file | ||
| 9874 | @end example | ||
| 9875 | 10516 | ||
| 9876 | @noindent | 10517 | @item SELECT_TAGS |
| 9877 | The @code{#+OPTIONS} line is a compact@footnote{If you want to configure many options | 10518 | @vindex org-export-select-tags |
| 9878 | this way, you can use several @code{#+OPTIONS} lines.} form to specify export | 10519 | The tags that select a tree for export (@code{org-export-select-tags}). The |
| 9879 | settings. Here you can: | 10520 | default value is @code{:export:}. Within a subtree tagged with |
| 9880 | @cindex headline levels | 10521 | @code{:export:}, you can still exclude entries with @code{:noexport:} (see |
| 9881 | @cindex section-numbers | 10522 | below). |
| 9882 | @cindex table of contents | 10523 | |
| 9883 | @cindex line-break preservation | 10524 | @item EXCLUDE_TAGS |
| 9884 | @cindex quoted HTML tags | 10525 | The tags that exclude a tree from export (@code{org-export-exclude-tags}). |
| 9885 | @cindex fixed-width sections | 10526 | The default value is @code{:noexport:}. Entries with the @code{:noexport:} |
| 9886 | @cindex tables | 10527 | tag will be unconditionally excluded from the export, even if they have an |
| 9887 | @cindex @TeX{}-like syntax for sub- and superscripts | 10528 | @code{:export:} tag. |
| 9888 | @cindex footnotes | 10529 | |
| 9889 | @cindex special strings | 10530 | @item TITLE |
| 9890 | @cindex emphasized text | 10531 | The title to be shown (otherwise derived from buffer's name). You can use |
| 9891 | @cindex @TeX{} macros | 10532 | several such keywords for long titles. |
| 9892 | @cindex @LaTeX{} fragments | 10533 | @end table |
| 9893 | @cindex author info, in export | 10534 | |
| 9894 | @cindex time info, in export | 10535 | The @code{#+OPTIONS} keyword is a compact@footnote{If you want to configure |
| 9895 | @vindex org-export-plist-vars | 10536 | many options this way, you can use several @code{#+OPTIONS} lines.} form that |
| 9896 | @vindex org-export-author-info | 10537 | recognizes the following arguments: |
| 9897 | @vindex org-export-creator-info | 10538 | |
| 9898 | @vindex org-export-email-info | 10539 | @table @code |
| 10540 | @item ': | ||
| 10541 | @vindex org-export-with-smart-quotes | ||
| 10542 | Toggle smart quotes (@code{org-export-with-smart-quotes}). | ||
| 10543 | |||
| 10544 | @item *: | ||
| 10545 | Toggle emphasized text (@code{org-export-with-emphasize}). | ||
| 10546 | |||
| 10547 | @item -: | ||
| 10548 | @vindex org-export-with-special-strings | ||
| 10549 | Toggle conversion of special strings | ||
| 10550 | (@code{org-export-with-special-strings}). | ||
| 10551 | |||
| 10552 | @item :: | ||
| 10553 | @vindex org-export-with-fixed-width | ||
| 10554 | Toggle fixed-width sections | ||
| 10555 | (@code{org-export-with-fixed-width}). | ||
| 10556 | |||
| 10557 | @item <: | ||
| 10558 | @vindex org-export-with-timestamps | ||
| 10559 | Toggle inclusion of any time/date active/inactive stamps | ||
| 10560 | (@code{org-export-with-timestamps}). | ||
| 10561 | |||
| 10562 | @item : | ||
| 10563 | @vindex org-export-preserve-breaks | ||
| 10564 | Toggle line-break-preservation (@code{org-export-preserve-breaks}). | ||
| 10565 | |||
| 10566 | @item ^: | ||
| 10567 | @vindex org-export-with-sub-superscripts | ||
| 10568 | Toggle @TeX{}-like syntax for sub- and superscripts. If you write "^:@{@}", | ||
| 10569 | @samp{a_@{b@}} will be interpreted, but the simple @samp{a_b} will be left as | ||
| 10570 | it is (@code{org-export-with-sub-superscripts}). | ||
| 10571 | |||
| 10572 | @item arch: | ||
| 10573 | @vindex org-export-with-archived-trees | ||
| 10574 | Configure export of archived trees. Can be set to @code{headline} to only | ||
| 10575 | process the headline, skipping its contents | ||
| 10576 | (@code{org-export-with-archived-trees}). | ||
| 10577 | |||
| 10578 | @item author: | ||
| 10579 | @vindex org-export-with-author | ||
| 10580 | Toggle inclusion of author name into exported file | ||
| 10581 | (@code{org-export-with-author}). | ||
| 10582 | |||
| 10583 | @item c: | ||
| 10584 | @vindex org-export-with-clocks | ||
| 10585 | Toggle inclusion of CLOCK keywords (@code{org-export-with-clocks}). | ||
| 10586 | |||
| 10587 | @item creator: | ||
| 10588 | @vindex org-export-with-creator | ||
| 10589 | Configure inclusion of creator info into exported file. It may be set to | ||
| 10590 | @code{comment} (@code{org-export-with-creator}). | ||
| 10591 | |||
| 10592 | @item d: | ||
| 10593 | @vindex org-export-with-drawers | ||
| 10594 | Toggle inclusion of drawers, or list drawers to include | ||
| 10595 | (@code{org-export-with-drawers}). | ||
| 10596 | |||
| 10597 | @item e: | ||
| 10598 | @vindex org-export-with-entities | ||
| 10599 | Toggle inclusion of entities (@code{org-export-with-entities}). | ||
| 10600 | |||
| 10601 | @item email: | ||
| 10602 | @vindex org-export-with-email | ||
| 10603 | Toggle inclusion of the author's e-mail into exported file | ||
| 10604 | (@code{org-export-with-email}). | ||
| 10605 | |||
| 10606 | @item f: | ||
| 10607 | @vindex org-export-with-footnotes | ||
| 10608 | Toggle the inclusion of footnotes (@code{org-export-with-footnotes}). | ||
| 10609 | |||
| 10610 | @item H: | ||
| 10611 | @vindex org-export-headline-levels | ||
| 10612 | Set the number of headline levels for export | ||
| 10613 | (@code{org-export-headline-levels}). Below that level, headlines are treated | ||
| 10614 | differently. In most back-ends, they become list items. | ||
| 10615 | |||
| 10616 | @item inline: | ||
| 10617 | @vindex org-export-with-inlinetasks | ||
| 10618 | Toggle inclusion of inlinetasks (@code{org-export-with-inlinetasks}). | ||
| 10619 | |||
| 10620 | @item num: | ||
| 10621 | @vindex org-export-with-section-numbers | ||
| 10622 | Toggle section-numbers (@code{org-export-with-section-numbers}). It can also | ||
| 10623 | be set to a number @samp{n}, so only headlines at that level or above will be | ||
| 10624 | numbered. | ||
| 10625 | |||
| 10626 | @item p: | ||
| 10627 | @vindex org-export-with-planning | ||
| 10628 | Toggle export of planning information (@code{org-export-with-planning}). | ||
| 10629 | ``Planning information'' is the line containing the @code{SCHEDULED:}, the | ||
| 10630 | @code{DEADLINE:} or the @code{CLOSED:} cookies or a combination of them. | ||
| 10631 | |||
| 10632 | @item pri: | ||
| 10633 | @vindex org-export-with-priority | ||
| 10634 | Toggle inclusion of priority cookies (@code{org-export-with-priority}). | ||
| 10635 | |||
| 10636 | @item stat: | ||
| 10637 | @vindex org-export-with-statistics-cookies | ||
| 10638 | Toggle inclusion of statistics cookies | ||
| 10639 | (@code{org-export-with-statistics-cookies}). | ||
| 10640 | |||
| 10641 | @item tags: | ||
| 10642 | @vindex org-export-with-tags | ||
| 10643 | Toggle inclusion of tags, may also be @code{not-in-toc} | ||
| 10644 | (@code{org-export-with-tags}). | ||
| 10645 | |||
| 10646 | @item tasks: | ||
| 10647 | @vindex org-export-with-tasks | ||
| 10648 | Toggle inclusion of tasks (TODO items), can be @code{nil} to remove all | ||
| 10649 | tasks, @code{todo} to remove DONE tasks, or a list of keywords to keep | ||
| 10650 | (@code{org-export-with-tasks}). | ||
| 10651 | |||
| 10652 | @item tex: | ||
| 10653 | @vindex org-export-with-latex | ||
| 10654 | Configure export of @LaTeX{} fragments and environments. It may be set to | ||
| 10655 | @code{verbatim} (@code{org-export-with-latex}). | ||
| 10656 | |||
| 10657 | @item timestamp: | ||
| 9899 | @vindex org-export-time-stamp-file | 10658 | @vindex org-export-time-stamp-file |
| 9900 | @example | 10659 | Toggle inclusion of the creation time into exported file |
| 9901 | H: @r{set the number of headline levels for export} | 10660 | (@code{org-export-time-stamp-file}). |
| 9902 | num: @r{turn on/off section-numbers} | ||
| 9903 | toc: @r{turn on/off table of contents, or set level limit (integer)} | ||
| 9904 | \n: @r{turn on/off line-break-preservation (DOES NOT WORK)} | ||
| 9905 | @@: @r{turn on/off quoted HTML tags} | ||
| 9906 | :: @r{turn on/off fixed-width sections} | ||
| 9907 | |: @r{turn on/off tables} | ||
| 9908 | ^: @r{turn on/off @TeX{}-like syntax for sub- and superscripts. If} | ||
| 9909 | @r{you write "^:@{@}", @code{a_@{b@}} will be interpreted, but} | ||
| 9910 | @r{the simple @code{a_b} will be left as it is.} | ||
| 9911 | -: @r{turn on/off conversion of special strings.} | ||
| 9912 | f: @r{turn on/off footnotes like this[1].} | ||
| 9913 | todo: @r{turn on/off inclusion of TODO keywords into exported text} | ||
| 9914 | tasks: @r{turn on/off inclusion of tasks (TODO items), can be nil to remove} | ||
| 9915 | @r{all tasks, @code{todo} to remove DONE tasks, or list of kwds to keep} | ||
| 9916 | pri: @r{turn on/off priority cookies} | ||
| 9917 | tags: @r{turn on/off inclusion of tags, may also be @code{not-in-toc}} | ||
| 9918 | <: @r{turn on/off inclusion of any time/date stamps like DEADLINES} | ||
| 9919 | *: @r{turn on/off emphasized text (bold, italic, underlined)} | ||
| 9920 | TeX: @r{turn on/off simple @TeX{} macros in plain text} | ||
| 9921 | LaTeX: @r{configure export of @LaTeX{} fragments. Default @code{auto}} | ||
| 9922 | skip: @r{turn on/off skipping the text before the first heading} | ||
| 9923 | author: @r{turn on/off inclusion of author name/email into exported file} | ||
| 9924 | email: @r{turn on/off inclusion of author email into exported file} | ||
| 9925 | creator: @r{turn on/off inclusion of creator info into exported file} | ||
| 9926 | timestamp: @r{turn on/off inclusion creation time into exported file} | ||
| 9927 | d: @r{turn on/off inclusion of drawers, or list drawers to include} | ||
| 9928 | @end example | ||
| 9929 | @noindent | ||
| 9930 | These options take effect in both the HTML and @LaTeX{} export, except for | ||
| 9931 | @code{TeX} and @code{LaTeX} options, which are respectively @code{t} and | ||
| 9932 | @code{nil} for the @LaTeX{} export. | ||
| 9933 | |||
| 9934 | The default values for these and many other options are given by a set of | ||
| 9935 | variables. For a list of such variables, the corresponding OPTIONS keys and | ||
| 9936 | also the publishing keys (@pxref{Project alist}), see the constant | ||
| 9937 | @code{org-export-plist-vars}. | ||
| 9938 | |||
| 9939 | When exporting only a single subtree by selecting it with @kbd{C-c @@} before | ||
| 9940 | calling an export command, the subtree can overrule some of the file's export | ||
| 9941 | settings with properties @code{EXPORT_FILE_NAME}, @code{EXPORT_TITLE}, | ||
| 9942 | @code{EXPORT_TEXT}, @code{EXPORT_AUTHOR}, @code{EXPORT_DATE}, and | ||
| 9943 | @code{EXPORT_OPTIONS}. | ||
| 9944 | |||
| 9945 | @node The export dispatcher, ASCII/Latin-1/UTF-8 export, Export options, Exporting | ||
| 9946 | @section The export dispatcher | ||
| 9947 | @cindex dispatcher, for export commands | ||
| 9948 | |||
| 9949 | All export commands can be reached using the export dispatcher, which is a | ||
| 9950 | prefix key that prompts for an additional key specifying the command. | ||
| 9951 | Normally the entire file is exported, but if there is an active region that | ||
| 9952 | contains one outline tree, the first heading is used as document title and | ||
| 9953 | the subtrees are exported. | ||
| 9954 | 10661 | ||
| 9955 | @table @kbd | 10662 | @item toc: |
| 9956 | @orgcmd{C-c C-e,org-export} | 10663 | @vindex org-export-with-toc |
| 9957 | @vindex org-export-run-in-background | 10664 | Toggle inclusion of the table of contents, or set the level limit |
| 9958 | Dispatcher for export and publishing commands. Displays a help-window | 10665 | (@code{org-export-with-toc}). |
| 9959 | listing the additional key(s) needed to launch an export or publishing | 10666 | |
| 9960 | command. The prefix arg is passed through to the exporter. A double prefix | 10667 | @item todo: |
| 9961 | @kbd{C-u C-u} causes most commands to be executed in the background, in a | 10668 | @vindex org-export-with-todo-keywords |
| 9962 | separate Emacs process@footnote{To make this behavior the default, customize | 10669 | Toggle inclusion of TODO keywords into exported text |
| 9963 | the variable @code{org-export-run-in-background}.}. | 10670 | (@code{org-export-with-todo-keywords}). |
| 9964 | @orgcmd{C-c C-e v,org-export-visible} | 10671 | |
| 9965 | Like @kbd{C-c C-e}, but only export the text that is currently visible | 10672 | @item |: |
| 9966 | (i.e., not hidden by outline visibility). | 10673 | @vindex org-export-with-tables |
| 9967 | @orgcmd{C-u C-u C-c C-e,org-export} | 10674 | Toggle inclusion of tables (@code{org-export-with-tables}). |
| 9968 | @vindex org-export-run-in-background | ||
| 9969 | Call the exporter, but reverse the setting of | ||
| 9970 | @code{org-export-run-in-background}, i.e., request background processing if | ||
| 9971 | not set, or force processing in the current Emacs process if set. | ||
| 9972 | @end table | 10675 | @end table |
| 9973 | 10676 | ||
| 9974 | @node ASCII/Latin-1/UTF-8 export, HTML export, The export dispatcher, Exporting | 10677 | @cindex property, EXPORT_FILE_NAME |
| 10678 | When exporting only a subtree, each of the previous keywords@footnote{With | ||
| 10679 | the exception of @samp{SETUPFILE}.} can be overriden locally by special node | ||
| 10680 | properties. These begin with @samp{EXPORT_}, followed by the name of the | ||
| 10681 | keyword they supplant. For example, @samp{DATE} and @samp{OPTIONS} keywords | ||
| 10682 | become, respectively, @samp{EXPORT_DATE} and @samp{EXPORT_OPTIONS} | ||
| 10683 | properties. Subtree export also supports the self-explicit | ||
| 10684 | @samp{EXPORT_FILE_NAME} property@footnote{There is no buffer-wide equivalent | ||
| 10685 | for this property. The file name in this case is derived from the file | ||
| 10686 | associated to the buffer, if possible, or asked to the user otherwise.}. | ||
| 10687 | |||
| 10688 | @cindex #+BIND | ||
| 10689 | @vindex org-export-allow-bind-keywords | ||
| 10690 | If @code{org-export-allow-bind-keywords} is non-@code{nil}, Emacs variables | ||
| 10691 | can become buffer-local during export by using the BIND keyword. Its syntax | ||
| 10692 | is @samp{#+BIND: variable value}. This is particularly useful for in-buffer | ||
| 10693 | settings that cannot be changed using specific keywords. | ||
| 10694 | |||
| 10695 | @node ASCII/Latin-1/UTF-8 export, Beamer export, Export settings, Exporting | ||
| 9975 | @section ASCII/Latin-1/UTF-8 export | 10696 | @section ASCII/Latin-1/UTF-8 export |
| 9976 | @cindex ASCII export | 10697 | @cindex ASCII export |
| 9977 | @cindex Latin-1 export | 10698 | @cindex Latin-1 export |
| @@ -9981,58 +10702,277 @@ ASCII export produces a simple and very readable version of an Org mode | |||
| 9981 | file, containing only plain ASCII@. Latin-1 and UTF-8 export augment the file | 10702 | file, containing only plain ASCII@. Latin-1 and UTF-8 export augment the file |
| 9982 | with special characters and symbols available in these encodings. | 10703 | with special characters and symbols available in these encodings. |
| 9983 | 10704 | ||
| 9984 | @cindex region, active | 10705 | @vindex org-ascii-links-to-notes |
| 9985 | @cindex active region | 10706 | Links are exported in a footnote-like style, with the descriptive part in the |
| 9986 | @cindex transient-mark-mode | 10707 | text and the link in a note before the next heading. See the variable |
| 10708 | @code{org-ascii-links-to-notes} for details and other options. | ||
| 10709 | |||
| 10710 | @subheading ASCII export commands | ||
| 10711 | |||
| 9987 | @table @kbd | 10712 | @table @kbd |
| 9988 | @orgcmd{C-c C-e a,org-export-as-ascii} | 10713 | @orgcmd{C-c C-e t a/l/u,org-ascii-export-to-ascii} |
| 9989 | @cindex property, EXPORT_FILE_NAME | ||
| 9990 | Export as an ASCII file. For an Org file, @file{myfile.org}, the ASCII file | 10714 | Export as an ASCII file. For an Org file, @file{myfile.org}, the ASCII file |
| 9991 | will be @file{myfile.txt}. The file will be overwritten without | 10715 | will be @file{myfile.txt}. The file will be overwritten without warning. |
| 9992 | warning. If there is an active region@footnote{This requires | 10716 | When the original file is @file{myfile.txt}, the resulting file becomes |
| 9993 | @code{transient-mark-mode} be turned on.}, only the region will be | 10717 | @file{myfile.txt.txt} in order to prevent data loss. |
| 9994 | exported. If the selected region is a single tree@footnote{To select the | 10718 | @orgcmd{C-c C-e t A/L/U,org-ascii-export-as-ascii} |
| 9995 | current subtree, use @kbd{C-c @@}.}, the tree head will | ||
| 9996 | become the document title. If the tree head entry has or inherits an | ||
| 9997 | @code{EXPORT_FILE_NAME} property, that name will be used for the | ||
| 9998 | export. | ||
| 9999 | @orgcmd{C-c C-e A,org-export-as-ascii-to-buffer} | ||
| 10000 | Export to a temporary buffer. Do not create a file. | 10719 | Export to a temporary buffer. Do not create a file. |
| 10001 | @orgcmd{C-c C-e n,org-export-as-latin1} | ||
| 10002 | @xorgcmd{C-c C-e N,org-export-as-latin1-to-buffer} | ||
| 10003 | Like the above commands, but use Latin-1 encoding. | ||
| 10004 | @orgcmd{C-c C-e u,org-export-as-utf8} | ||
| 10005 | @xorgcmd{C-c C-e U,org-export-as-utf8-to-buffer} | ||
| 10006 | Like the above commands, but use UTF-8 encoding. | ||
| 10007 | @item C-c C-e v a/n/u | ||
| 10008 | Export only the visible part of the document. | ||
| 10009 | @end table | 10720 | @end table |
| 10010 | 10721 | ||
| 10011 | @cindex headline levels, for exporting | 10722 | @subheading Header and sectioning structure |
| 10012 | In the exported version, the first 3 outline levels will become | 10723 | |
| 10013 | headlines, defining a general document structure. Additional levels | 10724 | In the exported version, the first three outline levels become headlines, |
| 10014 | will be exported as itemized lists. If you want that transition to occur | 10725 | defining a general document structure. Additional levels are exported as |
| 10015 | at a different level, specify it with a prefix argument. For example, | 10726 | lists. The transition can also occur at a different level (@pxref{Export |
| 10727 | settings}). | ||
| 10728 | |||
| 10729 | @subheading Quoting ASCII text | ||
| 10730 | |||
| 10731 | You can insert text that will only appear when using @code{ASCII} back-end | ||
| 10732 | with the following constructs: | ||
| 10016 | 10733 | ||
| 10734 | @cindex #+ASCII | ||
| 10735 | @cindex #+BEGIN_ASCII | ||
| 10017 | @example | 10736 | @example |
| 10018 | @kbd{C-1 C-c C-e a} | 10737 | Text @@@@ascii:and additional text@@@@ within a paragraph. |
| 10738 | |||
| 10739 | #+ASCII: Some text | ||
| 10740 | |||
| 10741 | #+BEGIN_ASCII | ||
| 10742 | All lines in this block will appear only when using this back-end. | ||
| 10743 | #+END_ASCII | ||
| 10019 | @end example | 10744 | @end example |
| 10020 | 10745 | ||
| 10021 | @noindent | 10746 | @subheading ASCII specific attributes |
| 10022 | creates only top level headlines and exports the rest as items. When | 10747 | @cindex #+ATTR_ASCII |
| 10023 | headlines are converted to items, the indentation of the text following | 10748 | @cindex horizontal rules, in ASCII export |
| 10024 | the headline is changed to fit nicely under the item. This is done with | 10749 | |
| 10025 | the assumption that the first body line indicates the base indentation of | 10750 | @code{ASCII} back-end only understands one attribute, @code{:width}, which |
| 10026 | the body text. Any indentation larger than this is adjusted to preserve | 10751 | specifies the length, in characters, of a given horizontal rule. It must be |
| 10027 | the layout relative to the first line. Should there be lines with less | 10752 | specified using an @code{ATTR_ASCII} line, directly preceding the rule. |
| 10028 | indentation than the first one, these are left alone. | 10753 | |
| 10029 | 10754 | @example | |
| 10030 | @vindex org-export-ascii-links-to-notes | 10755 | #+ATTR_ASCII: :width 10 |
| 10031 | Links will be exported in a footnote-like style, with the descriptive part in | 10756 | ----- |
| 10032 | the text and the link in a note before the next heading. See the variable | 10757 | @end example |
| 10033 | @code{org-export-ascii-links-to-notes} for details and other options. | 10758 | |
| 10034 | 10759 | @node Beamer export, HTML export, ASCII/Latin-1/UTF-8 export, Exporting | |
| 10035 | @node HTML export, @LaTeX{} and PDF export, ASCII/Latin-1/UTF-8 export, Exporting | 10760 | @section Beamer export |
| 10761 | @cindex Beamer export | ||
| 10762 | |||
| 10763 | The @LaTeX{} class @emph{Beamer} allows production of high quality | ||
| 10764 | presentations using @LaTeX{} and pdf processing. Org mode has special | ||
| 10765 | support for turning an Org mode file or tree into a Beamer presentation. | ||
| 10766 | |||
| 10767 | @subheading Beamer export commands | ||
| 10768 | |||
| 10769 | @table @kbd | ||
| 10770 | @orgcmd{C-c C-e l b,org-beamer-export-to-latex} | ||
| 10771 | Export as a @LaTeX{} file. For an Org file @file{myfile.org}, the @LaTeX{} | ||
| 10772 | file will be @file{myfile.tex}. The file will be overwritten without | ||
| 10773 | warning. | ||
| 10774 | @orgcmd{C-c C-e l B,org-beamer-export-as-latex} | ||
| 10775 | Export to a temporary buffer. Do not create a file. | ||
| 10776 | @orgcmd{C-c C-e l P,org-beamer-export-to-pdf} | ||
| 10777 | Export as @LaTeX{} and then process to PDF. | ||
| 10778 | @item C-c C-e l O | ||
| 10779 | Export as @LaTeX{} and then process to PDF, then open the resulting PDF file. | ||
| 10780 | @end table | ||
| 10781 | |||
| 10782 | @subheading Sectioning, Frames and Blocks | ||
| 10783 | |||
| 10784 | Any tree with not-too-deep level nesting should in principle be exportable as | ||
| 10785 | a Beamer presentation. Headlines fall into three categories: sectioning | ||
| 10786 | elements, frames and blocks. | ||
| 10787 | |||
| 10788 | @itemize @minus | ||
| 10789 | @item | ||
| 10790 | @vindex org-beamer-frame-level | ||
| 10791 | Headlines become frames when their level is equal to | ||
| 10792 | @code{org-beamer-frame-level} or @code{H} value in an @code{OPTIONS} line | ||
| 10793 | (@pxref{Export settings}). | ||
| 10794 | |||
| 10795 | @cindex property, BEAMER_ENV | ||
| 10796 | Though, if a headline in the current tree has a @code{BEAMER_ENV} property | ||
| 10797 | set to either to @code{frame} or @code{fullframe}, its level overrides the | ||
| 10798 | variable. A @code{fullframe} is a frame with an empty (ignored) title. | ||
| 10799 | |||
| 10800 | @item | ||
| 10801 | @vindex org-beamer-environments-default | ||
| 10802 | @vindex org-beamer-environments-extra | ||
| 10803 | All frame's children become @code{block} environments. Special block types | ||
| 10804 | can be enforced by setting headline's @code{BEAMER_ENV} property@footnote{If | ||
| 10805 | this property is set, the entry will also get a @code{:B_environment:} tag to | ||
| 10806 | make this visible. This tag has no semantic meaning, it is only a visual | ||
| 10807 | aid.} to an appropriate value (see @code{org-beamer-environments-default} for | ||
| 10808 | supported values and @code{org-beamer-environments-extra} for adding more). | ||
| 10809 | |||
| 10810 | @item | ||
| 10811 | @cindex property, BEAMER_REF | ||
| 10812 | As a special case, if the @code{BEAMER_ENV} property is set to either | ||
| 10813 | @code{appendix}, @code{note}, @code{noteNH} or @code{againframe}, the | ||
| 10814 | headline will become, respectively, an appendix, a note (within frame or | ||
| 10815 | between frame, depending on its level), a note with its title ignored or an | ||
| 10816 | @code{\againframe} command. In the latter case, a @code{BEAMER_REF} property | ||
| 10817 | is mandatory in order to refer to the frame being resumed, and contents are | ||
| 10818 | ignored. | ||
| 10819 | |||
| 10820 | Also, a headline with an @code{ignoreheading} environment will have its | ||
| 10821 | contents only inserted in the output. This special value is useful to have | ||
| 10822 | data between frames, or to properly close a @code{column} environment. | ||
| 10823 | @end itemize | ||
| 10824 | |||
| 10825 | @cindex property, BEAMER_ACT | ||
| 10826 | @cindex property, BEAMER_OPT | ||
| 10827 | Headlines also support @code{BEAMER_ACT} and @code{BEAMER_OPT} properties. | ||
| 10828 | The former is translated as an overlay/action specification, or a default | ||
| 10829 | overlay specification when enclosed within square brackets. The latter | ||
| 10830 | specifies options@footnote{The @code{fragile} option is added automatically | ||
| 10831 | if it contains code that requires a verbatim environment, though.} for the | ||
| 10832 | current frame or block. The export back-end will automatically wrap | ||
| 10833 | properties within angular or square brackets when appropriate. | ||
| 10834 | |||
| 10835 | @cindex property, BEAMER_COL | ||
| 10836 | Moreover, headlines handle the @code{BEAMER_COL} property. Its value should | ||
| 10837 | be a decimal number representing the width of the column as a fraction of the | ||
| 10838 | total text width. If the headline has no specific environment, its title | ||
| 10839 | will be ignored and its contents will fill the column created. Otherwise, | ||
| 10840 | the block will fill the whole column and the title will be preserved. Two | ||
| 10841 | contiguous headlines with a non-@code{nil} @code{BEAMER_COL} value share the same | ||
| 10842 | @code{columns} @LaTeX{} environment. It will end before the next headline | ||
| 10843 | without such a property. This environment is generated automatically. | ||
| 10844 | Although, it can also be explicitly created, with a special @code{columns} | ||
| 10845 | value for @code{BEAMER_ENV} property (if it needs to be set up with some | ||
| 10846 | specific options, for example). | ||
| 10847 | |||
| 10848 | @subheading Beamer specific syntax | ||
| 10849 | |||
| 10850 | Beamer back-end is an extension of @LaTeX{} back-end. As such, all @LaTeX{} | ||
| 10851 | specific syntax (e.g., @samp{#+LATEX:} or @samp{#+ATTR_LATEX:}) is | ||
| 10852 | recognized. See @ref{@LaTeX{} and PDF export} for more information. | ||
| 10853 | |||
| 10854 | @cindex #+BEAMER_THEME | ||
| 10855 | @cindex #+BEAMER_COLOR_THEME | ||
| 10856 | @cindex #+BEAMER_FONT_THEME | ||
| 10857 | @cindex #+BEAMER_INNER_THEME | ||
| 10858 | @cindex #+BEAMER_OUTER_THEME | ||
| 10859 | Beamer export introduces a number of keywords to insert code in the | ||
| 10860 | document's header. Four control appearance of the presentantion: | ||
| 10861 | @code{#+BEAMER_THEME}, @code{#+BEAMER_COLOR_THEME}, | ||
| 10862 | @code{#+BEAMER_FONT_THEME}, @code{#+BEAMER_INNER_THEME} and | ||
| 10863 | @code{#+BEAMER_OUTER_THEME}. All of them accept optional arguments | ||
| 10864 | within square brackets. The last one, @code{#+BEAMER_HEADER}, is more | ||
| 10865 | generic and allows you to append any line of code in the header. | ||
| 10866 | |||
| 10867 | @example | ||
| 10868 | #+BEAMER_THEME: Rochester [height=20pt] | ||
| 10869 | #+BEAMER_COLOR_THEME: spruce | ||
| 10870 | @end example | ||
| 10871 | |||
| 10872 | Table of contents generated from @code{toc:t} @code{OPTION} keyword are | ||
| 10873 | wrapped within a @code{frame} environment. Those generated from a @code{TOC} | ||
| 10874 | keyword (@pxref{Table of contents}) are not. In that case, it is also | ||
| 10875 | possible to specify options, enclosed within square brackets. | ||
| 10876 | |||
| 10877 | @example | ||
| 10878 | #+TOC: headlines [currentsection] | ||
| 10879 | @end example | ||
| 10880 | |||
| 10881 | Beamer specific code can be inserted with the following constructs: | ||
| 10882 | |||
| 10883 | @cindex #+BEAMER | ||
| 10884 | @cindex #+BEGIN_BEAMER | ||
| 10885 | @example | ||
| 10886 | #+BEAMER: \pause | ||
| 10887 | |||
| 10888 | #+BEGIN_BEAMER | ||
| 10889 | All lines in this block will appear only when using this back-end. | ||
| 10890 | #+END_BEAMER | ||
| 10891 | |||
| 10892 | Text @@@@beamer:some code@@@@ within a paragraph. | ||
| 10893 | @end example | ||
| 10894 | |||
| 10895 | In particular, this last example can be used to add overlay specifications to | ||
| 10896 | objects whose type is among @code{bold}, @code{item}, @code{link}, | ||
| 10897 | @code{radio-target} and @code{target}, when the value is enclosed within | ||
| 10898 | angular brackets and put at the beginning the object. | ||
| 10899 | |||
| 10900 | @example | ||
| 10901 | A *@@@@beamer:<2->@@@@useful* feature | ||
| 10902 | @end example | ||
| 10903 | |||
| 10904 | @cindex #+ATTR_BEAMER | ||
| 10905 | Eventually, every plain list has support for @code{:environment}, | ||
| 10906 | @code{:overlay} and @code{:options} attributes through | ||
| 10907 | @code{ATTR_BEAMER} affiliated keyword. The first one allows the use | ||
| 10908 | of a different environment, the second sets overlay specifications and | ||
| 10909 | the last one inserts optional arguments in current list environment. | ||
| 10910 | |||
| 10911 | @example | ||
| 10912 | #+ATTR_BEAMER: :overlay +- | ||
| 10913 | - item 1 | ||
| 10914 | - item 2 | ||
| 10915 | @end example | ||
| 10916 | |||
| 10917 | @subheading Editing support | ||
| 10918 | |||
| 10919 | You can turn on a special minor mode @code{org-beamer-mode} for faster | ||
| 10920 | editing with: | ||
| 10921 | |||
| 10922 | @example | ||
| 10923 | #+STARTUP: beamer | ||
| 10924 | @end example | ||
| 10925 | |||
| 10926 | @table @kbd | ||
| 10927 | @orgcmd{C-c C-b,org-beamer-select-environment} | ||
| 10928 | In @code{org-beamer-mode}, this key offers fast selection of a Beamer | ||
| 10929 | environment or the @code{BEAMER_COL} property. | ||
| 10930 | @end table | ||
| 10931 | |||
| 10932 | Also, a template for useful in-buffer settings or properties can be inserted | ||
| 10933 | into the buffer with @kbd{M-x org-beamer-insert-options-template}. Among | ||
| 10934 | other things, this will install a column view format which is very handy for | ||
| 10935 | editing special properties used by Beamer. | ||
| 10936 | |||
| 10937 | @subheading An example | ||
| 10938 | |||
| 10939 | Here is a simple example Org document that is intended for Beamer export. | ||
| 10940 | |||
| 10941 | @smallexample | ||
| 10942 | #+TITLE: Example Presentation | ||
| 10943 | #+AUTHOR: Carsten Dominik | ||
| 10944 | #+OPTIONS: H:2 | ||
| 10945 | #+LATEX_CLASS: beamer | ||
| 10946 | #+LATEX_CLASS_OPTIONS: [presentation] | ||
| 10947 | #+BEAMER_THEME: Madrid | ||
| 10948 | #+COLUMNS: %45ITEM %10BEAMER_ENV(Env) %10BEAMER_ACT(Act) %4BEAMER_COL(Col) %8BEAMER_OPT(Opt) | ||
| 10949 | |||
| 10950 | * This is the first structural section | ||
| 10951 | |||
| 10952 | ** Frame 1 | ||
| 10953 | *** Thanks to Eric Fraga :B_block:BMCOL: | ||
| 10954 | :PROPERTIES: | ||
| 10955 | :BEAMER_COL: 0.48 | ||
| 10956 | :BEAMER_ENV: block | ||
| 10957 | :END: | ||
| 10958 | for the first viable Beamer setup in Org | ||
| 10959 | *** Thanks to everyone else :B_block:BMCOL: | ||
| 10960 | :PROPERTIES: | ||
| 10961 | :BEAMER_COL: 0.48 | ||
| 10962 | :BEAMER_ACT: <2-> | ||
| 10963 | :BEAMER_ENV: block | ||
| 10964 | :END: | ||
| 10965 | for contributing to the discussion | ||
| 10966 | **** This will be formatted as a beamer note :B_note: | ||
| 10967 | :PROPERTIES: | ||
| 10968 | :BEAMER_env: note | ||
| 10969 | :END: | ||
| 10970 | ** Frame 2 (where we will not use columns) | ||
| 10971 | *** Request | ||
| 10972 | Please test this stuff! | ||
| 10973 | @end smallexample | ||
| 10974 | |||
| 10975 | @node HTML export, @LaTeX{} and PDF export, Beamer export, Exporting | ||
| 10036 | @section HTML export | 10976 | @section HTML export |
| 10037 | @cindex HTML export | 10977 | @cindex HTML export |
| 10038 | 10978 | ||
| @@ -10042,6 +10982,7 @@ language, but with additional support for tables. | |||
| 10042 | 10982 | ||
| 10043 | @menu | 10983 | @menu |
| 10044 | * HTML Export commands:: How to invoke HTML export | 10984 | * HTML Export commands:: How to invoke HTML export |
| 10985 | * HTML doctypes:: Org can export to various (X)HTML flavors | ||
| 10045 | * HTML preamble and postamble:: How to insert a preamble and a postamble | 10986 | * HTML preamble and postamble:: How to insert a preamble and a postamble |
| 10046 | * Quoting HTML tags:: Using direct HTML in Org mode | 10987 | * Quoting HTML tags:: Using direct HTML in Org mode |
| 10047 | * Links in HTML export:: How links will be interpreted and formatted | 10988 | * Links in HTML export:: How links will be interpreted and formatted |
| @@ -10053,100 +10994,161 @@ language, but with additional support for tables. | |||
| 10053 | * JavaScript support:: Info and Folding in a web browser | 10994 | * JavaScript support:: Info and Folding in a web browser |
| 10054 | @end menu | 10995 | @end menu |
| 10055 | 10996 | ||
| 10056 | @node HTML Export commands, HTML preamble and postamble, HTML export, HTML export | 10997 | @node HTML Export commands, HTML doctypes, HTML export, HTML export |
| 10057 | @subsection HTML export commands | 10998 | @subsection HTML export commands |
| 10058 | 10999 | ||
| 10059 | @cindex region, active | ||
| 10060 | @cindex active region | ||
| 10061 | @cindex transient-mark-mode | ||
| 10062 | @table @kbd | 11000 | @table @kbd |
| 10063 | @orgcmd{C-c C-e h,org-export-as-html} | 11001 | @orgcmd{C-c C-e h h,org-html-export-to-html} |
| 10064 | @cindex property, EXPORT_FILE_NAME | ||
| 10065 | Export as a HTML file. For an Org file @file{myfile.org}, | 11002 | Export as a HTML file. For an Org file @file{myfile.org}, |
| 10066 | the HTML file will be @file{myfile.html}. The file will be overwritten | 11003 | the HTML file will be @file{myfile.html}. The file will be overwritten |
| 10067 | without warning. If there is an active region@footnote{This requires | 11004 | without warning. |
| 10068 | @code{transient-mark-mode} be turned on.}, only the region will be | 11005 | @kbd{C-c C-e h o} |
| 10069 | exported. If the selected region is a single tree@footnote{To select the | ||
| 10070 | current subtree, use @kbd{C-c @@}.}, the tree head will become the document | ||
| 10071 | title. If the tree head entry has, or inherits, an @code{EXPORT_FILE_NAME} | ||
| 10072 | property, that name will be used for the export. | ||
| 10073 | @orgcmd{C-c C-e b,org-export-as-html-and-open} | ||
| 10074 | Export as a HTML file and immediately open it with a browser. | 11006 | Export as a HTML file and immediately open it with a browser. |
| 10075 | @orgcmd{C-c C-e H,org-export-as-html-to-buffer} | 11007 | @orgcmd{C-c C-e h H,org-html-export-as-html} |
| 10076 | Export to a temporary buffer. Do not create a file. | 11008 | Export to a temporary buffer. Do not create a file. |
| 10077 | @orgcmd{C-c C-e R,org-export-region-as-html} | ||
| 10078 | Export the active region to a temporary buffer. With a prefix argument, do | ||
| 10079 | not produce the file header and footer, but just the plain HTML section for | ||
| 10080 | the region. This is good for cut-and-paste operations. | ||
| 10081 | @item C-c C-e v h/b/H/R | ||
| 10082 | Export only the visible part of the document. | ||
| 10083 | @item M-x org-export-region-as-html | ||
| 10084 | Convert the region to HTML under the assumption that it was in Org mode | ||
| 10085 | syntax before. This is a global command that can be invoked in any | ||
| 10086 | buffer. | ||
| 10087 | @item M-x org-replace-region-by-HTML | ||
| 10088 | Replace the active region (assumed to be in Org mode syntax) by HTML | ||
| 10089 | code. | ||
| 10090 | @end table | 11009 | @end table |
| 10091 | 11010 | ||
| 10092 | @cindex headline levels, for exporting | 11011 | @c FIXME Exporting sublevels |
| 10093 | In the exported version, the first 3 outline levels will become headlines, | 11012 | @c @cindex headline levels, for exporting |
| 10094 | defining a general document structure. Additional levels will be exported as | 11013 | @c In the exported version, the first 3 outline levels will become headlines, |
| 10095 | itemized lists. If you want that transition to occur at a different level, | 11014 | @c defining a general document structure. Additional levels will be exported as |
| 10096 | specify it with a numeric prefix argument. For example, | 11015 | @c itemized lists. If you want that transition to occur at a different level, |
| 11016 | @c specify it with a numeric prefix argument. For example, | ||
| 11017 | |||
| 11018 | @c @example | ||
| 11019 | @c @kbd{C-2 C-c C-e b} | ||
| 11020 | @c @end example | ||
| 11021 | |||
| 11022 | @c @noindent | ||
| 11023 | @c creates two levels of headings and does the rest as items. | ||
| 11024 | |||
| 11025 | @node HTML doctypes, HTML preamble and postamble, HTML Export commands, HTML export | ||
| 11026 | @subsection HTML doctypes | ||
| 11027 | @vindex org-html-doctype | ||
| 11028 | @vindex org-html-doctype-alist | ||
| 11029 | |||
| 11030 | Org can export to various (X)HTML flavors. | ||
| 11031 | |||
| 11032 | Setting the variable @code{org-html-doctype} allows you to export to different | ||
| 11033 | (X)HTML variants. The exported HTML will be adjusted according to the sytax | ||
| 11034 | requirements of that variant. You can either set this variable to a doctype | ||
| 11035 | string directly, in which case the exporter will try to adjust the syntax | ||
| 11036 | automatically, or you can use a ready-made doctype. The ready-made options | ||
| 11037 | are: | ||
| 11038 | |||
| 11039 | @itemize | ||
| 11040 | @item | ||
| 11041 | ``html4-strict'' | ||
| 11042 | @item | ||
| 11043 | ``html4-transitional'' | ||
| 11044 | @item | ||
| 11045 | ``html4-frameset'' | ||
| 11046 | @item | ||
| 11047 | ``xhtml-strict'' | ||
| 11048 | @item | ||
| 11049 | ``xhtml-transitional'' | ||
| 11050 | @item | ||
| 11051 | ``xhtml-frameset'' | ||
| 11052 | @item | ||
| 11053 | ``xhtml-11'' | ||
| 11054 | @item | ||
| 11055 | ``html5'' | ||
| 11056 | @item | ||
| 11057 | ``xhtml5'' | ||
| 11058 | @end itemize | ||
| 11059 | |||
| 11060 | See the variable @code{org-html-doctype-alist} for details. The default is | ||
| 11061 | ``xhtml-strict''. | ||
| 11062 | |||
| 11063 | @subsubheading Fancy HTML5 export | ||
| 11064 | @vindex org-html-html5-fancy | ||
| 11065 | @vindex org-html-html5-elements | ||
| 11066 | |||
| 11067 | HTML5 introduces several new element types. By default, Org will not make | ||
| 11068 | use of these element types, but you can set @code{org-html-html5-fancy} to | ||
| 11069 | @code{t} (or set @code{html5-fancy} item in an @code{OPTIONS} line), to | ||
| 11070 | enable a few new block-level elements. These are created using arbitrary | ||
| 11071 | #+BEGIN and #+END blocks. For instance: | ||
| 10097 | 11072 | ||
| 10098 | @example | 11073 | @example |
| 10099 | @kbd{C-2 C-c C-e b} | 11074 | #+BEGIN_ASIDE |
| 11075 | Lorem ipsum | ||
| 11076 | #+END_ASIDE | ||
| 10100 | @end example | 11077 | @end example |
| 10101 | 11078 | ||
| 10102 | @noindent | 11079 | Will export to: |
| 10103 | creates two levels of headings and does the rest as items. | 11080 | |
| 11081 | @example | ||
| 11082 | <aside> | ||
| 11083 | <p>Lorem ipsum</p> | ||
| 11084 | </aside> | ||
| 11085 | @end example | ||
| 10104 | 11086 | ||
| 11087 | While this: | ||
| 10105 | 11088 | ||
| 10106 | @node HTML preamble and postamble, Quoting HTML tags, HTML Export commands, HTML export | 11089 | @example |
| 11090 | #+ATTR_HTML: :controls controls :width 350 | ||
| 11091 | #+BEGIN_VIDEO | ||
| 11092 | #+HTML: <source src="movie.mp4" type="video/mp4"> | ||
| 11093 | #+HTML: <source src="movie.ogg" type="video/ogg"> | ||
| 11094 | Your browser does not support the video tag. | ||
| 11095 | #+END_VIDEO | ||
| 11096 | @end example | ||
| 11097 | |||
| 11098 | Becomes: | ||
| 11099 | |||
| 11100 | @example | ||
| 11101 | <video controls="controls" width="350"> | ||
| 11102 | <source src="movie.mp4" type="video/mp4"> | ||
| 11103 | <source src="movie.ogg" type="video/ogg"> | ||
| 11104 | <p>Your browser does not support the video tag.</p> | ||
| 11105 | </video> | ||
| 11106 | @end example | ||
| 11107 | |||
| 11108 | Special blocks that do not correspond to HTML5 elements (see | ||
| 11109 | @code{org-html-html5-elements}) will revert to the usual behavior, | ||
| 11110 | i.e. #+BEGIN_LEDERHOSEN will still export to <div class=''lederhosen''>. | ||
| 11111 | |||
| 11112 | Headlines cannot appear within special blocks. To wrap a headline and its | ||
| 11113 | contents in e.g. <section> or <article> tags, set the @code{HTML_CONTAINER} | ||
| 11114 | property on the headline itself. | ||
| 11115 | |||
| 11116 | @node HTML preamble and postamble, Quoting HTML tags, HTML doctypes, HTML export | ||
| 10107 | @subsection HTML preamble and postamble | 11117 | @subsection HTML preamble and postamble |
| 10108 | @vindex org-export-html-preamble | 11118 | @vindex org-html-preamble |
| 10109 | @vindex org-export-html-postamble | 11119 | @vindex org-html-postamble |
| 10110 | @vindex org-export-html-preamble-format | 11120 | @vindex org-html-preamble-format |
| 10111 | @vindex org-export-html-postamble-format | 11121 | @vindex org-html-postamble-format |
| 10112 | @vindex org-export-html-validation-link | 11122 | @vindex org-html-validation-link |
| 10113 | @vindex org-export-author-info | 11123 | @vindex org-export-creator-string |
| 10114 | @vindex org-export-email-info | ||
| 10115 | @vindex org-export-creator-info | ||
| 10116 | @vindex org-export-time-stamp-file | 11124 | @vindex org-export-time-stamp-file |
| 10117 | 11125 | ||
| 10118 | The HTML exporter lets you define a preamble and a postamble. | 11126 | The HTML exporter lets you define a preamble and a postamble. |
| 10119 | 11127 | ||
| 10120 | The default value for @code{org-export-html-preamble} is @code{t}, which | 11128 | The default value for @code{org-html-preamble} is @code{t}, which means |
| 10121 | means that the preamble is inserted depending on the relevant format string | 11129 | that the preamble is inserted depending on the relevant format string in |
| 10122 | in @code{org-export-html-preamble-format}. | 11130 | @code{org-html-preamble-format}. |
| 10123 | 11131 | ||
| 10124 | Setting @code{org-export-html-preamble} to a string will override the default | 11132 | Setting @code{org-html-preamble} to a string will override the default format |
| 10125 | format string. Setting it to a function, will insert the output of the | 11133 | string. If you set it to a function, it will insert the output of the |
| 10126 | function, which must be a string; such a function takes no argument but you | 11134 | function, which must be a string. Setting to @code{nil} will not insert any |
| 10127 | can check against the value of @code{opt-plist}, which contains the list of | 11135 | preamble. |
| 10128 | publishing properties for the current file. Setting to @code{nil} will not | 11136 | |
| 10129 | insert any preamble. | 11137 | The default value for @code{org-html-postamble} is @code{'auto}, which means |
| 10130 | 11138 | that the HTML exporter will look for information about the author, the email, | |
| 10131 | The default value for @code{org-export-html-postamble} is @code{'auto}, which | 11139 | the creator and the date, and build the postamble from these values. Setting |
| 10132 | means that the HTML exporter will look for the value of | 11140 | @code{org-html-postamble} to @code{t} will insert the postamble from the |
| 10133 | @code{org-export-author-info}, @code{org-export-email-info}, | 11141 | relevant format string found in @code{org-html-postamble-format}. Setting it |
| 10134 | @code{org-export-creator-info} and @code{org-export-time-stamp-file}, | 11142 | to @code{nil} will not insert any postamble. |
| 10135 | @code{org-export-html-validation-link} and build the postamble from these | ||
| 10136 | values. Setting @code{org-export-html-postamble} to @code{t} will insert the | ||
| 10137 | postamble from the relevant format string found in | ||
| 10138 | @code{org-export-html-postamble-format}. Setting it to @code{nil} will not | ||
| 10139 | insert any postamble. | ||
| 10140 | 11143 | ||
| 10141 | @node Quoting HTML tags, Links in HTML export, HTML preamble and postamble, HTML export | 11144 | @node Quoting HTML tags, Links in HTML export, HTML preamble and postamble, HTML export |
| 10142 | @subsection Quoting HTML tags | 11145 | @subsection Quoting HTML tags |
| 10143 | 11146 | ||
| 10144 | Plain @samp{<} and @samp{>} are always transformed to @samp{<} and | 11147 | Plain @samp{<} and @samp{>} are always transformed to @samp{<} and |
| 10145 | @samp{>} in HTML export. If you want to include simple HTML tags | 11148 | @samp{>} in HTML export. If you want to include raw HTML code, which |
| 10146 | which should be interpreted as such, mark them with @samp{@@} as in | 11149 | should only appear in HTML export, mark it with @samp{@@@@html:} as in |
| 10147 | @samp{@@<b>bold text@@</b>}. Note that this really works only for | 11150 | @samp{@@@@html:<b>@@@@bold text@@@@html:</b>@@@@}. For more extensive HTML |
| 10148 | simple tags. For more extensive HTML that should be copied verbatim to | 11151 | that should be copied verbatim to the exported file use either |
| 10149 | the exported file use either | ||
| 10150 | 11152 | ||
| 10151 | @cindex #+HTML | 11153 | @cindex #+HTML |
| 10152 | @cindex #+BEGIN_HTML | 11154 | @cindex #+BEGIN_HTML |
| @@ -10187,37 +11189,42 @@ and @code{style} attributes for a link: | |||
| 10187 | 11189 | ||
| 10188 | @cindex #+ATTR_HTML | 11190 | @cindex #+ATTR_HTML |
| 10189 | @example | 11191 | @example |
| 10190 | #+ATTR_HTML: title="The Org mode homepage" style="color:red;" | 11192 | #+ATTR_HTML: :title The Org mode homepage :style color:red; |
| 10191 | [[http://orgmode.org]] | 11193 | [[http://orgmode.org]] |
| 10192 | @end example | 11194 | @end example |
| 10193 | 11195 | ||
| 10194 | @node Tables in HTML export, Images in HTML export, Links in HTML export, HTML export | 11196 | @node Tables in HTML export, Images in HTML export, Links in HTML export, HTML export |
| 10195 | @subsection Tables | 11197 | @subsection Tables |
| 10196 | @cindex tables, in HTML | 11198 | @cindex tables, in HTML |
| 10197 | @vindex org-export-html-table-tag | 11199 | @vindex org-html-table-default-attributes |
| 10198 | 11200 | ||
| 10199 | Org mode tables are exported to HTML using the table tag defined in | 11201 | Org mode tables are exported to HTML using the table attributes defined in |
| 10200 | @code{org-export-html-table-tag}. The default setting makes tables without | 11202 | @code{org-html-table-default-attributes}. The default setting makes tables |
| 10201 | cell borders and frame. If you would like to change this for individual | 11203 | without cell borders and frame. If you would like to change this for |
| 10202 | tables, place something like the following before the table: | 11204 | individual tables, place something like the following before the table: |
| 10203 | 11205 | ||
| 10204 | @cindex #+CAPTION | 11206 | @cindex #+CAPTION |
| 10205 | @cindex #+ATTR_HTML | 11207 | @cindex #+ATTR_HTML |
| 10206 | @example | 11208 | @example |
| 10207 | #+CAPTION: This is a table with lines around and between cells | 11209 | #+CAPTION: This is a table with lines around and between cells |
| 10208 | #+ATTR_HTML: border="2" rules="all" frame="border" | 11210 | #+ATTR_HTML: :border 2 :rules all :frame border |
| 10209 | @end example | 11211 | @end example |
| 10210 | 11212 | ||
| 11213 | @vindex org-html-table-row-tags | ||
| 11214 | You can also modify the default tags used for each row by setting | ||
| 11215 | @code{org-html-table-row-tags}. See the docstring for an example on | ||
| 11216 | how to use this option. | ||
| 11217 | |||
| 10211 | @node Images in HTML export, Math formatting in HTML export, Tables in HTML export, HTML export | 11218 | @node Images in HTML export, Math formatting in HTML export, Tables in HTML export, HTML export |
| 10212 | @subsection Images in HTML export | 11219 | @subsection Images in HTML export |
| 10213 | 11220 | ||
| 10214 | @cindex images, inline in HTML | 11221 | @cindex images, inline in HTML |
| 10215 | @cindex inlining images in HTML | 11222 | @cindex inlining images in HTML |
| 10216 | @vindex org-export-html-inline-images | 11223 | @vindex org-html-inline-images |
| 10217 | HTML export can inline images given as links in the Org file, and | 11224 | HTML export can inline images given as links in the Org file, and |
| 10218 | it can make an image the clickable part of a link. By | 11225 | it can make an image the clickable part of a link. By |
| 10219 | default@footnote{But see the variable | 11226 | default@footnote{But see the variable |
| 10220 | @code{org-export-html-inline-images}.}, images are inlined if a link does | 11227 | @code{org-html-inline-images}.}, images are inlined if a link does |
| 10221 | not have a description. So @samp{[[file:myimg.jpg]]} will be inlined, | 11228 | not have a description. So @samp{[[file:myimg.jpg]]} will be inlined, |
| 10222 | while @samp{[[file:myimg.jpg][the image]]} will just produce a link | 11229 | while @samp{[[file:myimg.jpg][the image]]} will just produce a link |
| 10223 | @samp{the image} that points to the image. If the description part | 11230 | @samp{the image} that points to the image. If the description part |
| @@ -10238,7 +11245,7 @@ support text viewers and accessibility, and align it to the right. | |||
| 10238 | @cindex #+ATTR_HTML | 11245 | @cindex #+ATTR_HTML |
| 10239 | @example | 11246 | @example |
| 10240 | #+CAPTION: A black cat stalking a spider | 11247 | #+CAPTION: A black cat stalking a spider |
| 10241 | #+ATTR_HTML: alt="cat/spider image" title="Action!" align="right" | 11248 | #+ATTR_HTML: :alt cat/spider image :title Action! :align right |
| 10242 | [[./img/a.jpg]] | 11249 | [[./img/a.jpg]] |
| 10243 | @end example | 11250 | @end example |
| 10244 | 11251 | ||
| @@ -10249,36 +11256,43 @@ You could use @code{http} addresses just as well. | |||
| 10249 | @subsection Math formatting in HTML export | 11256 | @subsection Math formatting in HTML export |
| 10250 | @cindex MathJax | 11257 | @cindex MathJax |
| 10251 | @cindex dvipng | 11258 | @cindex dvipng |
| 11259 | @cindex imagemagick | ||
| 10252 | 11260 | ||
| 10253 | @LaTeX{} math snippets (@pxref{@LaTeX{} fragments}) can be displayed in two | 11261 | @LaTeX{} math snippets (@pxref{@LaTeX{} fragments}) can be displayed in two |
| 10254 | different ways on HTML pages. The default is to use the | 11262 | different ways on HTML pages. The default is to use the |
| 10255 | @uref{http://www.mathjax.org, MathJax system} which should work out of the | 11263 | @uref{http://www.mathjax.org, MathJax system} which should work out of the |
| 10256 | box with Org mode installation because @code{http://orgmode.org} serves | 11264 | box with Org mode installation because @uref{http://orgmode.org} serves |
| 10257 | @file{MathJax} for Org mode users for small applications and for testing | 11265 | @file{MathJax} for Org mode users for small applications and for testing |
| 10258 | purposes. @b{If you plan to use this regularly or on pages with significant | 11266 | purposes. @b{If you plan to use this regularly or on pages with significant |
| 10259 | page views, you should install@footnote{Installation instructions can be | 11267 | page views, you should install@footnote{Installation instructions can be |
| 10260 | found on the MathJax website, see | 11268 | found on the MathJax website, see |
| 10261 | @uref{http://www.mathjax.org/resources/docs/?installation.html}.} MathJax on | 11269 | @uref{http://www.mathjax.org/resources/docs/?installation.html}.} MathJax on |
| 10262 | your own server in order to limit the load of our server.} To configure | 11270 | your own server in order to limit the load of our server.} To configure |
| 10263 | @file{MathJax}, use the variable @code{org-export-html-mathjax-options} or | 11271 | @file{MathJax}, use the variable @code{org-html-mathjax-options} or |
| 10264 | insert something like the following into the buffer: | 11272 | insert something like the following into the buffer: |
| 10265 | 11273 | ||
| 10266 | @example | 11274 | @example |
| 10267 | #+MATHJAX: align:"left" mathml:t path:"/MathJax/MathJax.js" | 11275 | #+HTML_MATHJAX: align:"left" mathml:t path:"/MathJax/MathJax.js" |
| 10268 | @end example | 11276 | @end example |
| 10269 | 11277 | ||
| 10270 | @noindent See the docstring of the variable | 11278 | @noindent See the docstring of the variable |
| 10271 | @code{org-export-html-mathjax-options} for the meaning of the parameters in | 11279 | @code{org-html-mathjax-options} for the meaning of the parameters in |
| 10272 | this line. | 11280 | this line. |
| 10273 | 11281 | ||
| 10274 | If you prefer, you can also request that @LaTeX{} fragments are processed | 11282 | If you prefer, you can also request that @LaTeX{} fragments are processed |
| 10275 | into small images that will be inserted into the browser page. Before the | 11283 | into small images that will be inserted into the browser page. Before the |
| 10276 | availability of MathJax, this was the default method for Org files. This | 11284 | availability of MathJax, this was the default method for Org files. This |
| 10277 | method requires that the @file{dvipng} program is available on your system. | 11285 | method requires that the @file{dvipng} program or @file{imagemagick} suite is |
| 10278 | You can still get this processing with | 11286 | available on your system. You can still get this processing with |
| 11287 | |||
| 11288 | @example | ||
| 11289 | #+OPTIONS: tex:dvipng | ||
| 11290 | @end example | ||
| 11291 | |||
| 11292 | or: | ||
| 10279 | 11293 | ||
| 10280 | @example | 11294 | @example |
| 10281 | #+OPTIONS: LaTeX:dvipng | 11295 | #+OPTIONS: tex:imagemagick |
| 10282 | @end example | 11296 | @end example |
| 10283 | 11297 | ||
| 10284 | @node Text areas in HTML export, CSS support, Math formatting in HTML export, HTML export | 11298 | @node Text areas in HTML export, CSS support, Math formatting in HTML export, HTML export |
| @@ -10287,15 +11301,16 @@ You can still get this processing with | |||
| 10287 | @cindex text areas, in HTML | 11301 | @cindex text areas, in HTML |
| 10288 | An alternative way to publish literal code examples in HTML is to use text | 11302 | An alternative way to publish literal code examples in HTML is to use text |
| 10289 | areas, where the example can even be edited before pasting it into an | 11303 | areas, where the example can even be edited before pasting it into an |
| 10290 | application. It is triggered by a @code{-t} switch at an @code{example} or | 11304 | application. It is triggered by @code{:textarea} attribute at an |
| 10291 | @code{src} block. Using this switch disables any options for syntax and | 11305 | @code{example} or @code{src} block. |
| 10292 | label highlighting, and line numbering, which may be present. You may also | 11306 | |
| 10293 | use @code{-h} and @code{-w} switches to specify the height and width of the | 11307 | You may also use @code{:height} and @code{:width} attributes to specify the |
| 10294 | text area, which default to the number of lines in the example, and 80, | 11308 | height and width of the text area, which default to the number of lines in |
| 10295 | respectively. For example | 11309 | the example, and 80, respectively. For example |
| 10296 | 11310 | ||
| 10297 | @example | 11311 | @example |
| 10298 | #+BEGIN_EXAMPLE -t -w 40 | 11312 | #+ATTR_HTML: :textarea t :width 40 |
| 11313 | #+BEGIN_EXAMPLE | ||
| 10299 | (defun org-xor (a b) | 11314 | (defun org-xor (a b) |
| 10300 | "Exclusive or." | 11315 | "Exclusive or." |
| 10301 | (if a (not b) b)) | 11316 | (if a (not b) b)) |
| @@ -10308,15 +11323,15 @@ respectively. For example | |||
| 10308 | @cindex CSS, for HTML export | 11323 | @cindex CSS, for HTML export |
| 10309 | @cindex HTML export, CSS | 11324 | @cindex HTML export, CSS |
| 10310 | 11325 | ||
| 10311 | @vindex org-export-html-todo-kwd-class-prefix | 11326 | @vindex org-html-todo-kwd-class-prefix |
| 10312 | @vindex org-export-html-tag-class-prefix | 11327 | @vindex org-html-tag-class-prefix |
| 10313 | You can also give style information for the exported file. The HTML exporter | 11328 | You can modify the CSS style definitions for the exported file. The HTML |
| 10314 | assigns the following special CSS classes@footnote{If the classes on TODO | 11329 | exporter assigns the following special CSS classes@footnote{If the classes on |
| 10315 | keywords and tags lead to conflicts, use the variables | 11330 | TODO keywords and tags lead to conflicts, use the variables |
| 10316 | @code{org-export-html-todo-kwd-class-prefix} and | 11331 | @code{org-html-todo-kwd-class-prefix} and @code{org-html-tag-class-prefix} to |
| 10317 | @code{org-export-html-tag-class-prefix} to make them unique.} to appropriate | 11332 | make them unique.} to appropriate parts of the document---your style |
| 10318 | parts of the document---your style specifications may change these, in | 11333 | specifications may change these, in addition to any of the standard classes |
| 10319 | addition to any of the standard classes like for headlines, tables, etc. | 11334 | like for headlines, tables, etc. |
| 10320 | @example | 11335 | @example |
| 10321 | p.author @r{author information, including email} | 11336 | p.author @r{author information, including email} |
| 10322 | p.date @r{publishing date} | 11337 | p.date @r{publishing date} |
| @@ -10336,6 +11351,9 @@ p.creator @r{creator info, about org mode version} | |||
| 10336 | div.outline-N @r{div for outline level N (headline plus text))} | 11351 | div.outline-N @r{div for outline level N (headline plus text))} |
| 10337 | div.outline-text-N @r{extra div for text at outline level N} | 11352 | div.outline-text-N @r{extra div for text at outline level N} |
| 10338 | .section-number-N @r{section number in headlines, different for each level} | 11353 | .section-number-N @r{section number in headlines, different for each level} |
| 11354 | .figure-number @r{label like "Figure 1:"} | ||
| 11355 | .table-number @r{label like "Table 1:"} | ||
| 11356 | .listing-number @r{label like "Listing 1:"} | ||
| 10339 | div.figure @r{how to format an inlined image} | 11357 | div.figure @r{how to format an inlined image} |
| 10340 | pre.src @r{formatted source code} | 11358 | pre.src @r{formatted source code} |
| 10341 | pre.example @r{normal example} | 11359 | pre.example @r{normal example} |
| @@ -10346,24 +11364,26 @@ p.footnote @r{footnote definition paragraph, containing a footnote} | |||
| 10346 | .footnum @r{footnote number in footnote definition (always <sup>)} | 11364 | .footnum @r{footnote number in footnote definition (always <sup>)} |
| 10347 | @end example | 11365 | @end example |
| 10348 | 11366 | ||
| 10349 | @vindex org-export-html-style-default | 11367 | @vindex org-html-style-default |
| 10350 | @vindex org-export-html-style-include-default | 11368 | @vindex org-html-head-include-default-style |
| 10351 | @vindex org-export-html-style | 11369 | @vindex org-html-head |
| 10352 | @vindex org-export-html-extra | 11370 | @vindex org-html-head-extra |
| 10353 | @vindex org-export-html-style-default | 11371 | @cindex #+HTML_INCLUDE_STYLE |
| 10354 | Each exported file contains a compact default style that defines these | 11372 | Each exported file contains a compact default style that defines these |
| 10355 | classes in a basic way@footnote{This style is defined in the constant | 11373 | classes in a basic way@footnote{This style is defined in the constant |
| 10356 | @code{org-export-html-style-default}, which you should not modify. To turn | 11374 | @code{org-html-style-default}, which you should not modify. To turn |
| 10357 | inclusion of these defaults off, customize | 11375 | inclusion of these defaults off, customize |
| 10358 | @code{org-export-html-style-include-default}}. You may overwrite these | 11376 | @code{org-html-head-include-default-style} or set @code{html-style} to |
| 10359 | settings, or add to them by using the variables @code{org-export-html-style} | 11377 | @code{nil} in an @code{OPTIONS} line.}. You may overwrite these settings, or |
| 10360 | (for Org-wide settings) and @code{org-export-html-style-extra} (for more | 11378 | add to them by using the variables @code{org-html-head} and |
| 10361 | fine-grained settings, like file-local settings). To set the latter variable | 11379 | @code{org-html-head-extra}. You can override the global values of these |
| 10362 | individually for each file, you can use | 11380 | variables for each file by using these keywords: |
| 10363 | 11381 | ||
| 10364 | @cindex #+STYLE | 11382 | @cindex #+HTML_HEAD |
| 11383 | @cindex #+HTML_HEAD_EXTRA | ||
| 10365 | @example | 11384 | @example |
| 10366 | #+STYLE: <link rel="stylesheet" type="text/css" href="stylesheet.css" /> | 11385 | #+HTML_HEAD: <link rel="stylesheet" type="text/css" href="style1.css" /> |
| 11386 | #+HTML_HEAD_EXTRA: <link rel="alternate stylesheet" type="text/css" href="style2.css" /> | ||
| 10367 | @end example | 11387 | @end example |
| 10368 | 11388 | ||
| 10369 | @noindent | 11389 | @noindent |
| @@ -10392,15 +11412,12 @@ as well, press @kbd{?} for an overview of the available keys). The second | |||
| 10392 | view type is a @emph{folding} view much like Org provides inside Emacs. The | 11412 | view type is a @emph{folding} view much like Org provides inside Emacs. The |
| 10393 | script is available at @url{http://orgmode.org/org-info.js} and you can find | 11413 | script is available at @url{http://orgmode.org/org-info.js} and you can find |
| 10394 | the documentation for it at @url{http://orgmode.org/worg/code/org-info-js/}. | 11414 | the documentation for it at @url{http://orgmode.org/worg/code/org-info-js/}. |
| 10395 | We host the script at our site, but if you use it a lot, you might | 11415 | We host the script at our site, but if you use it a lot, you might not want |
| 10396 | not want to be dependent on @url{http://orgmode.org} and prefer to install a local | 11416 | to be dependent on @url{http://orgmode.org} and prefer to install a local |
| 10397 | copy on your own web server. | 11417 | copy on your own web server. |
| 10398 | 11418 | ||
| 10399 | To use the script, you need to make sure that the @file{org-jsinfo.el} module | 11419 | All it then takes to use this program is adding a single line to the Org |
| 10400 | gets loaded. It should be loaded by default, but you can try @kbd{M-x | 11420 | file: |
| 10401 | customize-variable @key{RET} org-modules @key{RET}} to convince yourself that | ||
| 10402 | this is indeed the case. All it then takes to make use of the program is | ||
| 10403 | adding a single line to the Org file: | ||
| 10404 | 11421 | ||
| 10405 | @cindex #+INFOJS_OPT | 11422 | @cindex #+INFOJS_OPT |
| 10406 | @example | 11423 | @example |
| @@ -10440,92 +11457,61 @@ buttons: @r{Should view-toggle buttons be everywhere? When @code{nil} (the} | |||
| 10440 | @r{default), only one such button will be present.} | 11457 | @r{default), only one such button will be present.} |
| 10441 | @end example | 11458 | @end example |
| 10442 | @noindent | 11459 | @noindent |
| 10443 | @vindex org-infojs-options | 11460 | @vindex org-html-infojs-options |
| 10444 | @vindex org-export-html-use-infojs | 11461 | @vindex org-html-use-infojs |
| 10445 | You can choose default values for these options by customizing the variable | 11462 | You can choose default values for these options by customizing the variable |
| 10446 | @code{org-infojs-options}. If you always want to apply the script to your | 11463 | @code{org-html-infojs-options}. If you always want to apply the script to your |
| 10447 | pages, configure the variable @code{org-export-html-use-infojs}. | 11464 | pages, configure the variable @code{org-html-use-infojs}. |
| 10448 | 11465 | ||
| 10449 | @node @LaTeX{} and PDF export, DocBook export, HTML export, Exporting | 11466 | @node @LaTeX{} and PDF export, Markdown export, HTML export, Exporting |
| 10450 | @section @LaTeX{} and PDF export | 11467 | @section @LaTeX{} and PDF export |
| 10451 | @cindex @LaTeX{} export | 11468 | @cindex @LaTeX{} export |
| 10452 | @cindex PDF export | 11469 | @cindex PDF export |
| 10453 | @cindex Guerry, Bastien | 11470 | |
| 10454 | 11471 | @LaTeX{} export can produce an arbitrarily complex LaTeX document of any | |
| 10455 | Org mode contains a @LaTeX{} exporter written by Bastien Guerry. With | 11472 | standard or custom document class. With further processing@footnote{The |
| 10456 | further processing@footnote{The default @LaTeX{} output is designed for | 11473 | default @LaTeX{} output is designed for processing with @code{pdftex} or |
| 10457 | processing with @code{pdftex} or @LaTeX{}. It includes packages that are not | 11474 | @LaTeX{}. It includes packages that are not compatible with @code{xetex} and |
| 10458 | compatible with @code{xetex} and possibly @code{luatex}. See the variables | 11475 | possibly @code{luatex}. The @LaTeX{} exporter can be configured to support |
| 10459 | @code{org-export-latex-default-packages-alist} and | 11476 | alternative TeX engines, see the options |
| 10460 | @code{org-export-latex-packages-alist}.}, this backend is also used to | 11477 | @code{org-latex-default-packages-alist} and @code{org-latex-packages-alist}.}, |
| 10461 | produce PDF output. Since the @LaTeX{} output uses @file{hyperref} to | 11478 | which the @LaTeX{} exporter is able to control, this back-end is able to |
| 10462 | implement links and cross references, the PDF output file will be fully | 11479 | produce PDF output. Because the @LaTeX{} exporter can be configured to use |
| 10463 | linked. Beware of the fact that your @code{org} file has to be properly | 11480 | the @code{hyperref} package, the default setup produces fully-linked PDF |
| 10464 | structured in order to be correctly exported: respect the hierarchy of | 11481 | output. |
| 10465 | sections. | 11482 | |
| 11483 | As in @LaTeX{}, blank lines are meaningful for this back-end: a paragraph | ||
| 11484 | will not be started if two contiguous syntactical elements are not separated | ||
| 11485 | by an empty line. | ||
| 11486 | |||
| 11487 | This back-end also offers enhanced support for footnotes. Thus, it handles | ||
| 11488 | nested footnotes, footnotes in tables and footnotes in a list item's | ||
| 11489 | description. | ||
| 10466 | 11490 | ||
| 10467 | @menu | 11491 | @menu |
| 10468 | * @LaTeX{}/PDF export commands:: | 11492 | * @LaTeX{} export commands:: How to export to LaTeX and PDF |
| 10469 | * Header and sectioning:: Setting up the export file structure | 11493 | * Header and sectioning:: Setting up the export file structure |
| 10470 | * Quoting @LaTeX{} code:: Incorporating literal @LaTeX{} code | 11494 | * Quoting @LaTeX{} code:: Incorporating literal @LaTeX{} code |
| 10471 | * Tables in @LaTeX{} export:: Options for exporting tables to @LaTeX{} | 11495 | * @LaTeX{} specific attributes:: Controlling @LaTeX{} output |
| 10472 | * Images in @LaTeX{} export:: How to insert figures into @LaTeX{} output | ||
| 10473 | * Beamer class export:: Turning the file into a presentation | ||
| 10474 | @end menu | 11496 | @end menu |
| 10475 | 11497 | ||
| 10476 | @node @LaTeX{}/PDF export commands, Header and sectioning, @LaTeX{} and PDF export, @LaTeX{} and PDF export | 11498 | @node @LaTeX{} export commands, Header and sectioning, @LaTeX{} and PDF export, @LaTeX{} and PDF export |
| 10477 | @subsection @LaTeX{} export commands | 11499 | @subsection @LaTeX{} export commands |
| 10478 | 11500 | ||
| 10479 | @cindex region, active | ||
| 10480 | @cindex active region | ||
| 10481 | @cindex transient-mark-mode | ||
| 10482 | @table @kbd | 11501 | @table @kbd |
| 10483 | @orgcmd{C-c C-e l,org-export-as-latex} | 11502 | @orgcmd{C-c C-e l l,org-latex-export-to-latex} |
| 10484 | @cindex property EXPORT_FILE_NAME | 11503 | Export as a @LaTeX{} file. For an Org file @file{myfile.org}, the @LaTeX{} |
| 10485 | Export as a @LaTeX{} file. For an Org file | 11504 | file will be @file{myfile.tex}. The file will be overwritten without |
| 10486 | @file{myfile.org}, the @LaTeX{} file will be @file{myfile.tex}. The file will | 11505 | warning. |
| 10487 | be overwritten without warning. If there is an active region@footnote{This | 11506 | @orgcmd{C-c C-e l L,org-latex-export-as-latex} |
| 10488 | requires @code{transient-mark-mode} be turned on.}, only the region will be | ||
| 10489 | exported. If the selected region is a single tree@footnote{To select the | ||
| 10490 | current subtree, use @kbd{C-c @@}.}, the tree head will become the document | ||
| 10491 | title. If the tree head entry has or inherits an @code{EXPORT_FILE_NAME} | ||
| 10492 | property, that name will be used for the export. | ||
| 10493 | @orgcmd{C-c C-e L,org-export-as-latex-to-buffer} | ||
| 10494 | Export to a temporary buffer. Do not create a file. | 11507 | Export to a temporary buffer. Do not create a file. |
| 10495 | @item C-c C-e v l/L | 11508 | @orgcmd{C-c C-e l p,org-latex-export-to-pdf} |
| 10496 | Export only the visible part of the document. | ||
| 10497 | @item M-x org-export-region-as-latex | ||
| 10498 | Convert the region to @LaTeX{} under the assumption that it was in Org mode | ||
| 10499 | syntax before. This is a global command that can be invoked in any | ||
| 10500 | buffer. | ||
| 10501 | @item M-x org-replace-region-by-latex | ||
| 10502 | Replace the active region (assumed to be in Org mode syntax) by @LaTeX{} | ||
| 10503 | code. | ||
| 10504 | @orgcmd{C-c C-e p,org-export-as-pdf} | ||
| 10505 | Export as @LaTeX{} and then process to PDF. | 11509 | Export as @LaTeX{} and then process to PDF. |
| 10506 | @orgcmd{C-c C-e d,org-export-as-pdf-and-open} | 11510 | @item C-c C-e l o |
| 10507 | Export as @LaTeX{} and then process to PDF, then open the resulting PDF file. | 11511 | Export as @LaTeX{} and then process to PDF, then open the resulting PDF file. |
| 10508 | @end table | 11512 | @end table |
| 10509 | 11513 | ||
| 10510 | @cindex headline levels, for exporting | 11514 | @node Header and sectioning, Quoting @LaTeX{} code, @LaTeX{} export commands, @LaTeX{} and PDF export |
| 10511 | @vindex org-latex-low-levels | ||
| 10512 | In the exported version, the first 3 outline levels will become | ||
| 10513 | headlines, defining a general document structure. Additional levels | ||
| 10514 | will be exported as description lists. The exporter can ignore them or | ||
| 10515 | convert them to a custom string depending on | ||
| 10516 | @code{org-latex-low-levels}. | ||
| 10517 | |||
| 10518 | If you want that transition to occur at a different level, specify it | ||
| 10519 | with a numeric prefix argument. For example, | ||
| 10520 | |||
| 10521 | @example | ||
| 10522 | @kbd{C-2 C-c C-e l} | ||
| 10523 | @end example | ||
| 10524 | |||
| 10525 | @noindent | ||
| 10526 | creates two levels of headings and does the rest as items. | ||
| 10527 | |||
| 10528 | @node Header and sectioning, Quoting @LaTeX{} code, @LaTeX{}/PDF export commands, @LaTeX{} and PDF export | ||
| 10529 | @subsection Header and sectioning structure | 11515 | @subsection Header and sectioning structure |
| 10530 | @cindex @LaTeX{} class | 11516 | @cindex @LaTeX{} class |
| 10531 | @cindex @LaTeX{} sectioning structure | 11517 | @cindex @LaTeX{} sectioning structure |
| @@ -10533,493 +11519,368 @@ creates two levels of headings and does the rest as items. | |||
| 10533 | @cindex header, for @LaTeX{} files | 11519 | @cindex header, for @LaTeX{} files |
| 10534 | @cindex sectioning structure, for @LaTeX{} export | 11520 | @cindex sectioning structure, for @LaTeX{} export |
| 10535 | 11521 | ||
| 11522 | By default, the first three outline levels become headlines, defining a | ||
| 11523 | general document structure. Additional levels are exported as @code{itemize} | ||
| 11524 | or @code{enumerate} lists. The transition can also occur at a different | ||
| 11525 | level (@pxref{Export settings}). | ||
| 11526 | |||
| 10536 | By default, the @LaTeX{} output uses the class @code{article}. | 11527 | By default, the @LaTeX{} output uses the class @code{article}. |
| 10537 | 11528 | ||
| 10538 | @vindex org-export-latex-default-class | 11529 | @vindex org-latex-default-class |
| 10539 | @vindex org-export-latex-classes | 11530 | @vindex org-latex-classes |
| 10540 | @vindex org-export-latex-default-packages-alist | 11531 | @vindex org-latex-default-packages-alist |
| 10541 | @vindex org-export-latex-packages-alist | 11532 | @vindex org-latex-packages-alist |
| 10542 | @cindex #+LaTeX_HEADER | ||
| 10543 | @cindex #+LaTeX_CLASS | ||
| 10544 | @cindex #+LaTeX_CLASS_OPTIONS | ||
| 10545 | @cindex property, LaTeX_CLASS | ||
| 10546 | @cindex property, LaTeX_CLASS_OPTIONS | ||
| 10547 | You can change this globally by setting a different value for | 11533 | You can change this globally by setting a different value for |
| 10548 | @code{org-export-latex-default-class} or locally by adding an option like | 11534 | @code{org-latex-default-class} or locally by adding an option like |
| 10549 | @code{#+LaTeX_CLASS: myclass} in your file, or with a @code{:LaTeX_CLASS:} | 11535 | @code{#+LATEX_CLASS: myclass} in your file, or with |
| 10550 | property that applies when exporting a region containing only this (sub)tree. | 11536 | a @code{EXPORT_LATEX_CLASS} property that applies when exporting a region |
| 10551 | The class must be listed in @code{org-export-latex-classes}. This variable | 11537 | containing only this (sub)tree. The class must be listed in |
| 10552 | defines a header template for each class@footnote{Into which the values of | 11538 | @code{org-latex-classes}. This variable defines a header template for each |
| 10553 | @code{org-export-latex-default-packages-alist} and | 11539 | class@footnote{Into which the values of |
| 10554 | @code{org-export-latex-packages-alist} are spliced.}, and allows you to | 11540 | @code{org-latex-default-packages-alist} and @code{org-latex-packages-alist} |
| 10555 | define the sectioning structure for each class. You can also define your own | 11541 | are spliced.}, and allows you to define the sectioning structure for each |
| 10556 | classes there. @code{#+LaTeX_CLASS_OPTIONS} or a @code{:LaTeX_CLASS_OPTIONS:} | 11542 | class. You can also define your own classes there. |
| 10557 | property can specify the options for the @code{\documentclass} macro. The | 11543 | |
| 10558 | options to documentclass have to be provided, as expected by @LaTeX{}, within | 11544 | @cindex #+LATEX_CLASS |
| 10559 | square brackets. You can also use @code{#+LaTeX_HEADER: \usepackage@{xyz@}} | 11545 | @cindex #+LATEX_CLASS_OPTIONS |
| 10560 | to add lines to the header. See the docstring of | 11546 | @cindex property, EXPORT_LATEX_CLASS |
| 10561 | @code{org-export-latex-classes} for more information. An example is shown | 11547 | @cindex property, EXPORT_LATEX_CLASS_OPTIONS |
| 10562 | below. | 11548 | The @code{LATEX_CLASS_OPTIONS} keyword or @code{EXPORT_LATEX_CLASS_OPTIONS} |
| 10563 | 11549 | property can specify the options for the @code{\documentclass} macro. These | |
| 10564 | @example | 11550 | options have to be provided, as expected by @LaTeX{}, within square brackets. |
| 10565 | #+LaTeX_CLASS: article | 11551 | |
| 10566 | #+LaTeX_CLASS_OPTIONS: [a4paper] | 11552 | @cindex #+LATEX_HEADER |
| 10567 | #+LaTeX_HEADER: \usepackage@{xyz@} | 11553 | @cindex #+LATEX_HEADER_EXTRA |
| 11554 | You can also use the @code{LATEX_HEADER} and | ||
| 11555 | @code{LATEX_HEADER_EXTRA}@footnote{Unlike @code{LATEX_HEADER}, contents | ||
| 11556 | from @code{LATEX_HEADER_EXTRA} keywords will not be loaded when previewing | ||
| 11557 | @LaTeX{} snippets (@pxref{Previewing @LaTeX{} fragments}).} keywords in order | ||
| 11558 | to add lines to the header. See the docstring of @code{org-latex-classes} for | ||
| 11559 | more information. | ||
| 11560 | |||
| 11561 | An example is shown below. | ||
| 11562 | |||
| 11563 | @example | ||
| 11564 | #+LATEX_CLASS: article | ||
| 11565 | #+LATEX_CLASS_OPTIONS: [a4paper] | ||
| 11566 | #+LATEX_HEADER: \usepackage@{xyz@} | ||
| 10568 | 11567 | ||
| 10569 | * Headline 1 | 11568 | * Headline 1 |
| 10570 | some text | 11569 | some text |
| 10571 | @end example | 11570 | @end example |
| 10572 | 11571 | ||
| 10573 | @node Quoting @LaTeX{} code, Tables in @LaTeX{} export, Header and sectioning, @LaTeX{} and PDF export | 11572 | @node Quoting @LaTeX{} code, @LaTeX{} specific attributes, Header and sectioning, @LaTeX{} and PDF export |
| 10574 | @subsection Quoting @LaTeX{} code | 11573 | @subsection Quoting @LaTeX{} code |
| 10575 | 11574 | ||
| 10576 | Embedded @LaTeX{} as described in @ref{Embedded @LaTeX{}}, will be correctly | 11575 | Embedded @LaTeX{} as described in @ref{Embedded @LaTeX{}}, will be correctly |
| 10577 | inserted into the @LaTeX{} file. This includes simple macros like | 11576 | inserted into the @LaTeX{} file. Furthermore, you can add special code that |
| 10578 | @samp{\ref@{LABEL@}} to create a cross reference to a figure. Furthermore, | 11577 | should only be present in @LaTeX{} export with the following constructs: |
| 10579 | you can add special code that should only be present in @LaTeX{} export with | ||
| 10580 | the following constructs: | ||
| 10581 | 11578 | ||
| 10582 | @cindex #+LaTeX | 11579 | @cindex #+LATEX |
| 10583 | @cindex #+BEGIN_LaTeX | 11580 | @cindex #+BEGIN_LATEX |
| 10584 | @example | 11581 | @example |
| 10585 | #+LaTeX: Literal @LaTeX{} code for export | 11582 | Code within @@@@latex:some code@@@@ a paragraph. |
| 10586 | @end example | ||
| 10587 | 11583 | ||
| 10588 | @noindent or | 11584 | #+LATEX: Literal @LaTeX{} code for export |
| 10589 | @cindex #+BEGIN_LaTeX | ||
| 10590 | 11585 | ||
| 10591 | @example | 11586 | #+BEGIN_LATEX |
| 10592 | #+BEGIN_LaTeX | ||
| 10593 | All lines between these markers are exported literally | 11587 | All lines between these markers are exported literally |
| 10594 | #+END_LaTeX | 11588 | #+END_LATEX |
| 10595 | @end example | 11589 | @end example |
| 10596 | 11590 | ||
| 11591 | @node @LaTeX{} specific attributes, , Quoting @LaTeX{} code, @LaTeX{} and PDF export | ||
| 11592 | @subsection @LaTeX{} specific attributes | ||
| 11593 | @cindex #+ATTR_LATEX | ||
| 11594 | |||
| 11595 | @LaTeX{} understands attributes specified in an @code{ATTR_LATEX} line. They | ||
| 11596 | affect tables, images, plain lists, special blocks and source blocks. | ||
| 10597 | 11597 | ||
| 10598 | @node Tables in @LaTeX{} export, Images in @LaTeX{} export, Quoting @LaTeX{} code, @LaTeX{} and PDF export | 11598 | @subsubheading Tables in @LaTeX{} export |
| 10599 | @subsection Tables in @LaTeX{} export | ||
| 10600 | @cindex tables, in @LaTeX{} export | 11599 | @cindex tables, in @LaTeX{} export |
| 10601 | 11600 | ||
| 10602 | For @LaTeX{} export of a table, you can specify a label, a caption and | 11601 | For @LaTeX{} export of a table, you can specify a label and a caption |
| 10603 | placement options (@pxref{Images and tables}). You can also use the | 11602 | (@pxref{Images and tables}). You can also use attributes to control table |
| 10604 | @code{ATTR_LaTeX} line to request a @code{longtable} environment for the | 11603 | layout and contents. Valid @LaTeX{} attributes include: |
| 10605 | table, so that it may span several pages, or to change the default table | 11604 | |
| 10606 | environment from @code{table} to @code{table*} or to change the default inner | 11605 | @table @code |
| 10607 | tabular environment to @code{tabularx} or @code{tabulary}. Finally, you can | 11606 | @item :mode |
| 10608 | set the alignment string, and (with @code{tabularx} or @code{tabulary}) the | 11607 | @vindex org-latex-default-table-mode |
| 10609 | width: | 11608 | Nature of table's contents. It can be set to @code{table}, @code{math}, |
| 11609 | @code{inline-math} or @code{verbatim}. In particular, when in @code{math} or | ||
| 11610 | @code{inline-math} mode, every cell is exported as-is, horizontal rules are | ||
| 11611 | ignored and the table will be wrapped in a math environment. Also, | ||
| 11612 | contiguous tables sharing the same math mode will be wrapped within the same | ||
| 11613 | environment. Default mode is determined in | ||
| 11614 | @code{org-latex-default-table-mode}. | ||
| 11615 | @item :environment | ||
| 11616 | @vindex org-latex-default-table-environment | ||
| 11617 | Environment used for the table. It can be set to any @LaTeX{} table | ||
| 11618 | environment, like @code{tabularx}@footnote{Requires adding the | ||
| 11619 | @code{tabularx} package to @code{org-latex-packages-alist}.}, | ||
| 11620 | @code{longtable}, @code{array}, @code{tabu}@footnote{Requires adding the | ||
| 11621 | @code{tabu} package to @code{org-latex-packages-alist}.}, | ||
| 11622 | @code{bmatrix}@enddots{} It defaults to | ||
| 11623 | @code{org-latex-default-table-environment} value. | ||
| 11624 | @item :caption | ||
| 11625 | @code{#+CAPTION} keyword is the simplest way to set a caption for a table | ||
| 11626 | (@pxref{Images and tables}). If you need more advanced commands for that | ||
| 11627 | task, you can use @code{:caption} attribute instead. Its value should be raw | ||
| 11628 | @LaTeX{} code. It has precedence over @code{#+CAPTION}. | ||
| 11629 | @item :float | ||
| 11630 | @itemx :placement | ||
| 11631 | Float environment for the table. Possible values are @code{sidewaystable}, | ||
| 11632 | @code{multicolumn}, @code{t} and @code{nil}. When unspecified, a table with | ||
| 11633 | a caption will have a @code{table} environment. Moreover, @code{:placement} | ||
| 11634 | attribute can specify the positioning of the float. | ||
| 11635 | @item :align | ||
| 11636 | @itemx :font | ||
| 11637 | @itemx :width | ||
| 11638 | Set, respectively, the alignment string of the table, its font size and its | ||
| 11639 | width. They only apply on regular tables. | ||
| 11640 | @item :spread | ||
| 11641 | Boolean specific to the @code{tabu} and @code{longtabu} environments, and | ||
| 11642 | only takes effect when used in conjunction with the @code{:width} attribute. | ||
| 11643 | When @code{:spread} is non-@code{nil}, the table will be spread or shrunk by the | ||
| 11644 | value of @code{:width}. | ||
| 11645 | @item :booktabs | ||
| 11646 | @itemx :center | ||
| 11647 | @itemx :rmlines | ||
| 11648 | @vindex org-latex-tables-booktabs | ||
| 11649 | @vindex org-latex-tables-centered | ||
| 11650 | They toggle, respectively, @code{booktabs} usage (assuming the package is | ||
| 11651 | properly loaded), table centering and removal of every horizontal rule but | ||
| 11652 | the first one (in a "table.el" table only). In particular, | ||
| 11653 | @code{org-latex-tables-booktabs} (respectively @code{org-latex-tables-centered}) | ||
| 11654 | activates the first (respectively second) attribute globally. | ||
| 11655 | @item :math-prefix | ||
| 11656 | @itemx :math-suffix | ||
| 11657 | @itemx :math-arguments | ||
| 11658 | A string that will be inserted, respectively, before the table within the | ||
| 11659 | math environment, after the table within the math environment, and between | ||
| 11660 | the macro name and the contents of the table. The @code{:math-arguments} | ||
| 11661 | attribute is used for matrix macros that require more than one argument | ||
| 11662 | (e.g., @code{qbordermatrix}). | ||
| 11663 | @end table | ||
| 11664 | |||
| 11665 | Thus, attributes can be used in a wide array of situations, like writing | ||
| 11666 | a table that will span over multiple pages, or a matrix product: | ||
| 10610 | 11667 | ||
| 10611 | @cindex #+CAPTION | ||
| 10612 | @cindex #+LABEL | ||
| 10613 | @cindex #+ATTR_LaTeX | ||
| 10614 | @example | 11668 | @example |
| 10615 | #+CAPTION: A long table | 11669 | #+ATTR_LATEX: :environment longtable :align l|lp@{3cm@}r|l |
| 10616 | #+LABEL: tbl:long | ||
| 10617 | #+ATTR_LaTeX: longtable align=l|lp@{3cm@}r|l | ||
| 10618 | | ..... | ..... | | 11670 | | ..... | ..... | |
| 10619 | | ..... | ..... | | 11671 | | ..... | ..... | |
| 11672 | |||
| 11673 | #+ATTR_LATEX: :mode math :environment bmatrix :math-suffix \times | ||
| 11674 | | a | b | | ||
| 11675 | | c | d | | ||
| 11676 | #+ATTR_LATEX: :mode math :environment bmatrix | ||
| 11677 | | 1 | 2 | | ||
| 11678 | | 3 | 4 | | ||
| 10620 | @end example | 11679 | @end example |
| 10621 | 11680 | ||
| 10622 | or to specify a multicolumn table with @code{tabulary} | 11681 | In the example below, @LaTeX{} command |
| 11682 | @code{\bicaption@{HeadingA@}@{HeadingB@}} will set the caption. | ||
| 10623 | 11683 | ||
| 10624 | @cindex #+CAPTION | ||
| 10625 | @cindex #+LABEL | ||
| 10626 | @cindex #+ATTR_LaTeX | ||
| 10627 | @example | 11684 | @example |
| 10628 | #+CAPTION: A wide table with tabulary | 11685 | #+ATTR_LATEX: :caption \bicaption@{HeadingA@}@{HeadingB@} |
| 10629 | #+LABEL: tbl:wide | ||
| 10630 | #+ATTR_LaTeX: table* tabulary width=\textwidth | ||
| 10631 | | ..... | ..... | | 11686 | | ..... | ..... | |
| 10632 | | ..... | ..... | | 11687 | | ..... | ..... | |
| 10633 | @end example | 11688 | @end example |
| 10634 | 11689 | ||
| 10635 | @node Images in @LaTeX{} export, Beamer class export, Tables in @LaTeX{} export, @LaTeX{} and PDF export | 11690 | |
| 10636 | @subsection Images in @LaTeX{} export | 11691 | @subsubheading Images in @LaTeX{} export |
| 10637 | @cindex images, inline in @LaTeX{} | 11692 | @cindex images, inline in @LaTeX{} |
| 10638 | @cindex inlining images in @LaTeX{} | 11693 | @cindex inlining images in @LaTeX{} |
| 10639 | 11694 | ||
| 10640 | Images that are linked to without a description part in the link, like | 11695 | Images that are linked to without a description part in the link, like |
| 10641 | @samp{[[file:img.jpg]]} or @samp{[[./img.jpg]]} will be inserted into the PDF | 11696 | @samp{[[file:img.jpg]]} or @samp{[[./img.jpg]]} will be inserted into the PDF |
| 10642 | output file resulting from @LaTeX{} processing. Org will use an | 11697 | output file resulting from @LaTeX{} processing. Org will use an |
| 10643 | @code{\includegraphics} macro to insert the image. If you have specified a | 11698 | @code{\includegraphics} macro to insert the image@footnote{In the case of |
| 10644 | caption and/or a label as described in @ref{Images and tables}, the figure | 11699 | TikZ (@url{http://sourceforge.net/projects/pgf/}) images, it will become an |
| 10645 | will be wrapped into a @code{figure} environment and thus become a floating | 11700 | @code{\input} macro wrapped within a @code{tikzpicture} environment.}. |
| 10646 | element. You can use an @code{#+ATTR_LaTeX:} line to specify various other | 11701 | |
| 10647 | options. You can ask org to export an image as a float without specifying | 11702 | You can specify specify image width or height with, respectively, |
| 10648 | a label or a caption by using the keyword @code{float} in this line. Various | 11703 | @code{:width} and @code{:height} attributes. It is also possible to add any |
| 10649 | optional arguments to the @code{\includegraphics} macro can also be specified | 11704 | other option with the @code{:options} attribute, as shown in the following |
| 10650 | in this fashion. To modify the placement option of the floating environment, | 11705 | example: |
| 10651 | add something like @samp{placement=[h!]} to the attributes. It is to be noted | ||
| 10652 | this option can be used with tables as well@footnote{One can also take | ||
| 10653 | advantage of this option to pass other, unrelated options into the figure or | ||
| 10654 | table environment. For an example see the section ``Exporting org files'' in | ||
| 10655 | @url{http://orgmode.org/worg/org-hacks.html}}. | ||
| 10656 | |||
| 10657 | If you would like to let text flow around the image, add the word @samp{wrap} | ||
| 10658 | to the @code{#+ATTR_LaTeX:} line, which will make the figure occupy the left | ||
| 10659 | half of the page. To fine-tune, the @code{placement} field will be the set | ||
| 10660 | of additional arguments needed by the @code{wrapfigure} environment. Note | ||
| 10661 | that if you change the size of the image, you need to use compatible settings | ||
| 10662 | for @code{\includegraphics} and @code{wrapfigure}. | ||
| 10663 | 11706 | ||
| 10664 | @cindex #+CAPTION | ||
| 10665 | @cindex #+LABEL | ||
| 10666 | @cindex #+ATTR_LaTeX | ||
| 10667 | @example | 11707 | @example |
| 10668 | #+CAPTION: The black-body emission of the disk around HR 4049 | 11708 | #+ATTR_LATEX: :width 5cm :options angle=90 |
| 10669 | #+LABEL: fig:SED-HR4049 | ||
| 10670 | #+ATTR_LaTeX: width=5cm,angle=90 | ||
| 10671 | [[./img/sed-hr4049.pdf]] | 11709 | [[./img/sed-hr4049.pdf]] |
| 10672 | |||
| 10673 | #+ATTR_LaTeX: width=0.38\textwidth wrap placement=@{r@}@{0.4\textwidth@} | ||
| 10674 | [[./img/hst.png]] | ||
| 10675 | @end example | 11710 | @end example |
| 10676 | 11711 | ||
| 10677 | If you wish to include an image which spans multiple columns in a page, you | 11712 | If you need a specific command for the caption, use @code{:caption} |
| 10678 | can use the keyword @code{multicolumn} in the @code{#+ATTR_LaTeX} line. This | 11713 | attribute. It will override standard @code{#+CAPTION} value, if any. |
| 10679 | will export the image wrapped in a @code{figure*} environment. | ||
| 10680 | |||
| 10681 | If you need references to a label created in this way, write | ||
| 10682 | @samp{\ref@{fig:SED-HR4049@}} just like in @LaTeX{}. | ||
| 10683 | |||
| 10684 | @node Beamer class export, , Images in @LaTeX{} export, @LaTeX{} and PDF export | ||
| 10685 | @subsection Beamer class export | ||
| 10686 | |||
| 10687 | The @LaTeX{} class @file{beamer} allows production of high quality presentations | ||
| 10688 | using @LaTeX{} and pdf processing. Org mode has special support for turning an | ||
| 10689 | Org mode file or tree into a @file{beamer} presentation. | ||
| 10690 | |||
| 10691 | When the @LaTeX{} class for the current buffer (as set with @code{#+LaTeX_CLASS: | ||
| 10692 | beamer}) or subtree (set with a @code{LaTeX_CLASS} property) is | ||
| 10693 | @code{beamer}, a special export mode will turn the file or tree into a beamer | ||
| 10694 | presentation. Any tree with not-too-deep level nesting should in principle be | ||
| 10695 | exportable as a beamer presentation. By default, the top-level entries (or | ||
| 10696 | the first level below the selected subtree heading) will be turned into | ||
| 10697 | frames, and the outline structure below this level will become itemize lists. | ||
| 10698 | You can also configure the variable @code{org-beamer-frame-level} to a | ||
| 10699 | different level---then the hierarchy above frames will produce the sectioning | ||
| 10700 | structure of the presentation. | ||
| 10701 | 11714 | ||
| 10702 | A template for useful in-buffer settings or properties can be inserted into | 11715 | @example |
| 10703 | the buffer with @kbd{M-x org-insert-beamer-options-template}. Among other | 11716 | #+ATTR_LATEX: :caption \bicaption@{HeadingA@}@{HeadingB@} |
| 10704 | things, this will install a column view format which is very handy for | 11717 | [[./img/sed-hr4049.pdf]] |
| 10705 | editing special properties used by beamer. | 11718 | @end example |
| 10706 | |||
| 10707 | You can influence the structure of the presentation using the following | ||
| 10708 | properties: | ||
| 10709 | 11719 | ||
| 10710 | @table @code | 11720 | If you have specified a caption as described in @ref{Images and tables}, the |
| 10711 | @item BEAMER_env | 11721 | picture will be wrapped into a @code{figure} environment and thus become |
| 10712 | The environment that should be used to format this entry. Valid environments | 11722 | a floating element. You can also ask Org to export an image as a float |
| 10713 | are defined in the constant @code{org-beamer-environments-default}, and you | 11723 | without specifying caption by setting the @code{:float} attribute. You may |
| 10714 | can define more in @code{org-beamer-environments-extra}. If this property is | 11724 | also set it to: |
| 10715 | set, the entry will also get a @code{:B_environment:} tag to make this | 11725 | @itemize @minus |
| 10716 | visible. This tag has no semantic meaning, it is only a visual aid. | 11726 | @item |
| 10717 | @item BEAMER_envargs | 11727 | @code{t}: if you want to use the standard @samp{figure} environment. It is |
| 10718 | The beamer-special arguments that should be used for the environment, like | 11728 | used by default if you provide a caption to the image. |
| 10719 | @code{[t]} or @code{[<+->]} of @code{<2-3>}. If the @code{BEAMER_col} | 11729 | @item |
| 10720 | property is also set, something like @code{C[t]} can be added here as well to | 11730 | @code{multicolumn}: if you wish to include an image which spans multiple |
| 10721 | set an options argument for the implied @code{columns} environment. | 11731 | columns in a page. This will export the image wrapped in a @code{figure*} |
| 10722 | @code{c[t]} or @code{c<2->} will set an options for the implied @code{column} | ||
| 10723 | environment. | 11732 | environment. |
| 10724 | @item BEAMER_col | 11733 | @item |
| 10725 | The width of a column that should start with this entry. If this property is | 11734 | @code{wrap}: if you would like to let text flow around the image. It will |
| 10726 | set, the entry will also get a @code{:BMCOL:} property to make this visible. | 11735 | make the figure occupy the left half of the page. |
| 10727 | Also this tag is only a visual aid. When this is a plain number, it will be | 11736 | @item |
| 10728 | interpreted as a fraction of @code{\textwidth}. Otherwise it will be assumed | 11737 | @code{nil}: if you need to avoid any floating environment, even when |
| 10729 | that you have specified the units, like @samp{3cm}. The first such property | 11738 | a caption is provided. |
| 10730 | in a frame will start a @code{columns} environment to surround the columns. | 11739 | @end itemize |
| 10731 | This environment is closed when an entry has a @code{BEAMER_col} property | 11740 | @noindent |
| 10732 | with value 0 or 1, or automatically at the end of the frame. | 11741 | To modify the placement option of any floating environment, set the |
| 10733 | @item BEAMER_extra | 11742 | @code{placement} attribute. |
| 10734 | Additional commands that should be inserted after the environment has been | ||
| 10735 | opened. For example, when creating a frame, this can be used to specify | ||
| 10736 | transitions. | ||
| 10737 | @end table | ||
| 10738 | |||
| 10739 | Frames will automatically receive a @code{fragile} option if they contain | ||
| 10740 | source code that uses the verbatim environment. Special @file{beamer} | ||
| 10741 | specific code can be inserted using @code{#+BEAMER:} and | ||
| 10742 | @code{#+BEGIN_BEAMER...#+END_BEAMER} constructs, similar to other export | ||
| 10743 | backends, but with the difference that @code{#+LaTeX:} stuff will be included | ||
| 10744 | in the presentation as well. | ||
| 10745 | |||
| 10746 | Outline nodes with @code{BEAMER_env} property value @samp{note} or | ||
| 10747 | @samp{noteNH} will be formatted as beamer notes, i,e, they will be wrapped | ||
| 10748 | into @code{\note@{...@}}. The former will include the heading as part of the | ||
| 10749 | note text, the latter will ignore the heading of that node. To simplify note | ||
| 10750 | generation, it is actually enough to mark the note with a @emph{tag} (either | ||
| 10751 | @code{:B_note:} or @code{:B_noteNH:}) instead of creating the | ||
| 10752 | @code{BEAMER_env} property. | ||
| 10753 | |||
| 10754 | You can turn on a special minor mode @code{org-beamer-mode} for editing | ||
| 10755 | support with | ||
| 10756 | 11743 | ||
| 10757 | @example | 11744 | @example |
| 10758 | #+STARTUP: beamer | 11745 | #+ATTR_LATEX: :float wrap :width 0.38\textwidth :placement @{r@}@{0.4\textwidth@} |
| 11746 | [[./img/hst.png]] | ||
| 10759 | @end example | 11747 | @end example |
| 10760 | 11748 | ||
| 10761 | @table @kbd | 11749 | If the @code{:comment-include} attribute is set to a non-@code{nil} value, |
| 10762 | @orgcmd{C-c C-b,org-beamer-select-environment} | 11750 | the @LaTeX{} @code{\includegraphics} macro will be commented out. |
| 10763 | In @code{org-beamer-mode}, this key offers fast selection of a beamer | ||
| 10764 | environment or the @code{BEAMER_col} property. | ||
| 10765 | @end table | ||
| 10766 | |||
| 10767 | Column view provides a great way to set the environment of a node and other | ||
| 10768 | important parameters. Make sure you are using a COLUMN format that is geared | ||
| 10769 | toward this special purpose. The command @kbd{M-x | ||
| 10770 | org-insert-beamer-options-template} defines such a format. | ||
| 10771 | |||
| 10772 | Here is a simple example Org document that is intended for beamer export. | ||
| 10773 | |||
| 10774 | @smallexample | ||
| 10775 | #+LaTeX_CLASS: beamer | ||
| 10776 | #+TITLE: Example Presentation | ||
| 10777 | #+AUTHOR: Carsten Dominik | ||
| 10778 | #+LaTeX_CLASS_OPTIONS: [presentation] | ||
| 10779 | #+BEAMER_FRAME_LEVEL: 2 | ||
| 10780 | #+BEAMER_HEADER_EXTRA: \usetheme@{Madrid@}\usecolortheme@{default@} | ||
| 10781 | #+COLUMNS: %35ITEM %10BEAMER_env(Env) %10BEAMER_envargs(Args) %4BEAMER_col(Col) %8BEAMER_extra(Ex) | ||
| 10782 | |||
| 10783 | * This is the first structural section | ||
| 10784 | |||
| 10785 | ** Frame 1 \\ with a subtitle | ||
| 10786 | *** Thanks to Eric Fraga :BMCOL:B_block: | ||
| 10787 | :PROPERTIES: | ||
| 10788 | :BEAMER_env: block | ||
| 10789 | :BEAMER_envargs: C[t] | ||
| 10790 | :BEAMER_col: 0.5 | ||
| 10791 | :END: | ||
| 10792 | for the first viable beamer setup in Org | ||
| 10793 | *** Thanks to everyone else :BMCOL:B_block: | ||
| 10794 | :PROPERTIES: | ||
| 10795 | :BEAMER_col: 0.5 | ||
| 10796 | :BEAMER_env: block | ||
| 10797 | :BEAMER_envargs: <2-> | ||
| 10798 | :END: | ||
| 10799 | for contributing to the discussion | ||
| 10800 | **** This will be formatted as a beamer note :B_note: | ||
| 10801 | ** Frame 2 \\ where we will not use columns | ||
| 10802 | *** Request :B_block: | ||
| 10803 | Please test this stuff! | ||
| 10804 | :PROPERTIES: | ||
| 10805 | :BEAMER_env: block | ||
| 10806 | :END: | ||
| 10807 | @end smallexample | ||
| 10808 | |||
| 10809 | For more information, see the documentation on Worg. | ||
| 10810 | 11751 | ||
| 10811 | @node DocBook export, OpenDocument Text export, @LaTeX{} and PDF export, Exporting | 11752 | @subsubheading Plain lists in @LaTeX{} export |
| 10812 | @section DocBook export | 11753 | @cindex plain lists, in @LaTeX{} export |
| 10813 | @cindex DocBook export | ||
| 10814 | @cindex PDF export | ||
| 10815 | @cindex Cui, Baoqiu | ||
| 10816 | 11754 | ||
| 10817 | Org contains a DocBook exporter written by Baoqiu Cui. Once an Org file is | 11755 | Plain lists accept two optional attributes: @code{:environment} and |
| 10818 | exported to DocBook format, it can be further processed to produce other | 11756 | @code{:options}. The first one allows the use of a non-standard |
| 10819 | formats, including PDF, HTML, man pages, etc., using many available DocBook | 11757 | environment (e.g., @samp{inparaenum}). The second one specifies |
| 10820 | tools and stylesheets. | 11758 | optional arguments for that environment (square brackets may be |
| 11759 | omitted). | ||
| 10821 | 11760 | ||
| 10822 | Currently DocBook exporter only supports DocBook V5.0. | 11761 | @example |
| 11762 | #+ATTR_LATEX: :environment compactitem :options $\circ$ | ||
| 11763 | - you need ``paralist'' package to reproduce this example. | ||
| 11764 | @end example | ||
| 10823 | 11765 | ||
| 10824 | @menu | 11766 | @subsubheading Source blocks in @LaTeX{} export |
| 10825 | * DocBook export commands:: How to invoke DocBook export | 11767 | @cindex source blocks, in @LaTeX{} export |
| 10826 | * Quoting DocBook code:: Incorporating DocBook code in Org files | ||
| 10827 | * Recursive sections:: Recursive sections in DocBook | ||
| 10828 | * Tables in DocBook export:: Tables are exported as HTML tables | ||
| 10829 | * Images in DocBook export:: How to insert figures into DocBook output | ||
| 10830 | * Special characters:: How to handle special characters | ||
| 10831 | @end menu | ||
| 10832 | 11768 | ||
| 10833 | @node DocBook export commands, Quoting DocBook code, DocBook export, DocBook export | 11769 | In addition to syntax defined in @ref{Literal examples}, names and captions |
| 10834 | @subsection DocBook export commands | 11770 | (@pxref{Images and tables}), source blocks also accept a @code{:float} |
| 11771 | attribute. You may set it to: | ||
| 11772 | @itemize @minus | ||
| 11773 | @item | ||
| 11774 | @code{t}: if you want to make the source block a float. It is the default | ||
| 11775 | value when a caption is provided. | ||
| 11776 | @item | ||
| 11777 | @code{mulicolumn}: if you wish to include a source block which spans multiple | ||
| 11778 | colums in a page. | ||
| 11779 | @item | ||
| 11780 | @code{nil}: if you need to avoid any floating evironment, even when a caption | ||
| 11781 | is provided. It is useful for source code that may not fit in a single page. | ||
| 11782 | @end itemize | ||
| 10835 | 11783 | ||
| 10836 | @cindex region, active | 11784 | @example |
| 10837 | @cindex active region | 11785 | #+ATTR_LATEX: :float nil |
| 10838 | @cindex transient-mark-mode | 11786 | #+BEGIN_SRC emacs-lisp |
| 10839 | @table @kbd | 11787 | Code that may not fit in a single page. |
| 10840 | @orgcmd{C-c C-e D,org-export-as-docbook} | 11788 | #+END_SRC |
| 10841 | @cindex property EXPORT_FILE_NAME | 11789 | @end example |
| 10842 | Export as a DocBook file. For an Org file, @file{myfile.org}, the DocBook XML | ||
| 10843 | file will be @file{myfile.xml}. The file will be overwritten without | ||
| 10844 | warning. If there is an active region@footnote{This requires | ||
| 10845 | @code{transient-mark-mode} to be turned on}, only the region will be | ||
| 10846 | exported. If the selected region is a single tree@footnote{To select the | ||
| 10847 | current subtree, use @kbd{C-c @@}.}, the tree head will become the document | ||
| 10848 | title. If the tree head entry has, or inherits, an @code{EXPORT_FILE_NAME} | ||
| 10849 | property, that name will be used for the export. | ||
| 10850 | @orgcmd{C-c C-e V,org-export-as-docbook-pdf-and-open} | ||
| 10851 | Export as a DocBook file, process to PDF, then open the resulting PDF file. | ||
| 10852 | |||
| 10853 | @vindex org-export-docbook-xslt-proc-command | ||
| 10854 | @vindex org-export-docbook-xsl-fo-proc-command | ||
| 10855 | Note that, in order to produce PDF output based on an exported DocBook file, | ||
| 10856 | you need to have XSLT processor and XSL-FO processor software installed on your | ||
| 10857 | system. Check variables @code{org-export-docbook-xslt-proc-command} and | ||
| 10858 | @code{org-export-docbook-xsl-fo-proc-command}. | ||
| 10859 | |||
| 10860 | @vindex org-export-docbook-xslt-stylesheet | ||
| 10861 | The stylesheet argument @code{%s} in variable | ||
| 10862 | @code{org-export-docbook-xslt-proc-command} is replaced by the value of | ||
| 10863 | variable @code{org-export-docbook-xslt-stylesheet}, which needs to be set by | ||
| 10864 | the user. You can also overrule this global setting on a per-file basis by | ||
| 10865 | adding an in-buffer setting @code{#+XSLT:} to the Org file. | ||
| 10866 | |||
| 10867 | @orgkey{C-c C-e v D} | ||
| 10868 | Export only the visible part of the document. | ||
| 10869 | @end table | ||
| 10870 | 11790 | ||
| 10871 | @node Quoting DocBook code, Recursive sections, DocBook export commands, DocBook export | 11791 | @subsubheading Special blocks in @LaTeX{} export |
| 10872 | @subsection Quoting DocBook code | 11792 | @cindex special blocks, in @LaTeX{} export |
| 10873 | 11793 | ||
| 10874 | You can quote DocBook code in Org files and copy it verbatim into exported | 11794 | In @LaTeX{} back-end, special blocks become environments of the same name. |
| 10875 | DocBook file with the following constructs: | 11795 | Value of @code{:options} attribute will be appended as-is to that |
| 11796 | environment's opening string. For example: | ||
| 10876 | 11797 | ||
| 10877 | @cindex #+DOCBOOK | ||
| 10878 | @cindex #+BEGIN_DOCBOOK | ||
| 10879 | @example | 11798 | @example |
| 10880 | #+DOCBOOK: Literal DocBook code for export | 11799 | #+ATTR_LATEX: :options [Proof of important theorem] |
| 11800 | #+BEGIN_PROOF | ||
| 11801 | ... | ||
| 11802 | Therefore, any even number greater than 2 is the sum of two primes. | ||
| 11803 | #+END_PROOF | ||
| 10881 | @end example | 11804 | @end example |
| 10882 | 11805 | ||
| 10883 | @noindent or | 11806 | @noindent |
| 10884 | @cindex #+BEGIN_DOCBOOK | 11807 | becomes |
| 10885 | 11808 | ||
| 10886 | @example | 11809 | @example |
| 10887 | #+BEGIN_DOCBOOK | 11810 | \begin@{proof@}[Proof of important theorem] |
| 10888 | All lines between these markers are exported by DocBook exporter | 11811 | ... |
| 10889 | literally. | 11812 | Therefore, any even number greater than 2 is the sum of two primes. |
| 10890 | #+END_DOCBOOK | 11813 | \end@{proof@} |
| 10891 | @end example | 11814 | @end example |
| 10892 | 11815 | ||
| 10893 | For example, you can use the following lines to include a DocBook warning | 11816 | If you need to insert a specific caption command, use @code{:caption} |
| 10894 | admonition. As to what this warning says, you should pay attention to the | 11817 | attribute. It will override standard @code{#+CAPTION} value, if any. For |
| 10895 | document context when quoting DocBook code in Org files. You may make | 11818 | example: |
| 10896 | exported DocBook XML files invalid by not quoting DocBook code correctly. | ||
| 10897 | 11819 | ||
| 10898 | @example | 11820 | @example |
| 10899 | #+BEGIN_DOCBOOK | 11821 | #+ATTR_LATEX: :caption \MyCaption@{HeadingA@} |
| 10900 | <warning> | 11822 | #+BEGIN_PROOF |
| 10901 | <para>You should know what you are doing when quoting DocBook XML code | 11823 | ... |
| 10902 | in your Org file. Invalid DocBook XML may be generated by | 11824 | #+END_PROOF |
| 10903 | DocBook exporter if you are not careful!</para> | ||
| 10904 | </warning> | ||
| 10905 | #+END_DOCBOOK | ||
| 10906 | @end example | 11825 | @end example |
| 10907 | 11826 | ||
| 10908 | @node Recursive sections, Tables in DocBook export, Quoting DocBook code, DocBook export | 11827 | @subsubheading Horizontal rules |
| 10909 | @subsection Recursive sections | 11828 | @cindex horizontal rules, in @LaTeX{} export |
| 10910 | @cindex DocBook recursive sections | ||
| 10911 | |||
| 10912 | DocBook exporter exports Org files as articles using the @code{article} | ||
| 10913 | element in DocBook. Recursive sections, i.e., @code{section} elements, are | ||
| 10914 | used in exported articles. Top level headlines in Org files are exported as | ||
| 10915 | top level sections, and lower level headlines are exported as nested | ||
| 10916 | sections. The entire structure of Org files will be exported completely, no | ||
| 10917 | matter how many nested levels of headlines there are. | ||
| 10918 | |||
| 10919 | Using recursive sections makes it easy to port and reuse exported DocBook | ||
| 10920 | code in other DocBook document types like @code{book} or @code{set}. | ||
| 10921 | 11829 | ||
| 10922 | @node Tables in DocBook export, Images in DocBook export, Recursive sections, DocBook export | 11830 | Width and thickness of a given horizontal rule can be controlled with, |
| 10923 | @subsection Tables in DocBook export | 11831 | respectively, @code{:width} and @code{:thickness} attributes: |
| 10924 | @cindex tables, in DocBook export | ||
| 10925 | 11832 | ||
| 10926 | Tables in Org files are exported as HTML tables, which have been supported since | ||
| 10927 | DocBook V4.3. | ||
| 10928 | |||
| 10929 | If a table does not have a caption, an informal table is generated using the | ||
| 10930 | @code{informaltable} element; otherwise, a formal table will be generated | ||
| 10931 | using the @code{table} element. | ||
| 10932 | |||
| 10933 | @node Images in DocBook export, Special characters, Tables in DocBook export, DocBook export | ||
| 10934 | @subsection Images in DocBook export | ||
| 10935 | @cindex images, inline in DocBook | ||
| 10936 | @cindex inlining images in DocBook | ||
| 10937 | |||
| 10938 | Images that are linked to without a description part in the link, like | ||
| 10939 | @samp{[[file:img.jpg]]} or @samp{[[./img.jpg]]}, will be exported to DocBook | ||
| 10940 | using @code{mediaobject} elements. Each @code{mediaobject} element contains | ||
| 10941 | an @code{imageobject} that wraps an @code{imagedata} element. If you have | ||
| 10942 | specified a caption for an image as described in @ref{Images and tables}, a | ||
| 10943 | @code{caption} element will be added in @code{mediaobject}. If a label is | ||
| 10944 | also specified, it will be exported as an @code{xml:id} attribute of the | ||
| 10945 | @code{mediaobject} element. | ||
| 10946 | |||
| 10947 | @vindex org-export-docbook-default-image-attributes | ||
| 10948 | Image attributes supported by the @code{imagedata} element, like @code{align} | ||
| 10949 | or @code{width}, can be specified in two ways: you can either customize | ||
| 10950 | variable @code{org-export-docbook-default-image-attributes} or use the | ||
| 10951 | @code{#+ATTR_DOCBOOK:} line. Attributes specified in variable | ||
| 10952 | @code{org-export-docbook-default-image-attributes} are applied to all inline | ||
| 10953 | images in the Org file to be exported (unless they are overridden by image | ||
| 10954 | attributes specified in @code{#+ATTR_DOCBOOK:} lines). | ||
| 10955 | |||
| 10956 | The @code{#+ATTR_DOCBOOK:} line can be used to specify additional image | ||
| 10957 | attributes or override default image attributes for individual images. If | ||
| 10958 | the same attribute appears in both the @code{#+ATTR_DOCBOOK:} line and | ||
| 10959 | variable @code{org-export-docbook-default-image-attributes}, the former | ||
| 10960 | takes precedence. Here is an example about how image attributes can be | ||
| 10961 | set: | ||
| 10962 | |||
| 10963 | @cindex #+CAPTION | ||
| 10964 | @cindex #+LABEL | ||
| 10965 | @cindex #+ATTR_DOCBOOK | ||
| 10966 | @example | 11833 | @example |
| 10967 | #+CAPTION: The logo of Org mode | 11834 | #+ATTR_LATEX: :width .6\textwidth :thickness 0.8pt |
| 10968 | #+LABEL: unicorn-svg | 11835 | ----- |
| 10969 | #+ATTR_DOCBOOK: scalefit="1" width="100%" depth="100%" | ||
| 10970 | [[./img/org-mode-unicorn.svg]] | ||
| 10971 | @end example | 11836 | @end example |
| 10972 | 11837 | ||
| 10973 | @vindex org-export-docbook-inline-image-extensions | 11838 | @node Markdown export, OpenDocument Text export, @LaTeX{} and PDF export, Exporting |
| 10974 | By default, DocBook exporter recognizes the following image file types: | 11839 | @section Markdown export |
| 10975 | @file{jpeg}, @file{jpg}, @file{png}, @file{gif}, and @file{svg}. You can | 11840 | @cindex Markdown export |
| 10976 | customize variable @code{org-export-docbook-inline-image-extensions} to add | ||
| 10977 | more types to this list as long as DocBook supports them. | ||
| 10978 | 11841 | ||
| 10979 | @node Special characters, , Images in DocBook export, DocBook export | 11842 | @code{md} export back-end generates Markdown syntax@footnote{Vanilla flavour, |
| 10980 | @subsection Special characters in DocBook export | 11843 | as defined at @url{http://daringfireball.net/projects/markdown/}.} for an Org |
| 10981 | @cindex Special characters in DocBook export | 11844 | mode buffer. |
| 10982 | 11845 | ||
| 10983 | @vindex org-export-docbook-doctype | 11846 | It is built over HTML back-end: any construct not supported by Markdown |
| 10984 | @vindex org-entities | 11847 | syntax (e.g., tables) will be controlled and translated by @code{html} |
| 10985 | Special characters that are written in @TeX{}-like syntax, such as @code{\alpha}, | 11848 | back-end (@pxref{HTML export}). |
| 10986 | @code{\Gamma}, and @code{\Zeta}, are supported by DocBook exporter. These | ||
| 10987 | characters are rewritten to XML entities, like @code{α}, | ||
| 10988 | @code{Γ}, and @code{Ζ}, based on the list saved in variable | ||
| 10989 | @code{org-entities}. As long as the generated DocBook file includes the | ||
| 10990 | corresponding entities, these special characters are recognized. | ||
| 10991 | 11849 | ||
| 10992 | You can customize variable @code{org-export-docbook-doctype} to include the | 11850 | @subheading Markdown export commands |
| 10993 | entities you need. For example, you can set variable | ||
| 10994 | @code{org-export-docbook-doctype} to the following value to recognize all | ||
| 10995 | special characters included in XHTML entities: | ||
| 10996 | 11851 | ||
| 10997 | @example | 11852 | @table @kbd |
| 10998 | "<!DOCTYPE article [ | 11853 | @orgcmd{C-c C-e m m,org-md-export-to-markdown} |
| 10999 | <!ENTITY % xhtml1-symbol PUBLIC | 11854 | Export as a text file written in Markdown syntax. For an Org file, |
| 11000 | \"-//W3C//ENTITIES Symbol for HTML//EN//XML\" | 11855 | @file{myfile.org}, the resulting file will be @file{myfile.md}. The file |
| 11001 | \"http://www.w3.org/2003/entities/2007/xhtml1-symbol.ent\" | 11856 | will be overwritten without warning. |
| 11002 | > | 11857 | @orgcmd{C-c C-e m M,org-md-export-as-markdown} |
| 11003 | %xhtml1-symbol; | 11858 | Export to a temporary buffer. Do not create a file. |
| 11004 | ]> | 11859 | @item C-c C-e m o |
| 11005 | " | 11860 | Export as a text file with Markdown syntax, then open it. |
| 11006 | @end example | 11861 | @end table |
| 11862 | |||
| 11863 | @subheading Header and sectioning structure | ||
| 11864 | |||
| 11865 | @vindex org-md-headline-style | ||
| 11866 | Markdown export can generate both @code{atx} and @code{setext} types for | ||
| 11867 | headlines, according to @code{org-md-headline-style}. The former introduces | ||
| 11868 | a hard limit of two levels, whereas the latter pushes it to six. Headlines | ||
| 11869 | below that limit are exported as lists. You can also set a soft limit before | ||
| 11870 | that one (@pxref{Export settings}). | ||
| 11007 | 11871 | ||
| 11008 | @c begin opendocument | 11872 | @c begin opendocument |
| 11009 | 11873 | ||
| 11010 | @node OpenDocument Text export, TaskJuggler export, DocBook export, Exporting | 11874 | @node OpenDocument Text export, iCalendar export, Markdown export, Exporting |
| 11011 | @section OpenDocument Text export | 11875 | @section OpenDocument Text export |
| 11012 | @cindex K, Jambunathan | ||
| 11013 | @cindex ODT | 11876 | @cindex ODT |
| 11014 | @cindex OpenDocument | 11877 | @cindex OpenDocument |
| 11015 | @cindex export, OpenDocument | 11878 | @cindex export, OpenDocument |
| 11016 | @cindex LibreOffice | 11879 | @cindex LibreOffice |
| 11017 | @cindex org-odt.el | ||
| 11018 | @cindex org-modules | ||
| 11019 | 11880 | ||
| 11020 | Org Mode@footnote{Versions 7.8 or later} supports export to OpenDocument Text | 11881 | Org mode@footnote{Versions 7.8 or later} supports export to OpenDocument Text |
| 11021 | (ODT) format using the @file{org-odt.el} module. Documents created | 11882 | (ODT) format. Documents created by this exporter use the |
| 11022 | by this exporter use the @cite{OpenDocument-v1.2 | 11883 | @cite{OpenDocument-v1.2 |
| 11023 | specification}@footnote{@url{http://docs.oasis-open.org/office/v1.2/OpenDocument-v1.2.html, | 11884 | specification}@footnote{@url{http://docs.oasis-open.org/office/v1.2/OpenDocument-v1.2.html, |
| 11024 | Open Document Format for Office Applications (OpenDocument) Version 1.2}} and | 11885 | Open Document Format for Office Applications (OpenDocument) Version 1.2}} and |
| 11025 | are compatible with LibreOffice 3.4. | 11886 | are compatible with LibreOffice 3.4. |
| @@ -11054,14 +11915,14 @@ output. Check the availability of this program before proceeding further. | |||
| 11054 | @cindex active region | 11915 | @cindex active region |
| 11055 | @cindex transient-mark-mode | 11916 | @cindex transient-mark-mode |
| 11056 | @table @kbd | 11917 | @table @kbd |
| 11057 | @orgcmd{C-c C-e o,org-export-as-odt} | 11918 | @orgcmd{C-c C-e o o,org-odt-export-to-odt} |
| 11058 | @cindex property EXPORT_FILE_NAME | 11919 | @cindex property EXPORT_FILE_NAME |
| 11059 | 11920 | ||
| 11060 | Export as OpenDocument Text file. | 11921 | Export as OpenDocument Text file. |
| 11061 | 11922 | ||
| 11062 | @vindex org-export-odt-preferred-output-format | 11923 | @vindex org-odt-preferred-output-format |
| 11063 | If @code{org-export-odt-preferred-output-format} is specified, automatically | 11924 | If @code{org-odt-preferred-output-format} is specified, automatically convert |
| 11064 | convert the exported file to that format. @xref{x-export-to-other-formats, , | 11925 | the exported file to that format. @xref{x-export-to-other-formats, , |
| 11065 | Automatically exporting to other formats}. | 11926 | Automatically exporting to other formats}. |
| 11066 | 11927 | ||
| 11067 | For an Org file @file{myfile.org}, the ODT file will be | 11928 | For an Org file @file{myfile.org}, the ODT file will be |
| @@ -11073,13 +11934,13 @@ tree head will become the document title. If the tree head entry has, or | |||
| 11073 | inherits, an @code{EXPORT_FILE_NAME} property, that name will be used for the | 11934 | inherits, an @code{EXPORT_FILE_NAME} property, that name will be used for the |
| 11074 | export. | 11935 | export. |
| 11075 | 11936 | ||
| 11076 | @orgcmd{C-c C-e O,org-export-as-odt-and-open} | 11937 | @kbd{C-c C-e o O} |
| 11077 | Export as an OpenDocument Text file and open the resulting file. | 11938 | Export as an OpenDocument Text file and open the resulting file. |
| 11078 | 11939 | ||
| 11079 | @vindex org-export-odt-preferred-output-format | 11940 | @vindex org-odt-preferred-output-format |
| 11080 | If @code{org-export-odt-preferred-output-format} is specified, open the | 11941 | If @code{org-odt-preferred-output-format} is specified, open the converted |
| 11081 | converted file instead. @xref{x-export-to-other-formats, , Automatically | 11942 | file instead. @xref{x-export-to-other-formats, , Automatically exporting to |
| 11082 | exporting to other formats}. | 11943 | other formats}. |
| 11083 | @end table | 11944 | @end table |
| 11084 | 11945 | ||
| 11085 | @node Extending ODT export, Applying custom styles, ODT export commands, OpenDocument Text export | 11946 | @node Extending ODT export, Applying custom styles, ODT export commands, OpenDocument Text export |
| @@ -11095,7 +11956,7 @@ one format (say @samp{csv}) to another format (say @samp{ods} or @samp{xls}). | |||
| 11095 | If you have a working installation of LibreOffice, a document converter is | 11956 | If you have a working installation of LibreOffice, a document converter is |
| 11096 | pre-configured for you and you can use it right away. If you would like to | 11957 | pre-configured for you and you can use it right away. If you would like to |
| 11097 | use @file{unoconv} as your preferred converter, customize the variable | 11958 | use @file{unoconv} as your preferred converter, customize the variable |
| 11098 | @code{org-export-odt-convert-process} to point to @code{unoconv}. You can | 11959 | @code{org-odt-convert-process} to point to @code{unoconv}. You can |
| 11099 | also use your own favorite converter or tweak the default settings of the | 11960 | also use your own favorite converter or tweak the default settings of the |
| 11100 | @file{LibreOffice} and @samp{unoconv} converters. @xref{Configuring a | 11961 | @file{LibreOffice} and @samp{unoconv} converters. @xref{Configuring a |
| 11101 | document converter}. | 11962 | document converter}. |
| @@ -11103,12 +11964,12 @@ document converter}. | |||
| 11103 | @subsubsection Automatically exporting to other formats | 11964 | @subsubsection Automatically exporting to other formats |
| 11104 | @anchor{x-export-to-other-formats} | 11965 | @anchor{x-export-to-other-formats} |
| 11105 | 11966 | ||
| 11106 | @vindex org-export-odt-preferred-output-format | 11967 | @vindex org-odt-preferred-output-format |
| 11107 | Very often, you will find yourself exporting to ODT format, only to | 11968 | Very often, you will find yourself exporting to ODT format, only to |
| 11108 | immediately save the exported document to other formats like @samp{doc}, | 11969 | immediately save the exported document to other formats like @samp{doc}, |
| 11109 | @samp{docx}, @samp{rtf}, @samp{pdf} etc. In such cases, you can specify your | 11970 | @samp{docx}, @samp{rtf}, @samp{pdf} etc. In such cases, you can specify your |
| 11110 | preferred output format by customizing the variable | 11971 | preferred output format by customizing the variable |
| 11111 | @code{org-export-odt-preferred-output-format}. This way, the export commands | 11972 | @code{org-odt-preferred-output-format}. This way, the export commands |
| 11112 | (@pxref{x-export-to-odt,,Exporting to ODT}) can be extended to export to a | 11973 | (@pxref{x-export-to-odt,,Exporting to ODT}) can be extended to export to a |
| 11113 | format that is of immediate interest to you. | 11974 | format that is of immediate interest to you. |
| 11114 | 11975 | ||
| @@ -11121,10 +11982,10 @@ ODT format. LibreOffice converter, mentioned above, is one such | |||
| 11121 | converter. Once a converter is configured, you can interact with it using | 11982 | converter. Once a converter is configured, you can interact with it using |
| 11122 | the following command. | 11983 | the following command. |
| 11123 | 11984 | ||
| 11124 | @vindex org-export-odt-convert | 11985 | @vindex org-odt-convert |
| 11125 | @table @kbd | 11986 | @table @kbd |
| 11126 | 11987 | ||
| 11127 | @item M-x org-export-odt-convert | 11988 | @item M-x org-odt-convert RET |
| 11128 | Convert an existing document from one format to another. With a prefix | 11989 | Convert an existing document from one format to another. With a prefix |
| 11129 | argument, also open the newly produced file. | 11990 | argument, also open the newly produced file. |
| 11130 | @end table | 11991 | @end table |
| @@ -11161,8 +12022,8 @@ OpenDocument Text (@file{.odt}) or OpenDocument Template (@file{.ott}) file. | |||
| 11161 | 12022 | ||
| 11162 | @item | 12023 | @item |
| 11163 | @cindex #+ODT_STYLES_FILE | 12024 | @cindex #+ODT_STYLES_FILE |
| 11164 | @vindex org-export-odt-styles-file | 12025 | @vindex org-odt-styles-file |
| 11165 | Customize the variable @code{org-export-odt-styles-file} and point it to the | 12026 | Customize the variable @code{org-odt-styles-file} and point it to the |
| 11166 | newly created file. For additional configuration options | 12027 | newly created file. For additional configuration options |
| 11167 | @pxref{x-overriding-factory-styles,,Overriding factory styles}. | 12028 | @pxref{x-overriding-factory-styles,,Overriding factory styles}. |
| 11168 | 12029 | ||
| @@ -11192,7 +12053,7 @@ the factory settings. | |||
| 11192 | 12053 | ||
| 11193 | @node Links in ODT export, Tables in ODT export, Applying custom styles, OpenDocument Text export | 12054 | @node Links in ODT export, Tables in ODT export, Applying custom styles, OpenDocument Text export |
| 11194 | @subsection Links in ODT export | 12055 | @subsection Links in ODT export |
| 11195 | @cindex tables, in DocBook export | 12056 | @cindex links, in ODT export |
| 11196 | 12057 | ||
| 11197 | ODT exporter creates native cross-references for internal links. It creates | 12058 | ODT exporter creates native cross-references for internal links. It creates |
| 11198 | Internet-style links for all other links. | 12059 | Internet-style links for all other links. |
| @@ -11206,7 +12067,7 @@ with a cross-reference and sequence number of the labeled entity. | |||
| 11206 | 12067 | ||
| 11207 | @node Tables in ODT export, Images in ODT export, Links in ODT export, OpenDocument Text export | 12068 | @node Tables in ODT export, Images in ODT export, Links in ODT export, OpenDocument Text export |
| 11208 | @subsection Tables in ODT export | 12069 | @subsection Tables in ODT export |
| 11209 | @cindex tables, in DocBook export | 12070 | @cindex tables, in ODT export |
| 11210 | 12071 | ||
| 11211 | Export of native Org mode tables (@pxref{Tables}) and simple @file{table.el} | 12072 | Export of native Org mode tables (@pxref{Tables}) and simple @file{table.el} |
| 11212 | tables is supported. However, export of complex @file{table.el} tables---tables | 12073 | tables is supported. However, export of complex @file{table.el} tables---tables |
| @@ -11285,17 +12146,17 @@ You can control the size and scale of the embedded images using the | |||
| 11285 | @code{#+ATTR_ODT} attribute. | 12146 | @code{#+ATTR_ODT} attribute. |
| 11286 | 12147 | ||
| 11287 | @cindex identify, ImageMagick | 12148 | @cindex identify, ImageMagick |
| 11288 | @vindex org-export-odt-pixels-per-inch | 12149 | @vindex org-odt-pixels-per-inch |
| 11289 | The exporter specifies the desired size of the image in the final document in | 12150 | The exporter specifies the desired size of the image in the final document in |
| 11290 | units of centimeters. In order to scale the embedded images, the exporter | 12151 | units of centimeters. In order to scale the embedded images, the exporter |
| 11291 | queries for pixel dimensions of the images using one of a) ImageMagick's | 12152 | queries for pixel dimensions of the images using one of a) ImageMagick's |
| 11292 | @file{identify} program or b) Emacs `create-image' and `image-size' | 12153 | @file{identify} program or b) Emacs `create-image' and `image-size' |
| 11293 | APIs.@footnote{Use of @file{ImageMagick} is only desirable. However, if you | 12154 | APIs@footnote{Use of @file{ImageMagick} is only desirable. However, if you |
| 11294 | routinely produce documents that have large images or you export your Org | 12155 | routinely produce documents that have large images or you export your Org |
| 11295 | files that has images using a Emacs batch script, then the use of | 12156 | files that has images using a Emacs batch script, then the use of |
| 11296 | @file{ImageMagick} is mandatory.} The pixel dimensions are subsequently | 12157 | @file{ImageMagick} is mandatory.}. The pixel dimensions are subsequently |
| 11297 | converted in to units of centimeters using | 12158 | converted in to units of centimeters using |
| 11298 | @code{org-export-odt-pixels-per-inch}. The default value of this variable is | 12159 | @code{org-odt-pixels-per-inch}. The default value of this variable is |
| 11299 | set to @code{display-pixels-per-inch}. You can tweak this variable to | 12160 | set to @code{display-pixels-per-inch}. You can tweak this variable to |
| 11300 | achieve the best results. | 12161 | achieve the best results. |
| 11301 | 12162 | ||
| @@ -11404,27 +12265,34 @@ You can use the following commands to quickly verify the reliability of | |||
| 11404 | the @LaTeX{}-to-MathML converter. | 12265 | the @LaTeX{}-to-MathML converter. |
| 11405 | 12266 | ||
| 11406 | @table @kbd | 12267 | @table @kbd |
| 11407 | 12268 | @item M-x org-odt-export-as-odf RET | |
| 11408 | @item M-x org-export-as-odf | ||
| 11409 | Convert a @LaTeX{} math snippet to an OpenDocument formula (@file{.odf}) file. | 12269 | Convert a @LaTeX{} math snippet to an OpenDocument formula (@file{.odf}) file. |
| 11410 | 12270 | ||
| 11411 | @item M-x org-export-as-odf-and-open | 12271 | @item M-x org-odt-export-as-odf-and-open RET |
| 11412 | Convert a @LaTeX{} math snippet to an OpenDocument formula (@file{.odf}) file | 12272 | Convert a @LaTeX{} math snippet to an OpenDocument formula (@file{.odf}) file |
| 11413 | and open the formula file with the system-registered application. | 12273 | and open the formula file with the system-registered application. |
| 11414 | @end table | 12274 | @end table |
| 11415 | 12275 | ||
| 11416 | @cindex dvipng | 12276 | @cindex dvipng |
| 12277 | @cindex imagemagick | ||
| 11417 | @item PNG images | 12278 | @item PNG images |
| 11418 | 12279 | ||
| 11419 | This option is activated on a per-file basis with | 12280 | This option is activated on a per-file basis with |
| 11420 | 12281 | ||
| 11421 | @example | 12282 | @example |
| 11422 | #+OPTIONS: LaTeX:dvipng | 12283 | #+OPTIONS: tex:dvipng |
| 12284 | @end example | ||
| 12285 | |||
| 12286 | or: | ||
| 12287 | |||
| 12288 | @example | ||
| 12289 | #+OPTIONS: tex:imagemagick | ||
| 11423 | @end example | 12290 | @end example |
| 11424 | 12291 | ||
| 11425 | With this option, @LaTeX{} fragments are processed into PNG images and the | 12292 | With this option, @LaTeX{} fragments are processed into PNG images and the |
| 11426 | resulting images are embedded in the exported document. This method requires | 12293 | resulting images are embedded in the exported document. This method requires |
| 11427 | that the @file{dvipng} program be available on your system. | 12294 | that the @file{dvipng} program or @file{imagemagick} suite be available on |
| 12295 | your system. | ||
| 11428 | @end enumerate | 12296 | @end enumerate |
| 11429 | 12297 | ||
| 11430 | @node Working with MathML or OpenDocument formula files, , Working with @LaTeX{} math snippets, Math formatting in ODT export | 12298 | @node Working with MathML or OpenDocument formula files, , Working with @LaTeX{} math snippets, Math formatting in ODT export |
| @@ -11471,15 +12339,15 @@ It could be rendered as shown below in the exported document. | |||
| 11471 | Figure 2: Bell curve | 12339 | Figure 2: Bell curve |
| 11472 | @end example | 12340 | @end example |
| 11473 | 12341 | ||
| 11474 | @vindex org-export-odt-category-strings | 12342 | @vindex org-odt-category-map-alist |
| 11475 | You can modify the category component of the caption by customizing the | 12343 | You can modify the category component of the caption by customizing the |
| 11476 | variable @code{org-export-odt-category-strings}. For example, to tag all | 12344 | option @code{org-odt-category-map-alist}. For example, to tag all embedded |
| 11477 | embedded images with the string @samp{Illustration} (instead of the default | 12345 | images with the string @samp{Illustration} (instead of the default |
| 11478 | @samp{Figure}) use the following setting. | 12346 | @samp{Figure}) use the following setting: |
| 11479 | 12347 | ||
| 11480 | @lisp | 12348 | @lisp |
| 11481 | (setq org-export-odt-category-strings | 12349 | (setq org-odt-category-map-alist |
| 11482 | '(("en" "Table" "Illustration" "Equation" "Equation"))) | 12350 | (("__Figure__" "Illustration" "value" "Figure" org-odt--enumerable-image-p))) |
| 11483 | @end lisp | 12351 | @end lisp |
| 11484 | 12352 | ||
| 11485 | With this, previous image will be captioned as below in the exported | 12353 | With this, previous image will be captioned as below in the exported |
| @@ -11500,14 +12368,14 @@ fontification to be turned on.} The auto-generated styles have @samp{OrgSrc} | |||
| 11500 | as prefix and inherit their color from the faces used by Emacs | 12368 | as prefix and inherit their color from the faces used by Emacs |
| 11501 | @code{font-lock} library for the source language. | 12369 | @code{font-lock} library for the source language. |
| 11502 | 12370 | ||
| 11503 | @vindex org-export-odt-fontify-srcblocks | 12371 | @vindex org-odt-fontify-srcblocks |
| 11504 | If you prefer to use your own custom styles for fontification, you can do so | 12372 | If you prefer to use your own custom styles for fontification, you can do |
| 11505 | by customizing the variable | 12373 | so by customizing the option |
| 11506 | @code{org-export-odt-create-custom-styles-for-srcblocks}. | 12374 | @code{org-odt-create-custom-styles-for-srcblocks}. |
| 11507 | 12375 | ||
| 11508 | @vindex org-export-odt-create-custom-styles-for-srcblocks | 12376 | @vindex org-odt-create-custom-styles-for-srcblocks |
| 11509 | You can turn off fontification of literal examples by customizing the | 12377 | You can turn off fontification of literal examples by customizing the |
| 11510 | variable @code{org-export-odt-fontify-srcblocks}. | 12378 | option @code{org-odt-fontify-srcblocks}. |
| 11511 | 12379 | ||
| 11512 | @node Advanced topics in ODT export, , Literal examples in ODT export, OpenDocument Text export | 12380 | @node Advanced topics in ODT export, , Literal examples in ODT export, OpenDocument Text export |
| 11513 | @subsection Advanced topics in ODT export | 12381 | @subsection Advanced topics in ODT export |
| @@ -11538,27 +12406,27 @@ like to tweak the default converter settings, proceed as below. | |||
| 11538 | @enumerate | 12406 | @enumerate |
| 11539 | @item Register the converter | 12407 | @item Register the converter |
| 11540 | 12408 | ||
| 11541 | @vindex org-export-odt-convert-processes | 12409 | @vindex org-odt-convert-processes |
| 11542 | Name your converter and add it to the list of known converters by customizing | 12410 | Name your converter and add it to the list of known converters by |
| 11543 | the variable @code{org-export-odt-convert-processes}. Also specify how the | 12411 | customizing the option @code{org-odt-convert-processes}. Also specify how |
| 11544 | converter can be invoked via command-line to effect the conversion. | 12412 | the converter can be invoked via command-line to effect the conversion. |
| 11545 | 12413 | ||
| 11546 | @item Configure its capabilities | 12414 | @item Configure its capabilities |
| 11547 | 12415 | ||
| 11548 | @vindex org-export-odt-convert-capabilities | 12416 | @vindex org-odt-convert-capabilities |
| 11549 | @anchor{x-odt-converter-capabilities} | 12417 | @anchor{x-odt-converter-capabilities} Specify the set of formats the |
| 11550 | Specify the set of formats the converter can handle by customizing the | 12418 | converter can handle by customizing the variable |
| 11551 | variable @code{org-export-odt-convert-capabilities}. Use the default value | 12419 | @code{org-odt-convert-capabilities}. Use the default value for this |
| 11552 | for this variable as a guide for configuring your converter. As suggested by | 12420 | variable as a guide for configuring your converter. As suggested by the |
| 11553 | the default setting, you can specify the full set of formats supported by the | 12421 | default setting, you can specify the full set of formats supported by the |
| 11554 | converter and not limit yourself to specifying formats that are related to | 12422 | converter and not limit yourself to specifying formats that are related to |
| 11555 | just the OpenDocument Text format. | 12423 | just the OpenDocument Text format. |
| 11556 | 12424 | ||
| 11557 | @item Choose the converter | 12425 | @item Choose the converter |
| 11558 | 12426 | ||
| 11559 | @vindex org-export-odt-convert-process | 12427 | @vindex org-odt-convert-process |
| 11560 | Select the newly added converter as the preferred one by customizing the | 12428 | Select the newly added converter as the preferred one by customizing the |
| 11561 | variable @code{org-export-odt-convert-process}. | 12429 | option @code{org-odt-convert-process}. |
| 11562 | @end enumerate | 12430 | @end enumerate |
| 11563 | 12431 | ||
| 11564 | @node Working with OpenDocument style files, Creating one-off styles, Configuring a document converter, Advanced topics in ODT export | 12432 | @node Working with OpenDocument style files, Creating one-off styles, Configuring a document converter, Advanced topics in ODT export |
| @@ -11626,9 +12494,9 @@ customize these variables to override the factory styles used by the | |||
| 11626 | exporter. | 12494 | exporter. |
| 11627 | 12495 | ||
| 11628 | @itemize | 12496 | @itemize |
| 11629 | @anchor{x-org-export-odt-styles-file} | 12497 | @anchor{x-org-odt-styles-file} |
| 11630 | @item | 12498 | @item |
| 11631 | @code{org-export-odt-styles-file} | 12499 | @code{org-odt-styles-file} |
| 11632 | 12500 | ||
| 11633 | Use this variable to specify the @file{styles.xml} that will be used in the | 12501 | Use this variable to specify the @file{styles.xml} that will be used in the |
| 11634 | final output. You can specify one of the following values: | 12502 | final output. You can specify one of the following values: |
| @@ -11657,9 +12525,9 @@ like header and footer images. | |||
| 11657 | Use the default @file{styles.xml} | 12525 | Use the default @file{styles.xml} |
| 11658 | @end enumerate | 12526 | @end enumerate |
| 11659 | 12527 | ||
| 11660 | @anchor{x-org-export-odt-content-template-file} | 12528 | @anchor{x-org-odt-content-template-file} |
| 11661 | @item | 12529 | @item |
| 11662 | @code{org-export-odt-content-template-file} | 12530 | @code{org-odt-content-template-file} |
| 11663 | 12531 | ||
| 11664 | Use this variable to specify the blank @file{content.xml} that will be used | 12532 | Use this variable to specify the blank @file{content.xml} that will be used |
| 11665 | in the final output. | 12533 | in the final output. |
| @@ -11709,7 +12577,7 @@ custom @samp{PageBreak} style as shown below. | |||
| 11709 | 12577 | ||
| 11710 | @example | 12578 | @example |
| 11711 | <style:style style:name="PageBreak" style:family="paragraph" | 12579 | <style:style style:name="PageBreak" style:family="paragraph" |
| 11712 | style:parent-style-name="Text_20_body"> | 12580 | style:parent-style-name="Text_20_body"> |
| 11713 | <style:paragraph-properties fo:break-before="page"/> | 12581 | <style:paragraph-properties fo:break-before="page"/> |
| 11714 | </style:style> | 12582 | </style:style> |
| 11715 | @end example | 12583 | @end example |
| @@ -11746,22 +12614,21 @@ OpenDocument-v1.2 | |||
| 11746 | specification.@footnote{@url{http://docs.oasis-open.org/office/v1.2/OpenDocument-v1.2.html, | 12614 | specification.@footnote{@url{http://docs.oasis-open.org/office/v1.2/OpenDocument-v1.2.html, |
| 11747 | OpenDocument-v1.2 Specification}} | 12615 | OpenDocument-v1.2 Specification}} |
| 11748 | 12616 | ||
| 11749 | |||
| 11750 | |||
| 11751 | @subsubheading Custom table styles: an illustration | 12617 | @subsubheading Custom table styles: an illustration |
| 11752 | 12618 | ||
| 11753 | To have a quick preview of this feature, install the below setting and export | 12619 | @vindex org-odt-table-styles |
| 11754 | the table that follows. | 12620 | To have a quick preview of this feature, install the below setting and |
| 12621 | export the table that follows: | ||
| 11755 | 12622 | ||
| 11756 | @lisp | 12623 | @lisp |
| 11757 | (setq org-export-odt-table-styles | 12624 | (setq org-odt-table-styles |
| 11758 | (append org-export-odt-table-styles | 12625 | (append org-odt-table-styles |
| 11759 | '(("TableWithHeaderRowAndColumn" "Custom" | 12626 | '(("TableWithHeaderRowAndColumn" "Custom" |
| 11760 | ((use-first-row-styles . t) | 12627 | ((use-first-row-styles . t) |
| 11761 | (use-first-column-styles . t))) | 12628 | (use-first-column-styles . t))) |
| 11762 | ("TableWithFirstRowandLastRow" "Custom" | 12629 | ("TableWithFirstRowandLastRow" "Custom" |
| 11763 | ((use-first-row-styles . t) | 12630 | ((use-first-row-styles . t) |
| 11764 | (use-last-row-styles . t)))))) | 12631 | (use-last-row-styles . t)))))) |
| 11765 | @end lisp | 12632 | @end lisp |
| 11766 | 12633 | ||
| 11767 | @example | 12634 | @example |
| @@ -11774,9 +12641,9 @@ the table that follows. | |||
| 11774 | In the above example, you used a template named @samp{Custom} and installed | 12641 | In the above example, you used a template named @samp{Custom} and installed |
| 11775 | two table styles with the names @samp{TableWithHeaderRowAndColumn} and | 12642 | two table styles with the names @samp{TableWithHeaderRowAndColumn} and |
| 11776 | @samp{TableWithFirstRowandLastRow}. (@strong{Important:} The OpenDocument | 12643 | @samp{TableWithFirstRowandLastRow}. (@strong{Important:} The OpenDocument |
| 11777 | styles needed for producing the above template have been pre-defined for you. | 12644 | styles needed for producing the above template have been pre-defined for |
| 11778 | These styles are available under the section marked @samp{Custom Table | 12645 | you. These styles are available under the section marked @samp{Custom |
| 11779 | Template} in @file{OrgOdtContentTemplate.xml} | 12646 | Table Template} in @file{OrgOdtContentTemplate.xml} |
| 11780 | (@pxref{x-orgodtcontenttemplate-xml,,Factory styles}). If you need | 12647 | (@pxref{x-orgodtcontenttemplate-xml,,Factory styles}). If you need |
| 11781 | additional templates you have to define these styles yourselves. | 12648 | additional templates you have to define these styles yourselves. |
| 11782 | 12649 | ||
| @@ -11860,9 +12727,9 @@ Define a table style@footnote{See the attributes @code{table:template-name}, | |||
| 11860 | @code{table:use-banding-column-styles} of the @code{<table:table>} element in | 12727 | @code{table:use-banding-column-styles} of the @code{<table:table>} element in |
| 11861 | the OpenDocument-v1.2 specification} | 12728 | the OpenDocument-v1.2 specification} |
| 11862 | 12729 | ||
| 11863 | @vindex org-export-odt-table-styles | 12730 | @vindex org-odt-table-styles |
| 11864 | To define a table style, create an entry for the style in the variable | 12731 | To define a table style, create an entry for the style in the variable |
| 11865 | @code{org-export-odt-table-styles} and specify the following: | 12732 | @code{org-odt-table-styles} and specify the following: |
| 11866 | 12733 | ||
| 11867 | @itemize @minus | 12734 | @itemize @minus |
| 11868 | @item the name of the table template created in step (1) | 12735 | @item the name of the table template created in step (1) |
| @@ -11875,14 +12742,14 @@ based on the same template @samp{Custom}. The styles achieve their intended | |||
| 11875 | effect by selectively activating the individual cell styles in that template. | 12742 | effect by selectively activating the individual cell styles in that template. |
| 11876 | 12743 | ||
| 11877 | @lisp | 12744 | @lisp |
| 11878 | (setq org-export-odt-table-styles | 12745 | (setq org-odt-table-styles |
| 11879 | (append org-export-odt-table-styles | 12746 | (append org-odt-table-styles |
| 11880 | '(("TableWithHeaderRowAndColumn" "Custom" | 12747 | '(("TableWithHeaderRowAndColumn" "Custom" |
| 11881 | ((use-first-row-styles . t) | 12748 | ((use-first-row-styles . t) |
| 11882 | (use-first-column-styles . t))) | 12749 | (use-first-column-styles . t))) |
| 11883 | ("TableWithFirstRowandLastRow" "Custom" | 12750 | ("TableWithFirstRowandLastRow" "Custom" |
| 11884 | ((use-first-row-styles . t) | 12751 | ((use-first-row-styles . t) |
| 11885 | (use-last-row-styles . t)))))) | 12752 | (use-last-row-styles . t)))))) |
| 11886 | @end lisp | 12753 | @end lisp |
| 11887 | 12754 | ||
| 11888 | @item | 12755 | @item |
| @@ -11913,173 +12780,15 @@ nothing but @samp{zip} archives}: @inforef{File Archives,,emacs}. For | |||
| 11913 | general help with validation (and schema-sensitive editing) of XML files: | 12780 | general help with validation (and schema-sensitive editing) of XML files: |
| 11914 | @inforef{Introduction,,nxml-mode}. | 12781 | @inforef{Introduction,,nxml-mode}. |
| 11915 | 12782 | ||
| 11916 | @vindex org-export-odt-schema-dir | 12783 | @vindex org-odt-schema-dir |
| 11917 | If you have ready access to OpenDocument @file{.rnc} files and the needed | 12784 | If you have ready access to OpenDocument @file{.rnc} files and the needed |
| 11918 | schema-locating rules in a single folder, you can customize the variable | 12785 | schema-locating rules in a single folder, you can customize the variable |
| 11919 | @code{org-export-odt-schema-dir} to point to that directory. The | 12786 | @code{org-odt-schema-dir} to point to that directory. The ODT exporter |
| 11920 | ODT exporter will take care of updating the | 12787 | will take care of updating the @code{rng-schema-locating-files} for you. |
| 11921 | @code{rng-schema-locating-files} for you. | ||
| 11922 | 12788 | ||
| 11923 | @c end opendocument | 12789 | @c end opendocument |
| 11924 | 12790 | ||
| 11925 | @node TaskJuggler export, Freemind export, OpenDocument Text export, Exporting | 12791 | @node iCalendar export, Other built-in back-ends, OpenDocument Text export, Exporting |
| 11926 | @section TaskJuggler export | ||
| 11927 | @cindex TaskJuggler export | ||
| 11928 | @cindex Project management | ||
| 11929 | |||
| 11930 | @uref{http://www.taskjuggler.org/, TaskJuggler} is a project management tool. | ||
| 11931 | It provides an optimizing scheduler that computes your project time lines and | ||
| 11932 | resource assignments based on the project outline and the constraints that | ||
| 11933 | you have provided. | ||
| 11934 | |||
| 11935 | The TaskJuggler exporter is a bit different from other exporters, such as the | ||
| 11936 | @code{HTML} and @LaTeX{} exporters for example, in that it does not export all the | ||
| 11937 | nodes of a document or strictly follow the order of the nodes in the | ||
| 11938 | document. | ||
| 11939 | |||
| 11940 | Instead the TaskJuggler exporter looks for a tree that defines the tasks and | ||
| 11941 | a optionally tree that defines the resources for this project. It then | ||
| 11942 | creates a TaskJuggler file based on these trees and the attributes defined in | ||
| 11943 | all the nodes. | ||
| 11944 | |||
| 11945 | @subsection TaskJuggler export commands | ||
| 11946 | |||
| 11947 | @table @kbd | ||
| 11948 | @orgcmd{C-c C-e j,org-export-as-taskjuggler} | ||
| 11949 | Export as a TaskJuggler file. | ||
| 11950 | |||
| 11951 | @orgcmd{C-c C-e J,org-export-as-taskjuggler-and-open} | ||
| 11952 | Export as a TaskJuggler file and then open the file with TaskJugglerUI. | ||
| 11953 | @end table | ||
| 11954 | |||
| 11955 | @subsection Tasks | ||
| 11956 | |||
| 11957 | @vindex org-export-taskjuggler-project-tag | ||
| 11958 | Create your tasks as you usually do with Org mode. Assign efforts to each | ||
| 11959 | task using properties (it is easiest to do this in the column view). You | ||
| 11960 | should end up with something similar to the example by Peter Jones in | ||
| 11961 | @url{http://www.contextualdevelopment.com/static/artifacts/articles/2008/project-planning/project-planning.org}. | ||
| 11962 | Now mark the top node of your tasks with a tag named | ||
| 11963 | @code{:taskjuggler_project:} (or whatever you customized | ||
| 11964 | @code{org-export-taskjuggler-project-tag} to). You are now ready to export | ||
| 11965 | the project plan with @kbd{C-c C-e J} which will export the project plan and | ||
| 11966 | open a gantt chart in TaskJugglerUI. | ||
| 11967 | |||
| 11968 | @subsection Resources | ||
| 11969 | |||
| 11970 | @vindex org-export-taskjuggler-resource-tag | ||
| 11971 | Next you can define resources and assign those to work on specific tasks. You | ||
| 11972 | can group your resources hierarchically. Tag the top node of the resources | ||
| 11973 | with @code{:taskjuggler_resource:} (or whatever you customized | ||
| 11974 | @code{org-export-taskjuggler-resource-tag} to). You can optionally assign an | ||
| 11975 | identifier (named @samp{resource_id}) to the resources (using the standard | ||
| 11976 | Org properties commands, @pxref{Property syntax}) or you can let the exporter | ||
| 11977 | generate identifiers automatically (the exporter picks the first word of the | ||
| 11978 | headline as the identifier as long as it is unique---see the documentation of | ||
| 11979 | @code{org-taskjuggler-get-unique-id}). Using that identifier you can then | ||
| 11980 | allocate resources to tasks. This is again done with the @samp{allocate} | ||
| 11981 | property on the tasks. Do this in column view or when on the task type | ||
| 11982 | @kbd{C-c C-x p allocate @key{RET} <resource_id> @key{RET}}. | ||
| 11983 | |||
| 11984 | Once the allocations are done you can again export to TaskJuggler and check | ||
| 11985 | in the Resource Allocation Graph which person is working on what task at what | ||
| 11986 | time. | ||
| 11987 | |||
| 11988 | @subsection Export of properties | ||
| 11989 | |||
| 11990 | The exporter also takes TODO state information into consideration, i.e., if a | ||
| 11991 | task is marked as done it will have the corresponding attribute in | ||
| 11992 | TaskJuggler (@samp{complete 100}). Also it will export any property on a task | ||
| 11993 | resource or resource node which is known to TaskJuggler, such as | ||
| 11994 | @samp{limits}, @samp{vacation}, @samp{shift}, @samp{booking}, | ||
| 11995 | @samp{efficiency}, @samp{journalentry}, @samp{rate} for resources or | ||
| 11996 | @samp{account}, @samp{start}, @samp{note}, @samp{duration}, @samp{end}, | ||
| 11997 | @samp{journalentry}, @samp{milestone}, @samp{reference}, @samp{responsible}, | ||
| 11998 | @samp{scheduling}, etc.@: for tasks. | ||
| 11999 | |||
| 12000 | @subsection Dependencies | ||
| 12001 | |||
| 12002 | The exporter will handle dependencies that are defined in the tasks either | ||
| 12003 | with the @samp{ORDERED} attribute (@pxref{TODO dependencies}), with the | ||
| 12004 | @samp{BLOCKER} attribute (see @file{org-depend.el}) or alternatively with a | ||
| 12005 | @samp{depends} attribute. Both the @samp{BLOCKER} and the @samp{depends} | ||
| 12006 | attribute can be either @samp{previous-sibling} or a reference to an | ||
| 12007 | identifier (named @samp{task_id}) which is defined for another task in the | ||
| 12008 | project. @samp{BLOCKER} and the @samp{depends} attribute can define multiple | ||
| 12009 | dependencies separated by either space or comma. You can also specify | ||
| 12010 | optional attributes on the dependency by simply appending it. The following | ||
| 12011 | examples should illustrate this: | ||
| 12012 | |||
| 12013 | @example | ||
| 12014 | * Preparation | ||
| 12015 | :PROPERTIES: | ||
| 12016 | :task_id: preparation | ||
| 12017 | :ORDERED: t | ||
| 12018 | :END: | ||
| 12019 | * Training material | ||
| 12020 | :PROPERTIES: | ||
| 12021 | :task_id: training_material | ||
| 12022 | :ORDERED: t | ||
| 12023 | :END: | ||
| 12024 | ** Markup Guidelines | ||
| 12025 | :PROPERTIES: | ||
| 12026 | :Effort: 2d | ||
| 12027 | :END: | ||
| 12028 | ** Workflow Guidelines | ||
| 12029 | :PROPERTIES: | ||
| 12030 | :Effort: 2d | ||
| 12031 | :END: | ||
| 12032 | * Presentation | ||
| 12033 | :PROPERTIES: | ||
| 12034 | :Effort: 2d | ||
| 12035 | :BLOCKER: training_material @{ gapduration 1d @} preparation | ||
| 12036 | :END: | ||
| 12037 | @end example | ||
| 12038 | |||
| 12039 | @subsection Reports | ||
| 12040 | |||
| 12041 | @vindex org-export-taskjuggler-default-reports | ||
| 12042 | TaskJuggler can produce many kinds of reports (e.g., gantt chart, resource | ||
| 12043 | allocation, etc). The user defines what kind of reports should be generated | ||
| 12044 | for a project in the TaskJuggler file. The exporter will automatically insert | ||
| 12045 | some default reports in the file. These defaults are defined in | ||
| 12046 | @code{org-export-taskjuggler-default-reports}. They can be modified using | ||
| 12047 | customize along with a number of other options. For a more complete list, see | ||
| 12048 | @kbd{M-x customize-group @key{RET} org-export-taskjuggler @key{RET}}. | ||
| 12049 | |||
| 12050 | For more information and examples see the Org-taskjuggler tutorial at | ||
| 12051 | @uref{http://orgmode.org/worg/org-tutorials/org-taskjuggler.html}. | ||
| 12052 | |||
| 12053 | @node Freemind export, XOXO export, TaskJuggler export, Exporting | ||
| 12054 | @section Freemind export | ||
| 12055 | @cindex Freemind export | ||
| 12056 | @cindex mind map | ||
| 12057 | |||
| 12058 | The Freemind exporter was written by Lennart Borgman. | ||
| 12059 | |||
| 12060 | @table @kbd | ||
| 12061 | @orgcmd{C-c C-e m,org-export-as-freemind} | ||
| 12062 | Export as a Freemind mind map. For an Org file @file{myfile.org}, the Freemind | ||
| 12063 | file will be @file{myfile.mm}. | ||
| 12064 | @end table | ||
| 12065 | |||
| 12066 | @node XOXO export, iCalendar export, Freemind export, Exporting | ||
| 12067 | @section XOXO export | ||
| 12068 | @cindex XOXO export | ||
| 12069 | |||
| 12070 | Org mode contains an exporter that produces XOXO-style output. | ||
| 12071 | Currently, this exporter only handles the general outline structure and | ||
| 12072 | does not interpret any additional Org mode features. | ||
| 12073 | |||
| 12074 | @table @kbd | ||
| 12075 | @orgcmd{C-c C-e x,org-export-as-xoxo} | ||
| 12076 | Export as an XOXO file. For an Org file @file{myfile.org}, the XOXO file will be | ||
| 12077 | @file{myfile.html}. | ||
| 12078 | @orgkey{C-c C-e v x} | ||
| 12079 | Export only the visible part of the document. | ||
| 12080 | @end table | ||
| 12081 | |||
| 12082 | @node iCalendar export, , XOXO export, Exporting | ||
| 12083 | @section iCalendar export | 12792 | @section iCalendar export |
| 12084 | @cindex iCalendar export | 12793 | @cindex iCalendar export |
| 12085 | 12794 | ||
| @@ -12118,19 +12827,19 @@ In this way the UID remains unique, but a synchronization program can still | |||
| 12118 | figure out from which entry all the different instances originate. | 12827 | figure out from which entry all the different instances originate. |
| 12119 | 12828 | ||
| 12120 | @table @kbd | 12829 | @table @kbd |
| 12121 | @orgcmd{C-c C-e i,org-export-icalendar-this-file} | 12830 | @orgcmd{C-c C-e c f,org-icalendar-export-to-ics} |
| 12122 | Create iCalendar entries for the current file and store them in the same | 12831 | Create iCalendar entries for the current buffer and store them in the same |
| 12123 | directory, using a file extension @file{.ics}. | 12832 | directory, using a file extension @file{.ics}. |
| 12124 | @orgcmd{C-c C-e I, org-export-icalendar-all-agenda-files} | 12833 | @orgcmd{C-c C-e c a, org-icalendar-export-agenda-files} |
| 12125 | @vindex org-agenda-files | 12834 | @vindex org-agenda-files |
| 12126 | Like @kbd{C-c C-e i}, but do this for all files in | 12835 | Like @kbd{C-c C-e c f}, but do this for all files in |
| 12127 | @code{org-agenda-files}. For each of these files, a separate iCalendar | 12836 | @code{org-agenda-files}. For each of these files, a separate iCalendar |
| 12128 | file will be written. | 12837 | file will be written. |
| 12129 | @orgcmd{C-c C-e c,org-export-icalendar-combine-agenda-files} | 12838 | @orgcmd{C-c C-e c c,org-icalendar-combine-agenda-files} |
| 12130 | @vindex org-combined-agenda-icalendar-file | 12839 | @vindex org-icalendar-combined-agenda-file |
| 12131 | Create a single large iCalendar file from all files in | 12840 | Create a single large iCalendar file from all files in |
| 12132 | @code{org-agenda-files} and write it to the file given by | 12841 | @code{org-agenda-files} and write it to the file given by |
| 12133 | @code{org-combined-agenda-icalendar-file}. | 12842 | @code{org-icalendar-combined-agenda-file}. |
| 12134 | @end table | 12843 | @end table |
| 12135 | 12844 | ||
| 12136 | @vindex org-use-property-inheritance | 12845 | @vindex org-use-property-inheritance |
| @@ -12148,6 +12857,233 @@ and the description from the body (limited to | |||
| 12148 | How this calendar is best read and updated, depends on the application | 12857 | How this calendar is best read and updated, depends on the application |
| 12149 | you are using. The FAQ covers this issue. | 12858 | you are using. The FAQ covers this issue. |
| 12150 | 12859 | ||
| 12860 | @node Other built-in back-ends, Export in foreign buffers, iCalendar export, Exporting | ||
| 12861 | @section Other built-in back-ends | ||
| 12862 | @cindex export back-ends, built-in | ||
| 12863 | @vindex org-export-backends | ||
| 12864 | |||
| 12865 | On top of the aforemetioned back-ends, Org comes with other built-in ones: | ||
| 12866 | |||
| 12867 | @itemize | ||
| 12868 | @item @file{ox-man.el}: export to a man page. | ||
| 12869 | @item @file{ox-texinfo.el}: export to @code{Texinfo} format. | ||
| 12870 | @item @file{ox-org.el}: export to an Org document. | ||
| 12871 | @end itemize | ||
| 12872 | |||
| 12873 | To activate these export back-end, customize @code{org-export-backends} or | ||
| 12874 | load them directly with e.g., @code{(require 'ox-texinfo)}. This will add | ||
| 12875 | new keys in the export dispatcher (@pxref{The Export Dispatcher}). | ||
| 12876 | |||
| 12877 | See the comment section of these files for more information on how to use | ||
| 12878 | them. | ||
| 12879 | |||
| 12880 | @node Export in foreign buffers, Advanced configuration, Other built-in back-ends, Exporting | ||
| 12881 | @section Export in foreign buffers | ||
| 12882 | |||
| 12883 | Most built-in back-ends come with a command to convert the selected region | ||
| 12884 | into a selected format and replace this region by the exported output. Here | ||
| 12885 | is a list of such conversion commands: | ||
| 12886 | |||
| 12887 | @table @code | ||
| 12888 | @item org-html-convert-region-to-html | ||
| 12889 | Convert the selected region into HTML. | ||
| 12890 | @item org-latex-convert-region-to-latex | ||
| 12891 | Convert the selected region into @LaTeX{}. | ||
| 12892 | @item org-texinfo-convert-region-to-texinfo | ||
| 12893 | Convert the selected region into @code{Texinfo}. | ||
| 12894 | @item org-md-convert-region-to-md | ||
| 12895 | Convert the selected region into @code{MarkDown}. | ||
| 12896 | @end table | ||
| 12897 | |||
| 12898 | This is particularily useful for converting tables and lists in foreign | ||
| 12899 | buffers. E.g., in a HTML buffer, you can turn on @code{orgstruct-mode}, then | ||
| 12900 | use Org commands for editing a list, and finally select and convert the list | ||
| 12901 | with @code{M-x org-html-convert-region-to-html RET}. | ||
| 12902 | |||
| 12903 | @node Advanced configuration, , Export in foreign buffers, Exporting | ||
| 12904 | @section Advanced configuration | ||
| 12905 | |||
| 12906 | @subheading Hooks | ||
| 12907 | |||
| 12908 | @vindex org-export-before-processing-hook | ||
| 12909 | @vindex org-export-before-parsing-hook | ||
| 12910 | Two hooks are run during the first steps of the export process. The first | ||
| 12911 | one, @code{org-export-before-processing-hook} is called before expanding | ||
| 12912 | macros, Babel code and include keywords in the buffer. The second one, | ||
| 12913 | @code{org-export-before-parsing-hook}, as its name suggests, happens just | ||
| 12914 | before parsing the buffer. Their main use is for heavy duties, that is | ||
| 12915 | duties involving structural modifications of the document. For example, one | ||
| 12916 | may want to remove every headline in the buffer during export. The following | ||
| 12917 | code can achieve this: | ||
| 12918 | |||
| 12919 | @lisp | ||
| 12920 | @group | ||
| 12921 | (defun my-headline-removal (backend) | ||
| 12922 | "Remove all headlines in the current buffer. | ||
| 12923 | BACKEND is the export back-end being used, as a symbol." | ||
| 12924 | (org-map-entries | ||
| 12925 | (lambda () (delete-region (point) (progn (forward-line) (point)))))) | ||
| 12926 | |||
| 12927 | (add-hook 'org-export-before-parsing-hook 'my-headline-removal) | ||
| 12928 | @end group | ||
| 12929 | @end lisp | ||
| 12930 | |||
| 12931 | Note that functions used in these hooks require a mandatory argument, | ||
| 12932 | a symbol representing the back-end used. | ||
| 12933 | |||
| 12934 | @subheading Filters | ||
| 12935 | |||
| 12936 | @cindex Filters, exporting | ||
| 12937 | Filters are lists of functions applied on a specific part of the output from | ||
| 12938 | a given back-end. More explicitly, each time a back-end transforms an Org | ||
| 12939 | object or element into another language, all functions within a given filter | ||
| 12940 | type are called in turn on the string produced. The string returned by the | ||
| 12941 | last function will be the one used in the final output. | ||
| 12942 | |||
| 12943 | There are filters sets for each type of element or object, for plain text, | ||
| 12944 | for the parse tree, for the export options and for the final output. They | ||
| 12945 | are all named after the same scheme: @code{org-export-filter-TYPE-functions}, | ||
| 12946 | where @code{TYPE} is the type targeted by the filter. Valid types are: | ||
| 12947 | |||
| 12948 | @multitable @columnfractions .33 .33 .33 | ||
| 12949 | @item bold | ||
| 12950 | @tab babel-call | ||
| 12951 | @tab center-block | ||
| 12952 | @item clock | ||
| 12953 | @tab code | ||
| 12954 | @tab comment | ||
| 12955 | @item comment-block | ||
| 12956 | @tab diary-sexp | ||
| 12957 | @tab drawer | ||
| 12958 | @item dynamic-block | ||
| 12959 | @tab entity | ||
| 12960 | @tab example-block | ||
| 12961 | @item export-block | ||
| 12962 | @tab export-snippet | ||
| 12963 | @tab final-output | ||
| 12964 | @item fixed-width | ||
| 12965 | @tab footnote-definition | ||
| 12966 | @tab footnote-reference | ||
| 12967 | @item headline | ||
| 12968 | @tab horizontal-rule | ||
| 12969 | @tab inline-babel-call | ||
| 12970 | @item inline-src-block | ||
| 12971 | @tab inlinetask | ||
| 12972 | @tab italic | ||
| 12973 | @item item | ||
| 12974 | @tab keyword | ||
| 12975 | @tab latex-environment | ||
| 12976 | @item latex-fragment | ||
| 12977 | @tab line-break | ||
| 12978 | @tab link | ||
| 12979 | @item node-property | ||
| 12980 | @tab options | ||
| 12981 | @tab paragraph | ||
| 12982 | @item parse-tree | ||
| 12983 | @tab plain-list | ||
| 12984 | @tab plain-text | ||
| 12985 | @item planning | ||
| 12986 | @tab property-drawer | ||
| 12987 | @tab quote-block | ||
| 12988 | @item quote-section | ||
| 12989 | @tab radio-target | ||
| 12990 | @tab section | ||
| 12991 | @item special-block | ||
| 12992 | @tab src-block | ||
| 12993 | @tab statistics-cookie | ||
| 12994 | @item strike-through | ||
| 12995 | @tab subscript | ||
| 12996 | @tab superscript | ||
| 12997 | @item table | ||
| 12998 | @tab table-cell | ||
| 12999 | @tab table-row | ||
| 13000 | @item target | ||
| 13001 | @tab timestamp | ||
| 13002 | @tab underline | ||
| 13003 | @item verbatim | ||
| 13004 | @tab verse-block | ||
| 13005 | @tab | ||
| 13006 | @end multitable | ||
| 13007 | |||
| 13008 | For example, the following snippet allows me to use non-breaking spaces in | ||
| 13009 | the Org buffer and get them translated into @LaTeX{} without using the | ||
| 13010 | @code{\nbsp} macro (where @code{_} stands for the non-breaking space): | ||
| 13011 | |||
| 13012 | @lisp | ||
| 13013 | @group | ||
| 13014 | (defun my-latex-filter-nobreaks (text backend info) | ||
| 13015 | "Ensure \"Â \" are properly handled in LaTeX export." | ||
| 13016 | (when (org-export-derived-backend-p backend 'latex) | ||
| 13017 | (replace-regexp-in-string "Â " "~" text))) | ||
| 13018 | |||
| 13019 | (add-to-list 'org-export-filter-plain-text-functions | ||
| 13020 | 'my-latex-filter-nobreaks) | ||
| 13021 | @end group | ||
| 13022 | @end lisp | ||
| 13023 | |||
| 13024 | Three arguments must be provided to a filter: the code being changed, the | ||
| 13025 | back-end used, and some information about the export process. You can safely | ||
| 13026 | ignore the third argument for most purposes. Note the use of | ||
| 13027 | @code{org-export-derived-backend-p}, which ensures that the filter will only | ||
| 13028 | be applied when using @code{latex} back-end or any other back-end derived | ||
| 13029 | from it (e.g., @code{beamer}). | ||
| 13030 | |||
| 13031 | @subheading Extending an existing back-end | ||
| 13032 | |||
| 13033 | This is obviously the most powerful customization, since the changes happen | ||
| 13034 | at the parser level. Indeed, some export back-ends are built as extensions | ||
| 13035 | of other ones (e.g. Markdown back-end an extension of HTML back-end). | ||
| 13036 | |||
| 13037 | Extending a back-end means that if an element type is not transcoded by the | ||
| 13038 | new back-end, it will be handled by the original one. Hence you can extend | ||
| 13039 | specific parts of a back-end without too much work. | ||
| 13040 | |||
| 13041 | As an example, imagine we want the @code{ascii} back-end to display the | ||
| 13042 | language used in a source block, when it is available, but only when some | ||
| 13043 | attribute is non-@code{nil}, like the following: | ||
| 13044 | |||
| 13045 | @example | ||
| 13046 | #+ATTR_ASCII: :language t | ||
| 13047 | @end example | ||
| 13048 | |||
| 13049 | Because that back-end is lacking in that area, we are going to create a new | ||
| 13050 | back-end, @code{my-ascii} that will do the job. | ||
| 13051 | |||
| 13052 | @lisp | ||
| 13053 | @group | ||
| 13054 | (defun my-ascii-src-block (src-block contents info) | ||
| 13055 | "Transcode a SRC-BLOCK element from Org to ASCII. | ||
| 13056 | CONTENTS is nil. INFO is a plist used as a communication | ||
| 13057 | channel." | ||
| 13058 | (if (not (org-export-read-attribute :attr_ascii src-block :language)) | ||
| 13059 | (org-export-with-backend 'ascii src-block contents info) | ||
| 13060 | (concat | ||
| 13061 | (format ",--[ %s ]--\n%s`----" | ||
| 13062 | (org-element-property :language src-block) | ||
| 13063 | (replace-regexp-in-string | ||
| 13064 | "^" "| " | ||
| 13065 | (org-element-normalize-string | ||
| 13066 | (org-export-format-code-default src-block info))))))) | ||
| 13067 | |||
| 13068 | (org-export-define-derived-backend 'my-ascii 'ascii | ||
| 13069 | :translate-alist '((src-block . my-ascii-src-block))) | ||
| 13070 | @end group | ||
| 13071 | @end lisp | ||
| 13072 | |||
| 13073 | The @code{my-ascii-src-block} function looks at the attribute above the | ||
| 13074 | element. If it isn’t true, it gives hand to the @code{ascii} back-end. | ||
| 13075 | Otherwise, it creates a box around the code, leaving room for the language. | ||
| 13076 | A new back-end is then created. It only changes its behaviour when | ||
| 13077 | translating @code{src-block} type element. Now, all it takes to use the new | ||
| 13078 | back-end is calling the following from an Org buffer: | ||
| 13079 | |||
| 13080 | @smalllisp | ||
| 13081 | (org-export-to-buffer 'my-ascii "*Org MY-ASCII Export*") | ||
| 13082 | @end smalllisp | ||
| 13083 | |||
| 13084 | It is obviously possible to write an interactive function for this, install | ||
| 13085 | it in the export dispatcher menu, and so on. | ||
| 13086 | |||
| 12151 | @node Publishing, Working With Source Code, Exporting, Top | 13087 | @node Publishing, Working With Source Code, Exporting, Top |
| 12152 | @chapter Publishing | 13088 | @chapter Publishing |
| 12153 | @cindex publishing | 13089 | @cindex publishing |
| @@ -12227,7 +13163,7 @@ and where to put published files. | |||
| 12227 | @tab Directory containing publishing source files | 13163 | @tab Directory containing publishing source files |
| 12228 | @item @code{:publishing-directory} | 13164 | @item @code{:publishing-directory} |
| 12229 | @tab Directory where output files will be published. You can directly | 13165 | @tab Directory where output files will be published. You can directly |
| 12230 | publish to a webserver using a file name syntax appropriate for | 13166 | publish to a web server using a file name syntax appropriate for |
| 12231 | the Emacs @file{tramp} package. Or you can publish to a local directory and | 13167 | the Emacs @file{tramp} package. Or you can publish to a local directory and |
| 12232 | use external tools to upload your website (@pxref{Uploading files}). | 13168 | use external tools to upload your website (@pxref{Uploading files}). |
| 12233 | @item @code{:preparation-function} | 13169 | @item @code{:preparation-function} |
| @@ -12266,7 +13202,7 @@ extension. | |||
| 12266 | and @code{:exclude}. | 13202 | and @code{:exclude}. |
| 12267 | 13203 | ||
| 12268 | @item @code{:recursive} | 13204 | @item @code{:recursive} |
| 12269 | @tab Non-nil means, check base-directory recursively for files to publish. | 13205 | @tab non-@code{nil} means, check base-directory recursively for files to publish. |
| 12270 | @end multitable | 13206 | @end multitable |
| 12271 | 13207 | ||
| 12272 | @node Publishing action, Publishing options, Selecting files, Configuration | 13208 | @node Publishing action, Publishing options, Selecting files, Configuration |
| @@ -12276,201 +13212,164 @@ and @code{:exclude}. | |||
| 12276 | Publishing means that a file is copied to the destination directory and | 13212 | Publishing means that a file is copied to the destination directory and |
| 12277 | possibly transformed in the process. The default transformation is to export | 13213 | possibly transformed in the process. The default transformation is to export |
| 12278 | Org files as HTML files, and this is done by the function | 13214 | Org files as HTML files, and this is done by the function |
| 12279 | @code{org-publish-org-to-html} which calls the HTML exporter (@pxref{HTML | 13215 | @code{org-html-publish-to-html}, which calls the HTML exporter (@pxref{HTML |
| 12280 | export}). But you also can publish your content as PDF files using | 13216 | export}). But you also can publish your content as PDF files using |
| 12281 | @code{org-publish-org-to-pdf}, or as @code{ascii}, @code{latin1} or | 13217 | @code{org-latex-publish-to-pdf} or as @code{ascii}, @code{Texinfo}, etc., |
| 12282 | @code{utf8} encoded files using the corresponding functions. If you want to | 13218 | using the corresponding functions. |
| 12283 | publish the Org file itself, but with @i{archived}, @i{commented}, and | 13219 | |
| 12284 | @i{tag-excluded} trees removed, use @code{org-publish-org-to-org} and set the | 13220 | If you want to publish the Org file as an @code{.org} file but with the |
| 12285 | parameters @code{:plain-source} and/or @code{:htmlized-source}. This will | 13221 | @i{archived}, @i{commented} and @i{tag-excluded} trees removed, use the |
| 12286 | produce @file{file.org} and @file{file.org.html} in the publishing | 13222 | function @code{org-org-publish-to-org}. This will produce @file{file.org} |
| 12287 | directory@footnote{@file{file-source.org} and @file{file-source.org.html} if | 13223 | and put it in the publishing directory. If you want a htmlized version of |
| 12288 | source and publishing directories are equal. Note that with this kind of | 13224 | this file, set the parameter @code{:htmlized-source} to @code{t}, it will |
| 12289 | setup, you need to add @code{:exclude "-source\\.org"} to the project | 13225 | produce @file{file.org.html} in the publishing directory@footnote{If the |
| 12290 | definition in @code{org-publish-project-alist} to prevent the published | 13226 | publishing directory is the same than the source directory, @file{file.org} |
| 12291 | source files from being considered as new org files the next time the project | 13227 | will be exported as @file{file.org.org}, so probably don't want to do this.}. |
| 12292 | is published.}. Other files like images only need to be copied to the | 13228 | |
| 12293 | publishing destination; for this you may use @code{org-publish-attachment}. | 13229 | Other files like images only need to be copied to the publishing destination. |
| 12294 | For non-Org files, you always need to specify the publishing function: | 13230 | For this you can use @code{org-publish-attachment}. For non-org files, you |
| 13231 | always need to specify the publishing function: | ||
| 12295 | 13232 | ||
| 12296 | @multitable @columnfractions 0.3 0.7 | 13233 | @multitable @columnfractions 0.3 0.7 |
| 12297 | @item @code{:publishing-function} | 13234 | @item @code{:publishing-function} |
| 12298 | @tab Function executing the publication of a file. This may also be a | 13235 | @tab Function executing the publication of a file. This may also be a |
| 12299 | list of functions, which will all be called in turn. | 13236 | list of functions, which will all be called in turn. |
| 12300 | @item @code{:plain-source} | ||
| 12301 | @tab Non-nil means, publish plain source. | ||
| 12302 | @item @code{:htmlized-source} | 13237 | @item @code{:htmlized-source} |
| 12303 | @tab Non-nil means, publish htmlized source. | 13238 | @tab non-@code{nil} means, publish htmlized source. |
| 12304 | @end multitable | 13239 | @end multitable |
| 12305 | 13240 | ||
| 12306 | The function must accept three arguments: a property list containing at least | 13241 | The function must accept three arguments: a property list containing at least |
| 12307 | a @code{:publishing-directory} property, the name of the file to be | 13242 | a @code{:publishing-directory} property, the name of the file to be published |
| 12308 | published, and the path to the publishing directory of the output file. It | 13243 | and the path to the publishing directory of the output file. It should take |
| 12309 | should take the specified file, make the necessary transformation (if any) | 13244 | the specified file, make the necessary transformation (if any) and place the |
| 12310 | and place the result into the destination folder. | 13245 | result into the destination folder. |
| 12311 | 13246 | ||
| 12312 | @node Publishing options, Publishing links, Publishing action, Configuration | 13247 | @node Publishing options, Publishing links, Publishing action, Configuration |
| 12313 | @subsection Options for the HTML/@LaTeX{} exporters | 13248 | @subsection Options for the exporters |
| 12314 | @cindex options, for publishing | 13249 | @cindex options, for publishing |
| 12315 | 13250 | ||
| 12316 | The property list can be used to set many export options for the HTML | 13251 | The property list can be used to set many export options for the exporters. |
| 12317 | and @LaTeX{} exporters. In most cases, these properties correspond to user | 13252 | In most cases, these properties correspond to user variables in Org. The |
| 12318 | variables in Org. The table below lists these properties along | 13253 | first table below lists these properties along with the variable they belong |
| 12319 | with the variable they belong to. See the documentation string for the | 13254 | to. The second table list HTML specific properties. See the documentation |
| 12320 | respective variable for details. | 13255 | string of these options for details. |
| 12321 | 13256 | ||
| 12322 | @vindex org-export-html-link-up | ||
| 12323 | @vindex org-export-html-link-home | ||
| 12324 | @vindex org-export-default-language | ||
| 12325 | @vindex org-display-custom-times | 13257 | @vindex org-display-custom-times |
| 13258 | @vindex org-export-default-language | ||
| 13259 | @vindex org-export-exclude-tags | ||
| 12326 | @vindex org-export-headline-levels | 13260 | @vindex org-export-headline-levels |
| 12327 | @vindex org-export-with-section-numbers | ||
| 12328 | @vindex org-export-section-number-format | ||
| 12329 | @vindex org-export-with-toc | ||
| 12330 | @vindex org-export-preserve-breaks | 13261 | @vindex org-export-preserve-breaks |
| 13262 | @vindex org-export-publishing-directory | ||
| 13263 | @vindex org-export-select-tags | ||
| 12331 | @vindex org-export-with-archived-trees | 13264 | @vindex org-export-with-archived-trees |
| 13265 | @vindex org-export-with-author | ||
| 13266 | @vindex org-export-with-creator | ||
| 13267 | @vindex org-export-with-drawers | ||
| 13268 | @vindex org-export-with-email | ||
| 12332 | @vindex org-export-with-emphasize | 13269 | @vindex org-export-with-emphasize |
| 12333 | @vindex org-export-with-sub-superscripts | 13270 | @vindex org-export-with-fixed-width |
| 12334 | @vindex org-export-with-special-strings | ||
| 12335 | @vindex org-export-with-footnotes | 13271 | @vindex org-export-with-footnotes |
| 12336 | @vindex org-export-with-drawers | 13272 | @vindex org-export-with-latex |
| 13273 | @vindex org-export-with-planning | ||
| 13274 | @vindex org-export-with-priority | ||
| 13275 | @vindex org-export-with-section-numbers | ||
| 13276 | @vindex org-export-with-special-strings | ||
| 13277 | @vindex org-export-with-sub-superscripts | ||
| 13278 | @vindex org-export-with-tables | ||
| 12337 | @vindex org-export-with-tags | 13279 | @vindex org-export-with-tags |
| 12338 | @vindex org-export-with-todo-keywords | ||
| 12339 | @vindex org-export-with-tasks | 13280 | @vindex org-export-with-tasks |
| 12340 | @vindex org-export-with-done-tasks | ||
| 12341 | @vindex org-export-with-priority | ||
| 12342 | @vindex org-export-with-TeX-macros | ||
| 12343 | @vindex org-export-with-LaTeX-fragments | ||
| 12344 | @vindex org-export-skip-text-before-1st-heading | ||
| 12345 | @vindex org-export-with-fixed-width | ||
| 12346 | @vindex org-export-with-timestamps | 13281 | @vindex org-export-with-timestamps |
| 12347 | @vindex org-export-author-info | 13282 | @vindex org-export-with-toc |
| 12348 | @vindex org-export-email-info | 13283 | @vindex org-export-with-todo-keywords |
| 12349 | @vindex org-export-creator-info | ||
| 12350 | @vindex org-export-time-stamp-file | ||
| 12351 | @vindex org-export-with-tables | ||
| 12352 | @vindex org-export-highlight-first-table-line | ||
| 12353 | @vindex org-export-html-style-include-default | ||
| 12354 | @vindex org-export-html-style-include-scripts | ||
| 12355 | @vindex org-export-html-style | ||
| 12356 | @vindex org-export-html-style-extra | ||
| 12357 | @vindex org-export-html-link-org-files-as-html | ||
| 12358 | @vindex org-export-html-inline-images | ||
| 12359 | @vindex org-export-html-extension | ||
| 12360 | @vindex org-export-html-table-tag | ||
| 12361 | @vindex org-export-html-expand | ||
| 12362 | @vindex org-export-html-with-timestamp | ||
| 12363 | @vindex org-export-publishing-directory | ||
| 12364 | @vindex org-export-html-preamble | ||
| 12365 | @vindex org-export-html-postamble | ||
| 12366 | @vindex user-full-name | ||
| 12367 | @vindex user-mail-address | 13284 | @vindex user-mail-address |
| 12368 | @vindex org-export-select-tags | ||
| 12369 | @vindex org-export-exclude-tags | ||
| 12370 | 13285 | ||
| 12371 | @multitable @columnfractions 0.32 0.68 | 13286 | @multitable @columnfractions 0.32 0.68 |
| 12372 | @item @code{:link-up} @tab @code{org-export-html-link-up} | 13287 | @item @code{:archived-trees} @tab @code{org-export-with-archived-trees} |
| 12373 | @item @code{:link-home} @tab @code{org-export-html-link-home} | 13288 | @item @code{:exclude-tags} @tab @code{org-export-exclude-tags} |
| 12374 | @item @code{:language} @tab @code{org-export-default-language} | ||
| 12375 | @item @code{:customtime} @tab @code{org-display-custom-times} | ||
| 12376 | @item @code{:headline-levels} @tab @code{org-export-headline-levels} | 13289 | @item @code{:headline-levels} @tab @code{org-export-headline-levels} |
| 12377 | @item @code{:section-numbers} @tab @code{org-export-with-section-numbers} | 13290 | @item @code{:language} @tab @code{org-export-default-language} |
| 12378 | @item @code{:section-number-format} @tab @code{org-export-section-number-format} | ||
| 12379 | @item @code{:table-of-contents} @tab @code{org-export-with-toc} | ||
| 12380 | @item @code{:preserve-breaks} @tab @code{org-export-preserve-breaks} | 13291 | @item @code{:preserve-breaks} @tab @code{org-export-preserve-breaks} |
| 12381 | @item @code{:archived-trees} @tab @code{org-export-with-archived-trees} | ||
| 12382 | @item @code{:emphasize} @tab @code{org-export-with-emphasize} | ||
| 12383 | @item @code{:sub-superscript} @tab @code{org-export-with-sub-superscripts} | ||
| 12384 | @item @code{:special-strings} @tab @code{org-export-with-special-strings} | ||
| 12385 | @item @code{:footnotes} @tab @code{org-export-with-footnotes} | ||
| 12386 | @item @code{:drawers} @tab @code{org-export-with-drawers} | ||
| 12387 | @item @code{:tags} @tab @code{org-export-with-tags} | ||
| 12388 | @item @code{:todo-keywords} @tab @code{org-export-with-todo-keywords} | ||
| 12389 | @item @code{:tasks} @tab @code{org-export-with-tasks} | ||
| 12390 | @item @code{:priority} @tab @code{org-export-with-priority} | ||
| 12391 | @item @code{:TeX-macros} @tab @code{org-export-with-TeX-macros} | ||
| 12392 | @item @code{:LaTeX-fragments} @tab @code{org-export-with-LaTeX-fragments} | ||
| 12393 | @item @code{:latex-listings} @tab @code{org-export-latex-listings} | ||
| 12394 | @item @code{:skip-before-1st-heading} @tab @code{org-export-skip-text-before-1st-heading} | ||
| 12395 | @item @code{:fixed-width} @tab @code{org-export-with-fixed-width} | ||
| 12396 | @item @code{:timestamps} @tab @code{org-export-with-timestamps} | ||
| 12397 | @item @code{:author} @tab @code{user-full-name} | ||
| 12398 | @item @code{:email} @tab @code{user-mail-address} : @code{addr;addr;..} | ||
| 12399 | @item @code{:author-info} @tab @code{org-export-author-info} | ||
| 12400 | @item @code{:email-info} @tab @code{org-export-email-info} | ||
| 12401 | @item @code{:creator-info} @tab @code{org-export-creator-info} | ||
| 12402 | @item @code{:tables} @tab @code{org-export-with-tables} | ||
| 12403 | @item @code{:table-auto-headline} @tab @code{org-export-highlight-first-table-line} | ||
| 12404 | @item @code{:style-include-default} @tab @code{org-export-html-style-include-default} | ||
| 12405 | @item @code{:style-include-scripts} @tab @code{org-export-html-style-include-scripts} | ||
| 12406 | @item @code{:style} @tab @code{org-export-html-style} | ||
| 12407 | @item @code{:style-extra} @tab @code{org-export-html-style-extra} | ||
| 12408 | @item @code{:convert-org-links} @tab @code{org-export-html-link-org-files-as-html} | ||
| 12409 | @item @code{:inline-images} @tab @code{org-export-html-inline-images} | ||
| 12410 | @item @code{:html-extension} @tab @code{org-export-html-extension} | ||
| 12411 | @item @code{:html-preamble} @tab @code{org-export-html-preamble} | ||
| 12412 | @item @code{:html-postamble} @tab @code{org-export-html-postamble} | ||
| 12413 | @item @code{:xml-declaration} @tab @code{org-export-html-xml-declaration} | ||
| 12414 | @item @code{:html-table-tag} @tab @code{org-export-html-table-tag} | ||
| 12415 | @item @code{:expand-quoted-html} @tab @code{org-export-html-expand} | ||
| 12416 | @item @code{:timestamp} @tab @code{org-export-html-with-timestamp} | ||
| 12417 | @item @code{:publishing-directory} @tab @code{org-export-publishing-directory} | 13292 | @item @code{:publishing-directory} @tab @code{org-export-publishing-directory} |
| 13293 | @item @code{:section-numbers} @tab @code{org-export-with-section-numbers} | ||
| 12418 | @item @code{:select-tags} @tab @code{org-export-select-tags} | 13294 | @item @code{:select-tags} @tab @code{org-export-select-tags} |
| 12419 | @item @code{:exclude-tags} @tab @code{org-export-exclude-tags} | 13295 | @item @code{:with-author} @tab @code{org-export-with-author} |
| 12420 | @item @code{:latex-image-options} @tab @code{org-export-latex-image-default-option} | 13296 | @item @code{:with-creator} @tab @code{org-export-with-creator} |
| 13297 | @item @code{:with-drawers} @tab @code{org-export-with-drawers} | ||
| 13298 | @item @code{:with-email} @tab @code{org-export-with-email} | ||
| 13299 | @item @code{:with-emphasize} @tab @code{org-export-with-emphasize} | ||
| 13300 | @item @code{:with-fixed-width} @tab @code{org-export-with-fixed-width} | ||
| 13301 | @item @code{:with-footnotes} @tab @code{org-export-with-footnotes} | ||
| 13302 | @item @code{:with-latex} @tab @code{org-export-with-latex} | ||
| 13303 | @item @code{:with-planning} @tab @code{org-export-with-planning} | ||
| 13304 | @item @code{:with-priority} @tab @code{org-export-with-priority} | ||
| 13305 | @item @code{:with-special-strings} @tab @code{org-export-with-special-strings} | ||
| 13306 | @item @code{:with-sub-superscript} @tab @code{org-export-with-sub-superscripts} | ||
| 13307 | @item @code{:with-tables} @tab @code{org-export-with-tables} | ||
| 13308 | @item @code{:with-tags} @tab @code{org-export-with-tags} | ||
| 13309 | @item @code{:with-tasks} @tab @code{org-export-with-tasks} | ||
| 13310 | @item @code{:with-timestamps} @tab @code{org-export-with-timestamps} | ||
| 13311 | @item @code{:with-toc} @tab @code{org-export-with-toc} | ||
| 13312 | @item @code{:with-todo-keywords} @tab @code{org-export-with-todo-keywords} | ||
| 12421 | @end multitable | 13313 | @end multitable |
| 12422 | 13314 | ||
| 12423 | Most of the @code{org-export-with-*} variables have the same effect in | 13315 | @vindex org-html-doctype |
| 12424 | both HTML and @LaTeX{} exporters, except for @code{:TeX-macros} and | 13316 | @vindex org-html-xml-declaration |
| 12425 | @code{:LaTeX-fragments} options, respectively @code{nil} and @code{t} in the | 13317 | @vindex org-html-link-up |
| 12426 | @LaTeX{} export. See @code{org-export-plist-vars} to check this list of | 13318 | @vindex org-html-link-home |
| 12427 | options. | 13319 | @vindex org-html-link-org-files-as-html |
| 12428 | 13320 | @vindex org-html-head | |
| 13321 | @vindex org-html-head-extra | ||
| 13322 | @vindex org-html-inline-images | ||
| 13323 | @vindex org-html-extension | ||
| 13324 | @vindex org-html-preamble | ||
| 13325 | @vindex org-html-postamble | ||
| 13326 | @vindex org-html-table-default-attributes | ||
| 13327 | @vindex org-html-head-include-default-style | ||
| 13328 | @vindex org-html-head-include-scripts | ||
| 13329 | @multitable @columnfractions 0.32 0.68 | ||
| 13330 | @item @code{:html-doctype} @tab @code{org-html-doctype} | ||
| 13331 | @item @code{:html-xml-declaration} @tab @code{org-html-xml-declaration} | ||
| 13332 | @item @code{:html-link-up} @tab @code{org-html-link-up} | ||
| 13333 | @item @code{:html-link-home} @tab @code{org-html-link-home} | ||
| 13334 | @item @code{:html-link-org-as-html} @tab @code{org-html-link-org-files-as-html} | ||
| 13335 | @item @code{:html-head} @tab @code{org-html-head} | ||
| 13336 | @item @code{:html-head-extra} @tab @code{org-html-head-extra} | ||
| 13337 | @item @code{:html-inline-images} @tab @code{org-html-inline-images} | ||
| 13338 | @item @code{:html-extension} @tab @code{org-html-extension} | ||
| 13339 | @item @code{:html-preamble} @tab @code{org-html-preamble} | ||
| 13340 | @item @code{:html-postamble} @tab @code{org-html-postamble} | ||
| 13341 | @item @code{:html-table-attributes} @tab @code{org-html-table-default-attributes} | ||
| 13342 | @item @code{:html-head-include-default-style} @tab @code{org-html-head-include-default-style} | ||
| 13343 | @item @code{:html-head-include-scripts} @tab @code{org-html-head-include-scripts} | ||
| 13344 | @end multitable | ||
| 12429 | 13345 | ||
| 13346 | Most of the @code{org-export-with-*} variables have the same effect in each | ||
| 13347 | exporter. | ||
| 12430 | 13348 | ||
| 12431 | @vindex org-publish-project-alist | 13349 | @vindex org-publish-project-alist |
| 12432 | When a property is given a value in @code{org-publish-project-alist}, | 13350 | When a property is given a value in @code{org-publish-project-alist}, its |
| 12433 | its setting overrides the value of the corresponding user variable (if | 13351 | setting overrides the value of the corresponding user variable (if any) |
| 12434 | any) during publishing. Options set within a file (@pxref{Export | 13352 | during publishing. Options set within a file (@pxref{Export settings}), |
| 12435 | options}), however, override everything. | 13353 | however, override everything. |
| 12436 | 13354 | ||
| 12437 | @node Publishing links, Sitemap, Publishing options, Configuration | 13355 | @node Publishing links, Sitemap, Publishing options, Configuration |
| 12438 | @subsection Links between published files | 13356 | @subsection Links between published files |
| 12439 | @cindex links, publishing | 13357 | @cindex links, publishing |
| 12440 | 13358 | ||
| 12441 | To create a link from one Org file to another, you would use | 13359 | To create a link from one Org file to another, you would use something like |
| 12442 | something like @samp{[[file:foo.org][The foo]]} or simply | 13360 | @samp{[[file:foo.org][The foo]]} or simply @samp{file:foo.org.} |
| 12443 | @samp{file:foo.org.} (@pxref{Hyperlinks}). When published, this link | 13361 | (@pxref{Hyperlinks}). When published, this link becomes a link to |
| 12444 | becomes a link to @file{foo.html}. In this way, you can interlink the | 13362 | @file{foo.html}. You can thus interlink the pages of your "org web" project |
| 12445 | pages of your "org web" project and the links will work as expected when | 13363 | and the links will work as expected when you publish them to HTML@. If you |
| 12446 | you publish them to HTML@. If you also publish the Org source file and want | 13364 | also publish the Org source file and want to link to it, use an @code{http:} |
| 12447 | to link to that, use an @code{http:} link instead of a @code{file:} link, | 13365 | link instead of a @code{file:} link, because @code{file:} links are converted |
| 12448 | because @code{file:} links are converted to link to the corresponding | 13366 | to link to the corresponding @file{html} file. |
| 12449 | @file{html} file. | ||
| 12450 | 13367 | ||
| 12451 | You may also link to related files, such as images. Provided you are careful | 13368 | You may also link to related files, such as images. Provided you are careful |
| 12452 | with relative file names, and provided you have also configured Org to upload | 13369 | with relative file names, and provided you have also configured Org to upload |
| 12453 | the related files, these links will work too. See @ref{Complex example}, for | 13370 | the related files, these links will work too. See @ref{Complex example}, for |
| 12454 | an example of this usage. | 13371 | an example of this usage. |
| 12455 | 13372 | ||
| 12456 | Sometimes an Org file to be published may contain links that are | ||
| 12457 | only valid in your production environment, but not in the publishing | ||
| 12458 | location. In this case, use the property | ||
| 12459 | |||
| 12460 | @multitable @columnfractions 0.4 0.6 | ||
| 12461 | @item @code{:link-validation-function} | ||
| 12462 | @tab Function to validate links | ||
| 12463 | @end multitable | ||
| 12464 | |||
| 12465 | @noindent | ||
| 12466 | to define a function for checking link validity. This function must | ||
| 12467 | accept two arguments, the file name and a directory relative to which | ||
| 12468 | the file name is interpreted in the production environment. If this | ||
| 12469 | function returns @code{nil}, then the HTML generator will only insert a | ||
| 12470 | description into the HTML file, but no link. One option for this | ||
| 12471 | function is @code{org-publish-validate-link} which checks if the given | ||
| 12472 | file is part of any project in @code{org-publish-project-alist}. | ||
| 12473 | |||
| 12474 | @node Sitemap, Generating an index, Publishing links, Configuration | 13373 | @node Sitemap, Generating an index, Publishing links, Configuration |
| 12475 | @subsection Generating a sitemap | 13374 | @subsection Generating a sitemap |
| 12476 | @cindex sitemap, of published pages | 13375 | @cindex sitemap, of published pages |
| @@ -12480,7 +13379,7 @@ a map of files for a given project. | |||
| 12480 | 13379 | ||
| 12481 | @multitable @columnfractions 0.35 0.65 | 13380 | @multitable @columnfractions 0.35 0.65 |
| 12482 | @item @code{:auto-sitemap} | 13381 | @item @code{:auto-sitemap} |
| 12483 | @tab When non-nil, publish a sitemap during @code{org-publish-current-project} | 13382 | @tab When non-@code{nil}, publish a sitemap during @code{org-publish-current-project} |
| 12484 | or @code{org-publish-all}. | 13383 | or @code{org-publish-all}. |
| 12485 | 13384 | ||
| 12486 | @item @code{:sitemap-filename} | 13385 | @item @code{:sitemap-filename} |
| @@ -12525,7 +13424,7 @@ a sitemap entry's date is to be formatted. This property bypasses | |||
| 12525 | @code{org-publish-sitemap-date-format} which defaults to @code{%Y-%m-%d}. | 13424 | @code{org-publish-sitemap-date-format} which defaults to @code{%Y-%m-%d}. |
| 12526 | 13425 | ||
| 12527 | @item @code{:sitemap-sans-extension} | 13426 | @item @code{:sitemap-sans-extension} |
| 12528 | @tab When non-nil, remove filenames' extensions from the generated sitemap. | 13427 | @tab When non-@code{nil}, remove filenames' extensions from the generated sitemap. |
| 12529 | Useful to have cool URIs (see @uref{http://www.w3.org/Provider/Style/URI}). | 13428 | Useful to have cool URIs (see @uref{http://www.w3.org/Provider/Style/URI}). |
| 12530 | Defaults to @code{nil}. | 13429 | Defaults to @code{nil}. |
| 12531 | 13430 | ||
| @@ -12539,7 +13438,7 @@ Org mode can generate an index across the files of a publishing project. | |||
| 12539 | 13438 | ||
| 12540 | @multitable @columnfractions 0.25 0.75 | 13439 | @multitable @columnfractions 0.25 0.75 |
| 12541 | @item @code{:makeindex} | 13440 | @item @code{:makeindex} |
| 12542 | @tab When non-nil, generate in index in the file @file{theindex.org} and | 13441 | @tab When non-@code{nil}, generate in index in the file @file{theindex.org} and |
| 12543 | publish it as @file{theindex.html}. | 13442 | publish it as @file{theindex.html}. |
| 12544 | @end multitable | 13443 | @end multitable |
| 12545 | 13444 | ||
| @@ -12605,10 +13504,10 @@ directory on the local machine. | |||
| 12605 | :base-directory "~/org/" | 13504 | :base-directory "~/org/" |
| 12606 | :publishing-directory "~/public_html" | 13505 | :publishing-directory "~/public_html" |
| 12607 | :section-numbers nil | 13506 | :section-numbers nil |
| 12608 | :table-of-contents nil | 13507 | :with-toc nil |
| 12609 | :style "<link rel=\"stylesheet\" | 13508 | :html-head "<link rel=\"stylesheet\" |
| 12610 | href=\"../other/mystyle.css\" | 13509 | href=\"../other/mystyle.css\" |
| 12611 | type=\"text/css\"/>"))) | 13510 | type=\"text/css\"/>"))) |
| 12612 | @end lisp | 13511 | @end lisp |
| 12613 | 13512 | ||
| 12614 | @node Complex example, , Simple example, Sample configuration | 13513 | @node Complex example, , Simple example, Sample configuration |
| @@ -12638,12 +13537,12 @@ right place on the web server, and publishing images to it. | |||
| 12638 | :base-directory "~/org/" | 13537 | :base-directory "~/org/" |
| 12639 | :base-extension "org" | 13538 | :base-extension "org" |
| 12640 | :publishing-directory "/ssh:user@@host:~/html/notebook/" | 13539 | :publishing-directory "/ssh:user@@host:~/html/notebook/" |
| 12641 | :publishing-function org-publish-org-to-html | 13540 | :publishing-function org-html-publish-to-html |
| 12642 | :exclude "PrivatePage.org" ;; regexp | 13541 | :exclude "PrivatePage.org" ;; regexp |
| 12643 | :headline-levels 3 | 13542 | :headline-levels 3 |
| 12644 | :section-numbers nil | 13543 | :section-numbers nil |
| 12645 | :table-of-contents nil | 13544 | :with-toc nil |
| 12646 | :style "<link rel=\"stylesheet\" | 13545 | :html-head "<link rel=\"stylesheet\" |
| 12647 | href=\"../other/mystyle.css\" type=\"text/css\"/>" | 13546 | href=\"../other/mystyle.css\" type=\"text/css\"/>" |
| 12648 | :html-preamble t) | 13547 | :html-preamble t) |
| 12649 | 13548 | ||
| @@ -12667,13 +13566,13 @@ right place on the web server, and publishing images to it. | |||
| 12667 | Once properly configured, Org can publish with the following commands: | 13566 | Once properly configured, Org can publish with the following commands: |
| 12668 | 13567 | ||
| 12669 | @table @kbd | 13568 | @table @kbd |
| 12670 | @orgcmd{C-c C-e X,org-publish} | 13569 | @orgcmd{C-c C-e P x,org-publish} |
| 12671 | Prompt for a specific project and publish all files that belong to it. | 13570 | Prompt for a specific project and publish all files that belong to it. |
| 12672 | @orgcmd{C-c C-e P,org-publish-current-project} | 13571 | @orgcmd{C-c C-e P p,org-publish-current-project} |
| 12673 | Publish the project containing the current file. | 13572 | Publish the project containing the current file. |
| 12674 | @orgcmd{C-c C-e F,org-publish-current-file} | 13573 | @orgcmd{C-c C-e P f,org-publish-current-file} |
| 12675 | Publish only the current file. | 13574 | Publish only the current file. |
| 12676 | @orgcmd{C-c C-e E,org-publish-all} | 13575 | @orgcmd{C-c C-e P a,org-publish-all} |
| 12677 | Publish every project. | 13576 | Publish every project. |
| 12678 | @end table | 13577 | @end table |
| 12679 | 13578 | ||
| @@ -12770,7 +13669,7 @@ src_<language>[<header arguments>]@{<body>@} | |||
| 12770 | @table @code | 13669 | @table @code |
| 12771 | @item <#+NAME: name> | 13670 | @item <#+NAME: name> |
| 12772 | This line associates a name with the code block. This is similar to the | 13671 | This line associates a name with the code block. This is similar to the |
| 12773 | @code{#+TBLNAME: NAME} lines that can be used to name tables in Org mode | 13672 | @code{#+NAME: Name} lines that can be used to name tables in Org mode |
| 12774 | files. Referencing the name of a code block makes it possible to evaluate | 13673 | files. Referencing the name of a code block makes it possible to evaluate |
| 12775 | the block from other places in the file, from other files, or from Org mode | 13674 | the block from other places in the file, from other files, or from Org mode |
| 12776 | table formulas (see @ref{The spreadsheet}). Names are assumed to be unique | 13675 | table formulas (see @ref{The spreadsheet}). Names are assumed to be unique |
| @@ -12802,11 +13701,16 @@ Source code in the specified language. | |||
| 12802 | @cindex code block, editing | 13701 | @cindex code block, editing |
| 12803 | @cindex source code, editing | 13702 | @cindex source code, editing |
| 12804 | 13703 | ||
| 13704 | @vindex org-edit-src-auto-save-idle-delay | ||
| 13705 | @vindex org-edit-src-turn-on-auto-save | ||
| 12805 | @kindex C-c ' | 13706 | @kindex C-c ' |
| 12806 | Use @kbd{C-c '} to edit the current code block. This brings up | 13707 | Use @kbd{C-c '} to edit the current code block. This brings up a language |
| 12807 | a language major-mode edit buffer containing the body of the code | 13708 | major-mode edit buffer containing the body of the code block. Manually |
| 12808 | block. Saving this buffer will write the new contents back to the Org | 13709 | saving this buffer with @key{C-x C-s} will write the contents back to the Org |
| 12809 | buffer. Use @kbd{C-c '} again to exit. | 13710 | buffer. You can also set @code{org-edit-src-auto-save-idle-delay} to save the |
| 13711 | base buffer after some idle delay, or @code{org-edit-src-turn-on-auto-save} | ||
| 13712 | to auto-save this buffer into a separate file using @code{auto-save-mode}. | ||
| 13713 | Use @kbd{C-c '} again to exit. | ||
| 12810 | 13714 | ||
| 12811 | The @code{org-src-mode} minor mode will be active in the edit buffer. The | 13715 | The @code{org-src-mode} minor mode will be active in the edit buffer. The |
| 12812 | following variables can be used to configure the behavior of the edit | 13716 | following variables can be used to configure the behavior of the edit |
| @@ -12826,7 +13730,7 @@ This variable is especially useful for tangling languages such as | |||
| 12826 | Python, in which whitespace indentation in the output is critical. | 13730 | Python, in which whitespace indentation in the output is critical. |
| 12827 | @item org-src-ask-before-returning-to-edit-buffer | 13731 | @item org-src-ask-before-returning-to-edit-buffer |
| 12828 | By default, Org will ask before returning to an open edit buffer. Set this | 13732 | By default, Org will ask before returning to an open edit buffer. Set this |
| 12829 | variable to nil to switch without asking. | 13733 | variable to @code{nil} to switch without asking. |
| 12830 | @end table | 13734 | @end table |
| 12831 | 13735 | ||
| 12832 | To turn on native code fontification in the @emph{Org} buffer, configure the | 13736 | To turn on native code fontification in the @emph{Org} buffer, configure the |
| @@ -12851,6 +13755,7 @@ The @code{:exports} header argument can be used to specify export | |||
| 12851 | behavior: | 13755 | behavior: |
| 12852 | 13756 | ||
| 12853 | @subsubheading Header arguments: | 13757 | @subsubheading Header arguments: |
| 13758 | |||
| 12854 | @table @code | 13759 | @table @code |
| 12855 | @item :exports code | 13760 | @item :exports code |
| 12856 | The default in most languages. The body of the code block is exported, as | 13761 | The default in most languages. The body of the code block is exported, as |
| @@ -12872,7 +13777,12 @@ Setting the @code{org-export-babel-evaluate} variable to @code{nil} will | |||
| 12872 | ensure that no code blocks are evaluated as part of the export process. This | 13777 | ensure that no code blocks are evaluated as part of the export process. This |
| 12873 | can be useful in situations where potentially untrusted Org mode files are | 13778 | can be useful in situations where potentially untrusted Org mode files are |
| 12874 | exported in an automated fashion, for example when Org mode is used as the | 13779 | exported in an automated fashion, for example when Org mode is used as the |
| 12875 | markup language for a wiki. | 13780 | markup language for a wiki. It is also possible to set this variable to |
| 13781 | @code{‘inline-only}. In that case, only inline code blocks will be | ||
| 13782 | evaluated, in order to insert their results. Non-inline code blocks are | ||
| 13783 | assumed to have their results already inserted in the buffer by manual | ||
| 13784 | evaluation. This setting is useful to avoid expensive recalculations during | ||
| 13785 | export, not to provide security. | ||
| 12876 | 13786 | ||
| 12877 | @comment node-name, next, previous, up | 13787 | @comment node-name, next, previous, up |
| 12878 | @comment Extracting source code, Evaluating code blocks, Exporting code blocks, Working With Source Code | 13788 | @comment Extracting source code, Evaluating code blocks, Exporting code blocks, Working With Source Code |
| @@ -12889,6 +13799,7 @@ using @code{org-babel-expand-src-block} which can expand both variable and | |||
| 12889 | ``noweb'' style references (see @ref{Noweb reference syntax}). | 13799 | ``noweb'' style references (see @ref{Noweb reference syntax}). |
| 12890 | 13800 | ||
| 12891 | @subsubheading Header arguments | 13801 | @subsubheading Header arguments |
| 13802 | |||
| 12892 | @table @code | 13803 | @table @code |
| 12893 | @item :tangle no | 13804 | @item :tangle no |
| 12894 | The default. The code block is not included in the tangled output. | 13805 | The default. The code block is not included in the tangled output. |
| @@ -12902,14 +13813,18 @@ Include the code block in the tangled output to file @samp{filename}. | |||
| 12902 | 13813 | ||
| 12903 | @kindex C-c C-v t | 13814 | @kindex C-c C-v t |
| 12904 | @subsubheading Functions | 13815 | @subsubheading Functions |
| 13816 | |||
| 12905 | @table @code | 13817 | @table @code |
| 12906 | @item org-babel-tangle | 13818 | @item org-babel-tangle |
| 12907 | Tangle the current file. Bound to @kbd{C-c C-v t}. | 13819 | Tangle the current file. Bound to @kbd{C-c C-v t}. |
| 13820 | |||
| 13821 | With prefix argument only tangle the current code block. | ||
| 12908 | @item org-babel-tangle-file | 13822 | @item org-babel-tangle-file |
| 12909 | Choose a file to tangle. Bound to @kbd{C-c C-v f}. | 13823 | Choose a file to tangle. Bound to @kbd{C-c C-v f}. |
| 12910 | @end table | 13824 | @end table |
| 12911 | 13825 | ||
| 12912 | @subsubheading Hooks | 13826 | @subsubheading Hooks |
| 13827 | |||
| 12913 | @table @code | 13828 | @table @code |
| 12914 | @item org-babel-post-tangle-hook | 13829 | @item org-babel-post-tangle-hook |
| 12915 | This hook is run from within code files tangled by @code{org-babel-tangle}. | 13830 | This hook is run from within code files tangled by @code{org-babel-tangle}. |
| @@ -12917,6 +13832,21 @@ Example applications could include post-processing, compilation or evaluation | |||
| 12917 | of tangled code files. | 13832 | of tangled code files. |
| 12918 | @end table | 13833 | @end table |
| 12919 | 13834 | ||
| 13835 | @subsubheading Jumping between code and Org | ||
| 13836 | |||
| 13837 | When tangling code from an Org-mode buffer to a source code file, you'll | ||
| 13838 | frequently find yourself viewing the file of tangled source code (e.g., many | ||
| 13839 | debuggers point to lines of the source code file). It is useful to be able | ||
| 13840 | to navigate from the tangled source to the Org-mode buffer from which the | ||
| 13841 | code originated. | ||
| 13842 | |||
| 13843 | The @code{org-babel-tangle-jump-to-org} function provides this jumping from | ||
| 13844 | code to Org-mode functionality. Two header arguments are required for | ||
| 13845 | jumping to work, first the @code{padline} (@ref{padline}) option must be set | ||
| 13846 | to true (the default setting), second the @code{comments} (@ref{comments}) | ||
| 13847 | header argument must be set to @code{links}, which will insert comments into | ||
| 13848 | the source code buffer which point back to the original Org-mode file. | ||
| 13849 | |||
| 12920 | @node Evaluating code blocks, Library of Babel, Extracting source code, Working With Source Code | 13850 | @node Evaluating code blocks, Library of Babel, Extracting source code, Working With Source Code |
| 12921 | @section Evaluating code blocks | 13851 | @section Evaluating code blocks |
| 12922 | @cindex code block, evaluating | 13852 | @cindex code block, evaluating |
| @@ -12943,7 +13873,7 @@ used to define a code block). | |||
| 12943 | @kindex C-c C-c | 13873 | @kindex C-c C-c |
| 12944 | There are a number of ways to evaluate code blocks. The simplest is to press | 13874 | There are a number of ways to evaluate code blocks. The simplest is to press |
| 12945 | @kbd{C-c C-c} or @kbd{C-c C-v e} with the point on a code block@footnote{The | 13875 | @kbd{C-c C-c} or @kbd{C-c C-v e} with the point on a code block@footnote{The |
| 12946 | @code{org-babel-no-eval-on-ctrl-c-ctrl-c} variable can be used to remove code | 13876 | option @code{org-babel-no-eval-on-ctrl-c-ctrl-c} can be used to remove code |
| 12947 | evaluation from the @kbd{C-c C-c} key binding.}. This will call the | 13877 | evaluation from the @kbd{C-c C-c} key binding.}. This will call the |
| 12948 | @code{org-babel-execute-src-block} function to evaluate the block and insert | 13878 | @code{org-babel-execute-src-block} function to evaluate the block and insert |
| 12949 | its results into the Org mode buffer. | 13879 | its results into the Org mode buffer. |
| @@ -13054,10 +13984,10 @@ Language-specific documentation is available for some languages. If | |||
| 13054 | available, it can be found at | 13984 | available, it can be found at |
| 13055 | @uref{http://orgmode.org/worg/org-contrib/babel/languages.html}. | 13985 | @uref{http://orgmode.org/worg/org-contrib/babel/languages.html}. |
| 13056 | 13986 | ||
| 13057 | The @code{org-babel-load-languages} controls which languages are enabled for | 13987 | The option @code{org-babel-load-languages} controls which languages are |
| 13058 | evaluation (by default only @code{emacs-lisp} is enabled). This variable can | 13988 | enabled for evaluation (by default only @code{emacs-lisp} is enabled). This |
| 13059 | be set using the customization interface or by adding code like the following | 13989 | variable can be set using the customization interface or by adding code like |
| 13060 | to your emacs configuration. | 13990 | the following to your emacs configuration. |
| 13061 | 13991 | ||
| 13062 | @quotation | 13992 | @quotation |
| 13063 | The following disables @code{emacs-lisp} evaluation and enables evaluation of | 13993 | The following disables @code{emacs-lisp} evaluation and enables evaluation of |
| @@ -13099,13 +14029,16 @@ describes each header argument in detail. | |||
| 13099 | @node Using header arguments, Specific header arguments, Header arguments, Header arguments | 14029 | @node Using header arguments, Specific header arguments, Header arguments, Header arguments |
| 13100 | @subsection Using header arguments | 14030 | @subsection Using header arguments |
| 13101 | 14031 | ||
| 13102 | The values of header arguments can be set in six different ways, each more | 14032 | The values of header arguments can be set in several way. When the header |
| 13103 | specific (and having higher priority) than the last. | 14033 | arguments in each layer have been determined, they are combined in order from |
| 14034 | the first, least specific (having the lowest priority) up to the last, most | ||
| 14035 | specific (having the highest priority). A header argument with a higher | ||
| 14036 | priority replaces the same header argument specified at lower priority. | ||
| 13104 | @menu | 14037 | @menu |
| 13105 | * System-wide header arguments:: Set global default values | 14038 | * System-wide header arguments:: Set global default values |
| 13106 | * Language-specific header arguments:: Set default values by language | 14039 | * Language-specific header arguments:: Set default values by language |
| 13107 | * Buffer-wide header arguments:: Set default values for a specific buffer | ||
| 13108 | * Header arguments in Org mode properties:: Set default values for a buffer or heading | 14040 | * Header arguments in Org mode properties:: Set default values for a buffer or heading |
| 14041 | * Language-specific header arguments in Org mode properties:: Set language-specific default values for a buffer or heading | ||
| 13109 | * Code block specific header arguments:: The most common way to set values | 14042 | * Code block specific header arguments:: The most common way to set values |
| 13110 | * Header arguments in function calls:: The most specific level | 14043 | * Header arguments in function calls:: The most specific level |
| 13111 | @end menu | 14044 | @end menu |
| @@ -13114,7 +14047,7 @@ specific (and having higher priority) than the last. | |||
| 13114 | @node System-wide header arguments, Language-specific header arguments, Using header arguments, Using header arguments | 14047 | @node System-wide header arguments, Language-specific header arguments, Using header arguments, Using header arguments |
| 13115 | @subsubheading System-wide header arguments | 14048 | @subsubheading System-wide header arguments |
| 13116 | @vindex org-babel-default-header-args | 14049 | @vindex org-babel-default-header-args |
| 13117 | System-wide values of header arguments can be specified by customizing the | 14050 | System-wide values of header arguments can be specified by adapting the |
| 13118 | @code{org-babel-default-header-args} variable: | 14051 | @code{org-babel-default-header-args} variable: |
| 13119 | 14052 | ||
| 13120 | @example | 14053 | @example |
| @@ -13125,20 +14058,6 @@ System-wide values of header arguments can be specified by customizing the | |||
| 13125 | :noweb => "no" | 14058 | :noweb => "no" |
| 13126 | @end example | 14059 | @end example |
| 13127 | 14060 | ||
| 13128 | @c @example | ||
| 13129 | @c org-babel-default-header-args is a variable defined in `org-babel.el'. | ||
| 13130 | @c Its value is | ||
| 13131 | @c ((:session . "none") | ||
| 13132 | @c (:results . "replace") | ||
| 13133 | @c (:exports . "code") | ||
| 13134 | @c (:cache . "no") | ||
| 13135 | @c (:noweb . "no")) | ||
| 13136 | |||
| 13137 | |||
| 13138 | @c Documentation: | ||
| 13139 | @c Default arguments to use when evaluating a code block. | ||
| 13140 | @c @end example | ||
| 13141 | |||
| 13142 | For example, the following example could be used to set the default value of | 14061 | For example, the following example could be used to set the default value of |
| 13143 | @code{:noweb} header arguments to @code{yes}. This would have the effect of | 14062 | @code{:noweb} header arguments to @code{yes}. This would have the effect of |
| 13144 | expanding @code{:noweb} references by default when evaluating source code | 14063 | expanding @code{:noweb} references by default when evaluating source code |
| @@ -13147,64 +14066,88 @@ blocks. | |||
| 13147 | @lisp | 14066 | @lisp |
| 13148 | (setq org-babel-default-header-args | 14067 | (setq org-babel-default-header-args |
| 13149 | (cons '(:noweb . "yes") | 14068 | (cons '(:noweb . "yes") |
| 13150 | (assq-delete-all :noweb org-babel-default-header-args))) | 14069 | (assq-delete-all :noweb org-babel-default-header-args))) |
| 13151 | @end lisp | 14070 | @end lisp |
| 13152 | 14071 | ||
| 13153 | @node Language-specific header arguments, Buffer-wide header arguments, System-wide header arguments, Using header arguments | 14072 | @node Language-specific header arguments, Header arguments in Org mode properties, System-wide header arguments, Using header arguments |
| 13154 | @subsubheading Language-specific header arguments | 14073 | @subsubheading Language-specific header arguments |
| 13155 | Each language can define its own set of default header arguments. See the | 14074 | Each language can define its own set of default header arguments in variable |
| 13156 | language-specific documentation available online at | 14075 | @code{org-babel-default-header-args:<lang>}, where @code{<lang>} is the name |
| 14076 | of the language. See the language-specific documentation available online at | ||
| 13157 | @uref{http://orgmode.org/worg/org-contrib/babel}. | 14077 | @uref{http://orgmode.org/worg/org-contrib/babel}. |
| 13158 | 14078 | ||
| 13159 | @node Buffer-wide header arguments, Header arguments in Org mode properties, Language-specific header arguments, Using header arguments | 14079 | @node Header arguments in Org mode properties, Language-specific header arguments in Org mode properties, Language-specific header arguments, Using header arguments |
| 13160 | @subsubheading Buffer-wide header arguments | 14080 | @subsubheading Header arguments in Org mode properties |
| 14081 | |||
| 13161 | Buffer-wide header arguments may be specified as properties through the use | 14082 | Buffer-wide header arguments may be specified as properties through the use |
| 13162 | of @code{#+PROPERTY:} lines placed anywhere in an Org mode file (see | 14083 | of @code{#+PROPERTY:} lines placed anywhere in an Org mode file (see |
| 13163 | @ref{Property syntax}). | 14084 | @ref{Property syntax}). |
| 13164 | 14085 | ||
| 13165 | For example the following would set @code{session} to @code{*R*}, and | 14086 | For example the following would set @code{session} to @code{*R*} (only for R |
| 13166 | @code{results} to @code{silent} for every code block in the buffer, ensuring | 14087 | code blocks), and @code{results} to @code{silent} for every code block in the |
| 13167 | that all execution took place in the same session, and no results would be | 14088 | buffer, ensuring that all execution took place in the same session, and no |
| 13168 | inserted into the buffer. | 14089 | results would be inserted into the buffer. |
| 13169 | 14090 | ||
| 13170 | @example | 14091 | @example |
| 13171 | #+PROPERTY: session *R* | 14092 | #+PROPERTY: header-args:R :session *R* |
| 13172 | #+PROPERTY: results silent | 14093 | #+PROPERTY: header-args :results silent |
| 13173 | @end example | ||
| 13174 | |||
| 13175 | @node Header arguments in Org mode properties, Code block specific header arguments, Buffer-wide header arguments, Using header arguments | ||
| 13176 | @subsubheading Header arguments in Org mode properties | ||
| 13177 | |||
| 13178 | Header arguments are also read from Org mode properties (see @ref{Property | ||
| 13179 | syntax}), which can be set on a buffer-wide or per-heading basis. An example | ||
| 13180 | of setting a header argument for all code blocks in a buffer is | ||
| 13181 | |||
| 13182 | @example | ||
| 13183 | #+PROPERTY: tangle yes | ||
| 13184 | @end example | 14094 | @end example |
| 13185 | 14095 | ||
| 14096 | Header arguments read from Org mode properties can also be set on a | ||
| 14097 | per-subtree basis using property drawers (see @ref{Property syntax}). | ||
| 13186 | @vindex org-use-property-inheritance | 14098 | @vindex org-use-property-inheritance |
| 13187 | When properties are used to set default header arguments, they are looked up | 14099 | When properties are used to set default header arguments, they are always |
| 13188 | with inheritance, regardless of the value of | 14100 | looked up with inheritance, regardless of the value of |
| 13189 | @code{org-use-property-inheritance}. In the following example the value of | 14101 | @code{org-use-property-inheritance}. Properties are evaluated as seen by the |
| 14102 | outermost call or source block.@footnote{The deprecated syntax for default | ||
| 14103 | header argument properties, using the name of the header argument as a | ||
| 14104 | property name directly, evaluates the property as seen by the corresponding | ||
| 14105 | source block definition. This behaviour has been kept for backwards | ||
| 14106 | compatibility.} | ||
| 14107 | |||
| 14108 | In the following example the value of | ||
| 13190 | the @code{:cache} header argument will default to @code{yes} in all code | 14109 | the @code{:cache} header argument will default to @code{yes} in all code |
| 13191 | blocks in the subtree rooted at the following heading: | 14110 | blocks in the subtree rooted at the following heading: |
| 13192 | 14111 | ||
| 13193 | @example | 14112 | @example |
| 13194 | * outline header | 14113 | * outline header |
| 13195 | :PROPERTIES: | 14114 | :PROPERTIES: |
| 13196 | :cache: yes | 14115 | :header-args: :cache yes |
| 13197 | :END: | 14116 | :END: |
| 13198 | @end example | 14117 | @end example |
| 13199 | 14118 | ||
| 13200 | @kindex C-c C-x p | 14119 | @kindex C-c C-x p |
| 13201 | @vindex org-babel-default-header-args | 14120 | @vindex org-babel-default-header-args |
| 13202 | Properties defined in this way override the properties set in | 14121 | Properties defined in this way override the properties set in |
| 13203 | @code{org-babel-default-header-args}. It is convenient to use the | 14122 | @code{org-babel-default-header-args} and are applied for all activated |
| 13204 | @code{org-set-property} function bound to @kbd{C-c C-x p} to set properties | 14123 | languages. It is convenient to use the @code{org-set-property} function |
| 13205 | in Org mode documents. | 14124 | bound to @kbd{C-c C-x p} to set properties in Org mode documents. |
| 13206 | 14125 | ||
| 13207 | @node Code block specific header arguments, Header arguments in function calls, Header arguments in Org mode properties, Using header arguments | 14126 | @node Language-specific header arguments in Org mode properties, Code block specific header arguments, Header arguments in Org mode properties, Using header arguments |
| 14127 | @subsubheading Language-specific header arguments in Org mode properties | ||
| 14128 | |||
| 14129 | Language-specific header arguments are also read from properties | ||
| 14130 | @code{header-args:<lang>} where @code{<lang>} is the name of the language | ||
| 14131 | targeted. As an example | ||
| 14132 | |||
| 14133 | @example | ||
| 14134 | * Heading | ||
| 14135 | :PROPERTIES: | ||
| 14136 | :header-args:clojure: :session *clojure-1* | ||
| 14137 | :header-args:R: :session *R* | ||
| 14138 | :END: | ||
| 14139 | ** Subheading | ||
| 14140 | :PROPERTIES: | ||
| 14141 | :header-args:clojure: :session *clojure-2* | ||
| 14142 | :END: | ||
| 14143 | @end example | ||
| 14144 | |||
| 14145 | would independently set a default session header argument for R and clojure | ||
| 14146 | for calls and source blocks under subtree ``Heading'' and change to a | ||
| 14147 | different clojure setting for evaluations under subtree ``Subheading'', while | ||
| 14148 | the R session is inherited from ``Heading'' and therefore unchanged. | ||
| 14149 | |||
| 14150 | @node Code block specific header arguments, Header arguments in function calls, Language-specific header arguments in Org mode properties, Using header arguments | ||
| 13208 | @subsubheading Code block specific header arguments | 14151 | @subsubheading Code block specific header arguments |
| 13209 | 14152 | ||
| 13210 | The most common way to assign values to header arguments is at the | 14153 | The most common way to assign values to header arguments is at the |
| @@ -13318,8 +14261,12 @@ argument in lowercase letters. The following header arguments are defined: | |||
| 13318 | * colnames:: Handle column names in tables | 14261 | * colnames:: Handle column names in tables |
| 13319 | * rownames:: Handle row names in tables | 14262 | * rownames:: Handle row names in tables |
| 13320 | * shebang:: Make tangled files executable | 14263 | * shebang:: Make tangled files executable |
| 14264 | * tangle-mode:: Set permission of tangled files | ||
| 13321 | * eval:: Limit evaluation of specific code blocks | 14265 | * eval:: Limit evaluation of specific code blocks |
| 13322 | * wrap:: Mark source block evaluation results | 14266 | * wrap:: Mark source block evaluation results |
| 14267 | * post:: Post processing of code block results | ||
| 14268 | * prologue:: Text to prepend to code block body | ||
| 14269 | * epilogue:: Text to append to code block body | ||
| 13323 | @end menu | 14270 | @end menu |
| 13324 | 14271 | ||
| 13325 | Additional header arguments are defined on a language-specific basis, see | 14272 | Additional header arguments are defined on a language-specific basis, see |
| @@ -13334,11 +14281,13 @@ syntax used to specify arguments is the same across all languages. In every | |||
| 13334 | case, variables require a default value when they are declared. | 14281 | case, variables require a default value when they are declared. |
| 13335 | 14282 | ||
| 13336 | The values passed to arguments can either be literal values, references, or | 14283 | The values passed to arguments can either be literal values, references, or |
| 13337 | Emacs Lisp code (see @ref{var, Emacs Lisp evaluation of variables}). References | 14284 | Emacs Lisp code (see @ref{var, Emacs Lisp evaluation of variables}). |
| 13338 | include anything in the Org mode file that takes a @code{#+NAME:}, | 14285 | References include anything in the Org mode file that takes a @code{#+NAME:} |
| 13339 | @code{#+TBLNAME:}, or @code{#+RESULTS:} line. This includes tables, lists, | 14286 | or @code{#+RESULTS:} line: tables, lists, @code{#+BEGIN_EXAMPLE} blocks, |
| 13340 | @code{#+BEGIN_EXAMPLE} blocks, other code blocks, and the results of other | 14287 | other code blocks and the results of other code blocks. |
| 13341 | code blocks. | 14288 | |
| 14289 | Note: When a reference is made to another code block, the referenced block | ||
| 14290 | will be evaluated unless it has current cached results (see @ref{cache}). | ||
| 13342 | 14291 | ||
| 13343 | Argument values can be indexed in a manner similar to arrays (see @ref{var, | 14292 | Argument values can be indexed in a manner similar to arrays (see @ref{var, |
| 13344 | Indexable variable values}). | 14293 | Indexable variable values}). |
| @@ -13360,10 +14309,10 @@ Here are examples of passing values by reference: | |||
| 13360 | @table @dfn | 14309 | @table @dfn |
| 13361 | 14310 | ||
| 13362 | @item table | 14311 | @item table |
| 13363 | an Org mode table named with either a @code{#+NAME:} or @code{#+TBLNAME:} line | 14312 | an Org mode table named with either a @code{#+NAME:} line |
| 13364 | 14313 | ||
| 13365 | @example | 14314 | @example |
| 13366 | #+TBLNAME: example-table | 14315 | #+NAME: example-table |
| 13367 | | 1 | | 14316 | | 1 | |
| 13368 | | 2 | | 14317 | | 2 | |
| 13369 | | 3 | | 14318 | | 3 | |
| @@ -13456,19 +14405,6 @@ on two lines | |||
| 13456 | 14405 | ||
| 13457 | @end table | 14406 | @end table |
| 13458 | 14407 | ||
| 13459 | @subsubheading Alternate argument syntax | ||
| 13460 | It is also possible to specify arguments in a potentially more natural way | ||
| 13461 | using the @code{#+NAME:} line of a code block. As in the following | ||
| 13462 | example, arguments can be packed inside of parentheses, separated by commas, | ||
| 13463 | following the source name. | ||
| 13464 | |||
| 13465 | @example | ||
| 13466 | #+NAME: double(input=0, x=2) | ||
| 13467 | #+BEGIN_SRC emacs-lisp | ||
| 13468 | (* 2 (+ input x)) | ||
| 13469 | #+END_SRC | ||
| 13470 | @end example | ||
| 13471 | |||
| 13472 | @subsubheading Indexable variable values | 14408 | @subsubheading Indexable variable values |
| 13473 | It is possible to reference portions of variable values by ``indexing'' into | 14409 | It is possible to reference portions of variable values by ``indexing'' into |
| 13474 | the variables. Indexes are 0 based with negative values counting back from | 14410 | the variables. Indexes are 0 based with negative values counting back from |
| @@ -13593,7 +14529,7 @@ Emacs Lisp, as shown in the following example. | |||
| 13593 | @node results, file, var, Specific header arguments | 14529 | @node results, file, var, Specific header arguments |
| 13594 | @subsubsection @code{:results} | 14530 | @subsubsection @code{:results} |
| 13595 | 14531 | ||
| 13596 | There are three classes of @code{:results} header argument. Only one option | 14532 | There are four classes of @code{:results} header argument. Only one option |
| 13597 | per class may be supplied per code block. | 14533 | per class may be supplied per code block. |
| 13598 | 14534 | ||
| 13599 | @itemize @bullet | 14535 | @itemize @bullet |
| @@ -13602,6 +14538,10 @@ per class may be supplied per code block. | |||
| 13602 | from the code block | 14538 | from the code block |
| 13603 | @item | 14539 | @item |
| 13604 | @b{type} header arguments specify what type of result the code block will | 14540 | @b{type} header arguments specify what type of result the code block will |
| 14541 | return---which has implications for how they will be processed before | ||
| 14542 | insertion into the Org mode buffer | ||
| 14543 | @item | ||
| 14544 | @b{format} header arguments specify what type of result the code block will | ||
| 13605 | return---which has implications for how they will be inserted into the | 14545 | return---which has implications for how they will be inserted into the |
| 13606 | Org mode buffer | 14546 | Org mode buffer |
| 13607 | @item | 14547 | @item |
| @@ -13647,6 +14587,15 @@ buffer as quoted text. E.g., @code{:results value verbatim}. | |||
| 13647 | @item @code{file} | 14587 | @item @code{file} |
| 13648 | The results will be interpreted as the path to a file, and will be inserted | 14588 | The results will be interpreted as the path to a file, and will be inserted |
| 13649 | into the Org mode buffer as a file link. E.g., @code{:results value file}. | 14589 | into the Org mode buffer as a file link. E.g., @code{:results value file}. |
| 14590 | @end itemize | ||
| 14591 | |||
| 14592 | @subsubheading Format | ||
| 14593 | |||
| 14594 | The following options are mutually exclusive and specify what type of results | ||
| 14595 | the code block will return. By default, results are inserted according to the | ||
| 14596 | type as specified above. | ||
| 14597 | |||
| 14598 | @itemize @bullet | ||
| 13650 | @item @code{raw} | 14599 | @item @code{raw} |
| 13651 | The results are interpreted as raw Org mode code and are inserted directly | 14600 | The results are interpreted as raw Org mode code and are inserted directly |
| 13652 | into the buffer. If the results look like a table they will be aligned as | 14601 | into the buffer. If the results look like a table they will be aligned as |
| @@ -13728,7 +14677,7 @@ While the @code{:file} header argument can be used to specify the path to the | |||
| 13728 | output file, @code{:dir} specifies the default directory during code block | 14677 | output file, @code{:dir} specifies the default directory during code block |
| 13729 | execution. If it is absent, then the directory associated with the current | 14678 | execution. If it is absent, then the directory associated with the current |
| 13730 | buffer is used. In other words, supplying @code{:dir path} temporarily has | 14679 | buffer is used. In other words, supplying @code{:dir path} temporarily has |
| 13731 | the same effect as changing the current directory with @kbd{M-x cd path}, and | 14680 | the same effect as changing the current directory with @kbd{M-x cd path RET}, and |
| 13732 | then not supplying @code{:dir}. Under the surface, @code{:dir} simply sets | 14681 | then not supplying @code{:dir}. Under the surface, @code{:dir} simply sets |
| 13733 | the value of the Emacs variable @code{default-directory}. | 14682 | the value of the Emacs variable @code{default-directory}. |
| 13734 | 14683 | ||
| @@ -13853,7 +14802,6 @@ original Org file from which the code was tangled. | |||
| 13853 | A synonym for ``link'' to maintain backwards compatibility. | 14802 | A synonym for ``link'' to maintain backwards compatibility. |
| 13854 | @item @code{org} | 14803 | @item @code{org} |
| 13855 | Include text from the Org mode file as a comment. | 14804 | Include text from the Org mode file as a comment. |
| 13856 | |||
| 13857 | The text is picked from the leading context of the tangled code and is | 14805 | The text is picked from the leading context of the tangled code and is |
| 13858 | limited by the nearest headline or source block as the case may be. | 14806 | limited by the nearest headline or source block as the case may be. |
| 13859 | @item @code{both} | 14807 | @item @code{both} |
| @@ -13925,7 +14873,7 @@ references will not be expanded when the code block is exported. | |||
| 13925 | @item @code{strip-export} | 14873 | @item @code{strip-export} |
| 13926 | ``Noweb'' syntax references in the body of the code block will be expanded | 14874 | ``Noweb'' syntax references in the body of the code block will be expanded |
| 13927 | before the block is evaluated or tangled. However, ``noweb'' syntax | 14875 | before the block is evaluated or tangled. However, ``noweb'' syntax |
| 13928 | references will not be removed when the code block is exported. | 14876 | references will be removed when the code block is exported. |
| 13929 | @item @code{eval} | 14877 | @item @code{eval} |
| 13930 | ``Noweb'' syntax references in the body of the code block will only be | 14878 | ``Noweb'' syntax references in the body of the code block will only be |
| 13931 | expanded before the block is evaluated. | 14879 | expanded before the block is evaluated. |
| @@ -14085,7 +15033,7 @@ variable and raises an error. Setting @code{:hlines no} or relying on the | |||
| 14085 | default value yields the following results. | 15033 | default value yields the following results. |
| 14086 | 15034 | ||
| 14087 | @example | 15035 | @example |
| 14088 | #+TBLNAME: many-cols | 15036 | #+NAME: many-cols |
| 14089 | | a | b | c | | 15037 | | a | b | c | |
| 14090 | |---+---+---| | 15038 | |---+---+---| |
| 14091 | | d | e | f | | 15039 | | d | e | f | |
| @@ -14107,7 +15055,7 @@ default value yields the following results. | |||
| 14107 | Leaves hlines in the table. Setting @code{:hlines yes} has this effect. | 15055 | Leaves hlines in the table. Setting @code{:hlines yes} has this effect. |
| 14108 | 15056 | ||
| 14109 | @example | 15057 | @example |
| 14110 | #+TBLNAME: many-cols | 15058 | #+NAME: many-cols |
| 14111 | | a | b | c | | 15059 | | a | b | c | |
| 14112 | |---+---+---| | 15060 | |---+---+---| |
| 14113 | | d | e | f | | 15061 | | d | e | f | |
| @@ -14134,9 +15082,7 @@ Leaves hlines in the table. Setting @code{:hlines yes} has this effect. | |||
| 14134 | The @code{:colnames} header argument accepts the values @code{yes}, | 15082 | The @code{:colnames} header argument accepts the values @code{yes}, |
| 14135 | @code{no}, or @code{nil} for unassigned. The default value is @code{nil}. | 15083 | @code{no}, or @code{nil} for unassigned. The default value is @code{nil}. |
| 14136 | Note that the behavior of the @code{:colnames} header argument may differ | 15084 | Note that the behavior of the @code{:colnames} header argument may differ |
| 14137 | across languages. For example Emacs Lisp code blocks ignore the | 15085 | across languages. |
| 14138 | @code{:colnames} header argument entirely given the ease with which tables | ||
| 14139 | with column names may be handled directly in Emacs Lisp. | ||
| 14140 | 15086 | ||
| 14141 | @itemize @bullet | 15087 | @itemize @bullet |
| 14142 | @item @code{nil} | 15088 | @item @code{nil} |
| @@ -14146,7 +15092,7 @@ names will be removed from the table before | |||
| 14146 | processing, then reapplied to the results. | 15092 | processing, then reapplied to the results. |
| 14147 | 15093 | ||
| 14148 | @example | 15094 | @example |
| 14149 | #+TBLNAME: less-cols | 15095 | #+NAME: less-cols |
| 14150 | | a | | 15096 | | a | |
| 14151 | |---| | 15097 | |---| |
| 14152 | | b | | 15098 | | b | |
| @@ -14179,8 +15125,10 @@ hline) | |||
| 14179 | @node rownames, shebang, colnames, Specific header arguments | 15125 | @node rownames, shebang, colnames, Specific header arguments |
| 14180 | @subsubsection @code{:rownames} | 15126 | @subsubsection @code{:rownames} |
| 14181 | 15127 | ||
| 14182 | The @code{:rownames} header argument can take on the values @code{yes} | 15128 | The @code{:rownames} header argument can take on the values @code{yes} or |
| 14183 | or @code{no}, with a default value of @code{no}. | 15129 | @code{no}, with a default value of @code{no}. Note that Emacs Lisp code |
| 15130 | blocks ignore the @code{:rownames} header argument entirely given the ease | ||
| 15131 | with which tables with row names may be handled directly in Emacs Lisp. | ||
| 14184 | 15132 | ||
| 14185 | @itemize @bullet | 15133 | @itemize @bullet |
| 14186 | @item @code{no} | 15134 | @item @code{no} |
| @@ -14191,7 +15139,7 @@ The first column of the table is removed from the table before processing, | |||
| 14191 | and is then reapplied to the results. | 15139 | and is then reapplied to the results. |
| 14192 | 15140 | ||
| 14193 | @example | 15141 | @example |
| 14194 | #+TBLNAME: with-rownames | 15142 | #+NAME: with-rownames |
| 14195 | | one | 1 | 2 | 3 | 4 | 5 | | 15143 | | one | 1 | 2 | 3 | 4 | 5 | |
| 14196 | | two | 6 | 7 | 8 | 9 | 10 | | 15144 | | two | 6 | 7 | 8 | 9 | 10 | |
| 14197 | 15145 | ||
| @@ -14210,7 +15158,7 @@ variable indexing @xref{var, Indexable variable values}. | |||
| 14210 | 15158 | ||
| 14211 | @end itemize | 15159 | @end itemize |
| 14212 | 15160 | ||
| 14213 | @node shebang, eval, rownames, Specific header arguments | 15161 | @node shebang, tangle-mode, rownames, Specific header arguments |
| 14214 | @subsubsection @code{:shebang} | 15162 | @subsubsection @code{:shebang} |
| 14215 | 15163 | ||
| 14216 | Setting the @code{:shebang} header argument to a string value | 15164 | Setting the @code{:shebang} header argument to a string value |
| @@ -14218,7 +15166,21 @@ Setting the @code{:shebang} header argument to a string value | |||
| 14218 | first line of any tangled file holding the code block, and the file | 15166 | first line of any tangled file holding the code block, and the file |
| 14219 | permissions of the tangled file are set to make it executable. | 15167 | permissions of the tangled file are set to make it executable. |
| 14220 | 15168 | ||
| 14221 | @node eval, wrap, shebang, Specific header arguments | 15169 | |
| 15170 | @node tangle-mode, eval, shebang, Specific header arguments | ||
| 15171 | @subsubsection @code{:tangle-mode} | ||
| 15172 | |||
| 15173 | The @code{tangle-mode} header argument controls the permission set on tangled | ||
| 15174 | files. The value of this header argument will be passed to | ||
| 15175 | @code{set-file-modes}. For example, to set a tangled file as read only use | ||
| 15176 | @code{:tangle-mode (identity #o444)}, or to set a tangled file as executable | ||
| 15177 | use @code{:tangle-mode (identity #o755)}. Blocks with @code{shebang} | ||
| 15178 | (@ref{shebang}) header arguments will automatically be made executable unless | ||
| 15179 | the @code{tangle-mode} header argument is also used. The behavior is | ||
| 15180 | undefined if multiple code blocks with different values for the | ||
| 15181 | @code{tangle-mode} header argument are tangled to the same file. | ||
| 15182 | |||
| 15183 | @node eval, wrap, tangle-mode, Specific header arguments | ||
| 14222 | @subsubsection @code{:eval} | 15184 | @subsubsection @code{:eval} |
| 14223 | The @code{:eval} header argument can be used to limit the evaluation of | 15185 | The @code{:eval} header argument can be used to limit the evaluation of |
| 14224 | specific code blocks. The @code{:eval} header argument can be useful for | 15186 | specific code blocks. The @code{:eval} header argument can be useful for |
| @@ -14243,7 +15205,7 @@ If this header argument is not set then evaluation is determined by the value | |||
| 14243 | of the @code{org-confirm-babel-evaluate} variable see @ref{Code evaluation | 15205 | of the @code{org-confirm-babel-evaluate} variable see @ref{Code evaluation |
| 14244 | security}. | 15206 | security}. |
| 14245 | 15207 | ||
| 14246 | @node wrap, , eval, Specific header arguments | 15208 | @node wrap, post, eval, Specific header arguments |
| 14247 | @subsubsection @code{:wrap} | 15209 | @subsubsection @code{:wrap} |
| 14248 | The @code{:wrap} header argument is used to mark the results of source block | 15210 | The @code{:wrap} header argument is used to mark the results of source block |
| 14249 | evaluation. The header argument can be passed a string that will be appended | 15211 | evaluation. The header argument can be passed a string that will be appended |
| @@ -14251,6 +15213,59 @@ to @code{#+BEGIN_} and @code{#+END_}, which will then be used to wrap the | |||
| 14251 | results. If not string is specified then the results will be wrapped in a | 15213 | results. If not string is specified then the results will be wrapped in a |
| 14252 | @code{#+BEGIN/END_RESULTS} block. | 15214 | @code{#+BEGIN/END_RESULTS} block. |
| 14253 | 15215 | ||
| 15216 | @node post, prologue, wrap, Specific header arguments | ||
| 15217 | @subsubsection @code{:post} | ||
| 15218 | The @code{:post} header argument is used to post-process the results of a | ||
| 15219 | code block execution. When a post argument is given, the results of the code | ||
| 15220 | block will temporarily be bound to the @code{*this*} variable. This variable | ||
| 15221 | may then be included in header argument forms such as those used in @ref{var} | ||
| 15222 | header argument specifications allowing passing of results to other code | ||
| 15223 | blocks, or direct execution via Emacs Lisp. | ||
| 15224 | |||
| 15225 | The following example illustrates the usage of the @code{:post} header | ||
| 15226 | argument. | ||
| 15227 | |||
| 15228 | @example | ||
| 15229 | #+name: attr_wrap | ||
| 15230 | #+begin_src sh :var data="" :var width="\\textwidth" :results output | ||
| 15231 | echo "#+ATTR_LATEX :width $width" | ||
| 15232 | echo "$data" | ||
| 15233 | #+end_src | ||
| 15234 | |||
| 15235 | #+header: :file /tmp/it.png | ||
| 15236 | #+begin_src dot :post attr_wrap(width="5cm", data=*this*) :results drawer | ||
| 15237 | digraph@{ | ||
| 15238 | a -> b; | ||
| 15239 | b -> c; | ||
| 15240 | c -> a; | ||
| 15241 | @} | ||
| 15242 | #+end_src | ||
| 15243 | |||
| 15244 | #+RESULTS: | ||
| 15245 | :RESULTS: | ||
| 15246 | #+ATTR_LATEX :width 5cm | ||
| 15247 | [[file:/tmp/it.png]] | ||
| 15248 | :END: | ||
| 15249 | @end example | ||
| 15250 | |||
| 15251 | @node prologue, epilogue, post, Specific header arguments | ||
| 15252 | @subsubsection @code{:prologue} | ||
| 15253 | The value of the @code{prologue} header argument will be prepended to the | ||
| 15254 | code block body before execution. For example, @code{:prologue "reset"} may | ||
| 15255 | be used to reset a gnuplot session before execution of a particular code | ||
| 15256 | block, or the following configuration may be used to do this for all gnuplot | ||
| 15257 | code blocks. Also see @ref{epilogue}. | ||
| 15258 | |||
| 15259 | @lisp | ||
| 15260 | (add-to-list 'org-babel-default-header-args:gnuplot | ||
| 15261 | '((:prologue . "reset"))) | ||
| 15262 | @end lisp | ||
| 15263 | |||
| 15264 | @node epilogue, , prologue, Specific header arguments | ||
| 15265 | @subsubsection @code{:epilogue} | ||
| 15266 | The value of the @code{epilogue} header argument will be appended to the code | ||
| 15267 | block body before execution. Also see @ref{prologue}. | ||
| 15268 | |||
| 14254 | @node Results of evaluation, Noweb reference syntax, Header arguments, Working With Source Code | 15269 | @node Results of evaluation, Noweb reference syntax, Header arguments, Working With Source Code |
| 14255 | @section Results of evaluation | 15270 | @section Results of evaluation |
| 14256 | @cindex code block, results of evaluation | 15271 | @cindex code block, results of evaluation |
| @@ -14380,7 +15395,7 @@ syntactically valid in languages that you use, then please consider setting | |||
| 14380 | the default value. | 15395 | the default value. |
| 14381 | 15396 | ||
| 14382 | Note: if noweb tangling is slow in large Org mode files consider setting the | 15397 | Note: if noweb tangling is slow in large Org mode files consider setting the |
| 14383 | @code{*org-babel-use-quick-and-dirty-noweb-expansion*} variable to true. | 15398 | @code{org-babel-use-quick-and-dirty-noweb-expansion} variable to @code{t}. |
| 14384 | This will result in faster noweb reference resolution at the expense of not | 15399 | This will result in faster noweb reference resolution at the expense of not |
| 14385 | correctly resolving inherited values of the @code{:noweb-ref} header | 15400 | correctly resolving inherited values of the @code{:noweb-ref} header |
| 14386 | argument. | 15401 | argument. |
| @@ -14540,7 +15555,7 @@ emacs -Q --batch \ | |||
| 14540 | * Clean view:: Getting rid of leading stars in the outline | 15555 | * Clean view:: Getting rid of leading stars in the outline |
| 14541 | * TTY keys:: Using Org on a tty | 15556 | * TTY keys:: Using Org on a tty |
| 14542 | * Interaction:: Other Emacs packages | 15557 | * Interaction:: Other Emacs packages |
| 14543 | * org-crypt.el:: Encrypting Org files | 15558 | * org-crypt:: Encrypting Org files |
| 14544 | @end menu | 15559 | @end menu |
| 14545 | 15560 | ||
| 14546 | 15561 | ||
| @@ -14694,19 +15709,19 @@ which take off the default security brakes. | |||
| 14694 | 15709 | ||
| 14695 | @defopt org-confirm-babel-evaluate | 15710 | @defopt org-confirm-babel-evaluate |
| 14696 | When t (the default), the user is asked before every code block evaluation. | 15711 | When t (the default), the user is asked before every code block evaluation. |
| 14697 | When nil, the user is not asked. When set to a function, it is called with | 15712 | When @code{nil}, the user is not asked. When set to a function, it is called with |
| 14698 | two arguments (language and body of the code block) and should return t to | 15713 | two arguments (language and body of the code block) and should return t to |
| 14699 | ask and nil not to ask. | 15714 | ask and @code{nil} not to ask. |
| 14700 | @end defopt | 15715 | @end defopt |
| 14701 | 15716 | ||
| 14702 | For example, here is how to execute "ditaa" code (which is considered safe) | 15717 | For example, here is how to execute "ditaa" code (which is considered safe) |
| 14703 | without asking: | 15718 | without asking: |
| 14704 | 15719 | ||
| 14705 | @example | 15720 | @lisp |
| 14706 | (defun my-org-confirm-babel-evaluate (lang body) | 15721 | (defun my-org-confirm-babel-evaluate (lang body) |
| 14707 | (not (string= lang "ditaa"))) ; don't ask for ditaa | 15722 | (not (string= lang "ditaa"))) ; don't ask for ditaa |
| 14708 | (setq org-confirm-babel-evaluate 'my-org-confirm-babel-evaluate) | 15723 | (setq org-confirm-babel-evaluate 'my-org-confirm-babel-evaluate) |
| 14709 | @end example | 15724 | @end lisp |
| 14710 | 15725 | ||
| 14711 | @item Following @code{shell} and @code{elisp} links | 15726 | @item Following @code{shell} and @code{elisp} links |
| 14712 | Org has two link types that can directly evaluate code (@pxref{External | 15727 | Org has two link types that can directly evaluate code (@pxref{External |
| @@ -14734,7 +15749,7 @@ either by the @i{calc} interpreter, or by the @i{Emacs Lisp} interpreter. | |||
| 14734 | There are more than 500 variables that can be used to customize | 15749 | There are more than 500 variables that can be used to customize |
| 14735 | Org. For the sake of compactness of the manual, I am not | 15750 | Org. For the sake of compactness of the manual, I am not |
| 14736 | describing the variables here. A structured overview of customization | 15751 | describing the variables here. A structured overview of customization |
| 14737 | variables is available with @kbd{M-x org-customize}. Or select | 15752 | variables is available with @kbd{M-x org-customize RET}. Or select |
| 14738 | @code{Browse Org Group} from the @code{Org->Customization} menu. Many | 15753 | @code{Browse Org Group} from the @code{Org->Customization} menu. Many |
| 14739 | settings can also be activated on a per-file basis, by putting special | 15754 | settings can also be activated on a per-file basis, by putting special |
| 14740 | lines into the buffer (@pxref{In-buffer settings}). | 15755 | lines into the buffer (@pxref{In-buffer settings}). |
| @@ -14809,7 +15824,7 @@ as if they had been included in the buffer. In particular, the file can be | |||
| 14809 | any other Org mode file with internal setup. You can visit the file the | 15824 | any other Org mode file with internal setup. You can visit the file the |
| 14810 | cursor is in the line with @kbd{C-c '}. | 15825 | cursor is in the line with @kbd{C-c '}. |
| 14811 | @item #+STARTUP: | 15826 | @item #+STARTUP: |
| 14812 | @cindex #+STARTUP: | 15827 | @cindex #+STARTUP |
| 14813 | This line sets options to be used at startup of Org mode, when an | 15828 | This line sets options to be used at startup of Org mode, when an |
| 14814 | Org file is being visited. | 15829 | Org file is being visited. |
| 14815 | 15830 | ||
| @@ -14862,6 +15877,18 @@ inlineimages @r{show inline images} | |||
| 14862 | noinlineimages @r{don't show inline images on startup} | 15877 | noinlineimages @r{don't show inline images on startup} |
| 14863 | @end example | 15878 | @end example |
| 14864 | 15879 | ||
| 15880 | @vindex org-startup-with-latex-preview | ||
| 15881 | When visiting a file, @LaTeX{} fragments can be converted to images | ||
| 15882 | automatically. The variable @code{org-startup-with-latex-preview} which | ||
| 15883 | controls this behavior, is set to @code{nil} by default to avoid delays on | ||
| 15884 | startup. | ||
| 15885 | @cindex @code{latexpreview}, STARTUP keyword | ||
| 15886 | @cindex @code{nolatexpreview}, STARTUP keyword | ||
| 15887 | @example | ||
| 15888 | latexpreview @r{preview @LaTeX{} fragments} | ||
| 15889 | nolatexpreview @r{don't preview @LaTeX{} fragments} | ||
| 15890 | @end example | ||
| 15891 | |||
| 14865 | @vindex org-log-done | 15892 | @vindex org-log-done |
| 14866 | @vindex org-log-note-clock-out | 15893 | @vindex org-log-note-clock-out |
| 14867 | @vindex org-log-repeat | 15894 | @vindex org-log-repeat |
| @@ -14885,25 +15912,34 @@ configured using these options (see variables @code{org-log-done}, | |||
| 14885 | @cindex @code{logrefile}, STARTUP keyword | 15912 | @cindex @code{logrefile}, STARTUP keyword |
| 14886 | @cindex @code{lognoterefile}, STARTUP keyword | 15913 | @cindex @code{lognoterefile}, STARTUP keyword |
| 14887 | @cindex @code{nologrefile}, STARTUP keyword | 15914 | @cindex @code{nologrefile}, STARTUP keyword |
| 14888 | @example | 15915 | @cindex @code{logdrawer}, STARTUP keyword |
| 14889 | logdone @r{record a timestamp when an item is marked DONE} | 15916 | @cindex @code{nologdrawer}, STARTUP keyword |
| 14890 | lognotedone @r{record timestamp and a note when DONE} | 15917 | @cindex @code{logstatesreversed}, STARTUP keyword |
| 14891 | nologdone @r{don't record when items are marked DONE} | 15918 | @cindex @code{nologstatesreversed}, STARTUP keyword |
| 14892 | logrepeat @r{record a time when reinstating a repeating item} | 15919 | @example |
| 14893 | lognoterepeat @r{record a note when reinstating a repeating item} | 15920 | logdone @r{record a timestamp when an item is marked DONE} |
| 14894 | nologrepeat @r{do not record when reinstating repeating item} | 15921 | lognotedone @r{record timestamp and a note when DONE} |
| 14895 | lognoteclock-out @r{record a note when clocking out} | 15922 | nologdone @r{don't record when items are marked DONE} |
| 14896 | nolognoteclock-out @r{don't record a note when clocking out} | 15923 | logrepeat @r{record a time when reinstating a repeating item} |
| 14897 | logreschedule @r{record a timestamp when scheduling time changes} | 15924 | lognoterepeat @r{record a note when reinstating a repeating item} |
| 14898 | lognotereschedule @r{record a note when scheduling time changes} | 15925 | nologrepeat @r{do not record when reinstating repeating item} |
| 14899 | nologreschedule @r{do not record when a scheduling date changes} | 15926 | lognoteclock-out @r{record a note when clocking out} |
| 14900 | logredeadline @r{record a timestamp when deadline changes} | 15927 | nolognoteclock-out @r{don't record a note when clocking out} |
| 14901 | lognoteredeadline @r{record a note when deadline changes} | 15928 | logreschedule @r{record a timestamp when scheduling time changes} |
| 14902 | nologredeadline @r{do not record when a deadline date changes} | 15929 | lognotereschedule @r{record a note when scheduling time changes} |
| 14903 | logrefile @r{record a timestamp when refiling} | 15930 | nologreschedule @r{do not record when a scheduling date changes} |
| 14904 | lognoterefile @r{record a note when refiling} | 15931 | logredeadline @r{record a timestamp when deadline changes} |
| 14905 | nologrefile @r{do not record when refiling} | 15932 | lognoteredeadline @r{record a note when deadline changes} |
| 15933 | nologredeadline @r{do not record when a deadline date changes} | ||
| 15934 | logrefile @r{record a timestamp when refiling} | ||
| 15935 | lognoterefile @r{record a note when refiling} | ||
| 15936 | nologrefile @r{do not record when refiling} | ||
| 15937 | logdrawer @r{store log into drawer} | ||
| 15938 | nologdrawer @r{store log outside of drawer} | ||
| 15939 | logstatesreversed @r{reverse the order of states notes} | ||
| 15940 | nologstatesreversed @r{do not reverse the order of states notes} | ||
| 14906 | @end example | 15941 | @end example |
| 15942 | |||
| 14907 | @vindex org-hide-leading-stars | 15943 | @vindex org-hide-leading-stars |
| 14908 | @vindex org-odd-levels-only | 15944 | @vindex org-odd-levels-only |
| 14909 | Here are the options for hiding leading stars in outline headings, and for | 15945 | Here are the options for hiding leading stars in outline headings, and for |
| @@ -14922,6 +15958,7 @@ noindent @r{no virtual indentation according to outline level} | |||
| 14922 | odd @r{allow only odd outline levels (1,3,...)} | 15958 | odd @r{allow only odd outline levels (1,3,...)} |
| 14923 | oddeven @r{allow all outline levels} | 15959 | oddeven @r{allow all outline levels} |
| 14924 | @end example | 15960 | @end example |
| 15961 | |||
| 14925 | @vindex org-put-time-stamp-overlays | 15962 | @vindex org-put-time-stamp-overlays |
| 14926 | @vindex org-time-stamp-overlay-formats | 15963 | @vindex org-time-stamp-overlay-formats |
| 14927 | To turn on custom format overlays over timestamps (variables | 15964 | To turn on custom format overlays over timestamps (variables |
| @@ -14931,6 +15968,7 @@ To turn on custom format overlays over timestamps (variables | |||
| 14931 | @example | 15968 | @example |
| 14932 | customtime @r{overlay custom time format} | 15969 | customtime @r{overlay custom time format} |
| 14933 | @end example | 15970 | @end example |
| 15971 | |||
| 14934 | @vindex constants-unit-system | 15972 | @vindex constants-unit-system |
| 14935 | The following options influence the table spreadsheet (variable | 15973 | The following options influence the table spreadsheet (variable |
| 14936 | @code{constants-unit-system}). | 15974 | @code{constants-unit-system}). |
| @@ -14940,6 +15978,7 @@ The following options influence the table spreadsheet (variable | |||
| 14940 | constcgs @r{@file{constants.el} should use the c-g-s unit system} | 15978 | constcgs @r{@file{constants.el} should use the c-g-s unit system} |
| 14941 | constSI @r{@file{constants.el} should use the SI unit system} | 15979 | constSI @r{@file{constants.el} should use the SI unit system} |
| 14942 | @end example | 15980 | @end example |
| 15981 | |||
| 14943 | @vindex org-footnote-define-inline | 15982 | @vindex org-footnote-define-inline |
| 14944 | @vindex org-footnote-auto-label | 15983 | @vindex org-footnote-auto-label |
| 14945 | @vindex org-footnote-auto-adjust | 15984 | @vindex org-footnote-auto-adjust |
| @@ -14966,6 +16005,7 @@ fnplain @r{create @code{[1]}-like labels automatically} | |||
| 14966 | fnadjust @r{automatically renumber and sort footnotes} | 16005 | fnadjust @r{automatically renumber and sort footnotes} |
| 14967 | nofnadjust @r{do not renumber and sort automatically} | 16006 | nofnadjust @r{do not renumber and sort automatically} |
| 14968 | @end example | 16007 | @end example |
| 16008 | |||
| 14969 | @cindex org-hide-block-startup | 16009 | @cindex org-hide-block-startup |
| 14970 | To hide blocks on startup, use these keywords. The corresponding variable is | 16010 | To hide blocks on startup, use these keywords. The corresponding variable is |
| 14971 | @code{org-hide-block-startup}. | 16011 | @code{org-hide-block-startup}. |
| @@ -14975,6 +16015,7 @@ To hide blocks on startup, use these keywords. The corresponding variable is | |||
| 14975 | hideblocks @r{Hide all begin/end blocks on startup} | 16015 | hideblocks @r{Hide all begin/end blocks on startup} |
| 14976 | nohideblocks @r{Do not hide blocks on startup} | 16016 | nohideblocks @r{Do not hide blocks on startup} |
| 14977 | @end example | 16017 | @end example |
| 16018 | |||
| 14978 | @cindex org-pretty-entities | 16019 | @cindex org-pretty-entities |
| 14979 | The display of entities as UTF-8 characters is governed by the variable | 16020 | The display of entities as UTF-8 characters is governed by the variable |
| 14980 | @code{org-pretty-entities} and the keywords | 16021 | @code{org-pretty-entities} and the keywords |
| @@ -14984,20 +16025,29 @@ The display of entities as UTF-8 characters is governed by the variable | |||
| 14984 | entitiespretty @r{Show entities as UTF-8 characters where possible} | 16025 | entitiespretty @r{Show entities as UTF-8 characters where possible} |
| 14985 | entitiesplain @r{Leave entities plain} | 16026 | entitiesplain @r{Leave entities plain} |
| 14986 | @end example | 16027 | @end example |
| 16028 | |||
| 14987 | @item #+TAGS: TAG1(c1) TAG2(c2) | 16029 | @item #+TAGS: TAG1(c1) TAG2(c2) |
| 14988 | @vindex org-tag-alist | 16030 | @vindex org-tag-alist |
| 14989 | These lines (several such lines are allowed) specify the valid tags in | 16031 | These lines (several such lines are allowed) specify the valid tags in |
| 14990 | this file, and (potentially) the corresponding @emph{fast tag selection} | 16032 | this file, and (potentially) the corresponding @emph{fast tag selection} |
| 14991 | keys. The corresponding variable is @code{org-tag-alist}. | 16033 | keys. The corresponding variable is @code{org-tag-alist}. |
| 16034 | @cindex #+TBLFM | ||
| 14992 | @item #+TBLFM: | 16035 | @item #+TBLFM: |
| 14993 | This line contains the formulas for the table directly above the line. | 16036 | This line contains the formulas for the table directly above the line. |
| 14994 | @item #+TITLE:, #+AUTHOR:, #+EMAIL:, #+LANGUAGE:, #+TEXT:, #+DATE:, | 16037 | |
| 14995 | @itemx #+OPTIONS:, #+BIND:, #+XSLT:, | 16038 | Table can have multiple lines containing @samp{#+TBLFM:}. Note |
| 16039 | that only the first line of @samp{#+TBLFM:} will be applied when | ||
| 16040 | you recalculate the table. For more details see @ref{Using | ||
| 16041 | multiple #+TBLFM lines} in @ref{Editing and debugging formulas}. | ||
| 16042 | |||
| 16043 | @item #+TITLE:, #+AUTHOR:, #+EMAIL:, #+LANGUAGE:, #+DATE:, | ||
| 16044 | @itemx #+OPTIONS:, #+BIND:, | ||
| 14996 | @itemx #+DESCRIPTION:, #+KEYWORDS:, | 16045 | @itemx #+DESCRIPTION:, #+KEYWORDS:, |
| 14997 | @itemx #+LaTeX_HEADER:, #+STYLE:, #+LINK_UP:, #+LINK_HOME:, | 16046 | @itemx #+LaTeX_HEADER:, #+LaTeX_HEADER_EXTRA:, |
| 14998 | @itemx #+EXPORT_SELECT_TAGS:, #+EXPORT_EXCLUDE_TAGS: | 16047 | @itemx #+HTML_HEAD:, #+HTML_HEAD_EXTRA:, #+HTML_LINK_UP:, #+HTML_LINK_HOME:, |
| 16048 | @itemx #+SELECT_TAGS:, #+EXCLUDE_TAGS: | ||
| 14999 | These lines provide settings for exporting files. For more details see | 16049 | These lines provide settings for exporting files. For more details see |
| 15000 | @ref{Export options}. | 16050 | @ref{Export settings}. |
| 15001 | @item #+TODO: #+SEQ_TODO: #+TYP_TODO: | 16051 | @item #+TODO: #+SEQ_TODO: #+TYP_TODO: |
| 15002 | @vindex org-todo-keywords | 16052 | @vindex org-todo-keywords |
| 15003 | These lines set the TODO keywords and their interpretation in the | 16053 | These lines set the TODO keywords and their interpretation in the |
| @@ -15042,7 +16092,7 @@ If the cursor is in a property line or at the start or end of a property | |||
| 15042 | drawer, offer property commands. | 16092 | drawer, offer property commands. |
| 15043 | @item | 16093 | @item |
| 15044 | If the cursor is at a footnote reference, go to the corresponding | 16094 | If the cursor is at a footnote reference, go to the corresponding |
| 15045 | definition, and vice versa. | 16095 | definition, and @emph{vice versa}. |
| 15046 | @item | 16096 | @item |
| 15047 | If the cursor is on a statistics cookie, update it. | 16097 | If the cursor is on a statistics cookie, update it. |
| 15048 | @item | 16098 | @item |
| @@ -15221,7 +16271,7 @@ tty you would rather use @kbd{C-c .} to re-insert the timestamp. | |||
| 15221 | @end multitable | 16271 | @end multitable |
| 15222 | 16272 | ||
| 15223 | 16273 | ||
| 15224 | @node Interaction, org-crypt.el, TTY keys, Miscellaneous | 16274 | @node Interaction, org-crypt, TTY keys, Miscellaneous |
| 15225 | @section Interaction with other packages | 16275 | @section Interaction with other packages |
| 15226 | @cindex packages, interaction with other | 16276 | @cindex packages, interaction with other |
| 15227 | Org lives in the world of GNU Emacs and interacts in various ways | 16277 | Org lives in the world of GNU Emacs and interacts in various ways |
| @@ -15367,6 +16417,18 @@ Yes, these are unfortunately more difficult to remember. If you want | |||
| 15367 | to have other replacement keys, look at the variable | 16417 | to have other replacement keys, look at the variable |
| 15368 | @code{org-disputed-keys}. | 16418 | @code{org-disputed-keys}. |
| 15369 | 16419 | ||
| 16420 | @item @file{ecomplete.el} by Lars Magne Ingebrigtsen @email{larsi@@gnus.org} | ||
| 16421 | @cindex @file{ecomplete.el} | ||
| 16422 | |||
| 16423 | Ecomplete provides ``electric'' address completion in address header | ||
| 16424 | lines in message buffers. Sadly Orgtbl mode cuts ecompletes power | ||
| 16425 | supply: No completion happens when Orgtbl mode is enabled in message | ||
| 16426 | buffers while entering text in address header lines. If one wants to | ||
| 16427 | use ecomplete one should @emph{not} follow the advice to automagically | ||
| 16428 | turn on Orgtbl mode in message buffers (see @ref{Orgtbl mode}), but | ||
| 16429 | instead---after filling in the message headers---turn on Orgtbl mode | ||
| 16430 | manually when needed in the messages body. | ||
| 16431 | |||
| 15370 | @item @file{filladapt.el} by Kyle Jones | 16432 | @item @file{filladapt.el} by Kyle Jones |
| 15371 | @cindex @file{filladapt.el} | 16433 | @cindex @file{filladapt.el} |
| 15372 | 16434 | ||
| @@ -15381,7 +16443,7 @@ this: | |||
| 15381 | 16443 | ||
| 15382 | @item @file{yasnippet.el} | 16444 | @item @file{yasnippet.el} |
| 15383 | @cindex @file{yasnippet.el} | 16445 | @cindex @file{yasnippet.el} |
| 15384 | The way Org mode binds the TAB key (binding to @code{[tab]} instead of | 16446 | The way Org mode binds the @key{TAB} key (binding to @code{[tab]} instead of |
| 15385 | @code{"\t"}) overrules YASnippet's access to this key. The following code | 16447 | @code{"\t"}) overrules YASnippet's access to this key. The following code |
| 15386 | fixed this problem: | 16448 | fixed this problem: |
| 15387 | 16449 | ||
| @@ -15406,10 +16468,10 @@ Then, tell Org mode what to do with the new function: | |||
| 15406 | @lisp | 16468 | @lisp |
| 15407 | (add-hook 'org-mode-hook | 16469 | (add-hook 'org-mode-hook |
| 15408 | (lambda () | 16470 | (lambda () |
| 15409 | (make-variable-buffer-local 'yas/trigger-key) | 16471 | (make-variable-buffer-local 'yas/trigger-key) |
| 15410 | (setq yas/trigger-key [tab]) | 16472 | (setq yas/trigger-key [tab]) |
| 15411 | (add-to-list 'org-tab-first-hook 'yas/org-very-safe-expand) | 16473 | (add-to-list 'org-tab-first-hook 'yas/org-very-safe-expand) |
| 15412 | (define-key yas/keymap [tab] 'yas/next-field))) | 16474 | (define-key yas/keymap [tab] 'yas/next-field))) |
| 15413 | @end lisp | 16475 | @end lisp |
| 15414 | 16476 | ||
| 15415 | @item @file{windmove.el} by Hovav Shacham | 16477 | @item @file{windmove.el} by Hovav Shacham |
| @@ -15440,9 +16502,11 @@ another key for this command, or override the key in | |||
| 15440 | (define-key viper-vi-global-user-map "C-c /" 'org-sparse-tree) | 16502 | (define-key viper-vi-global-user-map "C-c /" 'org-sparse-tree) |
| 15441 | @end lisp | 16503 | @end lisp |
| 15442 | 16504 | ||
| 16505 | |||
| 16506 | |||
| 15443 | @end table | 16507 | @end table |
| 15444 | 16508 | ||
| 15445 | @node org-crypt.el, , Interaction, Miscellaneous | 16509 | @node org-crypt, , Interaction, Miscellaneous |
| 15446 | @section org-crypt.el | 16510 | @section org-crypt.el |
| 15447 | @cindex @file{org-crypt.el} | 16511 | @cindex @file{org-crypt.el} |
| 15448 | @cindex @code{org-decrypt-entry} | 16512 | @cindex @code{org-decrypt-entry} |
| @@ -15458,7 +16522,7 @@ customize the @code{org-crypt-tag-matcher} setting. | |||
| 15458 | To use org-crypt it is suggested that you have the following in your | 16522 | To use org-crypt it is suggested that you have the following in your |
| 15459 | @file{.emacs}: | 16523 | @file{.emacs}: |
| 15460 | 16524 | ||
| 15461 | @example | 16525 | @lisp |
| 15462 | (require 'org-crypt) | 16526 | (require 'org-crypt) |
| 15463 | (org-crypt-use-before-save-magic) | 16527 | (org-crypt-use-before-save-magic) |
| 15464 | (setq org-tags-exclude-from-inheritance (quote ("crypt"))) | 16528 | (setq org-tags-exclude-from-inheritance (quote ("crypt"))) |
| @@ -15476,7 +16540,7 @@ To use org-crypt it is suggested that you have the following in your | |||
| 15476 | ;; To turn it off only locally, you can insert this: | 16540 | ;; To turn it off only locally, you can insert this: |
| 15477 | ;; | 16541 | ;; |
| 15478 | ;; # -*- buffer-auto-save-file-name: nil; -*- | 16542 | ;; # -*- buffer-auto-save-file-name: nil; -*- |
| 15479 | @end example | 16543 | @end lisp |
| 15480 | 16544 | ||
| 15481 | Excluding the crypt tag from inheritance prevents already encrypted text | 16545 | Excluding the crypt tag from inheritance prevents already encrypted text |
| 15482 | being encrypted again. | 16546 | being encrypted again. |
| @@ -15492,11 +16556,13 @@ Org. | |||
| 15492 | * Hooks:: How to reach into Org's internals | 16556 | * Hooks:: How to reach into Org's internals |
| 15493 | * Add-on packages:: Available extensions | 16557 | * Add-on packages:: Available extensions |
| 15494 | * Adding hyperlink types:: New custom link types | 16558 | * Adding hyperlink types:: New custom link types |
| 16559 | * Adding export back-ends:: How to write new export back-ends | ||
| 15495 | * Context-sensitive commands:: How to add functionality to such commands | 16560 | * Context-sensitive commands:: How to add functionality to such commands |
| 15496 | * Tables in arbitrary syntax:: Orgtbl for @LaTeX{} and other programs | 16561 | * Tables in arbitrary syntax:: Orgtbl for @LaTeX{} and other programs |
| 15497 | * Dynamic blocks:: Automatically filled blocks | 16562 | * Dynamic blocks:: Automatically filled blocks |
| 15498 | * Special agenda views:: Customized views | 16563 | * Special agenda views:: Customized views |
| 15499 | * Extracting agenda information:: Postprocessing of agenda information | 16564 | * Speeding up your agendas:: Tips on how to speed up your agendas |
| 16565 | * Extracting agenda information:: Post-processing of agenda information | ||
| 15500 | * Using the property API:: Writing programs that use entry properties | 16566 | * Using the property API:: Writing programs that use entry properties |
| 15501 | * Using the mapping API:: Mapping over all or selected entries | 16567 | * Using the mapping API:: Mapping over all or selected entries |
| 15502 | @end menu | 16568 | @end menu |
| @@ -15516,15 +16582,14 @@ maintained by the Worg project and can be found at | |||
| 15516 | @cindex add-on packages | 16582 | @cindex add-on packages |
| 15517 | 16583 | ||
| 15518 | A large number of add-on packages have been written by various authors. | 16584 | A large number of add-on packages have been written by various authors. |
| 16585 | |||
| 15519 | These packages are not part of Emacs, but they are distributed as contributed | 16586 | These packages are not part of Emacs, but they are distributed as contributed |
| 15520 | packages with the separate release available at the Org mode home page at | 16587 | packages with the separate release available at @uref{http://orgmode.org}. |
| 15521 | @uref{http://orgmode.org}. The list of contributed packages, along with | 16588 | See the @file{contrib/README} file in the source code directory for a list of |
| 15522 | documentation about each package, is maintained by the Worg project at | 16589 | contributed files. You may also find some more information on the Worg page: |
| 15523 | @uref{http://orgmode.org/worg/org-contrib/}. | 16590 | @uref{http://orgmode.org/worg/org-contrib/}. |
| 15524 | 16591 | ||
| 15525 | 16592 | @node Adding hyperlink types, Adding export back-ends, Add-on packages, Hacking | |
| 15526 | |||
| 15527 | @node Adding hyperlink types, Context-sensitive commands, Add-on packages, Hacking | ||
| 15528 | @section Adding hyperlink types | 16593 | @section Adding hyperlink types |
| 15529 | @cindex hyperlinks, adding new types | 16594 | @cindex hyperlinks, adding new types |
| 15530 | 16595 | ||
| @@ -15627,7 +16692,37 @@ When it makes sense for your new link type, you may also define a function | |||
| 15627 | support for inserting such a link with @kbd{C-c C-l}. Such a function should | 16692 | support for inserting such a link with @kbd{C-c C-l}. Such a function should |
| 15628 | not accept any arguments, and return the full link with prefix. | 16693 | not accept any arguments, and return the full link with prefix. |
| 15629 | 16694 | ||
| 15630 | @node Context-sensitive commands, Tables in arbitrary syntax, Adding hyperlink types, Hacking | 16695 | @node Adding export back-ends, Context-sensitive commands, Adding hyperlink types, Hacking |
| 16696 | @section Adding export back-ends | ||
| 16697 | @cindex Export, writing back-ends | ||
| 16698 | |||
| 16699 | Org 8.0 comes with a completely rewritten export engine which makes it easy | ||
| 16700 | to write new export back-ends, either from scratch, or from deriving them | ||
| 16701 | from existing ones. | ||
| 16702 | |||
| 16703 | Your two entry points are respectively @code{org-export-define-backend} and | ||
| 16704 | @code{org-export-define-derived-backend}. To grok these functions, you | ||
| 16705 | should first have a look at @file{ox-latex.el} (for how to define a new | ||
| 16706 | back-end from scratch) and @file{ox-beamer.el} (for how to derive a new | ||
| 16707 | back-end from an existing one. | ||
| 16708 | |||
| 16709 | When creating a new back-end from scratch, the basic idea is to set the name | ||
| 16710 | of the back-end (as a symbol) and an an alist of elements and export | ||
| 16711 | functions. On top of this, you will need to set additional keywords like | ||
| 16712 | @code{:menu-entry} (to display the back-end in the export dispatcher), | ||
| 16713 | @code{:export-block} (to specify what blocks should not be exported by this | ||
| 16714 | back-end), and @code{:options-alist} (to let the user set export options that | ||
| 16715 | are specific to this back-end.) | ||
| 16716 | |||
| 16717 | Deriving a new back-end is similar, except that you need to set | ||
| 16718 | @code{:translate-alist} to an alist of export functions that should be used | ||
| 16719 | instead of the parent back-end functions. | ||
| 16720 | |||
| 16721 | For a complete reference documentation, see | ||
| 16722 | @url{http://orgmode.org/worg/dev/org-export-reference.html, the Org Export | ||
| 16723 | Reference on Worg}. | ||
| 16724 | |||
| 16725 | @node Context-sensitive commands, Tables in arbitrary syntax, Adding export back-ends, Hacking | ||
| 15631 | @section Context-sensitive commands | 16726 | @section Context-sensitive commands |
| 15632 | @cindex context-sensitive commands, hooks | 16727 | @cindex context-sensitive commands, hooks |
| 15633 | @cindex add-ons, context-sensitive commands | 16728 | @cindex add-ons, context-sensitive commands |
| @@ -15696,7 +16791,7 @@ can use Org's facilities to edit and structure lists by turning | |||
| 15696 | * Radio tables:: Sending and receiving radio tables | 16791 | * Radio tables:: Sending and receiving radio tables |
| 15697 | * A @LaTeX{} example:: Step by step, almost a tutorial | 16792 | * A @LaTeX{} example:: Step by step, almost a tutorial |
| 15698 | * Translator functions:: Copy and modify | 16793 | * Translator functions:: Copy and modify |
| 15699 | * Radio lists:: Doing the same for lists | 16794 | * Radio lists:: Sending and receiving lists |
| 15700 | @end menu | 16795 | @end menu |
| 15701 | 16796 | ||
| 15702 | @node Radio tables, A @LaTeX{} example, Tables in arbitrary syntax, Tables in arbitrary syntax | 16797 | @node Radio tables, A @LaTeX{} example, Tables in arbitrary syntax, Tables in arbitrary syntax |
| @@ -15704,9 +16799,10 @@ can use Org's facilities to edit and structure lists by turning | |||
| 15704 | @cindex radio tables | 16799 | @cindex radio tables |
| 15705 | 16800 | ||
| 15706 | To define the location of the target table, you first need to create two | 16801 | To define the location of the target table, you first need to create two |
| 15707 | lines that are comments in the current mode, but contain magic words for | 16802 | lines that are comments in the current mode, but contain magic words |
| 15708 | Orgtbl mode to find. Orgtbl mode will insert the translated table | 16803 | @code{BEGIN/END RECEIVE ORGTBL} for Orgtbl mode to find. Orgtbl mode will |
| 15709 | between these lines, replacing whatever was there before. For example: | 16804 | insert the translated table between these lines, replacing whatever was there |
| 16805 | before. For example in C mode where comments are between @code{/* ... */}: | ||
| 15710 | 16806 | ||
| 15711 | @example | 16807 | @example |
| 15712 | /* BEGIN RECEIVE ORGTBL table_name */ | 16808 | /* BEGIN RECEIVE ORGTBL table_name */ |
| @@ -15744,8 +16840,8 @@ removal of these columns, the function never knows that there have been | |||
| 15744 | additional columns. | 16840 | additional columns. |
| 15745 | 16841 | ||
| 15746 | @item :no-escape t | 16842 | @item :no-escape t |
| 15747 | When non-nil, do not escape special characters @code{&%#_^} when exporting | 16843 | When non-@code{nil}, do not escape special characters @code{&%#_^} when exporting |
| 15748 | the table. The default value is nil. | 16844 | the table. The default value is @code{nil}. |
| 15749 | @end table | 16845 | @end table |
| 15750 | 16846 | ||
| 15751 | @noindent | 16847 | @noindent |
| @@ -15766,7 +16862,7 @@ in @LaTeX{}. | |||
| 15766 | @item | 16862 | @item |
| 15767 | You can just comment the table line-by-line whenever you want to process | 16863 | You can just comment the table line-by-line whenever you want to process |
| 15768 | the file, and uncomment it whenever you need to edit the table. This | 16864 | the file, and uncomment it whenever you need to edit the table. This |
| 15769 | only sounds tedious---the command @kbd{M-x orgtbl-toggle-comment} | 16865 | only sounds tedious---the command @kbd{M-x orgtbl-toggle-comment RET} |
| 15770 | makes this comment-toggling very easy, in particular if you bind it to a | 16866 | makes this comment-toggling very easy, in particular if you bind it to a |
| 15771 | key. | 16867 | key. |
| 15772 | @end itemize | 16868 | @end itemize |
| @@ -15780,8 +16876,8 @@ The best way to wrap the source table in @LaTeX{} is to use the | |||
| 15780 | activated by placing @code{\usepackage@{comment@}} into the document | 16876 | activated by placing @code{\usepackage@{comment@}} into the document |
| 15781 | header. Orgtbl mode can insert a radio table skeleton@footnote{By | 16877 | header. Orgtbl mode can insert a radio table skeleton@footnote{By |
| 15782 | default this works only for @LaTeX{}, HTML, and Texinfo. Configure the | 16878 | default this works only for @LaTeX{}, HTML, and Texinfo. Configure the |
| 15783 | variable @code{orgtbl-radio-tables} to install templates for other | 16879 | variable @code{orgtbl-radio-table-templates} to install templates for other |
| 15784 | modes.} with the command @kbd{M-x orgtbl-insert-radio-table}. You will | 16880 | modes.} with the command @kbd{M-x orgtbl-insert-radio-table RET}. You will |
| 15785 | be prompted for a table name, let's say we use @samp{salesfigures}. You | 16881 | be prompted for a table name, let's say we use @samp{salesfigures}. You |
| 15786 | will then get the following template: | 16882 | will then get the following template: |
| 15787 | 16883 | ||
| @@ -15860,7 +16956,7 @@ interprets the following parameters (see also @pxref{Translator functions}): | |||
| 15860 | @table @code | 16956 | @table @code |
| 15861 | @item :splice nil/t | 16957 | @item :splice nil/t |
| 15862 | When set to t, return only table body lines, don't wrap them into a | 16958 | When set to t, return only table body lines, don't wrap them into a |
| 15863 | tabular environment. Default is nil. | 16959 | tabular environment. Default is @code{nil}. |
| 15864 | 16960 | ||
| 15865 | @item :fmt fmt | 16961 | @item :fmt fmt |
| 15866 | A format to be used to wrap each field, it should contain @code{%s} for the | 16962 | A format to be used to wrap each field, it should contain @code{%s} for the |
| @@ -16052,7 +17148,7 @@ The corresponding block writer function could look like this: | |||
| 16052 | (defun org-dblock-write:block-update-time (params) | 17148 | (defun org-dblock-write:block-update-time (params) |
| 16053 | (let ((fmt (or (plist-get params :format) "%d. %m. %Y"))) | 17149 | (let ((fmt (or (plist-get params :format) "%d. %m. %Y"))) |
| 16054 | (insert "Last block update at: " | 17150 | (insert "Last block update at: " |
| 16055 | (format-time-string fmt (current-time))))) | 17151 | (format-time-string fmt (current-time))))) |
| 16056 | @end lisp | 17152 | @end lisp |
| 16057 | 17153 | ||
| 16058 | If you want to make sure that all dynamic blocks are always up-to-date, | 17154 | If you want to make sure that all dynamic blocks are always up-to-date, |
| @@ -16064,21 +17160,25 @@ written in a way such that it does nothing in buffers that are not in | |||
| 16064 | You can narrow the current buffer to the current dynamic block (like any | 17160 | You can narrow the current buffer to the current dynamic block (like any |
| 16065 | other block) with @code{org-narrow-to-block}. | 17161 | other block) with @code{org-narrow-to-block}. |
| 16066 | 17162 | ||
| 16067 | @node Special agenda views, Extracting agenda information, Dynamic blocks, Hacking | 17163 | @node Special agenda views, Speeding up your agendas, Dynamic blocks, Hacking |
| 16068 | @section Special agenda views | 17164 | @section Special agenda views |
| 16069 | @cindex agenda views, user-defined | 17165 | @cindex agenda views, user-defined |
| 16070 | 17166 | ||
| 16071 | @vindex org-agenda-skip-function | 17167 | @vindex org-agenda-skip-function |
| 16072 | @vindex org-agenda-skip-function-global | 17168 | @vindex org-agenda-skip-function-global |
| 16073 | Org provides a special hook that can be used to narrow down the selection | 17169 | Org provides a special hook that can be used to narrow down the selection |
| 16074 | made by these agenda views: @code{agenda}, @code{todo}, @code{alltodo}, | 17170 | made by these agenda views: @code{agenda}, @code{agenda*}@footnote{The |
| 16075 | @code{tags}, @code{tags-todo}, @code{tags-tree}. You may specify a function | 17171 | @code{agenda*} view is the same than @code{agenda} except that it only |
| 16076 | that is used at each match to verify if the match should indeed be part of | 17172 | considers @emph{appointments}, i.e., scheduled and deadline items that have a |
| 16077 | the agenda view, and if not, how much should be skipped. You can specify a | 17173 | time specification @code{[h]h:mm} in their time-stamps.}, @code{todo}, |
| 16078 | global condition that will be applied to all agenda views, this condition | 17174 | @code{alltodo}, @code{tags}, @code{tags-todo}, @code{tags-tree}. You may |
| 16079 | would be stored in the variable @code{org-agenda-skip-function-global}. More | 17175 | specify a function that is used at each match to verify if the match should |
| 16080 | commonly, such a definition is applied only to specific custom searches, | 17176 | indeed be part of the agenda view, and if not, how much should be skipped. |
| 16081 | using @code{org-agenda-skip-function}. | 17177 | You can specify a global condition that will be applied to all agenda views, |
| 17178 | this condition would be stored in the variable | ||
| 17179 | @code{org-agenda-skip-function-global}. More commonly, such a definition is | ||
| 17180 | applied only to specific custom searches, using | ||
| 17181 | @code{org-agenda-skip-function}. | ||
| 16082 | 17182 | ||
| 16083 | Let's say you want to produce a list of projects that contain a WAITING | 17183 | Let's say you want to produce a list of projects that contain a WAITING |
| 16084 | tag anywhere in the project tree. Let's further assume that you have | 17184 | tag anywhere in the project tree. Let's further assume that you have |
| @@ -16165,7 +17265,48 @@ like this, even without defining a special function: | |||
| 16165 | (org-agenda-overriding-header "Projects waiting for something: ")))) | 17265 | (org-agenda-overriding-header "Projects waiting for something: ")))) |
| 16166 | @end lisp | 17266 | @end lisp |
| 16167 | 17267 | ||
| 16168 | @node Extracting agenda information, Using the property API, Special agenda views, Hacking | 17268 | @node Speeding up your agendas, Extracting agenda information, Special agenda views, Hacking |
| 17269 | @section Speeding up your agendas | ||
| 17270 | @cindex agenda views, optimization | ||
| 17271 | |||
| 17272 | When your Org files grow in both number and size, agenda commands may start | ||
| 17273 | to become slow. Below are some tips on how to speed up the agenda commands. | ||
| 17274 | |||
| 17275 | @enumerate | ||
| 17276 | @item | ||
| 17277 | Reduce the number of Org agenda files: this will reduce the slowliness caused | ||
| 17278 | by accessing to a hard drive. | ||
| 17279 | @item | ||
| 17280 | Reduce the number of DONE and archived headlines: this way the agenda does | ||
| 17281 | not need to skip them. | ||
| 17282 | @item | ||
| 17283 | @vindex org-agenda-dim-blocked-tasks | ||
| 17284 | Inhibit the dimming of blocked tasks: | ||
| 17285 | @lisp | ||
| 17286 | (setq org-agenda-dim-blocked-tasks nil) | ||
| 17287 | @end lisp | ||
| 17288 | @item | ||
| 17289 | @vindex org-startup-folded | ||
| 17290 | @vindex org-agenda-inhibit-startup | ||
| 17291 | Inhibit agenda files startup options: | ||
| 17292 | @lisp | ||
| 17293 | (setq org-agenda-inhibit-startup nil) | ||
| 17294 | @end lisp | ||
| 17295 | @item | ||
| 17296 | @vindex org-agenda-show-inherited-tags | ||
| 17297 | @vindex org-agenda-use-tag-inheritance | ||
| 17298 | Disable tag inheritance in agenda: | ||
| 17299 | @lisp | ||
| 17300 | (setq org-agenda-use-tag-inheritance nil) | ||
| 17301 | @end lisp | ||
| 17302 | @end enumerate | ||
| 17303 | |||
| 17304 | You can set these options for specific agenda views only. See the docstrings | ||
| 17305 | of these variables for details on why they affect the agenda generation, and | ||
| 17306 | this @uref{http://orgmode.org/worg/agenda-optimization.html, dedicated Worg | ||
| 17307 | page} for further explanations. | ||
| 17308 | |||
| 17309 | @node Extracting agenda information, Using the property API, Speeding up your agendas, Hacking | ||
| 16169 | @section Extracting agenda information | 17310 | @section Extracting agenda information |
| 16170 | @cindex agenda, pipe | 17311 | @cindex agenda, pipe |
| 16171 | @cindex Scripts, for agenda processing | 17312 | @cindex Scripts, for agenda processing |
| @@ -16282,27 +17423,27 @@ This includes the TODO keyword, the tags, time strings for deadline, | |||
| 16282 | scheduled, and clocking, and any additional properties defined in the | 17423 | scheduled, and clocking, and any additional properties defined in the |
| 16283 | entry. The return value is an alist. Keys may occur multiple times | 17424 | entry. The return value is an alist. Keys may occur multiple times |
| 16284 | if the property key was used several times.@* | 17425 | if the property key was used several times.@* |
| 16285 | POM may also be nil, in which case the current entry is used. | 17426 | POM may also be @code{nil}, in which case the current entry is used. |
| 16286 | If WHICH is nil or `all', get all properties. If WHICH is | 17427 | If WHICH is @code{nil} or `all', get all properties. If WHICH is |
| 16287 | `special' or `standard', only get that subclass. | 17428 | `special' or `standard', only get that subclass. |
| 16288 | @end defun | 17429 | @end defun |
| 16289 | @vindex org-use-property-inheritance | 17430 | @vindex org-use-property-inheritance |
| 16290 | @findex org-insert-property-drawer | 17431 | @findex org-insert-property-drawer |
| 16291 | @defun org-entry-get pom property &optional inherit | 17432 | @defun org-entry-get pom property &optional inherit |
| 16292 | Get value of PROPERTY for entry at point-or-marker POM@. By default, | 17433 | Get value of @code{PROPERTY} for entry at point-or-marker @code{POM}@. By default, |
| 16293 | this only looks at properties defined locally in the entry. If INHERIT | 17434 | this only looks at properties defined locally in the entry. If @code{INHERIT} |
| 16294 | is non-nil and the entry does not have the property, then also check | 17435 | is non-@code{nil} and the entry does not have the property, then also check |
| 16295 | higher levels of the hierarchy. If INHERIT is the symbol | 17436 | higher levels of the hierarchy. If @code{INHERIT} is the symbol |
| 16296 | @code{selective}, use inheritance if and only if the setting of | 17437 | @code{selective}, use inheritance if and only if the setting of |
| 16297 | @code{org-use-property-inheritance} selects PROPERTY for inheritance. | 17438 | @code{org-use-property-inheritance} selects @code{PROPERTY} for inheritance. |
| 16298 | @end defun | 17439 | @end defun |
| 16299 | 17440 | ||
| 16300 | @defun org-entry-delete pom property | 17441 | @defun org-entry-delete pom property |
| 16301 | Delete the property PROPERTY from entry at point-or-marker POM. | 17442 | Delete the property @code{PROPERTY} from entry at point-or-marker POM. |
| 16302 | @end defun | 17443 | @end defun |
| 16303 | 17444 | ||
| 16304 | @defun org-entry-put pom property value | 17445 | @defun org-entry-put pom property value |
| 16305 | Set PROPERTY to VALUE for entry at point-or-marker POM. | 17446 | Set @code{PROPERTY} to @code{VALUE} for entry at point-or-marker POM. |
| 16306 | @end defun | 17447 | @end defun |
| 16307 | 17448 | ||
| 16308 | @defun org-buffer-property-keys &optional include-specials | 17449 | @defun org-buffer-property-keys &optional include-specials |
| @@ -16314,28 +17455,29 @@ Insert a property drawer for the current entry. Also | |||
| 16314 | @end defun | 17455 | @end defun |
| 16315 | 17456 | ||
| 16316 | @defun org-entry-put-multivalued-property pom property &rest values | 17457 | @defun org-entry-put-multivalued-property pom property &rest values |
| 16317 | Set PROPERTY at point-or-marker POM to VALUES@. VALUES should be a list of | 17458 | Set @code{PROPERTY} at point-or-marker @code{POM} to @code{VALUES}@. |
| 16318 | strings. They will be concatenated, with spaces as separators. | 17459 | @code{VALUES} should be a list of strings. They will be concatenated, with |
| 17460 | spaces as separators. | ||
| 16319 | @end defun | 17461 | @end defun |
| 16320 | 17462 | ||
| 16321 | @defun org-entry-get-multivalued-property pom property | 17463 | @defun org-entry-get-multivalued-property pom property |
| 16322 | Treat the value of the property PROPERTY as a whitespace-separated list of | 17464 | Treat the value of the property @code{PROPERTY} as a whitespace-separated |
| 16323 | values and return the values as a list of strings. | 17465 | list of values and return the values as a list of strings. |
| 16324 | @end defun | 17466 | @end defun |
| 16325 | 17467 | ||
| 16326 | @defun org-entry-add-to-multivalued-property pom property value | 17468 | @defun org-entry-add-to-multivalued-property pom property value |
| 16327 | Treat the value of the property PROPERTY as a whitespace-separated list of | 17469 | Treat the value of the property @code{PROPERTY} as a whitespace-separated |
| 16328 | values and make sure that VALUE is in this list. | 17470 | list of values and make sure that @code{VALUE} is in this list. |
| 16329 | @end defun | 17471 | @end defun |
| 16330 | 17472 | ||
| 16331 | @defun org-entry-remove-from-multivalued-property pom property value | 17473 | @defun org-entry-remove-from-multivalued-property pom property value |
| 16332 | Treat the value of the property PROPERTY as a whitespace-separated list of | 17474 | Treat the value of the property @code{PROPERTY} as a whitespace-separated |
| 16333 | values and make sure that VALUE is @emph{not} in this list. | 17475 | list of values and make sure that @code{VALUE} is @emph{not} in this list. |
| 16334 | @end defun | 17476 | @end defun |
| 16335 | 17477 | ||
| 16336 | @defun org-entry-member-in-multivalued-property pom property value | 17478 | @defun org-entry-member-in-multivalued-property pom property value |
| 16337 | Treat the value of the property PROPERTY as a whitespace-separated list of | 17479 | Treat the value of the property @code{PROPERTY} as a whitespace-separated |
| 16338 | values and check if VALUE is in this list. | 17480 | list of values and check if @code{VALUE} is in this list. |
| 16339 | @end defun | 17481 | @end defun |
| 16340 | 17482 | ||
| 16341 | @defopt org-property-allowed-value-functions | 17483 | @defopt org-property-allowed-value-functions |
| @@ -16359,30 +17501,29 @@ functions for each or selected entries. The main entry point for this API | |||
| 16359 | is: | 17501 | is: |
| 16360 | 17502 | ||
| 16361 | @defun org-map-entries func &optional match scope &rest skip | 17503 | @defun org-map-entries func &optional match scope &rest skip |
| 16362 | Call FUNC at each headline selected by MATCH in SCOPE. | 17504 | Call @code{FUNC} at each headline selected by @code{MATCH} in @code{SCOPE}. |
| 16363 | 17505 | ||
| 16364 | FUNC is a function or a Lisp form. The function will be called without | 17506 | @code{FUNC} is a function or a Lisp form. The function will be called |
| 16365 | arguments, with the cursor positioned at the beginning of the headline. | 17507 | without arguments, with the cursor positioned at the beginning of the |
| 16366 | The return values of all calls to the function will be collected and | 17508 | headline. The return values of all calls to the function will be collected |
| 16367 | returned as a list. | 17509 | and returned as a list. |
| 16368 | 17510 | ||
| 16369 | The call to FUNC will be wrapped into a save-excursion form, so FUNC | 17511 | The call to @code{FUNC} will be wrapped into a save-excursion form, so |
| 16370 | does not need to preserve point. After evaluation, the cursor will be | 17512 | @code{FUNC} does not need to preserve point. After evaluation, the cursor |
| 16371 | moved to the end of the line (presumably of the headline of the | 17513 | will be moved to the end of the line (presumably of the headline of the |
| 16372 | processed entry) and search continues from there. Under some | 17514 | processed entry) and search continues from there. Under some circumstances, |
| 16373 | circumstances, this may not produce the wanted results. For example, | 17515 | this may not produce the wanted results. For example, if you have removed |
| 16374 | if you have removed (e.g., archived) the current (sub)tree it could | 17516 | (e.g., archived) the current (sub)tree it could mean that the next entry will |
| 16375 | mean that the next entry will be skipped entirely. In such cases, you | 17517 | be skipped entirely. In such cases, you can specify the position from where |
| 16376 | can specify the position from where search should continue by making | 17518 | search should continue by making @code{FUNC} set the variable |
| 16377 | FUNC set the variable `org-map-continue-from' to the desired buffer | 17519 | @code{org-map-continue-from} to the desired buffer position. |
| 16378 | position. | ||
| 16379 | 17520 | ||
| 16380 | MATCH is a tags/property/todo match as it is used in the agenda match view. | 17521 | @code{MATCH} is a tags/property/todo match as it is used in the agenda match |
| 16381 | Only headlines that are matched by this query will be considered during | 17522 | view. Only headlines that are matched by this query will be considered |
| 16382 | the iteration. When MATCH is nil or t, all headlines will be | 17523 | during the iteration. When @code{MATCH} is @code{nil} or @code{t}, all |
| 16383 | visited by the iteration. | 17524 | headlines will be visited by the iteration. |
| 16384 | 17525 | ||
| 16385 | SCOPE determines the scope of this command. It can be any of: | 17526 | @code{SCOPE} determines the scope of this command. It can be any of: |
| 16386 | 17527 | ||
| 16387 | @example | 17528 | @example |
| 16388 | nil @r{the current buffer, respecting the restriction if any} | 17529 | nil @r{the current buffer, respecting the restriction if any} |
| @@ -16420,17 +17561,18 @@ Here are a couple of functions that might be handy: | |||
| 16420 | 17561 | ||
| 16421 | @defun org-todo &optional arg | 17562 | @defun org-todo &optional arg |
| 16422 | Change the TODO state of the entry. See the docstring of the functions for | 17563 | Change the TODO state of the entry. See the docstring of the functions for |
| 16423 | the many possible values for the argument ARG. | 17564 | the many possible values for the argument @code{ARG}. |
| 16424 | @end defun | 17565 | @end defun |
| 16425 | 17566 | ||
| 16426 | @defun org-priority &optional action | 17567 | @defun org-priority &optional action |
| 16427 | Change the priority of the entry. See the docstring of this function for the | 17568 | Change the priority of the entry. See the docstring of this function for the |
| 16428 | possible values for ACTION. | 17569 | possible values for @code{ACTION}. |
| 16429 | @end defun | 17570 | @end defun |
| 16430 | 17571 | ||
| 16431 | @defun org-toggle-tag tag &optional onoff | 17572 | @defun org-toggle-tag tag &optional onoff |
| 16432 | Toggle the tag TAG in the current entry. Setting ONOFF to either @code{on} | 17573 | Toggle the tag @code{TAG} in the current entry. Setting @code{ONOFF} to |
| 16433 | or @code{off} will not toggle tag, but ensure that it is either on or off. | 17574 | either @code{on} or @code{off} will not toggle tag, but ensure that it is |
| 17575 | either on or off. | ||
| 16434 | @end defun | 17576 | @end defun |
| 16435 | 17577 | ||
| 16436 | @defun org-promote | 17578 | @defun org-promote |
| @@ -16466,10 +17608,10 @@ The following example counts the number of entries with TODO keyword | |||
| 16466 | @i{MobileOrg} is the name of the mobile companion app for Org mode, currently | 17608 | @i{MobileOrg} is the name of the mobile companion app for Org mode, currently |
| 16467 | available for iOS and for Android. @i{MobileOrg} offers offline viewing and | 17609 | available for iOS and for Android. @i{MobileOrg} offers offline viewing and |
| 16468 | capture support for an Org mode system rooted on a ``real'' computer. It | 17610 | capture support for an Org mode system rooted on a ``real'' computer. It |
| 16469 | does also allow you to record changes to existing entries. | 17611 | does also allow you to record changes to existing entries. The |
| 16470 | The @uref{http://mobileorg.ncogni.to/, iOS implementation} for the | 17612 | @uref{https://github.com/MobileOrg/, iOS implementation} for the |
| 16471 | @i{iPhone/iPod Touch/iPad} series of devices, was developed by Richard | 17613 | @i{iPhone/iPod Touch/iPad} series of devices, was started by Richard Moreland |
| 16472 | Moreland. Android users should check out | 17614 | and is now in the hands Sean Escriva. Android users should check out |
| 16473 | @uref{http://wiki.github.com/matburt/mobileorg-android/, MobileOrg Android} | 17615 | @uref{http://wiki.github.com/matburt/mobileorg-android/, MobileOrg Android} |
| 16474 | by Matt Jones. The two implementations are not identical but offer similar | 17616 | by Matt Jones. The two implementations are not identical but offer similar |
| 16475 | features. | 17617 | features. |
| @@ -16479,7 +17621,7 @@ format that can be displayed by @i{MobileOrg}, and for integrating notes | |||
| 16479 | captured and changes made by @i{MobileOrg} into the main system. | 17621 | captured and changes made by @i{MobileOrg} into the main system. |
| 16480 | 17622 | ||
| 16481 | For changing tags and TODO states in MobileOrg, you should have set up the | 17623 | For changing tags and TODO states in MobileOrg, you should have set up the |
| 16482 | customization variables @code{org-todo-keywords} and @code{org-tags-alist} to | 17624 | customization variables @code{org-todo-keywords} and @code{org-tag-alist} to |
| 16483 | cover all important tags and TODO keywords, even if individual files use only | 17625 | cover all important tags and TODO keywords, even if individual files use only |
| 16484 | part of these. MobileOrg will also offer you states and tags set up with | 17626 | part of these. MobileOrg will also offer you states and tags set up with |
| 16485 | in-buffer settings, but it will understand the logistics of TODO state | 17627 | in-buffer settings, but it will understand the logistics of TODO state |
| @@ -16580,6 +17722,7 @@ should then go through these entries and do whatever actions are necessary. | |||
| 16580 | If a note has been stored while flagging an entry in @i{MobileOrg}, that note | 17722 | If a note has been stored while flagging an entry in @i{MobileOrg}, that note |
| 16581 | will be displayed in the echo area when the cursor is on the corresponding | 17723 | will be displayed in the echo area when the cursor is on the corresponding |
| 16582 | agenda line. | 17724 | agenda line. |
| 17725 | |||
| 16583 | @table @kbd | 17726 | @table @kbd |
| 16584 | @kindex ? | 17727 | @kindex ? |
| 16585 | @item ? | 17728 | @item ? |
| @@ -16596,11 +17739,11 @@ this flagged entry is finished. | |||
| 16596 | @kindex C-c a ? | 17739 | @kindex C-c a ? |
| 16597 | If you are not able to process all flagged entries directly, you can always | 17740 | If you are not able to process all flagged entries directly, you can always |
| 16598 | return to this agenda view@footnote{Note, however, that there is a subtle | 17741 | return to this agenda view@footnote{Note, however, that there is a subtle |
| 16599 | difference. The view created automatically by @kbd{M-x org-mobile-pull | 17742 | difference. The view created automatically by @kbd{M-x org-mobile-pull RET} |
| 16600 | @key{RET}} is guaranteed to search all files that have been addressed by the | 17743 | is guaranteed to search all files that have been addressed by the last pull. |
| 16601 | last pull. This might include a file that is not currently in your list of | 17744 | This might include a file that is not currently in your list of agenda files. |
| 16602 | agenda files. If you later use @kbd{C-c a ?} to regenerate the view, only | 17745 | If you later use @kbd{C-c a ?} to regenerate the view, only the current |
| 16603 | the current agenda files will be searched.} using @kbd{C-c a ?}. | 17746 | agenda files will be searched.} using @kbd{C-c a ?}. |
| 16604 | 17747 | ||
| 16605 | @node History and Acknowledgments, GNU Free Documentation License, MobileOrg, Top | 17748 | @node History and Acknowledgments, GNU Free Documentation License, MobileOrg, Top |
| 16606 | @appendix History and acknowledgments | 17749 | @appendix History and acknowledgments |
| @@ -16660,7 +17803,7 @@ of his great @file{remember.el}. | |||
| 16660 | Without Sebastian, the HTML/XHTML publishing of Org would be the pitiful work | 17803 | Without Sebastian, the HTML/XHTML publishing of Org would be the pitiful work |
| 16661 | of an ignorant amateur. Sebastian has pushed this part of Org onto a much | 17804 | of an ignorant amateur. Sebastian has pushed this part of Org onto a much |
| 16662 | higher level. He also wrote @file{org-info.js}, a Java script for displaying | 17805 | higher level. He also wrote @file{org-info.js}, a Java script for displaying |
| 16663 | webpages derived from Org using an Info-like or a folding interface with | 17806 | web pages derived from Org using an Info-like or a folding interface with |
| 16664 | single-key navigation. | 17807 | single-key navigation. |
| 16665 | @end table | 17808 | @end table |
| 16666 | 17809 | ||
| @@ -16674,8 +17817,8 @@ would not be complete without adding a few more acknowledgements and thanks | |||
| 16674 | to Carsten's ones above. | 17817 | to Carsten's ones above. |
| 16675 | 17818 | ||
| 16676 | I am first grateful to Carsten for his trust while handing me over the | 17819 | I am first grateful to Carsten for his trust while handing me over the |
| 16677 | maintainership of Org. His support as been great since day one of this new | 17820 | maintainership of Org. His unremitting support is what really helped me |
| 16678 | adventure, and it helped a lot. | 17821 | getting more confident over time, with both the community and the code. |
| 16679 | 17822 | ||
| 16680 | When I took over maintainership, I knew I would have to make Org more | 17823 | When I took over maintainership, I knew I would have to make Org more |
| 16681 | collaborative than ever, as I would have to rely on people that are more | 17824 | collaborative than ever, as I would have to rely on people that are more |
| @@ -16689,15 +17832,13 @@ Eric is maintaining the Babel parts of Org. His reactivity here kept me away | |||
| 16689 | from worrying about possible bugs here and let me focus on other parts. | 17832 | from worrying about possible bugs here and let me focus on other parts. |
| 16690 | 17833 | ||
| 16691 | @item Nicolas Goaziou | 17834 | @item Nicolas Goaziou |
| 16692 | Nicolas is maintaining the consistency of the deepest parts of Org. His work | 17835 | Nicolas is maintaining the consistency of the deepest parts of Org. His |
| 16693 | on @file{org-element.el} and @file{org-export.el} has been outstanding, and | 17836 | work on @file{org-element.el} and @file{ox.el} has been outstanding, and |
| 16694 | opened the doors for many new ideas and features. | 17837 | opened the doors for many new ideas and features. He rewrote many of the |
| 16695 | 17838 | old exporters to use the new export engine, and helped with documenting | |
| 16696 | @item Jambunathan K | 17839 | this major change. More importantly (if that's possible), he has been more |
| 16697 | Jambunathan contributed the ODT exporter, definitely a killer feature of | 17840 | than reliable during all the work done for Org 8.0, and always very |
| 16698 | Org mode. He also contributed the new HTML exporter, which is another core | 17841 | reactive on the mailing list. |
| 16699 | feature of Org. Here too, I knew I could rely on him to fix bugs in these | ||
| 16700 | areas and to patiently explain the users what was the problems and solutions. | ||
| 16701 | 17842 | ||
| 16702 | @item Achim Gratz | 17843 | @item Achim Gratz |
| 16703 | Achim rewrote the building process of Org, turning some @emph{ad hoc} tools | 17844 | Achim rewrote the building process of Org, turning some @emph{ad hoc} tools |
| @@ -16721,8 +17862,17 @@ complete if the ones above were not mentioned in this manual. | |||
| 16721 | @item | 17862 | @item |
| 16722 | @i{Russel Adams} came up with the idea for drawers. | 17863 | @i{Russel Adams} came up with the idea for drawers. |
| 16723 | @item | 17864 | @item |
| 17865 | @i{Suvayu Ali} has steadily helped on the mailing list, providing useful | ||
| 17866 | feedback on many features and several patches. | ||
| 17867 | @item | ||
| 17868 | @i{Luis Anaya} wrote @file{ox-man.el}. | ||
| 17869 | @item | ||
| 16724 | @i{Thomas Baumann} wrote @file{org-bbdb.el} and @file{org-mhe.el}. | 17870 | @i{Thomas Baumann} wrote @file{org-bbdb.el} and @file{org-mhe.el}. |
| 16725 | @item | 17871 | @item |
| 17872 | @i{Michael Brand} helped by reporting many bugs and testing many features. | ||
| 17873 | He also implemented the distinction between empty fields and 0-value fields | ||
| 17874 | in Org's spreadsheets. | ||
| 17875 | @item | ||
| 16726 | @i{Christophe Bataillon} created the great unicorn logo that we use on the | 17876 | @i{Christophe Bataillon} created the great unicorn logo that we use on the |
| 16727 | Org mode website. | 17877 | Org mode website. |
| 16728 | @item | 17878 | @item |
| @@ -16746,7 +17896,11 @@ calculations and improved XEmacs compatibility, in particular by porting | |||
| 16746 | @item | 17896 | @item |
| 16747 | @i{Sacha Chua} suggested copying some linking code from Planner. | 17897 | @i{Sacha Chua} suggested copying some linking code from Planner. |
| 16748 | @item | 17898 | @item |
| 16749 | @i{Baoqiu Cui} contributed the DocBook exporter. | 17899 | @i{Toby S. Cubitt} contributed to the code for clock formats. |
| 17900 | @item | ||
| 17901 | @i{Baoqiu Cui} contributed the DocBook exporter. It has been deleted from | ||
| 17902 | Org 8.0: you can now export to Texinfo and export the @file{.texi} file to | ||
| 17903 | DocBook using @code{makeinfo}. | ||
| 16750 | @item | 17904 | @item |
| 16751 | @i{Eddward DeVilla} proposed and tested checkbox statistics. He also | 17905 | @i{Eddward DeVilla} proposed and tested checkbox statistics. He also |
| 16752 | came up with the idea of properties, and that there should be an API for | 17906 | came up with the idea of properties, and that there should be an API for |
| @@ -16758,16 +17912,23 @@ them. | |||
| 16758 | inspired some of the early development, including HTML export. He also | 17912 | inspired some of the early development, including HTML export. He also |
| 16759 | asked for a way to narrow wide table columns. | 17913 | asked for a way to narrow wide table columns. |
| 16760 | @item | 17914 | @item |
| 17915 | @i{Jason Dunsmore} has been maintaining the Org-Mode server at Rackspace for | ||
| 17916 | several years now. He also sponsered the hosting costs until Rackspace | ||
| 17917 | started to host us for free. | ||
| 17918 | @item | ||
| 16761 | @i{Thomas S. Dye} contributed documentation on Worg and helped integrating | 17919 | @i{Thomas S. Dye} contributed documentation on Worg and helped integrating |
| 16762 | the Org-Babel documentation into the manual. | 17920 | the Org-Babel documentation into the manual. |
| 16763 | @item | 17921 | @item |
| 16764 | @i{Christian Egli} converted the documentation into Texinfo format, inspired | 17922 | @i{Christian Egli} converted the documentation into Texinfo format, inspired |
| 16765 | the agenda, patched CSS formatting into the HTML exporter, and wrote | 17923 | the agenda, patched CSS formatting into the HTML exporter, and wrote |
| 16766 | @file{org-taskjuggler.el}. | 17924 | @file{org-taskjuggler.el}, which has been rewritten by Nicolas Goaziou as |
| 17925 | @file{ox-taskjuggler.el} for Org 8.0. | ||
| 16767 | @item | 17926 | @item |
| 16768 | @i{David Emery} provided a patch for custom CSS support in exported | 17927 | @i{David Emery} provided a patch for custom CSS support in exported |
| 16769 | HTML agendas. | 17928 | HTML agendas. |
| 16770 | @item | 17929 | @item |
| 17930 | @i{Sean Escriva} took over MobileOrg development on the iPhone platform. | ||
| 17931 | @item | ||
| 16771 | @i{Nic Ferrier} contributed mailcap and XOXO support. | 17932 | @i{Nic Ferrier} contributed mailcap and XOXO support. |
| 16772 | @item | 17933 | @item |
| 16773 | @i{Miguel A. Figueroa-Villanueva} implemented hierarchical checkboxes. | 17934 | @i{Miguel A. Figueroa-Villanueva} implemented hierarchical checkboxes. |
| @@ -16789,7 +17950,9 @@ publication through Network Theory Ltd. | |||
| 16789 | @item | 17950 | @item |
| 16790 | @i{Niels Giesen} had the idea to automatically archive DONE trees. | 17951 | @i{Niels Giesen} had the idea to automatically archive DONE trees. |
| 16791 | @item | 17952 | @item |
| 16792 | @i{Nicolas Goaziou} rewrote much of the plain list code. | 17953 | @i{Nicolas Goaziou} rewrote much of the plain list code. He also wrote |
| 17954 | @file{org-element.el} and @file{org-export.el}, which was a huge step forward | ||
| 17955 | in implementing a clean framework for Org exporters. | ||
| 16793 | @item | 17956 | @item |
| 16794 | @i{Kai Grossjohann} pointed out key-binding conflicts with other packages. | 17957 | @i{Kai Grossjohann} pointed out key-binding conflicts with other packages. |
| 16795 | @item | 17958 | @item |
| @@ -16812,6 +17975,8 @@ folded entries, and column view for properties. | |||
| 16812 | @item | 17975 | @item |
| 16813 | @i{Tokuya Kameshima} wrote @file{org-wl.el} and @file{org-mew.el}. | 17976 | @i{Tokuya Kameshima} wrote @file{org-wl.el} and @file{org-mew.el}. |
| 16814 | @item | 17977 | @item |
| 17978 | @i{Jonathan Leech-Pepin} wrote @file{ox-texinfo.el}. | ||
| 17979 | @item | ||
| 16815 | @i{Shidai Liu} ("Leo") asked for embedded @LaTeX{} and tested it. He also | 17980 | @i{Shidai Liu} ("Leo") asked for embedded @LaTeX{} and tested it. He also |
| 16816 | provided frequent feedback and some patches. | 17981 | provided frequent feedback and some patches. |
| 16817 | @item | 17982 | @item |
| @@ -16824,7 +17989,7 @@ small fixes and patches. | |||
| 16824 | @item | 17989 | @item |
| 16825 | @i{Jason F. McBrayer} suggested agenda export to CSV format. | 17990 | @i{Jason F. McBrayer} suggested agenda export to CSV format. |
| 16826 | @item | 17991 | @item |
| 16827 | @i{Max Mikhanosha} came up with the idea of refiling. | 17992 | @i{Max Mikhanosha} came up with the idea of refiling and sticky agendas. |
| 16828 | @item | 17993 | @item |
| 16829 | @i{Dmitri Minaev} sent a patch to set priority limits on a per-file | 17994 | @i{Dmitri Minaev} sent a patch to set priority limits on a per-file |
| 16830 | basis. | 17995 | basis. |
| @@ -16858,9 +18023,14 @@ links, among other things. | |||
| 16858 | @i{Pete Phillips} helped during the development of the TAGS feature, and | 18023 | @i{Pete Phillips} helped during the development of the TAGS feature, and |
| 16859 | provided frequent feedback. | 18024 | provided frequent feedback. |
| 16860 | @item | 18025 | @item |
| 18026 | @i{Francesco Pizzolante} provided patches that helped speeding up the agenda | ||
| 18027 | generation. | ||
| 18028 | @item | ||
| 16861 | @i{Martin Pohlack} provided the code snippet to bundle character insertion | 18029 | @i{Martin Pohlack} provided the code snippet to bundle character insertion |
| 16862 | into bundles of 20 for undo. | 18030 | into bundles of 20 for undo. |
| 16863 | @item | 18031 | @item |
| 18032 | @i{Rackspace.com} is hosting our website for free. Thank you Rackspace! | ||
| 18033 | @item | ||
| 16864 | @i{T.V. Raman} reported bugs and suggested improvements. | 18034 | @i{T.V. Raman} reported bugs and suggested improvements. |
| 16865 | @item | 18035 | @item |
| 16866 | @i{Matthias Rempe} (Oelde) provided ideas, Windows support, and quality | 18036 | @i{Matthias Rempe} (Oelde) provided ideas, Windows support, and quality |
| @@ -16883,6 +18053,9 @@ of feedback, developed and applied standards to the Org documentation. | |||
| 16883 | @i{Christian Schlauer} proposed angular brackets around links, among | 18053 | @i{Christian Schlauer} proposed angular brackets around links, among |
| 16884 | other things. | 18054 | other things. |
| 16885 | @item | 18055 | @item |
| 18056 | @i{Christopher Schmidt} reworked @code{orgstruct-mode} so that users can | ||
| 18057 | enjoy folding in non-org buffers by using Org headlines in comments. | ||
| 18058 | @item | ||
| 16886 | @i{Paul Sexton} wrote @file{org-ctags.el}. | 18059 | @i{Paul Sexton} wrote @file{org-ctags.el}. |
| 16887 | @item | 18060 | @item |
| 16888 | Linking to VM/BBDB/Gnus was first inspired by @i{Tom Shannon}'s | 18061 | Linking to VM/BBDB/Gnus was first inspired by @i{Tom Shannon}'s |
| @@ -16914,7 +18087,7 @@ with links transformation to Org syntax. | |||
| 16914 | @i{David O'Toole} wrote @file{org-publish.el} and drafted the manual | 18087 | @i{David O'Toole} wrote @file{org-publish.el} and drafted the manual |
| 16915 | chapter about publishing. | 18088 | chapter about publishing. |
| 16916 | @item | 18089 | @item |
| 16917 | @i{Jambunathan K} contributed the ODT exporter. | 18090 | @i{Jambunathan K} contributed the ODT exporter and rewrote the HTML exporter. |
| 16918 | @item | 18091 | @item |
| 16919 | @i{Sebastien Vauban} reported many issues with @LaTeX{} and BEAMER export and | 18092 | @i{Sebastien Vauban} reported many issues with @LaTeX{} and BEAMER export and |
| 16920 | enabled source code highlighting in Gnus. | 18093 | enabled source code highlighting in Gnus. |