From ea1a2b9bd68d3dc52e2642cb160e83cde40dd9e1 Mon Sep 17 00:00:00 2001 From: Bernt Hansen Date: Wed, 14 Dec 2011 13:10:04 -0500 Subject: [PATCH 01/44] * doc/org.texi (Agenda commands): Document org-clock-report-include-clocking-task Add reference to this variable when describing the agenda clock report. --- doc/org.texi | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/doc/org.texi b/doc/org.texi index 93c8c5a38..04fa19974 100644 --- a/doc/org.texi +++ b/doc/org.texi @@ -7969,6 +7969,7 @@ press @kbd{v a} again. @c @orgcmdkskc{v R,R,org-agenda-clockreport-mode} @vindex org-agenda-start-with-clockreport-mode +@vindex org-clock-report-include-clocking-task Toggle Clockreport mode. In Clockreport mode, the daily/weekly agenda will always show a table with the clocked times for the timespan and file scope covered by the current agenda view. The initial setting for this mode in new @@ -7976,7 +7977,8 @@ agenda buffers can be set with the variable @code{org-agenda-start-with-clockreport-mode}. By using a prefix argument when toggling this mode (i.e.@: @kbd{C-u R}), the clock table will not show contributions from entries that are hidden by agenda filtering@footnote{Only -tags filtering will be respected here, effort filtering is ignored.}. +tags filtering will be respected here, effort filtering is ignored.}. See +also the variable @code{org-clock-report-include-clocking-task}. @c @orgkey{v c} @vindex org-agenda-clock-consistency-checks From d072aab7fea1a922750dc19688ec169487b730b7 Mon Sep 17 00:00:00 2001 From: Bastien Guerry Date: Wed, 14 Dec 2011 23:26:23 +0100 Subject: [PATCH 02/44] org.texi: Fix small typo. Thanks to Paul Eggert for fixing this in Emacs first. --- doc/org.texi | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/doc/org.texi b/doc/org.texi index 04fa19974..1d2babd58 100644 --- a/doc/org.texi +++ b/doc/org.texi @@ -13329,7 +13329,7 @@ block. E.g., @code{:results value html}. Results assumed to be LaTeX and are enclosed in a @code{begin_latex} block. E.g., @code{:results value latex}. @item @code{code} -Result are assumed to be parseable code and are enclosed in a code block. +Result are assumed to be parsable code and are enclosed in a code block. E.g., @code{:results value code}. @item @code{pp} The result is converted to pretty-printed code and is enclosed in a code From ba605e77d9e3c2e66ed787c97a08dc6ec184772f Mon Sep 17 00:00:00 2001 From: Jambunathan K Date: Thu, 15 Dec 2011 12:15:19 +0530 Subject: [PATCH 03/44] org-odt.el: Include author and date in the title * lisp/org-odt.el (org-export-odt-default-org-styles-alist): Add styles for title and subtitle. (org-odt-format-toc): New. (org-odt-format-preamble): New. Users can redefine this to customize what goes before the document body. Currently it outputs title, author and email, date and toc. (org-odt-begin-document-body): Use `org-odt-format-preamble'. (org-odt-format-date): Renamed from `org-odt-iso-date-from-org-timestamp'. Also added an additional param for format string. (org-odt-begin-annotation, org-odt-update-meta-file): Use `org-odt-format-date'. * etc/styles/OrgOdtStyles.xml (Title, OrgTitle, Subtitle) (OrgSubtitle): New styles for formatting title. --- etc/styles/OrgOdtStyles.xml | 18 ++++++++- lisp/org-odt.el | 81 ++++++++++++++++++++++++++++++------- 2 files changed, 83 insertions(+), 16 deletions(-) mode change 100644 => 100755 lisp/org-odt.el diff --git a/etc/styles/OrgOdtStyles.xml b/etc/styles/OrgOdtStyles.xml index 5ec868ac8..410b354ac 100644 --- a/etc/styles/OrgOdtStyles.xml +++ b/etc/styles/OrgOdtStyles.xml @@ -135,6 +135,22 @@ + + + + + + + + + + + + + + + + @@ -277,7 +293,7 @@ - + diff --git a/lisp/org-odt.el b/lisp/org-odt.el old mode 100644 new mode 100755 index 2a1882cfe..d5be1e16a --- a/lisp/org-odt.el +++ b/lisp/org-odt.el @@ -286,7 +286,8 @@ This variable is effective only if (center . "OrgCenter") (left . "OrgLeft") (right . "OrgRight") - (title . "Heading_20_1.title") + (title . "OrgTitle") + (subtitle . "OrgSubtitle") (footnote . "Footnote") (src . "OrgSrcBlock") (illustration . "Illustration") @@ -485,16 +486,64 @@ PUB-DIR is set, use this as the publishing directory." ;; Following variable is let bound when `org-do-lparse' is in ;; progress. See org-html.el. (defvar org-lparse-toc) +(defun org-odt-format-toc () + (if (not org-lparse-toc) "" (concat "\n" org-lparse-toc "\n"))) + +(defun org-odt-format-preamble (opt-plist) + (let* ((title (plist-get opt-plist :title)) + (author (plist-get opt-plist :author)) + (date (plist-get opt-plist :date)) + (iso-date (org-odt-format-date date)) + (date (org-odt-format-date date "%d %b %Y")) + (email (plist-get opt-plist :email))) + (concat + ;; title + (when title + (concat + (org-odt-format-stylized-paragraph + 'title (org-odt-format-tags + '("" . "") title)) + ;; separator + "")) + + (cond + ((and author (not email)) + ;; author only + (concat + (org-odt-format-stylized-paragraph + 'subtitle + (org-odt-format-tags + '("" . "") + author)) + ;; separator + "")) + ((and author email) + ;; author and email + (concat + (org-odt-format-stylized-paragraph + 'subtitle + (org-odt-format-link + (org-odt-format-tags + '("" . "") + author) (concat "mailto:" email))) + ;; separator + ""))) + ;; date + (when date + (concat + (org-odt-format-stylized-paragraph + 'subtitle + (org-odt-format-tags + '("" + . "") date "N75" iso-date)) + ;; separator + "")) + ;; toc + (org-odt-format-toc)))) + (defun org-odt-begin-document-body (opt-plist) (org-odt-begin-office-body) - (let ((title (plist-get opt-plist :title))) - (when title - (insert - (org-odt-format-stylized-paragraph 'title title)))) - - ;; insert toc - (when org-lparse-toc - (insert "\n" org-lparse-toc "\n"))) + (insert (org-odt-format-preamble opt-plist))) (defvar org-lparse-body-only) ; let bound during org-do-lparse (defvar org-lparse-to-buffer) ; let bound during org-do-lparse @@ -553,7 +602,7 @@ PUB-DIR is set, use this as the publishing directory." (when (setq author (or author (plist-get org-lparse-opt-plist :author))) (org-odt-format-tags '("" . "") author))) -(defun org-odt-iso-date-from-org-timestamp (&optional org-ts) +(defun org-odt-format-date (&optional org-ts fmt) (save-match-data (let* ((time (and (stringp org-ts) @@ -561,8 +610,11 @@ PUB-DIR is set, use this as the publishing directory." (apply 'encode-time (org-fix-decoded-time (org-parse-time-string (match-string 0 org-ts) t))))) - (date (format-time-string "%Y-%m-%dT%H:%M:%S%z" time))) - (format "%s:%s" (substring date 0 -2) (substring date -2))))) + date) + (cond + (fmt (format-time-string fmt time)) + (t (setq date (format-time-string "%Y-%m-%dT%H:%M:%S%z" time)) + (format "%s:%s" (substring date 0 -2) (substring date -2))))))) (defun org-odt-begin-annotation (&optional author date) (org-lparse-insert-tag "") @@ -570,7 +622,7 @@ PUB-DIR is set, use this as the publishing directory." (insert author)) (insert (org-odt-format-tags '("" . "") - (org-odt-iso-date-from-org-timestamp + (org-odt-format-date (or date (plist-get org-lparse-opt-plist :date))))) (org-lparse-begin-paragraph)) @@ -2002,8 +2054,7 @@ visually." (insert "\n")))) (defun org-odt-update-meta-file (opt-plist) - (let ((date (org-odt-iso-date-from-org-timestamp - (plist-get opt-plist :date))) + (let ((date (org-odt-format-date (plist-get opt-plist :date))) (author (or (plist-get opt-plist :author) "")) (email (plist-get opt-plist :email)) (keywords (plist-get opt-plist :keywords)) From bc1af7b52aa294c4766e690c663680b56f6b502a Mon Sep 17 00:00:00 2001 From: Jambunathan K Date: Thu, 15 Dec 2011 12:32:33 +0530 Subject: [PATCH 04/44] org-odt.el: Fix permissions --- lisp/org-odt.el | 0 1 file changed, 0 insertions(+), 0 deletions(-) mode change 100755 => 100644 lisp/org-odt.el diff --git a/lisp/org-odt.el b/lisp/org-odt.el old mode 100755 new mode 100644 From 26d98193d694ae51caa532755066f78c809d4e34 Mon Sep 17 00:00:00 2001 From: Bastien Guerry Date: Thu, 15 Dec 2011 09:37:30 +0100 Subject: [PATCH 05/44] org-protocol.el: Fix spelling mistake. * org-protocol.el (org-protocol-check-filename-for-protocol): Fix spelling mistake. Thanks to Paul Eggert for fixing this in Emacs first. --- lisp/org-protocol.el | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lisp/org-protocol.el b/lisp/org-protocol.el index 6a8f42387..8bda9556a 100644 --- a/lisp/org-protocol.el +++ b/lisp/org-protocol.el @@ -546,8 +546,8 @@ as filename." (when (string-match proto fname) (let* ((func (plist-get (cdr prolist) :function)) (greedy (plist-get (cdr prolist) :greedy)) - (splitted (split-string fname proto)) - (result (if greedy restoffiles (cadr splitted)))) + (split (split-string fname proto)) + (result (if greedy restoffiles (cadr split)))) (when (plist-get (cdr prolist) :kill-client) (message "Greedy org-protocol handler. Killing client.") (server-edit)) From a3ac9d80edb483bf212447dbbada6c2da04e5b2e Mon Sep 17 00:00:00 2001 From: Bastien Guerry Date: Sat, 17 Dec 2011 15:07:13 +0100 Subject: [PATCH 06/44] Create proper file target for index entries in subdirectories. * org-publish.el (org-publish-index-generate-theindex): Create proper file target for index entries in subdirectories. --- lisp/org-publish.el | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/lisp/org-publish.el b/lisp/org-publish.el index 1518efe59..8e32658d0 100644 --- a/lisp/org-publish.el +++ b/lisp/org-publish.el @@ -984,7 +984,9 @@ the project." main last-main letter last-letter file sub link tgext) ;; `files' contains the list of relative file names (dolist (file files) - (setq origfile (substring file 1 -1)) + (setq origfile + (concat (file-name-directory file) + (substring (file-name-nondirectory file) 1 -1))) (setq buf (find-file-noselect file)) (with-current-buffer buf (goto-char (point-min)) From 006d704145bbc39313fed89dc958ea7230e3b9d7 Mon Sep 17 00:00:00 2001 From: Bastien Guerry Date: Sat, 17 Dec 2011 15:55:18 +0100 Subject: [PATCH 07/44] Use theindex.inc and theindex.org as described in the manual. * org-publish.el (org-publish-index-generate-theindex): Use theindex.inc for storing index entries, and theindex.org for including theindex.inc. Commit f0d7ac removed the theindex.inc and directly included index entries in theindex.org. This is not as flexible as using theindex.org as a page you want to manually edit, which can then include theindex.inc with proper content. Thanks to Stefan Vollmar for insisting about this issue. --- lisp/org-publish.el | 13 +++++++++++-- 1 file changed, 11 insertions(+), 2 deletions(-) diff --git a/lisp/org-publish.el b/lisp/org-publish.el index 8e32658d0..228666b97 100644 --- a/lisp/org-publish.el +++ b/lisp/org-publish.el @@ -997,7 +997,7 @@ the project." (kill-buffer buf)) (setq index (sort index (lambda (a b) (string< (downcase (car a)) (downcase (car b)))))) - (setq ibuffer (find-file-noselect (expand-file-name "theindex.org" directory))) + (setq ibuffer (find-file-noselect (expand-file-name "theindex.inc" directory))) (with-current-buffer ibuffer (erase-buffer) (insert "* Index\n") @@ -1024,7 +1024,16 @@ the project." (insert " - " link "\n") (insert " - " link "\n"))) (save-buffer)) - (kill-buffer ibuffer))) + (kill-buffer ibuffer) + ;; Create theindex.org if it doesn't exist already + (let ((index-file (expand-file-name "theindex.org" directory))) + (unless (file-exists-p index-file) + (setq ibuffer (find-file-noselect index-file)) + (with-current-buffer ibuffer + (erase-buffer) + (insert "\n\n#+include: \"theindex.inc\"\n\n") + (save-buffer)) + (kill-buffer ibuffer))))) ;; Caching functions: From a2cdccf5cbcef919b0e3675ecf26f625a2052717 Mon Sep 17 00:00:00 2001 From: Eric Schulte Date: Fri, 16 Dec 2011 17:32:38 -0700 Subject: [PATCH 08/44] move `org-babel-lob-one-liner-regexp' into ob.el to fix autoloading error * lisp/ob.el (org-babel-map-call-lines): Moved this file from ob-lob.el into ob.el to ease dependency pains. --- lisp/ob-lob.el | 23 ----------------------- lisp/ob.el | 25 ++++++++++++++++++++++++- 2 files changed, 24 insertions(+), 24 deletions(-) diff --git a/lisp/ob-lob.el b/lisp/ob-lob.el index d2ebb17b3..181eee22b 100644 --- a/lisp/ob-lob.el +++ b/lisp/ob-lob.el @@ -82,29 +82,6 @@ To add files to this list use the `org-babel-lob-ingest' command." ;; functions for executing lob one-liners -;;;###autoload -(defmacro org-babel-map-call-lines (file &rest body) - "Evaluate BODY forms on each call line in FILE. -If FILE is nil evaluate BODY forms on source blocks in current -buffer." - (declare (indent 1)) - (let ((tempvar (make-symbol "file"))) - `(let* ((,tempvar ,file) - (visited-p (or (null ,tempvar) - (get-file-buffer (expand-file-name ,tempvar)))) - (point (point)) to-be-removed) - (save-window-excursion - (when ,tempvar (find-file ,tempvar)) - (setq to-be-removed (current-buffer)) - (goto-char (point-min)) - (while (re-search-forward org-babel-lob-one-liner-regexp nil t) - (goto-char (match-beginning 1)) - (save-match-data ,@body) - (goto-char (match-end 0)))) - (unless visited-p (kill-buffer to-be-removed)) - (goto-char point)))) -(def-edebug-spec org-babel-map-call-lines (form body)) - ;;;###autoload (defun org-babel-lob-execute-maybe () "Execute a Library of Babel source block, if appropriate. diff --git a/lisp/ob.el b/lisp/ob.el index 1fdda8c0b..991941698 100644 --- a/lisp/ob.el +++ b/lisp/ob.el @@ -72,7 +72,6 @@ (declare-function org-babel-ref-goto-headline-id "ob-ref" (id)) (declare-function org-babel-ref-headline-body "ob-ref" ()) (declare-function org-babel-lob-execute-maybe "ob-lob" ()) -(declare-function org-babel-map-call-lines "ob-lob" (file &rest body)) (declare-function org-number-sequence "org-compat" (from &optional to inc)) (declare-function org-at-item-p "org-list" ()) (declare-function org-list-parse-list "org-list" (&optional delete)) @@ -861,6 +860,30 @@ buffer." (goto-char point)))) (def-edebug-spec org-babel-map-inline-src-blocks (form body)) +(defvar org-babel-lob-one-liner-regexp) +;;;###autoload +(defmacro org-babel-map-call-lines (file &rest body) + "Evaluate BODY forms on each call line in FILE. +If FILE is nil evaluate BODY forms on source blocks in current +buffer." + (declare (indent 1)) + (let ((tempvar (make-symbol "file"))) + `(let* ((,tempvar ,file) + (visited-p (or (null ,tempvar) + (get-file-buffer (expand-file-name ,tempvar)))) + (point (point)) to-be-removed) + (save-window-excursion + (when ,tempvar (find-file ,tempvar)) + (setq to-be-removed (current-buffer)) + (goto-char (point-min)) + (while (re-search-forward org-babel-lob-one-liner-regexp nil t) + (goto-char (match-beginning 1)) + (save-match-data ,@body) + (goto-char (match-end 0)))) + (unless visited-p (kill-buffer to-be-removed)) + (goto-char point)))) +(def-edebug-spec org-babel-map-call-lines (form body)) + ;;;###autoload (defun org-babel-execute-buffer (&optional arg) "Execute source code blocks in a buffer. From 094173b45d034799951c6b77b29b84368f5ad734 Mon Sep 17 00:00:00 2001 From: David Maus Date: Sun, 18 Dec 2011 20:28:00 +0100 Subject: [PATCH 09/44] Ignore headlines without a true headline * org.el (org-refile-get-targets): Ignore headlines without a true headline. This fixes a bug reported by Nathan Neff in . Headlines with just a keyword are ignored as possible refile target. --- lisp/org.el | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/lisp/org.el b/lisp/org.el index 8a1fbd398..9980d03d7 100644 --- a/lisp/org.el +++ b/lisp/org.el @@ -10405,7 +10405,8 @@ on the system \"/user@host:\"." (or (funcall org-refile-target-verify-function) (throw 'next t)))) (when (and (looking-at org-complex-heading-regexp) - (not (member (match-string 4) excluded-entries))) + (not (member (match-string 4) excluded-entries)) + (match-string 4)) (setq level (org-reduced-level (- (match-end 1) (match-beginning 1))) txt (org-link-display-format (match-string 4)) From c5b230b065f6c2bad81743293f396b80470a4ff6 Mon Sep 17 00:00:00 2001 From: Julian Gehring Date: Mon, 12 Dec 2011 21:54:01 +0100 Subject: [PATCH 10/44] Manual: Consistently use 'Org mode' * doc/org.texi: Use 'Org mode' instead of alternatives like 'Org-mode' or 'org-mode', as suggested in Phil's notes ('doc/Documentation_Standards.org'). --- doc/org.texi | 464 +++++++++++++++++++++++++-------------------------- 1 file changed, 232 insertions(+), 232 deletions(-) diff --git a/doc/org.texi b/doc/org.texi index 1d2babd58..9d9dd81fa 100644 --- a/doc/org.texi +++ b/doc/org.texi @@ -433,7 +433,7 @@ Tags Properties and columns * Property syntax:: How properties are spelled out -* Special properties:: Access to other Org-mode features +* Special properties:: Access to other Org mode features * Property searches:: Matching property values * Property inheritance:: Passing values down the tree * Column view:: Tabular viewing and editing @@ -462,7 +462,7 @@ Dates and times Creating timestamps -* The date/time prompt:: How Org-mode helps you entering date and time +* The date/time prompt:: How Org mode helps you entering date and time * Custom time format:: Making dates look different Deadlines and scheduling @@ -583,7 +583,7 @@ HTML export * HTML Export commands:: How to invoke HTML export * HTML preamble and postamble:: How to insert a preamble and a postamble -* Quoting HTML tags:: Using direct HTML in Org-mode +* Quoting HTML tags:: Using direct HTML in Org mode * Links in HTML export:: How links will be interpreted and formatted * Tables in HTML export:: How to modify the formatting of tables * Images in HTML export:: How to insert figures into HTML output @@ -664,12 +664,12 @@ Working with source code * Editing source code:: Language major-mode editing * Exporting code blocks:: Export contents and/or results * Extracting source code:: Create pure source code files -* Evaluating code blocks:: Place results of evaluation in the Org-mode buffer +* Evaluating code blocks:: Place results of evaluation in the Org mode buffer * Library of Babel:: Use and contribute to a library of useful code blocks * Languages:: List of supported code block languages * Header arguments:: Configure code block functionality * Results of evaluation:: How evaluation results are handled -* Noweb reference syntax:: Literate programming in Org-mode +* Noweb reference syntax:: Literate programming in Org mode * Key bindings and useful functions:: Work quickly with code blocks * Batch execution:: Call functions from the command line @@ -683,7 +683,7 @@ Using header arguments * System-wide header arguments:: Set global default values * Language-specific header arguments:: Set default values by language * Buffer-wide header arguments:: Set default values for a specific buffer -* Header arguments in Org-mode properties:: Set default values for a buffer or heading +* Header arguments in Org mode properties:: Set default values for a buffer or heading * Code block specific header arguments:: The most common way to set values * Header arguments in function calls:: The most specific level @@ -913,7 +913,7 @@ make install-info Then add the following line to @file{.emacs}. It is needed so that Emacs can autoload functions that are located in files not immediately loaded -when Org-mode starts. +when Org mode starts. @lisp (require 'org-install) @end lisp @@ -949,9 +949,9 @@ liking. (global-set-key "\C-cb" 'org-iswitchb) @end lisp -@cindex Org-mode, turning on +@cindex Org mode, turning on With this setup, all files with extension @samp{.org} will be put -into Org-mode. As an alternative, make the first line of a file look +into Org mode. As an alternative, make the first line of a file look like this: @example @@ -959,7 +959,7 @@ MY PROJECTS -*- mode: org; -*- @end example @vindex org-insert-mode-line-in-empty-file -@noindent which will select Org-mode for this buffer no matter what +@noindent which will select Org mode for this buffer no matter what the file's name is. See also the variable @code{org-insert-mode-line-in-empty-file}. @@ -1002,17 +1002,17 @@ version information of Emacs (@kbd{M-x emacs-version @key{RET}}) and Org that you only need to add your description. If you re not sending the Email from within Emacs, please copy and paste the content into your Email program. -Sometimes you might face a problem due to an error in your Emacs or Org-mode +Sometimes you might face a problem due to an error in your Emacs or Org mode setup. Before reporting a bug, it is very helpful to start Emacs with minimal customisations and reproduce the problem. Doing so often helps you determine -if the problem is with your customisation or with Org-mode itself. You can +if the problem is with your customisation or with Org mode itself. You can start a typical minimal session with a command like the example below. @example $ emacs -Q -l /path/to/minimal-org.el @end example -However if you are using Org-mode as distributed with Emacs, a minimal setup +However if you are using Org mode as distributed with Emacs, a minimal setup is not necessary. In that case it is sufficient to start Emacs as @code{emacs -Q}. The @code{minimal-org.el} setup file can have contents as shown below. @@ -1054,7 +1054,7 @@ error occurred. Here is how to produce a useful backtrace: @enumerate @item -Reload uncompiled versions of all Org-mode Lisp files. The backtrace +Reload uncompiled versions of all Org mode Lisp files. The backtrace contains much more information if it is produced with uncompiled code. To do this, use @example @@ -1475,7 +1475,7 @@ functionality. @vindex org-show-following-heading @vindex org-show-siblings @vindex org-show-entry-below -An important feature of Org-mode is the ability to construct @emph{sparse +An important feature of Org mode is the ability to construct @emph{sparse trees} for selected information in an outline tree, so that the entire document is folded as much as possible, but the selected information is made visible along with the headline structure above it@footnote{See also the @@ -1484,7 +1484,7 @@ variables @code{org-show-hierarchy-above}, @code{org-show-following-heading}, control on how much context is shown around each match.}. Just try it out and you will see immediately how it works. -Org-mode contains several commands creating such trees, all these +Org mode contains several commands creating such trees, all these commands can be accessed through a dispatcher: @table @asis @@ -1758,7 +1758,7 @@ numerically, alphabetically, by time, or by custom function. @vindex org-drawers Sometimes you want to keep information associated with an entry, but you -normally don't want to see it. For this, Org-mode has @emph{drawers}. +normally don't want to see it. For this, Org mode has @emph{drawers}. Drawers need to be configured with the variable @code{org-drawers}@footnote{You can define drawers on a per-file basis with a line like @code{#+DRAWERS: HIDDEN PROPERTIES STATE}}. Drawers @@ -1776,7 +1776,7 @@ look like this: Visibility cycling (@pxref{Visibility cycling}) on the headline will hide and show the entry, but keep the drawer collapsed to a single line. In order to look inside the drawer, you need to move the cursor to the drawer line and -press @key{TAB} there. Org-mode uses the @code{PROPERTIES} drawer for +press @key{TAB} there. Org mode uses the @code{PROPERTIES} drawer for storing properties (@pxref{Properties and Columns}), and you can also arrange for state change notes (@pxref{Tracking TODO state changes}) and clock times (@pxref{Clocking work time}) to be stored in a drawer @code{LOGBOOK}. If you @@ -1793,7 +1793,7 @@ Add a time-stamped note to the LOGBOOK drawer. @vindex org-hide-block-startup @cindex blocks, folding -Org-mode uses begin...end blocks for various purposes from including source +Org mode uses begin...end blocks for various purposes from including source code examples (@pxref{Literal examples}) to capturing time logging information (@pxref{Clocking work time}). These blocks can be folded and unfolded by pressing TAB in the begin line. You can also get all blocks @@ -1811,8 +1811,8 @@ or on a per-file basis by using @section Footnotes @cindex footnotes -Org-mode supports the creation of footnotes. In contrast to the -@file{footnote.el} package, Org-mode's footnotes are designed for work on a +Org mode supports the creation of footnotes. In contrast to the +@file{footnote.el} package, Org mode's footnotes are designed for work on a larger document, not only for one-off documents like emails. The basic syntax is similar to the one used by @file{footnote.el}, i.e.@: a footnote is defined in a paragraph that is started by a footnote marker in square @@ -1826,7 +1826,7 @@ The Org homepage[fn:1] now looks a lot better than it used to. [fn:1] The link is: http://orgmode.org @end example -Org-mode extends the number-based syntax to @emph{named} footnotes and +Org mode extends the number-based syntax to @emph{named} footnotes and optional inline definition. Using plain numbers as markers (as @file{footnote.el} does) is supported for backward compatibility, but not encouraged because of possible conflicts with @LaTeX{} snippets (@pxref{Embedded @@ -1920,7 +1920,7 @@ you can use the usual commands to follow these links. @cindex Orgstruct mode @cindex minor mode for structure editing -If you like the intuitive way the Org-mode structure editing and list +If you like the intuitive way the Org mode structure editing and list formatting works, you might want to use these commands in other modes like Text mode or Mail mode as well. The minor mode @code{orgstruct-mode} makes this possible. Toggle the mode with @kbd{M-x orgstruct-mode}, or @@ -3052,7 +3052,7 @@ When plotting @code{3d} or @code{grid} types, set this to @code{t} to graph a flat mapping rather than a @code{3d} slope. @item timefmt -Specify format of Org-mode timestamps as they will be parsed by Gnuplot. +Specify format of Org mode timestamps as they will be parsed by Gnuplot. Defaults to @samp{%Y-%m-%d-%H:%M:%S}. @item script @@ -3290,7 +3290,7 @@ create a link. The link will be stored for later insertion into an Org buffer (see below). What kind of link will be created depends on the current buffer: -@b{Org-mode buffers}@* +@b{Org mode buffers}@* For Org files, if there is a @samp{<>} at the cursor, the link points to the target. Otherwise it points to the current headline, which will also be the description@footnote{If the headline contains a timestamp, it will be @@ -3583,7 +3583,7 @@ Link to a heading with a @code{CUSTOM_ID} property @item /regexp/ Do a regular expression search for @code{regexp}. This uses the Emacs command @code{occur} to list all matches in a separate window. If the -target file is in Org-mode, @code{org-occur} is used to create a +target file is in Org mode, @code{org-occur} is used to create a sparse tree with the matches. @c If the target file is a directory, @c @code{grep} will be used to search all files in the directory. @@ -3622,7 +3622,7 @@ an implementation example. See the file @file{org-bibtex.el}. @chapter TODO items @cindex TODO items -Org-mode does not maintain TODO lists as separate documents@footnote{Of +Org mode does not maintain TODO lists as separate documents@footnote{Of course, you can make a document that contains only long lists of TODO items, but this is not required.}. Instead, TODO items are an integral part of the notes file, because TODO items usually come up while taking notes! With Org @@ -3631,7 +3631,7 @@ information is not duplicated, and the entire context from which the TODO item emerged is always present. Of course, this technique for managing TODO items scatters them -throughout your notes file. Org-mode compensates for this by providing +throughout your notes file. Org mode compensates for this by providing methods to give you an overview of all the things that you have to do. @menu @@ -3717,7 +3717,7 @@ option @code{org-todo-state-tags-triggers} for details. @vindex org-todo-keywords By default, marked TODO entries have one of only two states: TODO and -DONE. Org-mode allows you to classify TODO items in more complex ways +DONE. Org mode allows you to classify TODO items in more complex ways with @emph{TODO keywords} (stored in @code{org-todo-keywords}). With special setup, the TODO keyword system can work differently in different files. @@ -3742,7 +3742,7 @@ TODO items in particular (@pxref{Tags}). You can use TODO keywords to indicate different @emph{sequential} states in the process of working on an item, for example@footnote{Changing -this variable only becomes effective after restarting Org-mode in a +this variable only becomes effective after restarting Org mode in a buffer.}: @lisp @@ -3785,7 +3785,7 @@ be set up like this: In this case, different keywords do not indicate a sequence, but rather different types. So the normal work flow would be to assign a task to a -person, and later to mark it DONE. Org-mode supports this style by adapting +person, and later to mark it DONE. Org mode supports this style by adapting the workings of the command @kbd{C-c C-t}@footnote{This is also true for the @kbd{t} command in the timeline and agenda buffers.}. When used several times in succession, it will still cycle through all names, in order to first @@ -3816,7 +3816,7 @@ like this: (sequence "|" "CANCELED"))) @end lisp -The keywords should all be different, this helps Org-mode to keep track +The keywords should all be different, this helps Org mode to keep track of which subsequence should be used for a given entry. In this setup, @kbd{C-c C-t} only operates within a subsequence, so it switches from @code{DONE} to (nothing) to @code{TODO}, and from @code{FIXED} to @@ -3913,9 +3913,9 @@ Remember that the keywords after the vertical bar (or the last keyword if no bar is there) must always mean that the item is DONE (although you may use a different word). After changing one of these lines, use @kbd{C-c C-c} with the cursor still in the line to make the changes -known to Org-mode@footnote{Org-mode parses these lines only when -Org-mode is activated after visiting a file. @kbd{C-c C-c} with the -cursor in a line starting with @samp{#+} is simply restarting Org-mode +known to Org mode@footnote{Org mode parses these lines only when +Org mode is activated after visiting a file. @kbd{C-c C-c} with the +cursor in a line starting with @samp{#+} is simply restarting Org mode for the current buffer.}. @node Faces for TODO keywords, TODO dependencies, Per-file keywords, TODO extensions @@ -3925,7 +3925,7 @@ for the current buffer.}. @vindex org-todo @r{(face)} @vindex org-done @r{(face)} @vindex org-todo-keyword-faces -Org-mode highlights TODO keywords with special faces: @code{org-todo} +Org mode highlights TODO keywords with special faces: @code{org-todo} for keywords indicating that an item still has to be acted upon, and @code{org-done} for keywords indicating that an item is finished. If you are using more than 2 different states, you might want to use @@ -4013,7 +4013,7 @@ module @file{org-depend.el}. @cindex progress logging @cindex logging, of progress -Org-mode can automatically record a timestamp and possibly a note when +Org mode can automatically record a timestamp and possibly a note when you mark a TODO item as DONE, or even each time you change the state of a TODO item. This system is highly configurable, settings can be on a per-keyword basis and can be localized to a file or even a subtree. For @@ -4077,7 +4077,7 @@ behavior---the recommended drawer for this is called @code{LOGBOOK}. You can also overrule the setting of this variable for a subtree by setting a @code{LOG_INTO_DRAWER} property. -Since it is normally too much to record a note for every state, Org-mode +Since it is normally too much to record a note for every state, Org mode expects configuration on a per-keyword basis for this. This is achieved by adding special markers @samp{!} (for a timestamp) or @samp{@@} (for a note with timestamp) in parentheses after each keyword. For example, with the @@ -4095,7 +4095,7 @@ To record a timestamp without a note for TODO keywords configured with @vindex org-log-done you not only define global TODO keywords and fast access keys, but also request that a time is recorded when the entry is set to -DONE@footnote{It is possible that Org-mode will record two timestamps +DONE@footnote{It is possible that Org mode will record two timestamps when you are using both @code{org-log-done} and state change logging. However, it will never prompt for two notes---if you have configured both, the state change recording note will take precedence and cancel @@ -4244,7 +4244,7 @@ which should only be done in certain contexts, for example. @section Priorities @cindex priorities -If you use Org-mode extensively, you may end up with enough TODO items that +If you use Org mode extensively, you may end up with enough TODO items that it starts to make sense to prioritize them. Prioritizing can be done by placing a @emph{priority cookie} into the headline of a TODO item, like this @@ -4254,11 +4254,11 @@ placing a @emph{priority cookie} into the headline of a TODO item, like this @noindent @vindex org-priority-faces -By default, Org-mode supports three priorities: @samp{A}, @samp{B}, and +By default, Org mode supports three priorities: @samp{A}, @samp{B}, and @samp{C}. @samp{A} is the highest priority. An entry without a cookie is treated just like priority @samp{B}. Priorities make a difference only for sorting in the agenda (@pxref{Weekly/daily agenda}); outside the agenda, they -have no inherent meaning to Org-mode. The cookies can be highlighted with +have no inherent meaning to Org mode. The cookies can be highlighted with special faces by customizing the variable @code{org-priority-faces}. Priorities can be attached to any outline node; they do not need to be TODO @@ -4472,7 +4472,7 @@ hand, use this command to get things back into sync. @cindex sparse tree, tag based An excellent way to implement labels and contexts for cross-correlating -information is to assign @i{tags} to headlines. Org-mode has extensive +information is to assign @i{tags} to headlines. Org mode has extensive support for tags. @vindex org-tag-faces @@ -4551,7 +4551,7 @@ also a special command for inserting tags: @orgcmd{C-c C-q,org-set-tags-command} @cindex completion, of tags @vindex org-tags-column -Enter new tags for the current headline. Org-mode will either offer +Enter new tags for the current headline. Org mode will either offer completion or a special single-key interface for setting tags, see below. After pressing @key{RET}, the tags will be inserted and aligned to @code{org-tags-column}. When called with a @kbd{C-u} prefix, all @@ -4594,7 +4594,7 @@ by adding a STARTUP option line to that file: #+STARTUP: noptag @end example -By default Org-mode uses the standard minibuffer completion facilities for +By default Org mode uses the standard minibuffer completion facilities for entering tags. However, it also implements another, quicker, tag selection method called @emph{fast tag selection}. This allows you to select and deselect tags with just a single key press. For this to work well you should @@ -4755,9 +4755,9 @@ and properties. For a complete description with many examples, see A property is a key-value pair associated with an entry. Properties can be set so they are associated with a single entry, with every entry in a tree, -or with every entry in an Org-mode file. +or with every entry in an Org mode file. -There are two main applications for properties in Org-mode. First, +There are two main applications for properties in Org mode. First, properties are like tags, but with a value. Imagine maintaining a file where you document bugs and plan releases for a piece of software. Instead of using tags like @code{:release_1:}, @code{:release_2:}, you can use a @@ -4772,7 +4772,7 @@ Properties can be conveniently edited and viewed in column view @menu * Property syntax:: How properties are spelled out -* Special properties:: Access to other Org-mode features +* Special properties:: Access to other Org mode features * Property searches:: Matching property values * Property inheritance:: Passing values down the tree * Column view:: Tabular viewing and editing @@ -4902,7 +4902,7 @@ nearest column format definition. @section Special properties @cindex properties, special -Special properties provide an alternative access method to Org-mode features, +Special properties provide an alternative access method to Org mode features, like the TODO state or the priority of an entry, discussed in the previous chapters. This interface exists so that you can include these states in a column view (@pxref{Column view}), or to use them in queries. The following @@ -4984,9 +4984,9 @@ a regular expression and matched against the property values. @cindex inheritance, of properties @vindex org-use-property-inheritance -The outline structure of Org-mode documents lends itself to an +The outline structure of Org mode documents lends itself to an inheritance model of properties: if the parent in a tree has a certain -property, the children can inherit this property. Org-mode does not +property, the children can inherit this property. Org mode does not turn this on by default, because it can slow down property searches significantly and is often not needed. However, if you find inheritance useful, you can turn it on by setting the variable @@ -4997,7 +4997,7 @@ inherited properties. If a property has the value @samp{nil}, this is interpreted as an explicit undefine of the property, so that inheritance search will stop at this value and return @code{nil}. -Org-mode has a few properties for which inheritance is hard-coded, at +Org mode has a few properties for which inheritance is hard-coded, at least for the special applications for which they are used: @cindex property, COLUMNS @@ -5028,7 +5028,7 @@ subtree (@pxref{Tracking TODO state changes}). A great way to view and edit properties in an outline tree is @emph{column view}. In column view, each outline node is turned into a table row. Columns in this table provide access to properties of the -entries. Org-mode implements columns by overlaying a tabular structure +entries. Org mode implements columns by overlaying a tabular structure over the headline of each item. While the headlines have been turned into a table row, you can still change the visibility of the outline tree. For example, you get a compact table by switching to CONTENTS @@ -5330,9 +5330,9 @@ property API}. To assist project planning, TODO items can be labeled with a date and/or a time. The specially formatted string carrying the date and time -information is called a @emph{timestamp} in Org-mode. This may be a +information is called a @emph{timestamp} in Org mode. This may be a little confusing because timestamp is often used as indicating when -something was created or last changed. However, in Org-mode this term +something was created or last changed. However, in Org mode this term is used in a much wider sense. @menu @@ -5391,7 +5391,7 @@ following will show up in the agenda every Wednesday: @end example @item Diary-style sexp entries -For more complex date specifications, Org-mode supports using the special +For more complex date specifications, Org mode supports using the special sexp diary entries implemented in the Emacs calendar/diary package@footnote{When working with the standard diary sexp functions, you need to be very careful with the order of the arguments. That order depend @@ -5399,7 +5399,7 @@ evilly on the variable @code{calendar-date-style} (or, for older Emacs versions, @code{european-calendar-style}). For example, to specify a date December 12, 2005, the call might look like @code{(diary-date 12 1 2005)} or @code{(diary-date 1 12 2005)} or @code{(diary-date 2005 12 1)}, depending on -the settings. This has been the source of much confusion. Org-mode users +the settings. This has been the source of much confusion. Org mode users can resort to special versions of these functions like @code{org-date} or @code{org-anniversary}. These work just like the corresponding @code{diary-} functions, but with stable ISO order of arguments (year, month, day) wherever @@ -5440,7 +5440,7 @@ angular ones. These timestamps are inactive in the sense that they do @cindex creating timestamps @cindex timestamps, creating -For Org-mode to recognize timestamps, they need to be in the specific +For Org mode to recognize timestamps, they need to be in the specific format. All commands listed below produce timestamps in the correct format. @@ -5502,7 +5502,7 @@ the following column). @menu -* The date/time prompt:: How Org-mode helps you entering date and time +* The date/time prompt:: How Org mode helps you entering date and time * Custom time format:: Making dates look different @end menu @@ -5512,17 +5512,17 @@ the following column). @cindex time, reading in minibuffer @vindex org-read-date-prefer-future -When Org-mode prompts for a date/time, the default is shown in default +When Org mode prompts for a date/time, the default is shown in default date/time format, and the prompt therefore seems to ask for a specific format. But it will in fact accept any string containing some date and/or time information, and it is really smart about interpreting your input. You can, for example, use @kbd{C-y} to paste a (possibly multi-line) string -copied from an email message. Org-mode will find whatever information is in +copied from an email message. Org mode will find whatever information is in there and derive anything you have not specified from the @emph{default date and time}. The default is usually the current date and time, but when modifying an existing timestamp, or when entering the second stamp of a range, it is taken from the stamp in the buffer. When filling in -information, Org-mode assumes that most of the time you will want to enter a +information, Org mode assumes that most of the time you will want to enter a date in the future: if you omit the month/year and the given day/month is @i{before} today, it will assume that you mean a future date@footnote{See the variable @code{org-read-date-prefer-future}. You may set that variable to @@ -5531,7 +5531,7 @@ tomorrow.}. If the date has been automatically shifted into the future, the time prompt will show this with @samp{(=>F).} For example, let's assume that today is @b{June 13, 2006}. Here is how -various inputs will be interpreted, the items filled in by Org-mode are +various inputs will be interpreted, the items filled in by Org mode are in @b{bold}. @example @@ -5641,7 +5641,7 @@ minibuffer@footnote{If you find this distracting, turn the display of with @vindex org-display-custom-times @vindex org-time-stamp-custom-formats -Org-mode uses the standard ISO notation for dates and times as it is +Org mode uses the standard ISO notation for dates and times as it is defined in ISO 8601. If you cannot get used to this and require another representation of date and time to keep you happy, you can get it by customizing the variables @code{org-display-custom-times} and @@ -5653,7 +5653,7 @@ Toggle the display of custom formats for dates and times. @end table @noindent -Org-mode needs the default format for scanning, so the custom date/time +Org mode needs the default format for scanning, so the custom date/time format does not @emph{replace} the default format---instead it is put @emph{over} the default format using text properties. This has the following consequences: @@ -5730,23 +5730,23 @@ the task will automatically be forwarded until completed. @end example @noindent -@b{Important:} Scheduling an item in Org-mode should @i{not} be +@b{Important:} Scheduling an item in Org mode should @i{not} be understood in the same way that we understand @i{scheduling a meeting}. Setting a date for a meeting is just a simple appointment, you should mark this entry with a simple plain timestamp, to get this item shown on the date where it applies. This is a frequent misunderstanding by -Org users. In Org-mode, @i{scheduling} means setting a date when you +Org users. In Org mode, @i{scheduling} means setting a date when you want to start working on an action item. @end table You may use timestamps with repeaters in scheduling and deadline -entries. Org-mode will issue early and late warnings based on the +entries. Org mode will issue early and late warnings based on the assumption that the timestamp represents the @i{nearest instance} of the repeater. However, the use of diary sexp entries like @c @code{<%%(org-float t 42)>} @c -in scheduling and deadline timestamps is limited. Org-mode does not +in scheduling and deadline timestamps is limited. Org mode does not know enough about the internals of each sexp function to issue early and late warnings. However, it will show the item on each day where the sexp entry matches. @@ -5819,7 +5819,7 @@ to the previous week before any current timestamp. @cindex tasks, repeated @cindex repeated tasks -Some tasks need to be repeated again and again. Org-mode helps to +Some tasks need to be repeated again and again. Org mode helps to organize such tasks using a so-called repeater in a DEADLINE, SCHEDULED, or plain timestamp. In the following example @example @@ -5839,7 +5839,7 @@ over-due, so it is important to be able to mark such an entry as completed once you have done so. When you mark a DEADLINE or a SCHEDULE with the TODO keyword DONE, it will no longer produce entries in the agenda. The problem with this is, however, that then also the @emph{next} instance of the -repeated entry will not be active. Org-mode deals with this in the following +repeated entry will not be active. Org mode deals with this in the following way: When you try to mark such an entry DONE (using @kbd{C-c C-t}), it will shift the base date of the repeating timestamp by the repeater interval, and immediately set the entry state back to TODO@footnote{In fact, the target @@ -5872,7 +5872,7 @@ task, this may not be the best way to handle it. For example, if you forgot to call your father for 3 weeks, it does not make sense to call him 3 times in a single day to make up for it. Finally, there are tasks like changing batteries which should always repeat a certain time -@i{after} the last time you did it. For these tasks, Org-mode has +@i{after} the last time you did it. For these tasks, Org mode has special repeaters @samp{++} and @samp{.+}. For example: @example @@ -5901,7 +5901,7 @@ created for this purpose, it is described in @ref{Structure editing}. @cindex clocking time @cindex time clocking -Org-mode allows you to clock the time you spend on specific tasks in a +Org mode allows you to clock the time you spend on specific tasks in a project. When you start working on an item, you can start the clock. When you stop working on that task, or when you mark the task done, the clock is stopped and the corresponding time interval is recorded. It @@ -6020,7 +6020,7 @@ formatted as one or several Org tables. @table @kbd @orgcmd{C-c C-x C-r,org-clock-report} Insert a dynamic block (@pxref{Dynamic blocks}) containing a clock -report as an Org-mode table into the current file. When the cursor is +report as an Org mode table into the current file. When the cursor is at an existing clock table, just update it. When called with a prefix argument, jump to the first clock report in the current document and update it. The clock table always includes also trees with @@ -6321,7 +6321,7 @@ not started at exactly the right moment. @kindex C-c C-x ; @kindex ; -Calling @code{org-timer-set-timer} from an Org-mode buffer runs a countdown +Calling @code{org-timer-set-timer} from an Org mode buffer runs a countdown timer. Use @kbd{;} from agenda buffers, @key{C-c C-x ;} everwhere else. @code{org-timer-set-timer} prompts the user for a duration and displays a @@ -6355,7 +6355,7 @@ trees to an archive file keeps the system compact and fast. Org's method for capturing new items is heavily inspired by John Wiegley excellent remember package. Up to version 6.36 Org used a special setup -for @file{remember.el}. @file{org-remember.el} is still part of Org-mode for +for @file{remember.el}. @file{org-remember.el} is still part of Org mode for backward compatibility with existing setups. You can find the documentation for org-remember at @url{http://orgmode.org/org-remember.pdf}. @@ -6524,8 +6524,8 @@ selection. The type of entry, a symbol. Valid values are: @table @code @item entry -An Org-mode node, with a headline. Will be filed as the child of the target -entry or as a top-level entry. The target file should be an Org-mode file. +An Org mode node, with a headline. Will be filed as the child of the target +entry or as a top-level entry. The target file should be an Org mode file. @item item A plain list item, placed in the first plain list at the target location. Again the target file should be an Org file. @@ -6542,7 +6542,7 @@ Text to be inserted as it is. @item target @vindex org-default-notes-file -Specification of where the captured item should be placed. In Org-mode +Specification of where the captured item should be placed. In Org mode files, targets usually define a node. Entries will become children of this node. Other types will be added to the table or list in the body of this node. Most target specifications contain a file name. If that file name is @@ -7293,7 +7293,7 @@ anniversaries, lunar phases, sunrise/set, recurrent appointments Org. It can be very useful to combine output from Org with the diary. -In order to include entries from the Emacs diary into Org-mode's +In order to include entries from the Emacs diary into Org mode's agenda, you only need to customize the variable @lisp @@ -7302,7 +7302,7 @@ agenda, you only need to customize the variable @noindent After that, everything will happen automatically. All diary entries including holidays, anniversaries, etc., will be included in the -agenda buffer created by Org-mode. @key{SPC}, @key{TAB}, and +agenda buffer created by Org mode. @key{SPC}, @key{TAB}, and @key{RET} can be used from the agenda buffer to jump to the diary file in order to edit existing diary entries. The @kbd{i} command to insert new entries for the current date works in the agenda buffer, as @@ -7313,7 +7313,7 @@ between calendar and agenda. If you are using the diary only for sexp entries and holidays, it is faster to not use the above setting, but instead to copy or even move -the entries into an Org file. Org-mode evaluates diary-style sexp +the entries into an Org file. Org mode evaluates diary-style sexp entries, and does it faster because there is no overhead for first creating the diary display. Note that the sexp entries must start at the left margin, no whitespace is allowed before them. For example, @@ -7359,7 +7359,7 @@ followed by a space and the class of the anniversary (@samp{birthday} or 1973-06-22 06-22 1955-08-02 wedding -2008-04-14 %s released version 6.01 of org-mode, %d years ago +2008-04-14 %s released version 6.01 of org mode, %d years ago @end example After a change to BBDB, or for the first agenda display during an Emacs @@ -7574,7 +7574,7 @@ other properties will slow down the search. However, once you have paid the price by accessing one property, testing additional properties is cheap again. -You can configure Org-mode to use property inheritance during a search, but +You can configure Org mode to use property inheritance during a search, but beware that this can slow down searches considerably. See @ref{Property inheritance}, for details. @@ -7607,7 +7607,7 @@ Select @samp{:work:}-tagged TODO lines that are either @samp{WAITING} or @cindex timeline, single file @cindex time-sorted view -The timeline summarizes all time-stamped items from a single Org-mode +The timeline summarizes all time-stamped items from a single Org mode file in a @emph{time-sorted view}. The main purpose of this command is to give an overview over events in a project. @@ -7628,7 +7628,7 @@ The commands available in the timeline buffer are listed in @cindex text search @cindex searching, for text -This agenda view is a general text search facility for Org-mode entries. +This agenda view is a general text search facility for Org mode entries. It is particularly useful to find notes. @table @kbd @@ -7660,7 +7660,7 @@ If you are following a system like David Allen's GTD to organize your work, one of the ``duties'' you have is a regular review to make sure that all projects move along. A @emph{stuck} project is a project that has no defined next actions, so it will never show up in the TODO lists -Org-mode produces. During the review, you need to identify such +Org mode produces. During the review, you need to identify such projects and define next actions for them. @table @kbd @@ -7678,7 +7678,7 @@ work for you. The built-in default assumes that all your projects are level-2 headlines, and that a project is not stuck if it has at least one entry marked with a TODO keyword TODO or NEXT or NEXTACTION. -Let's assume that you, in your own way of using Org-mode, identify +Let's assume that you, in your own way of using Org mode, identify projects with a tag PROJECT, and that you use a TODO keyword MAYBE to indicate a project that should not be considered yet. Let's further assume that the TODO keyword DONE marks finished projects, and that NEXT @@ -7706,7 +7706,7 @@ will still be searched for stuck projects. @vindex org-agenda-prefix-format @vindex org-agenda-tags-column -Before displaying items in an agenda view, Org-mode visually prepares the +Before displaying items in an agenda view, Org mode visually prepares the items and sorts them. Each item occupies a single line. The line starts with a @emph{prefix} that contains the @emph{category} (@pxref{Categories}) of the item and other important information. You can customize in which @@ -7759,7 +7759,7 @@ You can set up icons for category by customizing the @subsection Time-of-day specifications @cindex time-of-day specification -Org-mode checks each agenda item for a time-of-day specification. The +Org mode checks each agenda item for a time-of-day specification. The time can be part of the timestamp that triggered inclusion into the agenda, for example as in @w{@samp{<2005-05-10 Tue 19:00>}}. Time ranges can be specified with two timestamps, like @@ -7771,7 +7771,7 @@ plain text (like @samp{12:45} or a @samp{8:30-1pm}). If the agenda integrates the Emacs diary (@pxref{Weekly/daily agenda}), time specifications in diary entries are recognized as well. -For agenda display, Org-mode extracts the time and displays it in a +For agenda display, Org mode extracts the time and displays it in a standard 24 hour format as part of the prefix. The example times in the previous paragraphs would end up in the agenda like this: @@ -8186,7 +8186,7 @@ agenda, change a tag for all headings in the region. @kindex , @item , Set the priority for the current item (@command{org-agenda-priority}). -Org-mode prompts for the priority character. If you reply with @key{SPC}, +Org mode prompts for the priority character. If you reply with @key{SPC}, the priority cookie is removed from the entry. @c @orgcmd{P,org-agenda-show-priority} @@ -8325,7 +8325,7 @@ f @r{Apply a function to marked entries.} Open the Emacs calendar and move to the date at the agenda cursor. @c @orgcmd{c,org-calendar-goto-agenda} -When in the calendar, compute and show the Org-mode agenda for the +When in the calendar, compute and show the Org mode agenda for the date at the cursor. @c @cindex diary entries, creating from agenda @@ -8338,8 +8338,8 @@ file@footnote{This file is parsed for the agenda when command in the calendar. The diary file will pop up in another window, where you can add the entry. -If you configure @code{org-agenda-diary-file} to point to an Org-mode file, -Org will create entries (in org-mode syntax) in that file instead. Most +If you configure @code{org-agenda-diary-file} to point to an Org mode file, +Org will create entries (in Org mode syntax) in that file instead. Most entries will be stored in a date-based outline tree that will later make it easy to archive appointments from previous months/years. The tree will be built under an entry with a @code{DATE_TREE} property, or else with years as @@ -8515,7 +8515,7 @@ command @kbd{C-c a o} provides a similar view for office tasks. @cindex options, for custom agenda views @vindex org-agenda-custom-commands -Org-mode contains a number of variables regulating agenda construction +Org mode contains a number of variables regulating agenda construction and display. The global variables define the behavior for all agenda commands, including the custom commands. However, if you want to change some settings just for a single custom view, you can do so. Setting @@ -8587,7 +8587,7 @@ yourself. @cindex agenda views, exporting If you are away from your computer, it can be very useful to have a printed -version of some agenda views to carry around. Org-mode can export custom +version of some agenda views to carry around. Org mode can export custom agenda views as plain text, HTML@footnote{You need to install Hrvoje Niksic's @file{htmlize.el}.}, Postscript, PDF@footnote{To create PDF output, the ghostscript @file{ps2pdf} utility must be installed on the system. Selecting @@ -8651,7 +8651,7 @@ or absolute. @end lisp The extension of the file name determines the type of export. If it is -@file{.html}, Org-mode will use the @file{htmlize.el} package to convert +@file{.html}, Org mode will use the @file{htmlize.el} package to convert the buffer to HTML and save it to this file name. If the extension is @file{.ps}, @code{ps-print-buffer-with-faces} is used to produce Postscript output. If the extension is @file{.ics}, iCalendar export is @@ -8780,11 +8780,11 @@ the agenda). @node Markup, Exporting, Agenda Views, Top @chapter Markup for rich export -When exporting Org-mode documents, the exporter tries to reflect the +When exporting Org mode documents, the exporter tries to reflect the structure of the document as accurately as possible in the backend. Since export targets like HTML, @LaTeX{}, or DocBook allow much richer formatting, -Org-mode has rules on how to prepare text for rich export. This section -summarizes the markup rules used in an Org-mode buffer. +Org mode has rules on how to prepare text for rich export. This section +summarizes the markup rules used in an Org mode buffer. @menu * Structural markup elements:: The basic structure as seen by the exporter @@ -8876,7 +8876,7 @@ the table of contents entirely, by configuring the variable @cindex text before first headline, markup rules @cindex #+TEXT -Org-mode normally exports the text before the first headline, and even uses +Org mode normally exports the text before the first headline, and even uses the first line as the document title. The text will be fully marked up. If you need to include literal HTML, @LaTeX{}, or DocBook code, use the special constructs described below in the sections for the individual exporters. @@ -8930,7 +8930,7 @@ can use this construct, which can also be used to format poetry. When quoting a passage from another document, it is customary to format this as a paragraph that is indented on both the left and the right margin. You -can include quotations in Org-mode documents like this: +can include quotations in Org mode documents like this: @cindex #+BEGIN_QUOTE @example @@ -8970,7 +8970,7 @@ multiple footnotes side by side. @cindex strike-through text, markup rules You can make words @b{*bold*}, @i{/italic/}, _underlined_, @code{=code=} and @code{~verbatim~}, and, if you must, @samp{+strike-through+}. Text -in the code and verbatim string is not processed for Org-mode specific +in the code and verbatim string is not processed for Org mode specific syntax; it is exported verbatim. @node Horizontal rules, Comment lines, Emphasis and monospace, Structural markup elements @@ -9004,8 +9004,8 @@ Toggle the COMMENT keyword at the beginning of an entry. @cindex tables, markup rules @cindex #+CAPTION @cindex #+LABEL -Both the native Org-mode tables (@pxref{Tables}) and tables formatted with -the @file{table.el} package will be exported properly. For Org-mode tables, +Both the native Org mode tables (@pxref{Tables}) and tables formatted with +the @file{table.el} package will be exported properly. For Org mode tables, the lines before the first horizontal separator line will become table header lines. You can use the following lines somewhere before the table to assign a caption and a label for cross references, and in the text you can refer to @@ -9117,7 +9117,7 @@ cool. You can also add a @code{-r} switch which @i{removes} the labels from the source code@footnote{Adding @code{-k} to @code{-n -r} will @i{keep} the labels in the source code while using line numbers for the links, which might -be useful to explain those in an org-mode example code.}. With the @code{-n} +be useful to explain those in an Org mode example code.}. With the @code{-n} switch, links to these references will be labeled by the line numbers from the code listing, otherwise links will use the labels with no parentheses. Here is an example: @@ -9183,11 +9183,11 @@ include your @file{.emacs} file, you could use: The optional second and third parameter are the markup (e.g.@: @samp{quote}, @samp{example}, or @samp{src}), and, if the markup is @samp{src}, the language for formatting the contents. The markup is optional; if it is not -given, the text will be assumed to be in Org-mode format and will be +given, the text will be assumed to be in Org mode format and will be processed normally. The include line will also allow additional keyword parameters @code{:prefix1} and @code{:prefix} to specify prefixes for the first line and for each following line, @code{:minlevel} in order to get -org-mode content demoted to a specified level, as well as any options +Org mode content demoted to a specified level, as well as any options accepted by the selected markup. For example, to include a file as an item, use @@ -9265,7 +9265,7 @@ include scientific notes, which often require mathematical symbols and the occasional formula. @LaTeX{}@footnote{@LaTeX{} is a macro system based on Donald E. Knuth's @TeX{} system. Many of the features described here as ``@LaTeX{}'' are really from @TeX{}, but for simplicity I am blurring this -distinction.} is widely used to typeset scientific documents. Org-mode +distinction.} is widely used to typeset scientific documents. Org mode supports embedding @LaTeX{} code into its files, because many academics are used to writing and reading @LaTeX{} source code, and because it can be readily processed to produce pretty output for a number of export backends. @@ -9291,7 +9291,7 @@ You can use @LaTeX{} macros to insert special symbols like @samp{\alpha} to indicate the Greek letter, or @samp{\to} to indicate an arrow. Completion for these macros is available, just type @samp{\} and maybe a few letters, and press @kbd{M-@key{TAB}} to see possible completions. Unlike @LaTeX{} -code, Org-mode allows these macros to be present without surrounding math +code, Org mode allows these macros to be present without surrounding math delimiters, for example: @example @@ -9369,7 +9369,7 @@ format sub- and superscripts in a WYSIWYM way. @vindex org-format-latex-header Going beyond symbols and sub- and superscripts, a full formula language is -needed. Org-mode can contain @LaTeX{} math fragments, and it supports ways +needed. Org mode can contain @LaTeX{} math fragments, and it supports ways to process these for several export backends. When exporting to @LaTeX{}, the code is obviously left as it is. When exporting to HTML, Org invokes the @uref{http://www.mathjax.org, MathJax library} (@pxref{Math formatting in @@ -9468,12 +9468,12 @@ preview images. CDLa@TeX{} mode is a minor mode that is normally used in combination with a major @LaTeX{} mode like AUC@TeX{} in order to speed-up insertion of -environments and math templates. Inside Org-mode, you can make use of +environments and math templates. Inside Org mode, you can make use of some of the features of CDLa@TeX{} mode. You need to install @file{cdlatex.el} and @file{texmathp.el} (the latter comes also with AUC@TeX{}) from @url{http://www.astro.uva.nl/~dominik/Tools/cdlatex}. -Don't use CDLa@TeX{} mode itself under Org-mode, but use the light -version @code{org-cdlatex-mode} that comes as part of Org-mode. Turn it +Don't use CDLa@TeX{} mode itself under Org mode, but use the light +version @code{org-cdlatex-mode} that comes as part of Org mode. Turn it on for the current buffer with @code{M-x org-cdlatex-mode}, or for all Org files with @@ -9490,7 +9490,7 @@ Environment templates can be inserted with @kbd{C-c @{}. @item @kindex @key{TAB} The @key{TAB} key will do template expansion if the cursor is inside a -@LaTeX{} fragment@footnote{Org-mode has a method to test if the cursor is +@LaTeX{} fragment@footnote{Org mode has a method to test if the cursor is inside such a fragment, see the documentation of the function @code{org-inside-LaTeX-fragment-p}.}. For example, @key{TAB} will expand @code{fr} to @code{\frac@{@}@{@}} and position the cursor @@ -9527,19 +9527,19 @@ is normal. @chapter Exporting @cindex exporting -Org-mode documents can be exported into a variety of other formats. For +Org mode documents can be exported into a variety of other formats. For printing and sharing of notes, ASCII export produces a readable and simple version of an Org file. HTML export allows you to publish a notes file on the web, while the XOXO format provides a solid base for exchange with a -broad range of other applications. @LaTeX{} export lets you use Org-mode and +broad range of other applications. @LaTeX{} export lets you use Org mode and its structured editing functions to easily create @LaTeX{} files. DocBook export makes it possible to convert Org files to many other formats using DocBook tools. OpenDocument Text(@acronym{ODT}) export allows seamless colloboration across organizational boundaries. For project management you can create gantt and resource charts by using TaskJuggler export. To incorporate entries with associated times like deadlines or appointments into -a desktop calendar program like iCal, Org-mode can also produce extracts in -the iCalendar format. Currently Org-mode only supports export, not import of +a desktop calendar program like iCal, Org mode can also produce extracts in +the iCalendar format. Currently Org mode only supports export, not import of these different formats. Org supports export of selected regions when @code{transient-mark-mode} is @@ -9756,7 +9756,7 @@ not set, or force processing in the current Emacs process if set. @cindex Latin-1 export @cindex UTF-8 export -ASCII export produces a simple and very readable version of an Org-mode +ASCII export produces a simple and very readable version of an Org mode file, containing only plain ASCII. Latin-1 and UTF-8 export augment the file with special characters and symbols available in these encodings. @@ -9815,14 +9815,14 @@ the text and the link in a note before the next heading. See the variable @section HTML export @cindex HTML export -Org-mode contains an HTML (XHTML 1.0 strict) exporter with extensive +Org mode contains an HTML (XHTML 1.0 strict) exporter with extensive HTML formatting, in ways similar to John Gruber's @emph{markdown} language, but with additional support for tables. @menu * HTML Export commands:: How to invoke HTML export * HTML preamble and postamble:: How to insert a preamble and a postamble -* Quoting HTML tags:: Using direct HTML in Org-mode +* Quoting HTML tags:: Using direct HTML in Org mode * Links in HTML export:: How links will be interpreted and formatted * Tables in HTML export:: How to modify the formatting of tables * Images in HTML export:: How to insert figures into HTML output @@ -9860,11 +9860,11 @@ the region. This is good for cut-and-paste operations. @item C-c C-e v h/b/H/R Export only the visible part of the document. @item M-x org-export-region-as-html -Convert the region to HTML under the assumption that it was Org-mode +Convert the region to HTML under the assumption that it was Org mode syntax before. This is a global command that can be invoked in any buffer. @item M-x org-replace-region-by-HTML -Replace the active region (assumed to be in Org-mode syntax) by HTML +Replace the active region (assumed to be in Org mode syntax) by HTML code. @end table @@ -9966,7 +9966,7 @@ and @code{style} attributes for a link: @cindex #+ATTR_HTML @example -#+ATTR_HTML: title="The Org-mode homepage" style="color:red;" +#+ATTR_HTML: title="The Org mode homepage" style="color:red;" [[http://orgmode.org]] @end example @@ -9975,7 +9975,7 @@ and @code{style} attributes for a link: @cindex tables, in HTML @vindex org-export-html-table-tag -Org-mode tables are exported to HTML using the table tag defined in +Org mode tables are exported to HTML using the table tag defined in @code{org-export-html-table-tag}. The default setting makes tables without cell borders and frame. If you would like to change this for individual tables, place something like the following before the table: @@ -10033,7 +10033,7 @@ You could use @code{http} addresses just as well. different ways on HTML pages. The default is to use the @uref{http://www.mathjax.org, MathJax system} which should work out of the box with Org mode installation because @code{http://orgmode.org} serves -@file{MathJax} for Org-mode users for small applications and for testing +@file{MathJax} for Org mode users for small applications and for testing purposes. @b{If you plan to use this regularly or on pages with significant page views, you should install@footnote{Installation instructions can be found on the MathJax website, see @@ -10099,7 +10099,7 @@ addition to any of the standard classes like for headlines, tables, etc. @example p.author @r{author information, including email} p.date @r{publishing date} -p.creator @r{creator info, about org-mode version} +p.creator @r{creator info, about org mode version} .title @r{document title} .todo @r{TODO keywords, all not-done states} .done @r{the DONE keywords, all states that count as done} @@ -10231,7 +10231,7 @@ pages, configure the variable @code{org-export-html-use-infojs}. @cindex PDF export @cindex Guerry, Bastien -Org-mode contains a @LaTeX{} exporter written by Bastien Guerry. With +Org mode contains a @LaTeX{} exporter written by Bastien Guerry. With further processing@footnote{The default LaTeX output is designed for processing with pdftex or latex. It includes packages that are not compatible with xetex and possibly luatex. See the variables @@ -10274,11 +10274,11 @@ Export to a temporary buffer. Do not create a file. @item C-c C-e v l/L Export only the visible part of the document. @item M-x org-export-region-as-latex -Convert the region to @LaTeX{} under the assumption that it was Org-mode +Convert the region to @LaTeX{} under the assumption that it was Org mode syntax before. This is a global command that can be invoked in any buffer. @item M-x org-replace-region-by-latex -Replace the active region (assumed to be in Org-mode syntax) by @LaTeX{} +Replace the active region (assumed to be in Org mode syntax) by @LaTeX{} code. @orgcmd{C-c C-e p,org-export-as-pdf} Export as @LaTeX{} and then process to PDF. @@ -10455,8 +10455,8 @@ If you need references to a label created in this way, write @subsection Beamer class export The LaTeX class @file{beamer} allows production of high quality presentations -using LaTeX and pdf processing. Org-mode has special support for turning an -Org-mode file or tree into a @file{beamer} presentation. +using LaTeX and pdf processing. Org mode has special support for turning an +Org mode file or tree into a @file{beamer} presentation. When the LaTeX class for the current buffer (as set with @code{#+LaTeX_CLASS: beamer}) or subtree (set with a @code{LaTeX_CLASS} property) is @@ -10734,7 +10734,7 @@ set: @cindex #+LABEL @cindex #+ATTR_DOCBOOK @example -#+CAPTION: The logo of Org-mode +#+CAPTION: The logo of Org mode #+LABEL: unicorn-svg #+ATTR_DOCBOOK: scalefit="1" width="100%" depth="100%" [[./img/org-mode-unicorn.svg]] @@ -10932,7 +10932,7 @@ internal links. It creates Internet-style links for all other links. @subsection Tables in @acronym{ODT} export @cindex tables, in DocBook export -Export of native Org-mode tables (@pxref{Tables}) and simple @file{table.el} +Export of native Org mode tables (@pxref{Tables}) and simple @file{table.el} tables is supported. However, export of complex @file{table.el} tables - tables that have column or row spans - is not supported. Such tables are stripped from the exported document. @@ -11641,7 +11641,7 @@ Export as TaskJuggler file and then open the file with TaskJugglerUI. @subsection Tasks @vindex org-export-taskjuggler-project-tag -Create your tasks as you usually do with Org-mode. Assign efforts to each +Create your tasks as you usually do with Org mode. Assign efforts to each task using properties (it is easiest to do this in the column view). You should end up with something similar to the example by Peter Jones in @url{http://www.contextualdevelopment.com/static/artifacts/articles/2008/project-planning/project-planning.org}. @@ -11753,9 +11753,9 @@ file will be @file{myfile.mm}. @section XOXO export @cindex XOXO export -Org-mode contains an exporter that produces XOXO-style output. +Org mode contains an exporter that produces XOXO-style output. Currently, this exporter only handles the general outline structure and -does not interpret any additional Org-mode features. +does not interpret any additional Org mode features. @table @kbd @orgcmd{C-c C-e x,org-export-as-xoxo} @@ -11774,10 +11774,10 @@ Export only the visible part of the document. @vindex org-icalendar-use-scheduled @vindex org-icalendar-categories @vindex org-icalendar-alarm-time -Some people use Org-mode for keeping track of projects, but still prefer a +Some people use Org mode for keeping track of projects, but still prefer a standard calendar application for anniversaries and appointments. In this case it can be useful to show deadlines and other time-stamped items in Org -files in the calendar application. Org-mode can export calendar information +files in the calendar application. Org mode can export calendar information in the standard iCalendar format. If you also want to have TODO entries included in the export, configure the variable @code{org-icalendar-include-todo}. Plain timestamps are exported as VEVENT, @@ -12221,7 +12221,7 @@ Defaults to @code{nil}. @subsection Generating an index @cindex index, in a publishing project -Org-mode can generate an index across the files of a publishing project. +Org mode can generate an index across the files of a publishing project. @multitable @columnfractions 0.25 0.75 @item @code{:makeindex} @@ -12241,7 +12241,7 @@ a title, style information, etc. For those people already utilizing third party sync tools such as @command{rsync} or @command{unison}, it might be preferable not to use the built in -@i{remote} publishing facilities of Org-mode which rely heavily on +@i{remote} publishing facilities of Org mode which rely heavily on Tramp. Tramp, while very useful and powerful, tends not to be so efficient for multiple file transfer and has been known to cause problems under heavy usage. @@ -12380,7 +12380,7 @@ This may be necessary in particular if files include other files via @cindex Davison, Dan @cindex source code, working with -Source code can be included in Org-mode documents using a @samp{src} block, +Source code can be included in Org mode documents using a @samp{src} block, e.g.@: @example @@ -12391,26 +12391,26 @@ e.g.@: #+END_SRC @end example -Org-mode provides a number of features for working with live source code, +Org mode provides a number of features for working with live source code, including editing of code blocks in their native major-mode, evaluation of code blocks, converting code blocks into source files (known as @dfn{tangling} in literate programming), and exporting code blocks and their results in several formats. This functionality was contributed by Eric Schulte and Dan Davison, and was originally named Org-babel. -The following sections describe Org-mode's code block handling facilities. +The following sections describe Org mode's code block handling facilities. @menu * Structure of code blocks:: Code block syntax described * Editing source code:: Language major-mode editing * Exporting code blocks:: Export contents and/or results * Extracting source code:: Create pure source code files -* Evaluating code blocks:: Place results of evaluation in the Org-mode buffer +* Evaluating code blocks:: Place results of evaluation in the Org mode buffer * Library of Babel:: Use and contribute to a library of useful code blocks * Languages:: List of supported code block languages * Header arguments:: Configure code block functionality * Results of evaluation:: How evaluation results are handled -* Noweb reference syntax:: Literate programming in Org-mode +* Noweb reference syntax:: Literate programming in Org mode * Key bindings and useful functions:: Work quickly with code blocks * Batch execution:: Call functions from the command line @end menu @@ -12426,7 +12426,7 @@ The following sections describe Org-mode's code block handling facilities. @cindex #+BEGIN_SRC Live code blocks can be specified with a @samp{src} block or -inline.@footnote{Note that @samp{src} blocks may be inserted using Org-mode's +inline.@footnote{Note that @samp{src} blocks may be inserted using Org mode's @ref{Easy Templates} system} The structure of a @samp{src} block is @example @@ -12456,11 +12456,11 @@ src_[
]@{@} @table @code @item <#+NAME: name> This line associates a name with the code block. This is similar to the -@code{#+TBLNAME: NAME} lines that can be used to name tables in Org-mode +@code{#+TBLNAME: NAME} lines that can be used to name tables in Org mode files. Referencing the name of a code block makes it possible to evaluate -the block from other places in the file, from other files, or from Org-mode +the block from other places in the file, from other files, or from Org mode table formulas (see @ref{The spreadsheet}). Names are assumed to be unique -and the behavior of Org-mode when two or more blocks share the same name is +and the behavior of Org mode when two or more blocks share the same name is undefined. @cindex #+NAME @item @@ -12543,7 +12543,7 @@ The default in most languages. The body of the code block is exported, as described in @ref{Literal examples}. @item :exports results The code block will be evaluated and the results will be placed in the -Org-mode buffer for export, either updating previous results of the code +Org mode buffer for export, either updating previous results of the code block located anywhere in the buffer or, if no previous results exist, placing the results immediately after the code block. The body of the code block will not be exported. @@ -12556,8 +12556,8 @@ Neither the code block nor its results will be exported. It is possible to inhibit the evaluation of code blocks during export. Setting the @code{org-export-babel-evaluate} variable to @code{nil} will ensure that no code blocks are evaluated as part of the export process. This -can be useful in situations where potentially untrusted Org-mode files are -exported in an automated fashion, for example when Org-mode is used as the +can be useful in situations where potentially untrusted Org mode files are +exported in an automated fashion, for example when Org mode is used as the markup language for a wiki. @comment node-name, next, previous, up @@ -12609,13 +12609,13 @@ of tangled code files. @cindex source code, evaluating Code blocks can be evaluated@footnote{Whenever code is evaluated there is a -potential for that code to do harm. Org-mode provides safeguards to ensure +potential for that code to do harm. Org mode provides safeguards to ensure that code is only evaluated after explicit confirmation from the user. For information on these safeguards (and on how to disable them) see @ref{Code evaluation security}.} and the results of evaluation optionally placed in the -Org-mode buffer. By default, the evaluation facility is only enabled for -Lisp code blocks specified as @code{emacs-lisp}. However, souce code blocks -in many languages can be evaluated within Org-mode (see @ref{Languages} for a +Org mode buffer. By default, the evaluation facility is only enabled for +Lisp code blocks specified as @code{emacs-lisp}. However, souce code blocks +in many languages can be evaluated within Org mode (see @ref{Languages} for a list of supported languages and @ref{Structure of code blocks} for information on the syntax used to define a code block). @@ -12625,12 +12625,12 @@ There are a number of ways to evaluate code blocks. The simplest is to press @code{org-babel-no-eval-on-ctrl-c-ctrl-c} variable can be used to remove code evaluation from the @kbd{C-c C-c} key binding.}. This will call the @code{org-babel-execute-src-block} function to evaluate the block and insert -its results into the Org-mode buffer. +its results into the Org mode buffer. @cindex #+CALL It is also possible to evaluate named code blocks from anywhere in an -Org-mode buffer or an Org-mode table. Live code blocks located in the current -Org-mode buffer or in the ``Library of Babel'' (see @ref{Library of Babel}) +Org mode buffer or an Org mode table. Live code blocks located in the current +Org mode buffer or in the ``Library of Babel'' (see @ref{Library of Babel}) can be executed. Named code blocks can be executed with a separate @code{#+CALL:} line or inline within a block of text. @@ -12666,7 +12666,7 @@ everything printed to @code{STDOUT} during execution of the code block. @item End header arguments are applied to the calling instance and do not affect evaluation of the named code block. They affect how the results are -incorporated into the Org-mode buffer and how the call line is exported. For +incorporated into the Org mode buffer and how the call line is exported. For example, @code{:results html} will insert the results of the call line evaluation in the Org buffer, wrapped in a @code{BEGIN_HTML:} block. @@ -12681,21 +12681,21 @@ For more examples of passing header arguments to @code{#+CALL:} lines see @cindex code block, library The ``Library of Babel'' consists of code blocks that can be called from any -Org-mode file. Code blocks defined in the ``Library of Babel'' can be called -remotely as if they were in the current Org-mode buffer (see @ref{Evaluating +Org mode file. Code blocks defined in the ``Library of Babel'' can be called +remotely as if they were in the current Org mode buffer (see @ref{Evaluating code blocks} for information on the syntax of remote code block evaluation). The central repository of code blocks in the ``Library of Babel'' is housed -in an Org-mode file located in the @samp{contrib} directory of Org-mode. +in an Org mode file located in the @samp{contrib} directory of Org mode. Users can add code blocks they believe to be generally useful to their -``Library of Babel.'' The code blocks can be stored in any Org-mode file and +``Library of Babel.'' The code blocks can be stored in any Org mode file and then loaded into the library with @code{org-babel-lob-ingest}. @kindex C-c C-v i -Code blocks located in any Org-mode file can be loaded into the ``Library of +Code blocks located in any Org mode file can be loaded into the ``Library of Babel'' with the @code{org-babel-lob-ingest} function, bound to @kbd{C-c C-v i}. @@ -12720,7 +12720,7 @@ Code blocks in the following languages are supported. @item Ledger @tab ledger @tab Lisp @tab lisp @item Lilypond @tab lilypond @tab MATLAB @tab matlab @item Mscgen @tab mscgen @tab Objective Caml @tab ocaml -@item Octave @tab octave @tab Org-mode @tab org +@item Octave @tab octave @tab Org mode @tab org @item Oz @tab oz @tab Perl @tab perl @item Plantuml @tab plantuml @tab Python @tab python @item R @tab R @tab Ruby @tab ruby @@ -12784,7 +12784,7 @@ specific (and having higher priority) than the last. * System-wide header arguments:: Set global default values * Language-specific header arguments:: Set default values by language * Buffer-wide header arguments:: Set default values for a specific buffer -* Header arguments in Org-mode properties:: Set default values for a buffer or heading +* Header arguments in Org mode properties:: Set default values for a buffer or heading * Code block specific header arguments:: The most common way to set values * Header arguments in function calls:: The most specific level @end menu @@ -12835,10 +12835,10 @@ Each language can define its own set of default header arguments. See the language-specific documentation available online at @uref{http://orgmode.org/worg/org-contrib/babel}. -@node Buffer-wide header arguments, Header arguments in Org-mode properties, Language-specific header arguments, Using header arguments +@node Buffer-wide header arguments, Header arguments in Org mode properties, Language-specific header arguments, Using header arguments @subsubheading Buffer-wide header arguments Buffer-wide header arguments may be specified as properties through the use -of @code{#+PROPERTY:} lines placed anywhere in an Org-mode file (see +of @code{#+PROPERTY:} lines placed anywhere in an Org mode file (see @ref{Property syntax}). For example the following would set @code{session} to @code{*R*}, and @@ -12851,10 +12851,10 @@ inserted into the buffer. #+PROPERTY: results silent @end example -@node Header arguments in Org-mode properties, Code block specific header arguments, Buffer-wide header arguments, Using header arguments -@subsubheading Header arguments in Org-mode properties +@node Header arguments in Org mode properties, Code block specific header arguments, Buffer-wide header arguments, Using header arguments +@subsubheading Header arguments in Org mode properties -Header arguments are also read from Org-mode properties (see @ref{Property +Header arguments are also read from Org mode properties (see @ref{Property syntax}), which can be set on a buffer-wide or per-heading basis. An example of setting a header argument for all code blocks in a buffer is @@ -12881,9 +12881,9 @@ blocks in the subtree rooted at the following heading: Properties defined in this way override the properties set in @code{org-babel-default-header-args}. It is convenient to use the @code{org-set-property} function bound to @kbd{C-c C-x p} to set properties -in Org-mode documents. +in Org mode documents. -@node Code block specific header arguments, Header arguments in function calls, Header arguments in Org-mode properties, Using header arguments +@node Code block specific header arguments, Header arguments in function calls, Header arguments in Org mode properties, Using header arguments @subsubheading Code block specific header arguments The most common way to assign values to header arguments is at the @@ -13006,8 +13006,8 @@ syntax used to specify arguments is the same across all languages. In every case, variables require a default value when they are declared. The values passed to arguments can either be literal values, references, or -Emacs Lisp code (see @ref{var, Emacs Lisp evaluation of variables}). References -include anything in the Org-mode file that takes a @code{#+NAME:}, +Emacs Lisp code (see @ref{var, Emacs Lisp evaluation of variables}). References +include anything in the Org mode file that takes a @code{#+NAME:}, @code{#+TBLNAME:}, or @code{#+RESULTS:} line. This includes tables, lists, @code{#+BEGIN_EXAMPLE} blocks, other code blocks, and the results of other code blocks. @@ -13234,9 +13234,9 @@ Emacs lisp code can be used to initialize variable values. When a variable value starts with @code{(}, @code{[}, @code{'} or @code{`} it will be evaluated as Emacs Lisp and the result of the evaluation will be assigned as the variable value. The following example demonstrates use of this -evaluation to reliably pass the file-name of the org-mode buffer to a code +evaluation to reliably pass the file-name of the Org mode buffer to a code block---note that evaluation of header arguments is guaranteed to take place -in the original Org-mode file, while there is no such guarantee for +in the original Org mode file, while there is no such guarantee for evaluation of the code block body. @example @@ -13274,7 +13274,7 @@ from the code block @item @b{type} header arguments specify what type of result the code block will return---which has implications for how they will be inserted into the -Org-mode buffer +Org mode buffer @item @b{handling} header arguments specify how the results of evaluating the code block should be handled. @@ -13305,23 +13305,23 @@ table or scalar depending on their value. @itemize @bullet @item @code{table}, @code{vector} -The results should be interpreted as an Org-mode table. If a single value is +The results should be interpreted as an Org mode table. If a single value is returned, it will be converted into a table with one row and one column. E.g., @code{:results value table}. @item @code{list} -The results should be interpreted as an Org-mode list. If a single scalar +The results should be interpreted as an Org mode list. If a single scalar value is returned it will be converted into a list with only one element. @item @code{scalar}, @code{verbatim} The results should be interpreted literally---they will not be -converted into a table. The results will be inserted into the Org-mode +converted into a table. The results will be inserted into the Org mode buffer as quoted text. E.g., @code{:results value verbatim}. @item @code{file} The results will be interpreted as the path to a file, and will be inserted -into the Org-mode buffer as a file link. E.g., @code{:results value file}. +into the Org mode buffer as a file link. E.g., @code{:results value file}. @item @code{raw}, @code{org} -The results are interpreted as raw Org-mode code and are inserted directly +The results are interpreted as raw Org mode code and are inserted directly into the buffer. If the results look like a table they will be aligned as -such by Org-mode. E.g., @code{:results value raw}. +such by Org mode. E.g., @code{:results value raw}. @item @code{html} Results are assumed to be HTML and will be enclosed in a @code{begin_html} block. E.g., @code{:results value html}. @@ -13348,10 +13348,10 @@ results once they are collected. @itemize @bullet @item @code{silent} The results will be echoed in the minibuffer but will not be inserted into -the Org-mode buffer. E.g., @code{:results output silent}. +the Org mode buffer. E.g., @code{:results output silent}. @item @code{replace} The default value. Any existing results will be removed, and the new results -will be inserted into the Org-mode buffer in their place. E.g., +will be inserted into the Org mode buffer in their place. E.g., @code{:results output replace}. @item @code{append} If there are pre-existing results of the code block then the new results will @@ -13367,9 +13367,9 @@ inserted as with @code{replace}. @subsubsection @code{:file} The header argument @code{:file} is used to specify an external file in which -to save code block results. After code block evaluation an Org-mode style +to save code block results. After code block evaluation an Org mode style @code{[[file:]]} link (see @ref{Link format}) to the file will be inserted -into the Org-mode buffer. Some languages including R, gnuplot, dot, and +into the Org mode buffer. Some languages including R, gnuplot, dot, and ditaa provide special handling of the @code{:file} header argument automatically wrapping the code block body in the boilerplate code required to save output to the specified file. This is often useful for saving @@ -13413,9 +13413,9 @@ plot(1:10, main=system("hostname", intern=TRUE)) #+END_SRC @end example -Text results will be returned to the local Org-mode buffer as usual, and file +Text results will be returned to the local Org mode buffer as usual, and file output will be created on the remote machine with relative paths interpreted -relative to the remote directory. An Org-mode link to the remote file will be +relative to the remote directory. An Org mode link to the remote file will be created. So, in the above example a plot will be created on the remote machine, @@ -13451,7 +13451,7 @@ which the link does not point. @subsubsection @code{:exports} The @code{:exports} header argument specifies what should be included in HTML -or LaTeX exports of the Org-mode file. +or LaTeX exports of the Org mode file. @itemize @bullet @item @code{code} @@ -13476,14 +13476,14 @@ block should be included in tangled extraction of source code files. @itemize @bullet @item @code{tangle} The code block is exported to a source code file named after the full path -(including the directory) and file name (w/o extension) of the Org-mode file. +(including the directory) and file name (w/o extension) of the Org mode file. E.g., @code{:tangle yes}. @item @code{no} The default. The code block is not exported to a source code file. E.g., @code{:tangle no}. @item other Any other string passed to the @code{:tangle} header argument is interpreted -as a path (directory and file name relative to the directory of the Org-mode +as a path (directory and file name relative to the directory of the Org mode file) to which the block will be exported. E.g., @code{:tangle path}. @end itemize @@ -13510,7 +13510,7 @@ original Org file from which the code was tangled. @item @code{yes} A synonym for ``link'' to maintain backwards compatibility. @item @code{org} -Include text from the org-mode file as a comment. +Include text from the Org mode file as a comment. The text is picked from the leading context of the tangled code and is limited by the nearest headline or source block as the case may be. @@ -13611,7 +13611,7 @@ concatenated together to form the replacement text. By setting this header argument at the sub-tree or file level, simple code block concatenation may be achieved. For example, when tangling the -following Org-mode file, the bodies of code blocks will be concatenated into +following Org mode file, the bodies of code blocks will be concatenated into the resulting pure code file. @example @@ -13692,7 +13692,7 @@ changed since it was last run. @subsubsection @code{:sep} The @code{:sep} header argument can be used to control the delimiter used -when writing tabular results out to files external to Org-mode. This is used +when writing tabular results out to files external to Org mode. This is used either when opening tabular results of a code block by calling the @code{org-open-at-point} function bound to @kbd{C-c C-o} on the code block, or when writing code block results to an external file (see @ref{file}) @@ -13891,7 +13891,7 @@ of the possible results header arguments see @ref{results}. @end multitable Note: With @code{:results value}, the result in both @code{:session} and -non-session is returned to Org-mode as a table (a one- or two-dimensional +non-session is returned to Org mode as a table (a one- or two-dimensional vector of strings or numbers) when appropriate. @subsection Non-session @@ -13996,7 +13996,7 @@ the default value. @section Key bindings and useful functions @cindex code block, key bindings -Many common Org-mode key sequences are re-bound depending on +Many common Org mode key sequences are re-bound depending on the context. Within a code block, the following key bindings @@ -14013,7 +14013,7 @@ are active: @item @kbd{M-@key{down}} @tab @code{org-babel-pop-to-session} @end multitable -In an Org-mode buffer, the following key bindings are active: +In an Org mode buffer, the following key bindings are active: @multitable @columnfractions 0.45 0.55 @kindex C-c C-v a @@ -14130,7 +14130,7 @@ emacs -Q --batch -l $ORGINSTALL \ @cindex tag completion @cindex link abbreviations, completion of -Emacs would not be Emacs without completion, and Org-mode uses it whenever it +Emacs would not be Emacs without completion, and Org mode uses it whenever it makes sense. If you prefer an @i{iswitchb}- or @i{ido}-like interface for some of the completion prompts, you can specify your preference by setting at most one of the variables @code{org-completion-use-iswitchb} @@ -14165,7 +14165,7 @@ buffer. After @samp{[}, complete link abbreviations (@pxref{Link abbreviations}). @item After @samp{#+}, complete the special keywords like @samp{TYP_TODO} or -@samp{OPTIONS} which set file-specific options for Org-mode. When the +@samp{OPTIONS} which set file-specific options for Org mode. When the option keyword is already complete, pressing @kbd{M-@key{TAB}} again will insert example settings for this keyword. @item @@ -14181,7 +14181,7 @@ Elsewhere, complete dictionary words using Ispell. @cindex template insertion @cindex insertion, of templates -Org-mode supports insertion of empty structural elements (like +Org mode supports insertion of empty structural elements (like @code{#+BEGIN_SRC} and @code{#+END_SRC} pairs) with just a few key strokes. This is achieved through a native template expansion mechanism. Note that Emacs has several other template mechanisms which could be used in @@ -14313,7 +14313,7 @@ lines into the buffer (@pxref{In-buffer settings}). @cindex in-buffer settings @cindex special keywords -Org-mode uses special lines in the buffer to define settings on a +Org mode uses special lines in the buffer to define settings on a per-file basis. These lines start with a @samp{#+} followed by a keyword, a colon, and then individual words defining a setting. Several setting words can be in the same line, but you can also have multiple @@ -14372,14 +14372,14 @@ buffer, most useful for specifying the allowed values of a property. @item #+SETUPFILE: file This line defines a file that holds more in-buffer setup. Normally this is entirely ignored. Only when the buffer is parsed for option-setting lines -(i.e.@: when starting Org-mode for a file, when pressing @kbd{C-c C-c} in a +(i.e.@: when starting Org mode for a file, when pressing @kbd{C-c C-c} in a settings line, or when exporting), then the contents of this file are parsed as if they had been included in the buffer. In particular, the file can be -any other Org-mode file with internal setup. You can visit the file the +any other Org mode file with internal setup. You can visit the file the cursor is in the line with @kbd{C-c '}. @item #+STARTUP: @cindex #+STARTUP: -This line sets options to be used at startup of Org-mode, when an +This line sets options to be used at startup of Org mode, when an Org file is being visited. The first set of options deals with the initial visibility of the outline @@ -14402,7 +14402,7 @@ showeverything @r{show even drawer contents} @cindex @code{indent}, STARTUP keyword @cindex @code{noindent}, STARTUP keyword Dynamic virtual indentation is controlled by the variable -@code{org-startup-indented}@footnote{Emacs 23 and Org-mode 6.29 are required} +@code{org-startup-indented}@footnote{Emacs 23 and Org mode 6.29 are required} @example indent @r{start with @code{org-indent-mode} turned on} noindent @r{start with @code{org-indent-mode} turned off} @@ -14833,11 +14833,11 @@ setup. See the installation instructions in the file @item @file{cdlatex.el} by Carsten Dominik @cindex @file{cdlatex.el} @cindex Dominik, Carsten -Org-mode can make use of the CDLa@TeX{} package to efficiently enter +Org mode can make use of the CDLa@TeX{} package to efficiently enter @LaTeX{} fragments into Org files. See @ref{CDLaTeX mode}. @item @file{imenu.el} by Ake Stenhoff and Lars Lindberg @cindex @file{imenu.el} -Imenu allows menu access to an index of items in a file. Org-mode +Imenu allows menu access to an index of items in a file. Org mode supports Imenu---all you need to do to get the index is the following: @lisp (add-hook 'org-mode-hook @@ -14854,7 +14854,7 @@ Org used to use this package for capture, but no longer does. @cindex @file{speedbar.el} @cindex Ludlam, Eric M. Speedbar is a package that creates a special frame displaying files and -index items in files. Org-mode supports Speedbar and allows you to +index items in files. Org mode supports Speedbar and allows you to drill into Org files directly from the Speedbar. It also allows you to restrict the scope of agenda commands to a file or a subtree by using the command @kbd{<} in the Speedbar frame. @@ -14868,8 +14868,8 @@ the command @kbd{<} in the Speedbar frame. Complex ASCII tables with automatic line wrapping, column- and row-spanning, and alignment can be created using the Emacs table package by Takaaki Ota (@uref{http://sourceforge.net/projects/table}, and also part of Emacs 22). -Org-mode will recognize these tables and export them properly. Because of -interference with other Org-mode functionality, you unfortunately cannot edit +Org mode will recognize these tables and export them properly. Because of +interference with other Org mode functionality, you unfortunately cannot edit these tables directly in the buffer. Instead, you need to use the command @kbd{C-c '} to edit them, similar to source code snippets. @@ -14879,7 +14879,7 @@ Edit a @file{table.el} table. Works when the cursor is in a table.el table. @c @orgcmd{C-c ~,org-table-create-with-table.el} Insert a @file{table.el} table. If there is already a table at point, this -command converts it between the @file{table.el} format and the Org-mode +command converts it between the @file{table.el} format and the Org mode format. See the documentation string of the command @code{org-convert-table} for the restrictions under which this is possible. @@ -14888,13 +14888,13 @@ possible. @item @file{footnote.el} by Steven L. Baur @cindex @file{footnote.el} @cindex Baur, Steven L. -Org-mode recognizes numerical footnotes as provided by this package. -However, Org-mode also has its own footnote support (@pxref{Footnotes}), +Org mode recognizes numerical footnotes as provided by this package. +However, Org mode also has its own footnote support (@pxref{Footnotes}), which makes using @file{footnote.el} unnecessary. @end table @node Conflicts, , Cooperation, Interaction -@subsection Packages that lead to conflicts with Org-mode +@subsection Packages that lead to conflicts with Org mode @table @asis @@ -14906,7 +14906,7 @@ This conflicts with the use of @kbd{S-@key{cursor}} commands in Org to change timestamps, TODO keywords, priorities, and item bullet types if the cursor is at such a location. By default, @kbd{S-@key{cursor}} commands outside special contexts don't do anything, but you can customize the variable -@code{org-support-shift-select}. Org-mode then tries to accommodate shift +@code{org-support-shift-select}. Org mode then tries to accommodate shift selection by (i) using it outside of the special contexts where special commands apply, and by (ii) extending an existing active region even if the cursor moves across a special context. @@ -14921,7 +14921,7 @@ region. In fact, Emacs 23 has this built-in in the form of @code{shift-selection-mode}, see previous paragraph. If you are using Emacs 23, you probably don't want to use another package for this purpose. However, if you prefer to leave these keys to a different package while working in -Org-mode, configure the variable @code{org-replace-disputed-keys}. When set, +Org mode, configure the variable @code{org-replace-disputed-keys}. When set, Org will move the following key bindings in Org files, and in the agenda buffer (but not during date selection). @@ -14973,7 +14973,7 @@ Then, tell Org mode what to do with the new function: @cindex @file{windmove.el} This package also uses the @kbd{S-} keys, so everything written in the paragraph above about CUA mode also applies here. If you want make -the windmove function active in locations where Org-mode does not have +the windmove function active in locations where Org mode does not have special functionality on @kbd{S-@key{cursor}}, add this to your configuration: @@ -14989,7 +14989,7 @@ configuration: @cindex @file{viper.el} @kindex C-c / Viper uses @kbd{C-c /} and therefore makes this key not access the -corresponding Org-mode command @code{org-sparse-tree}. You need to find +corresponding Org mode command @code{org-sparse-tree}. You need to find another key for this command, or override the key in @code{viper-vi-global-user-map} with @@ -15074,7 +15074,7 @@ maintained by the Worg project and can be found at A large number of add-on packages have been written by various authors. These packages are not part of Emacs, but they are distributed as contributed -packages with the separate release available at the Org-mode home page at +packages with the separate release available at the Org mode home page at @uref{http://orgmode.org}. The list of contributed packages, along with documentation about each package, is maintained by the Worg project at @uref{http://orgmode.org/worg/org-contrib/}. @@ -15198,7 +15198,7 @@ Add-ons can tap into this functionality by providing a function that detects special context for that add-on and executes functionality appropriate for the context. Here is an example from Dan Davison's @file{org-R.el} which allows you to evaluate commands based on the @file{R} programming language -@footnote{@file{org-R.el} has been replaced by the org-mode functionality +@footnote{@file{org-R.el} has been replaced by the Org mode functionality described in @ref{Working With Source Code} and is now obsolete.}. For this package, special contexts are lines that start with @code{#+R:} or @code{#+RR:}. @@ -16016,7 +16016,7 @@ The following example counts the number of entries with TODO keyword @uref{http://mobileorg.ncogni.to/, MobileOrg} is an application for the @i{iPhone/iPod Touch} series of devices, developed by Richard Moreland. -@i{MobileOrg} offers offline viewing and capture support for an Org-mode +@i{MobileOrg} offers offline viewing and capture support for an Org mode system rooted on a ``real'' computer. It does also allow you to record changes to existing entries. Android users should check out @uref{http://wiki.github.com/matburt/mobileorg-android/, MobileOrg Android} @@ -16045,7 +16045,7 @@ in-buffer settings, but it will understand the logistics of TODO state MobileOrg needs to interact with Emacs through a directory on a server. If you are using a public server, you should consider to encrypt the files that are -uploaded to the server. This can be done with Org-mode 7.02 and with +uploaded to the server. This can be done with Org mode 7.02 and with @i{MobileOrg 1.5} (iPhone version), and you need an @file{openssl} installation on your system. To turn on encryption, set a password in @i{MobileOrg} and, on the Emacs side, configure the variable @@ -16068,7 +16068,7 @@ Emacs about it: (setq org-mobile-directory "~/Dropbox/MobileOrg") @end lisp -Org-mode has commands to put files for @i{MobileOrg} into that directory, +Org mode has commands to put files for @i{MobileOrg} into that directory, and to read captured notes from there. @node Pushing to MobileOrg, Pulling from MobileOrg, Setting up the staging area, MobileOrg @@ -16081,7 +16081,7 @@ can be included by customizing @code{org-mobile-files}. File names will be staged with paths relative to @code{org-directory}, so all files should be inside this directory. The push operation also creates a special Org file @file{agendas.org} with all custom agenda view defined by the -user@footnote{While creating the agendas, Org-mode will force ID properties +user@footnote{While creating the agendas, Org mode will force ID properties on all referenced entries, so that these entries can be uniquely identified if @i{MobileOrg} flags them for further action. If you do not want to get these properties in so many entries, you can set the variable @@ -16217,13 +16217,13 @@ know what I am missing here! @i{Thomas Baumann} wrote @file{org-bbdb.el} and @file{org-mhe.el}. @item @i{Christophe Bataillon} created the great unicorn logo that we use on the -Org-mode website. +Org mode website. @item @i{Alex Bochannek} provided a patch for rounding timestamps. @item @i{Jan Böcker} wrote @file{org-docview.el}. @item -@i{Brad Bozarth} showed how to pull RSS feed data into Org-mode files. +@i{Brad Bozarth} showed how to pull RSS feed data into Org mode files. @item @i{Tom Breton} wrote @file{org-choose.el}. @item From 6f916bc61b803851a5b5948becaf990243da6f76 Mon Sep 17 00:00:00 2001 From: Bastien Guerry Date: Tue, 20 Dec 2011 23:22:29 +0100 Subject: [PATCH 11/44] * org.texi (Plain lists, Agenda files): Add index entries. --- doc/org.texi | 2 ++ 1 file changed, 2 insertions(+) diff --git a/doc/org.texi b/doc/org.texi index 9d9dd81fa..5781f46a7 100644 --- a/doc/org.texi +++ b/doc/org.texi @@ -1642,6 +1642,7 @@ to disable them individually. @table @asis @orgcmd{@key{TAB},org-cycle} +@cindex cycling, in plain lists @vindex org-cycle-include-plain-lists Items can be folded just like headline levels. Normally this works only if the cursor is on a plain list item. For more details, see the variable @@ -7138,6 +7139,7 @@ the front. With a prefix argument, file is added/moved to the end. @orgcmd{C-c ],org-remove-file} Remove current file from the list of agenda files. @kindex C-, +@cindex cycling, of agenda files @orgcmd{C-',org-cycle-agenda-files} @itemx C-, Cycle through agenda file list, visiting one file after the other. From 3305602f746b7a9e1cd8932eda5f9d0a85e75094 Mon Sep 17 00:00:00 2001 From: David Maus Date: Sun, 18 Dec 2011 19:23:57 +0100 Subject: [PATCH 12/44] Escape link path only if path contains space or non-ascii character * org.el (org-open-at-point): Escape link path for http:, https:, ftp:, news:, and doi: links only if the path contains space or non-ascii character. This should take care of mistakenly double-escaped links as reported by Jeff Horn in . We are just guessing here and push the responsibility for proper escaping to the target application. --- lisp/org.el | 13 ++++++++----- 1 file changed, 8 insertions(+), 5 deletions(-) diff --git a/lisp/org.el b/lisp/org.el index 9980d03d7..7e243676a 100644 --- a/lisp/org.el +++ b/lisp/org.el @@ -9569,13 +9569,16 @@ application the system uses for this file type." (apply cmd (nreverse args1)))) ((member type '("http" "https" "ftp" "news")) - (browse-url (concat type ":" (org-link-escape - path org-link-escape-chars-browser)))) + (browse-url (concat type ":" (if (org-string-match-p "[[:nonascii:] ]" path) + (org-link-escape + path org-link-escape-chars-browser) + path)))) ((string= type "doi") - (browse-url (concat "http://dx.doi.org/" - (org-link-escape - path org-link-escape-chars-browser)))) + (browse-url (concat "http://dx.doi.org/" (if (org-string-match-p "[[:nonascii:] ]" path) + (org-link-escape + path org-link-escape-chars-browser) + path)))) ((member type '("message")) (browse-url (concat type ":" path))) From 26d54bbc805c015dd5619a95f945ba2f151bae82 Mon Sep 17 00:00:00 2001 From: Bastien Guerry Date: Wed, 21 Dec 2011 19:41:41 +0100 Subject: [PATCH 13/44] org.texi (Plain lists): Fix misplaced explantion. * org.texi (Plain lists): Fix misplaced explantion. Thanks to Takaaki ISHIKAWA for spotting this and for a patch to this effect. --- doc/org.texi | 14 ++++++-------- 1 file changed, 6 insertions(+), 8 deletions(-) diff --git a/doc/org.texi b/doc/org.texi index 5781f46a7..f2f28b8e7 100644 --- a/doc/org.texi +++ b/doc/org.texi @@ -1648,9 +1648,12 @@ Items can be folded just like headline levels. Normally this works only if the cursor is on a plain list item. For more details, see the variable @code{org-cycle-include-plain-lists}. If this variable is set to @code{integrate}, plain list items will be treated like low-level -headlines. The level of an item is then given by the -indentation of the bullet/number. Items are always subordinate to real -headlines, however; the hierarchies remain completely separated. +headlines. The level of an item is then given by the indentation of the +bullet/number. Items are always subordinate to real headlines, however; the +hierarchies remain completely separated. In a new item with no text yet, the +first @key{TAB} demotes the item to become a child of the previous +one. Subsequent @key{TAB}s move the item to meaningful levels in the list +and eventually get it back to its initial position. @orgcmd{M-@key{RET},org-insert-heading} @vindex org-M-RET-may-split-line @vindex org-list-automatic-rules @@ -1664,11 +1667,6 @@ one. @kindex M-S-@key{RET} @item M-S-@key{RET} Insert a new item with a checkbox (@pxref{Checkboxes}). -@orgcmd{@key{TAB},org-cycle} -In a new item with no text yet, the first @key{TAB} demotes the item to -become a child of the previous one. Subsequent @key{TAB}s move the item to -meaningful levels in the list and eventually get it back to its initial -position. @kindex S-@key{down} @item S-@key{up} @itemx S-@key{down} From 090f802003f595c5f3f093a2f326374d8a347467 Mon Sep 17 00:00:00 2001 From: Bastien Guerry Date: Fri, 23 Dec 2011 17:40:37 +0100 Subject: [PATCH 14/44] org-exp-blocks.el: Fix regexp for matching the end of a block. * org-exp-blocks.el (org-export-blocks-preprocess): Fix regexp for matching the end of a block. Thanks to Robert Lupton the Good for reporting this and to Nick Dokos for digging the issue further. --- lisp/org-exp-blocks.el | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lisp/org-exp-blocks.el b/lisp/org-exp-blocks.el index 940068aee..3396d5812 100644 --- a/lisp/org-exp-blocks.el +++ b/lisp/org-exp-blocks.el @@ -178,7 +178,7 @@ which defaults to the value of `org-export-blocks-witheld'." (let* ((match-start (copy-marker (match-beginning 0))) (body-start (copy-marker (match-end 0))) (indentation (length (match-string 1))) - (inner-re (format "[\r\n][ \t]*#\\+\\(begin\\|end\\)_%s" + (inner-re (format "^[ \t]*#\\+\\(begin\\|end\\)_%s" (regexp-quote (downcase (match-string 2))))) (type (intern (downcase (match-string 2)))) (headers (save-match-data From 024ae841918fa8c78b54497f0a6bde6ca58c3675 Mon Sep 17 00:00:00 2001 From: Jambunathan K Date: Sat, 24 Dec 2011 09:36:29 +0530 Subject: [PATCH 15/44] org-odt.el: Honor author. timestamp and email options in preamble * org-odt.el (org-odt-format-preamble): Honor following user options: author, timestamp and email. See http://lists.gnu.org/archive/html/emacs-orgmode/2011-12/msg00539.html --- lisp/org-odt.el | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/lisp/org-odt.el b/lisp/org-odt.el index d5be1e16a..b2c6f334d 100644 --- a/lisp/org-odt.el +++ b/lisp/org-odt.el @@ -495,7 +495,11 @@ PUB-DIR is set, use this as the publishing directory." (date (plist-get opt-plist :date)) (iso-date (org-odt-format-date date)) (date (org-odt-format-date date "%d %b %Y")) - (email (plist-get opt-plist :email))) + (email (plist-get opt-plist :email)) + ;; switch on or off above vars based on user settings + (author (and (plist-get opt-plist :author-info) (or author email))) + (email (and (plist-get opt-plist :email-info) email)) + (date (and (plist-get opt-plist :time-stamp-file) date))) (concat ;; title (when title @@ -505,7 +509,6 @@ PUB-DIR is set, use this as the publishing directory." '("" . "") title)) ;; separator "")) - (cond ((and author (not email)) ;; author only From d75585cc2e22ad64b34534ee6fcacbdbd0b74704 Mon Sep 17 00:00:00 2001 From: Jambunathan K Date: Sat, 24 Dec 2011 11:33:54 +0530 Subject: [PATCH 16/44] org-odt.el (org-odt-styles-dir): It is etc/org/ under vanilla Emacs * org-odt.el (org-odt-styles-dir): Assume that the styles files are located under `data-directory' of Emacs distribution as etc/org/OrgOdtStyles.xml and etc/org/OrgOdtContentTemplate.xml. Also update docstring. (org-export-odt-schema-dir): Update docstring. --- lisp/org-odt.el | 32 ++++++++++++++++++++++++-------- 1 file changed, 24 insertions(+), 8 deletions(-) diff --git a/lisp/org-odt.el b/lisp/org-odt.el index b2c6f334d..d23909a74 100644 --- a/lisp/org-odt.el +++ b/lisp/org-odt.el @@ -77,8 +77,9 @@ (defconst org-odt-lib-dir (file-name-directory load-file-name)) (defconst org-odt-styles-dir - (let* ((styles-dir1 (expand-file-name "../etc/styles/" org-odt-lib-dir)) - (styles-dir2 (expand-file-name "./etc/styles/" org-odt-lib-dir)) + (let* ((styles-dir1 (expand-file-name "../etc/styles/" org-odt-lib-dir)) ; git + (styles-dir2 (expand-file-name "./etc/styles/" org-odt-lib-dir)) ; elpa + (styles-dir3 (expand-file-name "./etc/org/" data-directory)) ; system (styles-dir (catch 'styles-dir (mapc (lambda (styles-dir) @@ -89,7 +90,7 @@ (expand-file-name "OrgOdtStyles.xml" styles-dir))) (throw 'styles-dir styles-dir))) - (list styles-dir1 styles-dir2)) + (list styles-dir1 styles-dir2 styles-dir3)) nil))) (unless styles-dir (error "Cannot find factory styles file. Check package dir layout")) @@ -100,7 +101,12 @@ This directory contains the following XML files - \"OrgOdtStyles.xml\" and \"OrgOdtContentTemplate.xml\". These XML files are used as the default values of `org-export-odt-styles-file' and - `org-export-odt-content-template-file'.") + `org-export-odt-content-template-file'. + +The default value of this variable varies depending on the +version of org in use. Note that the user could be using org +from one of: org's own private git repository, GNU ELPA tar or +standard Emacs.") (defcustom org-export-odt-schema-dir (let ((schema-dir (expand-file-name @@ -115,10 +121,20 @@ This directory contains the following XML files - (prog1 nil (message "Unable to locate OpenDocument schema files.")))) "Directory that contains OpenDocument schema files. -This directory contains rnc files for OpenDocument schema. It -also contains a \"schemas.xml\" that can be added to -`rng-schema-locating-files' for auto validation of OpenDocument -XML files. See also `rng-nxml-auto-validate-flag'." +This directory contains: +1. rnc files for OpenDocument schema +2. a \"schemas.xml\" file that specifies locating rules needed + for auto validation of OpenDocument XML files. + +Use the customize interface to set this variable. This ensures +that `rng-schema-locating-files' is updated and auto-validation +of OpenDocument XML takes place based on the value +`rng-nxml-auto-validate-flag'. + +The default value of this variable varies depending on the +version of org in use. The OASIS schema files are available only +in the org's private git repository. It is *not* bundled with +GNU ELPA tar or standard Emacs distribution." :type '(choice (const :tag "Not set" nil) (directory :tag "Schema directory")) From f49108a6548149a793e2adf32b8d7e690b704ca7 Mon Sep 17 00:00:00 2001 From: Jambunathan K Date: Sat, 24 Dec 2011 12:18:45 +0530 Subject: [PATCH 17/44] org-odt.el: Declare vars and functions from htmlfontify --- lisp/org-odt.el | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/lisp/org-odt.el b/lisp/org-odt.el index d23909a74..b6723caed 100644 --- a/lisp/org-odt.el +++ b/lisp/org-odt.el @@ -27,10 +27,7 @@ ;;; Code: (eval-when-compile - (require 'cl) - ;; htmlfontify.el was introduce in Emacs 23.2 - (when (>= (string-to-number emacs-version) 23.2) - (require 'htmlfontify))) + (require 'cl)) (require 'org-lparse) (defgroup org-export-odt nil @@ -1195,6 +1192,10 @@ This style is much the same as that of \"OrgFixedWidthBlock\" except that the foreground and background colors are set according to the default face identified by the `htmlfontify'.") +(defvar hfy-optimisations) +(declare-function hfy-face-to-style "htmlfontify" (fn)) +(declare-function hfy-face-or-def-to-name "htmlfontify" (fn)) + (defun org-odt-hfy-face-to-css (fn) "Create custom style for face FN. When FN is the default face, use it's foreground and background @@ -1297,6 +1298,8 @@ value of `org-export-odt-fontify-srcblocks." lines (funcall (or (and org-export-odt-fontify-srcblocks (or (featurep 'htmlfontify) + ;; htmlfontify.el was introduced in Emacs 23.2 + ;; So load it with some caution (require 'htmlfontify nil t)) (fboundp 'htmlfontify-string) 'org-odt-format-source-code-or-example-colored) From a2c242a4335cc55703007c9f60b641f37b4ea6f6 Mon Sep 17 00:00:00 2001 From: Bastien Guerry Date: Sun, 25 Dec 2011 09:36:20 +0100 Subject: [PATCH 18/44] org.texi: Normalize the use of @LaTeX{} in the manual. Thanks to Elias Assarsson for mentioning this problem. --- doc/org.texi | 134 +++++++++++++++++++++++++-------------------------- 1 file changed, 67 insertions(+), 67 deletions(-) diff --git a/doc/org.texi b/doc/org.texi index f2f28b8e7..bf78e7db5 100644 --- a/doc/org.texi +++ b/doc/org.texi @@ -541,7 +541,7 @@ Markup for rich export * Include files:: Include additional files into a document * Index entries:: Making an index * Macro replacement:: Use macros to create complex output -* Embedded LaTeX:: LaTeX can be freely used inside Org documents +* Embedded @LaTeX{}:: LaTeX can be freely used inside Org documents Structural markup elements @@ -560,8 +560,8 @@ Embedded @LaTeX{} * Special symbols:: Greek letters and other symbols * Subscripts and superscripts:: Simple syntax for raising/lowering text -* LaTeX fragments:: Complex formulas made easy -* Previewing LaTeX fragments:: What will this snippet look like? +* @LaTeX{} fragments:: Complex formulas made easy +* Previewing @LaTeX{} fragments:: What will this snippet look like? * CDLaTeX mode:: Speed up entering of formulas Exporting @@ -571,7 +571,7 @@ Exporting * The export dispatcher:: How to access exporter commands * ASCII/Latin-1/UTF-8 export:: Exporting to flat files with encoding * HTML export:: Exporting to HTML -* LaTeX and PDF export:: Exporting to @LaTeX{}, and processing to PDF +* @LaTeX{} and PDF export:: Exporting to @LaTeX{}, and processing to PDF * DocBook export:: Exporting to DocBook * OpenDocument Text export:: Exporting to OpenDocument Text * TaskJuggler export:: Exporting to TaskJuggler @@ -594,11 +594,11 @@ HTML export @LaTeX{} and PDF export -* LaTeX/PDF export commands:: Which key invokes which commands +* @LaTeX{}/PDF export commands:: * Header and sectioning:: Setting up the export file structure -* Quoting LaTeX code:: Incorporating literal @LaTeX{} code -* Tables in LaTeX export:: Options for exporting tables to @LaTeX{} -* Images in LaTeX export:: How to insert figures into @LaTeX{} output +* Quoting @LaTeX{} code:: Incorporating literal @LaTeX{} code +* Tables in @LaTeX{} export:: Options for exporting tables to @LaTeX{} +* Images in @LaTeX{} export:: How to insert figures into @LaTeX{} output * Beamer class export:: Turning the file into a presentation DocBook export @@ -751,7 +751,7 @@ Hacking Tables and lists in arbitrary syntax * Radio tables:: Sending and receiving radio tables -* A LaTeX example:: Step by step, almost a tutorial +* A @LaTeX{} example:: Step by step, almost a tutorial * Translator functions:: Copy and modify * Radio lists:: Doing the same for lists @@ -1829,7 +1829,7 @@ Org mode extends the number-based syntax to @emph{named} footnotes and optional inline definition. Using plain numbers as markers (as @file{footnote.el} does) is supported for backward compatibility, but not encouraged because of possible conflicts with @LaTeX{} snippets (@pxref{Embedded -LaTeX}). Here are the valid references: +@LaTeX{}}). Here are the valid references: @table @code @item [1] @@ -8793,7 +8793,7 @@ summarizes the markup rules used in an Org mode buffer. * Include files:: Include additional files into a document * Index entries:: Making an index * Macro replacement:: Use macros to create complex output -* Embedded LaTeX:: LaTeX can be freely used inside Org documents +* Embedded @LaTeX{}:: LaTeX can be freely used inside Org documents @end menu @node Structural markup elements, Images and tables, Markup, Markup @@ -9075,16 +9075,16 @@ If the example is source code from a programming language, or any other text that can be marked up by font-lock in Emacs, you can ask for the example to look like the fontified Emacs buffer@footnote{This works automatically for the HTML backend (it requires version 1.34 of the @file{htmlize.el} package, -which is distributed with Org). Fontified code chunks in LaTeX can be +which is distributed with Org). Fontified code chunks in @LaTeX{} can be achieved using either the listings or the @url{http://code.google.com/p/minted, minted,} package. To use listings, turn on the variable @code{org-export-latex-listings} and ensure that the listings -package is included by the LaTeX header (e.g.@: by configuring +package is included by the @LaTeX{} header (e.g.@: by configuring @code{org-export-latex-packages-alist}). See the listings documentation for configuration options, including obtaining colored output. For minted it is necessary to install the program @url{http://pygments.org, pygments}, in addition to setting @code{org-export-latex-minted}, ensuring that the minted -package is included by the LaTeX header, and ensuring that the +package is included by the @LaTeX{} header, and ensuring that the @code{-shell-escape} option is passed to @file{pdflatex} (see @code{org-latex-to-pdf-process}). See the documentation of the variables @code{org-export-latex-listings} and @code{org-export-latex-minted} for @@ -9230,7 +9230,7 @@ an index} for more information. -@node Macro replacement, Embedded LaTeX, Index entries, Markup +@node Macro replacement, Embedded @LaTeX{}, Index entries, Markup @section Macro replacement @cindex macro replacement, during export @cindex #+MACRO @@ -9255,7 +9255,7 @@ Macro expansion takes place during export, and some people use it to construct complex HTML code. -@node Embedded LaTeX, , Macro replacement, Markup +@node Embedded @LaTeX{}, , Macro replacement, Markup @section Embedded @LaTeX{} @cindex @TeX{} interpretation @cindex @LaTeX{} interpretation @@ -9273,12 +9273,12 @@ readily processed to produce pretty output for a number of export backends. @menu * Special symbols:: Greek letters and other symbols * Subscripts and superscripts:: Simple syntax for raising/lowering text -* LaTeX fragments:: Complex formulas made easy -* Previewing LaTeX fragments:: What will this snippet look like? +* @LaTeX{} fragments:: Complex formulas made easy +* Previewing @LaTeX{} fragments:: What will this snippet look like? * CDLaTeX mode:: Speed up entering of formulas @end menu -@node Special symbols, Subscripts and superscripts, Embedded LaTeX, Embedded LaTeX +@node Special symbols, Subscripts and superscripts, Embedded @LaTeX{}, Embedded @LaTeX{} @subsection Special symbols @cindex math symbols @cindex special symbols @@ -9325,7 +9325,7 @@ buffer content which remains plain ASCII, but it overlays the UTF-8 character for display purposes only. @end table -@node Subscripts and superscripts, LaTeX fragments, Special symbols, Embedded LaTeX +@node Subscripts and superscripts, @LaTeX{} fragments, Special symbols, Embedded @LaTeX{} @subsection Subscripts and superscripts @cindex subscript @cindex superscript @@ -9363,7 +9363,7 @@ In addition to showing entities as UTF-8 characters, this command will also format sub- and superscripts in a WYSIWYM way. @end table -@node LaTeX fragments, Previewing LaTeX fragments, Subscripts and superscripts, Embedded LaTeX +@node @LaTeX{} fragments, Previewing @LaTeX{} fragments, Subscripts and superscripts, Embedded @LaTeX{} @subsection @LaTeX{} fragments @cindex @LaTeX{} fragments @@ -9422,10 +9422,10 @@ can configure the option @code{org-format-latex-options} to deselect the ones you do not wish to have interpreted by the @LaTeX{} converter. @vindex org-export-with-LaTeX-fragments -LaTeX processing can be configured with the variable +@LaTeX{} processing can be configured with the variable @code{org-export-with-LaTeX-fragments}. The default setting is @code{t} which means @file{MathJax} for HTML, and no processing for DocBook, ASCII and -LaTeX backends. You can also set this variable on a per-file basis using one +@LaTeX{} backends. You can also set this variable on a per-file basis using one of these lines: @example @@ -9435,9 +9435,9 @@ of these lines: #+OPTIONS: LaTeX:verbatim @r{Verbatim export, for jsMath or so} @end example -@node Previewing LaTeX fragments, CDLaTeX mode, LaTeX fragments, Embedded LaTeX -@subsection Previewing LaTeX fragments -@cindex LaTeX fragments, preview +@node Previewing @LaTeX{} fragments, CDLaTeX mode, @LaTeX{} fragments, Embedded @LaTeX{} +@subsection Previewing @LaTeX{} fragments +@cindex @LaTeX{} fragments, preview If you have @file{dvipng} installed, @LaTeX{} fragments can be processed to produce preview images of the typeset expressions: @@ -9462,7 +9462,7 @@ some aspects of the preview. In particular, the @code{:scale} (and for HTML export, @code{:html-scale}) property can be used to adjust the size of the preview images. -@node CDLaTeX mode, , Previewing LaTeX fragments, Embedded LaTeX +@node CDLaTeX mode, , Previewing @LaTeX{} fragments, Embedded @LaTeX{} @subsection Using CDLa@TeX{} to enter math @cindex CDLa@TeX{} @@ -9551,7 +9551,7 @@ enabled (default in Emacs 23). * The export dispatcher:: How to access exporter commands * ASCII/Latin-1/UTF-8 export:: Exporting to flat files with encoding * HTML export:: Exporting to HTML -* LaTeX and PDF export:: Exporting to @LaTeX{}, and processing to PDF +* @LaTeX{} and PDF export:: Exporting to @LaTeX{}, and processing to PDF * DocBook export:: Exporting to DocBook * OpenDocument Text export:: Exporting to OpenDocument Text * TaskJuggler export:: Exporting to TaskJuggler @@ -9642,11 +9642,11 @@ Insert template with export options, see example below. #+TEXT: Some descriptive text to be inserted at the beginning. #+TEXT: Several lines may be given. #+OPTIONS: H:2 num:t toc:t \n:nil @@:t ::t |:t ^:t f:t TeX:t ... -#+BIND: lisp-var lisp-val, e.g.@:: org-export-latex-low-levels itemize +#+BIND: lisp-var lisp-val, e.g.@:: @code{org-export-latex-low-levels itemize} @r{You need to confirm using these, or configure @code{org-export-allow-BIND}} #+LINK_UP: the ``up'' link of an exported page #+LINK_HOME: the ``home'' link of an exported page -#+LATEX_HEADER: extra line(s) for the LaTeX header, like \usepackage@{xyz@} +#+LATEX_HEADER: extra line(s) for the @LaTeX{} header, like \usepackage@{xyz@} #+EXPORT_SELECT_TAGS: Tags that select a tree for export #+EXPORT_EXCLUDE_TAGS: Tags that exclude a tree from export #+XSLT: the XSLT stylesheet used by DocBook exporter to generate FO file @@ -9811,7 +9811,7 @@ Links will be exported in a footnote-like style, with the descriptive part in the text and the link in a note before the next heading. See the variable @code{org-export-ascii-links-to-notes} for details and other options. -@node HTML export, LaTeX and PDF export, ASCII/Latin-1/UTF-8 export, Exporting +@node HTML export, @LaTeX{} and PDF export, ASCII/Latin-1/UTF-8 export, Exporting @section HTML export @cindex HTML export @@ -10029,7 +10029,7 @@ You could use @code{http} addresses just as well. @cindex MathJax @cindex dvipng -@LaTeX{} math snippets (@pxref{LaTeX fragments}) can be displayed in two +@LaTeX{} math snippets (@pxref{@LaTeX{} fragments}) can be displayed in two different ways on HTML pages. The default is to use the @uref{http://www.mathjax.org, MathJax system} which should work out of the box with Org mode installation because @code{http://orgmode.org} serves @@ -10225,16 +10225,16 @@ You can choose default values for these options by customizing the variable @code{org-infojs-options}. If you always want to apply the script to your pages, configure the variable @code{org-export-html-use-infojs}. -@node LaTeX and PDF export, DocBook export, HTML export, Exporting +@node @LaTeX{} and PDF export, DocBook export, HTML export, Exporting @section @LaTeX{} and PDF export @cindex @LaTeX{} export @cindex PDF export @cindex Guerry, Bastien Org mode contains a @LaTeX{} exporter written by Bastien Guerry. With -further processing@footnote{The default LaTeX output is designed for -processing with pdftex or latex. It includes packages that are not -compatible with xetex and possibly luatex. See the variables +further processing@footnote{The default @LaTeX{} output is designed for +processing with @code{pdftex} or @LaTeX{}. It includes packages that are not +compatible with @code{xetex} and possibly @code{luatex}. See the variables @code{org-export-latex-default-packages-alist} and @code{org-export-latex-packages-alist}.}, this backend is also used to produce PDF output. Since the @LaTeX{} output uses @file{hyperref} to @@ -10244,15 +10244,15 @@ structured in order to be correctly exported: respect the hierarchy of sections. @menu -* LaTeX/PDF export commands:: Which key invokes which commands +* @LaTeX{}/PDF export commands:: * Header and sectioning:: Setting up the export file structure -* Quoting LaTeX code:: Incorporating literal @LaTeX{} code -* Tables in LaTeX export:: Options for exporting tables to @LaTeX{} -* Images in LaTeX export:: How to insert figures into @LaTeX{} output +* Quoting @LaTeX{} code:: Incorporating literal @LaTeX{} code +* Tables in @LaTeX{} export:: Options for exporting tables to @LaTeX{} +* Images in @LaTeX{} export:: How to insert figures into @LaTeX{} output * Beamer class export:: Turning the file into a presentation @end menu -@node LaTeX/PDF export commands, Header and sectioning, LaTeX and PDF export, LaTeX and PDF export +@node @LaTeX{}/PDF export commands, Header and sectioning, @LaTeX{} and PDF export, @LaTeX{} and PDF export @subsection @LaTeX{} export commands @cindex region, active @@ -10304,13 +10304,13 @@ with a numeric prefix argument. For example, @noindent creates two levels of headings and does the rest as items. -@node Header and sectioning, Quoting LaTeX code, LaTeX/PDF export commands, LaTeX and PDF export +@node Header and sectioning, Quoting @LaTeX{} code, @LaTeX{}/PDF export commands, @LaTeX{} and PDF export @subsection Header and sectioning structure @cindex @LaTeX{} class @cindex @LaTeX{} sectioning structure @cindex @LaTeX{} header -@cindex header, for LaTeX files -@cindex sectioning structure, for LaTeX export +@cindex header, for @LaTeX{} files +@cindex sectioning structure, for @LaTeX{} export By default, the @LaTeX{} output uses the class @code{article}. @@ -10338,10 +10338,10 @@ can also use @code{#+LATEX_HEADER: \usepackage@{xyz@}} to add lines to the header. See the docstring of @code{org-export-latex-classes} for more information. -@node Quoting LaTeX code, Tables in LaTeX export, Header and sectioning, LaTeX and PDF export +@node Quoting @LaTeX{} code, Tables in @LaTeX{} export, Header and sectioning, @LaTeX{} and PDF export @subsection Quoting @LaTeX{} code -Embedded @LaTeX{} as described in @ref{Embedded LaTeX}, will be correctly +Embedded @LaTeX{} as described in @ref{Embedded @LaTeX{}}, will be correctly inserted into the @LaTeX{} file. This includes simple macros like @samp{\ref@{LABEL@}} to create a cross reference to a figure. Furthermore, you can add special code that should only be present in @LaTeX{} export with @@ -10350,7 +10350,7 @@ the following constructs: @cindex #+LaTeX @cindex #+BEGIN_LaTeX @example -#+LaTeX: Literal LaTeX code for export +#+LaTeX: Literal @LaTeX{} code for export @end example @noindent or @@ -10363,7 +10363,7 @@ All lines between these markers are exported literally @end example -@node Tables in LaTeX export, Images in LaTeX export, Quoting LaTeX code, LaTeX and PDF export +@node Tables in @LaTeX{} export, Images in @LaTeX{} export, Quoting @LaTeX{} code, @LaTeX{} and PDF export @subsection Tables in @LaTeX{} export @cindex tables, in @LaTeX{} export @@ -10400,7 +10400,7 @@ or to specify a multicolumn table with @code{tabulary} | ..... | ..... | @end example -@node Images in LaTeX export, Beamer class export, Tables in LaTeX export, LaTeX and PDF export +@node Images in @LaTeX{} export, Beamer class export, Tables in @LaTeX{} export, @LaTeX{} and PDF export @subsection Images in @LaTeX{} export @cindex images, inline in @LaTeX{} @cindex inlining images in @LaTeX{} @@ -10451,14 +10451,14 @@ will export the image wrapped in a @code{figure*} environment. If you need references to a label created in this way, write @samp{\ref@{fig:SED-HR4049@}} just like in @LaTeX{}. -@node Beamer class export, , Images in LaTeX export, LaTeX and PDF export +@node Beamer class export, , Images in @LaTeX{} export, @LaTeX{} and PDF export @subsection Beamer class export -The LaTeX class @file{beamer} allows production of high quality presentations -using LaTeX and pdf processing. Org mode has special support for turning an +The @LaTeX{} class @file{beamer} allows production of high quality presentations +using @LaTeX{} and pdf processing. Org mode has special support for turning an Org mode file or tree into a @file{beamer} presentation. -When the LaTeX class for the current buffer (as set with @code{#+LaTeX_CLASS: +When the @LaTeX{} class for the current buffer (as set with @code{#+LaTeX_CLASS: beamer}) or subtree (set with a @code{LaTeX_CLASS} property) is @code{beamer}, a special export mode will turn the file or tree into a beamer presentation. Any tree with not-too-deep level nesting should in principle be @@ -10578,7 +10578,7 @@ Here is a simple example Org document that is intended for beamer export. For more information, see the documentation on Worg. -@node DocBook export, OpenDocument Text export, LaTeX and PDF export, Exporting +@node DocBook export, OpenDocument Text export, @LaTeX{} and PDF export, Exporting @section DocBook export @cindex DocBook export @cindex PDF export @@ -11042,7 +11042,7 @@ The @acronym{ODT} exporter has special support for handling math. @node Working with @LaTeX{} math snippets, Working with MathML or OpenDocument formula files, Math formatting in @acronym{ODT} export, Math formatting in @acronym{ODT} export @subsubsection Working with @LaTeX{} math snippets -@LaTeX{} math snippets (@pxref{LaTeX fragments}) can be embedded in the ODT +@LaTeX{} math snippets (@pxref{@LaTeX{} fragments}) can be embedded in the ODT document in one of the following ways: @cindex MathML @@ -11063,7 +11063,7 @@ the exported document. @vindex org-latex-to-mathml-convert-command @vindex org-latex-to-mathml-jar-file -You can specify the LaTeX-to-MathML converter by customizing the variables +You can specify the @LaTeX{}-to-MathML converter by customizing the variables @code{org-latex-to-mathml-convert-command} and @code{org-latex-to-mathml-jar-file}. @@ -11619,7 +11619,7 @@ resource assignments based on the project outline and the constraints that you have provided. The TaskJuggler exporter is a bit different from other exporters, such as the -HTML and LaTeX exporters for example, in that it does not export all the +@code{HTML} and @LaTeX{} exporters for example, in that it does not export all the nodes of a document or strictly follow the order of the nodes in the document. @@ -12895,7 +12895,7 @@ properties. In the following example, the @code{:results} header argument is set to @code{silent}, meaning the results of execution will not be inserted in the buffer, and the @code{:exports} header argument is set to @code{code}, meaning only the body of the code block will be -preserved on export to HTML or LaTeX. +preserved on export to HTML or @LaTeX{}. @example #+NAME: factorial @@ -13326,7 +13326,7 @@ such by Org mode. E.g., @code{:results value raw}. Results are assumed to be HTML and will be enclosed in a @code{begin_html} block. E.g., @code{:results value html}. @item @code{latex} -Results assumed to be LaTeX and are enclosed in a @code{begin_latex} block. +Results assumed to be @LaTeX{} and are enclosed in a @code{begin_latex} block. E.g., @code{:results value latex}. @item @code{code} Result are assumed to be parsable code and are enclosed in a code block. @@ -13451,7 +13451,7 @@ which the link does not point. @subsubsection @code{:exports} The @code{:exports} header argument specifies what should be included in HTML -or LaTeX exports of the Org mode file. +or @LaTeX{} exports of the Org mode file. @itemize @bullet @item @code{code} @@ -15251,12 +15251,12 @@ can use Org's facilities to edit and structure lists by turning @menu * Radio tables:: Sending and receiving radio tables -* A LaTeX example:: Step by step, almost a tutorial +* A @LaTeX{} example:: Step by step, almost a tutorial * Translator functions:: Copy and modify * Radio lists:: Doing the same for lists @end menu -@node Radio tables, A LaTeX example, Tables in arbitrary syntax, Tables in arbitrary syntax +@node Radio tables, A @LaTeX{} example, Tables in arbitrary syntax, Tables in arbitrary syntax @subsection Radio tables @cindex radio tables @@ -15324,7 +15324,7 @@ makes this comment-toggling very easy, in particular if you bind it to a key. @end itemize -@node A LaTeX example, Translator functions, Radio tables, Tables in arbitrary syntax +@node A @LaTeX{} example, Translator functions, Radio tables, Tables in arbitrary syntax @subsection A @LaTeX{} example of radio tables @cindex @LaTeX{}, and Orgtbl mode @@ -15434,7 +15434,7 @@ applied. Similar to @code{fmt}, functions of two arguments can be supplied instead of strings. @end table -@node Translator functions, Radio lists, A LaTeX example, Tables in arbitrary syntax +@node Translator functions, Radio lists, A @LaTeX{} example, Tables in arbitrary syntax @subsection Translator functions @cindex HTML, and Orgtbl mode @cindex translator function @@ -16182,7 +16182,7 @@ Before I get to this list, a few special mentions are in order: @table @i @item Bastien Guerry Bastien has written a large number of extensions to Org (most of them -integrated into the core by now), including the LaTeX exporter and the plain +integrated into the core by now), including the @LaTeX{} exporter and the plain list parser. His support during the early days, when he basically acted as co-maintainer, was central to the success of this project. Bastien also invented Worg, helped establishing the Web presence of Org, and sponsors @@ -16399,7 +16399,7 @@ tweaks and features. extension system, added support for mairix, and proposed the mapping API. @item @i{Ulf Stegemann} created the table to translate special symbols to HTML, -LaTeX, UTF-8, Latin-1 and ASCII. +@LaTeX{}, UTF-8, Latin-1 and ASCII. @item @i{Andy Stewart} contributed code to @file{org-w3m.el}, to copy HTML content with links transformation to Org syntax. @@ -16409,7 +16409,7 @@ chapter about publishing. @item @i{Jambunathan K} contributed the @acronym{ODT} exporter. @item -@i{Sebastien Vauban} reported many issues with LaTeX and BEAMER export and +@i{Sebastien Vauban} reported many issues with @LaTeX{} and BEAMER export and enabled source code highlighling in Gnus. @item @i{Stefan Vollmar} organized a video-recorded talk at the From f015bb452cb5907311079487a1aa7d9853bc5b68 Mon Sep 17 00:00:00 2001 From: Bastien Guerry Date: Sun, 25 Dec 2011 09:42:08 +0100 Subject: [PATCH 19/44] Normalize the use of @LaTeX{} in the Org compact guide. --- doc/orgguide.texi | 52 +++++++++++++++++++++++------------------------ 1 file changed, 26 insertions(+), 26 deletions(-) diff --git a/doc/orgguide.texi b/doc/orgguide.texi index 3f3d696e2..6f71f52a1 100644 --- a/doc/orgguide.texi +++ b/doc/orgguide.texi @@ -195,7 +195,7 @@ Markup for rich export * Images and tables:: Tables and Images will be included * Literal examples:: Source code examples with special formatting * Include files:: Include additional files into a document -* Embedded LaTeX:: LaTeX can be freely used inside Org documents +* Embedded @LaTeX{}:: @LaTeX{} can be freely used inside Org documents Structural markup elements @@ -212,7 +212,7 @@ Exporting * The export dispatcher:: How to access exporter commands * ASCII/Latin-1/UTF-8 export:: Exporting to flat files with encoding * HTML export:: Exporting to HTML -* LaTeX and PDF export:: Exporting to La@TeX{}, and processing to PDF +* @LaTeX{} and PDF export:: Exporting to @LaTeX{}, and processing to PDF * DocBook export:: Exporting to DocBook * iCalendar export:: @@ -2047,7 +2047,7 @@ John Wiegley's setup}} When exporting Org-mode documents, the exporter tries to reflect the structure of the document as accurately as possible in the backend. Since -export targets like HTML, La@TeX{}, or DocBook allow much richer formatting, +export targets like HTML, @LaTeX{}, or DocBook allow much richer formatting, Org mode has rules on how to prepare text for rich export. This section summarizes the markup rules used in an Org-mode buffer. @@ -2056,7 +2056,7 @@ summarizes the markup rules used in an Org-mode buffer. * Images and tables:: Tables and Images will be included * Literal examples:: Source code examples with special formatting * Include files:: Include additional files into a document -* Embedded LaTeX:: LaTeX can be freely used inside Org documents +* Embedded @LaTeX{}:: @LaTeX{} can be freely used inside Org documents @end menu @node Structural markup elements, Images and tables, Markup, Markup @@ -2183,7 +2183,7 @@ the text you can refer to the object with @code{\ref@{tab:basic-data@}}: |-----|----| @end smallexample -Some backends (HTML, La@TeX{}, and DocBook) allow you to directly include +Some backends (HTML, @LaTeX{}, and DocBook) allow you to directly include images into the exported document. Org does this, if a link to an image files does not have a description part, for example @code{[[./img/a.jpg]]}. If you wish to define a caption for the image and maybe a label for internal @@ -2238,7 +2238,7 @@ look like the fontified Emacs buffer To edit the example in a special buffer supporting this language, use @kbd{C-c '} to both enter and leave the editing buffer. -@node Include files, Embedded LaTeX, Literal examples, Markup +@node Include files, Embedded @LaTeX{}, Literal examples, Markup @section Include files During export, you can include the content of another file. For example, to @@ -2254,13 +2254,13 @@ language for formatting the contents. The markup is optional, if it is not given, the text will be assumed to be in Org mode format and will be processed normally. @kbd{C-c '} will visit the included file. -@node Embedded LaTeX, , Include files, Markup -@section Embedded La@TeX{} +@node Embedded @LaTeX{}, , Include files, Markup +@section Embedded @LaTeX{} For scientific notes which need to be able to contain mathematical symbols -and the occasional formula, Org-mode supports embedding La@TeX{} code into +and the occasional formula, Org-mode supports embedding @LaTeX{} code into its files. You can directly use TeX-like macros for special symbols, enter -formulas and entire LaTeX environments. +formulas and entire @LaTeX{} environments. @smallexample Angles are written as Greek letters \alpha, \beta and \gamma. The mass if @@ -2274,7 +2274,7 @@ x=\sqrt@{b@} @end smallexample @noindent With @uref{http://orgmode.org/manual/LaTeX-fragments.html#LaTeX-fragments,special -setup}, LaTeX snippets will be included as images when exporting to HTML. +setup}, @LaTeX{} snippets will be included as images when exporting to HTML. @seealso{ @uref{http://orgmode.org/manual/Markup.html#Markup, Chapter 11 of the manual}} @@ -2283,7 +2283,7 @@ setup}, LaTeX snippets will be included as images when exporting to HTML. @chapter Exporting Org-mode documents can be exported into a variety of other formats: ASCII -export for inclusion into emails, HTML to publish on the web, La@TeX{}/PDF +export for inclusion into emails, HTML to publish on the web, @LaTeX{}/PDF for beautiful printed documents and DocBook to enter the world of many other formats using DocBook tools. There is also export to iCalendar format so that planning information can be incorporated into desktop calendars. @@ -2293,7 +2293,7 @@ that planning information can be incorporated into desktop calendars. * The export dispatcher:: How to access exporter commands * ASCII/Latin-1/UTF-8 export:: Exporting to flat files with encoding * HTML export:: Exporting to HTML -* LaTeX and PDF export:: Exporting to La@TeX{}, and processing to PDF +* @LaTeX{} and PDF export:: Exporting to @LaTeX{}, and processing to PDF * DocBook export:: Exporting to DocBook * iCalendar export:: @end menu @@ -2324,7 +2324,7 @@ Insert template with export options, see example below. #+OPTIONS: H:2 num:t toc:t \n:nil @@:t ::t |:t ^:t f:t TeX:t ... #+LINK_UP: the ``up'' link of an exported page #+LINK_HOME: the ``home'' link of an exported page -#+LATEX_HEADER: extra line(s) for the LaTeX header, like \usepackage@{xyz@} +#+LATEX_HEADER: extra line(s) for the @LaTeX{} header, like \usepackage@{xyz@} @end smallexample @node The export dispatcher, ASCII/Latin-1/UTF-8 export, Export options, Exporting @@ -2357,7 +2357,7 @@ Like the above commands, but use Latin-1 encoding. Like the above commands, but use UTF-8 encoding. @end table -@node HTML export, LaTeX and PDF export, ASCII/Latin-1/UTF-8 export, Exporting +@node HTML export, @LaTeX{} and PDF export, ASCII/Latin-1/UTF-8 export, Exporting @section HTML export @table @kbd @@ -2380,28 +2380,28 @@ All lines between these markers are exported literally #+END_HTML @end smallexample -@node LaTeX and PDF export, DocBook export, HTML export, Exporting -@section La@TeX{} and PDF export +@node @LaTeX{} and PDF export, DocBook export, HTML export, Exporting +@section @LaTeX{} and PDF export @table @kbd @item C-c C-e l -Export as La@TeX{} file @file{myfile.tex}. +Export as @LaTeX{} file @file{myfile.tex}. @item C-c C-e p -Export as La@TeX{} and then process to PDF. +Export as @LaTeX{} and then process to PDF. @item C-c C-e d -Export as La@TeX{} and then process to PDF, then open the resulting PDF file. +Export as @LaTeX{} and then process to PDF, then open the resulting PDF file. @end table -By default, the La@TeX{} output uses the class @code{article}. You can +By default, the @LaTeX{} output uses the class @code{article}. You can change this by adding an option like @code{#+LaTeX_CLASS: myclass} in your file. The class must be listed in @code{org-export-latex-classes}. -Embedded La@TeX{} as described in @ref{Embedded LaTeX}, will be correctly -inserted into the La@TeX{} file. Similarly to the HTML exporter, you can use +Embedded @LaTeX{} as described in @ref{Embedded @LaTeX{}}, will be correctly +inserted into the @LaTeX{} file. Similarly to the HTML exporter, you can use @code{#+LaTeX:} and @code{#+BEGIN_LaTeX ... #+END_LaTeX} construct to add -verbatim LaTeX code. +verbatim @LaTeX{} code. -@node DocBook export, iCalendar export, LaTeX and PDF export, Exporting +@node DocBook export, iCalendar export, @LaTeX{} and PDF export, Exporting @section DocBook export @table @kbd @@ -2410,7 +2410,7 @@ Export as DocBook file. @end table Similarly to the HTML exporter, you can use @code{#+DocBook:} and -@code{#+BEGIN_DocBook ... #+END_DocBook} construct to add verbatim LaTeX +@code{#+BEGIN_DocBook ... #+END_DocBook} construct to add verbatim @LaTeX{} code. @node iCalendar export, , DocBook export, Exporting From 2898391bada07e0228e7a5cd40721a4037136f8c Mon Sep 17 00:00:00 2001 From: Bastien Guerry Date: Sun, 25 Dec 2011 09:43:30 +0100 Subject: [PATCH 20/44] Use CD@LaTeX{} instead of CDLa@TeX. --- doc/org.texi | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) diff --git a/doc/org.texi b/doc/org.texi index bf78e7db5..1a162c9a1 100644 --- a/doc/org.texi +++ b/doc/org.texi @@ -9463,16 +9463,16 @@ export, @code{:html-scale}) property can be used to adjust the size of the preview images. @node CDLaTeX mode, , Previewing @LaTeX{} fragments, Embedded @LaTeX{} -@subsection Using CDLa@TeX{} to enter math -@cindex CDLa@TeX{} +@subsection Using CD@LaTeX{} to enter math +@cindex CD@LaTeX{} -CDLa@TeX{} mode is a minor mode that is normally used in combination with a +CD@LaTeX{} mode is a minor mode that is normally used in combination with a major @LaTeX{} mode like AUC@TeX{} in order to speed-up insertion of environments and math templates. Inside Org mode, you can make use of -some of the features of CDLa@TeX{} mode. You need to install +some of the features of CD@LaTeX{} mode. You need to install @file{cdlatex.el} and @file{texmathp.el} (the latter comes also with AUC@TeX{}) from @url{http://www.astro.uva.nl/~dominik/Tools/cdlatex}. -Don't use CDLa@TeX{} mode itself under Org mode, but use the light +Don't use CD@LaTeX{} mode itself under Org mode, but use the light version @code{org-cdlatex-mode} that comes as part of Org mode. Turn it on for the current buffer with @code{M-x org-cdlatex-mode}, or for all Org files with @@ -9482,7 +9482,7 @@ Org files with @end lisp When this mode is enabled, the following features are present (for more -details see the documentation of CDLa@TeX{} mode): +details see the documentation of CD@LaTeX{} mode): @itemize @bullet @kindex C-c @{ @item @@ -14833,7 +14833,7 @@ setup. See the installation instructions in the file @item @file{cdlatex.el} by Carsten Dominik @cindex @file{cdlatex.el} @cindex Dominik, Carsten -Org mode can make use of the CDLa@TeX{} package to efficiently enter +Org mode can make use of the CD@LaTeX{} package to efficiently enter @LaTeX{} fragments into Org files. See @ref{CDLaTeX mode}. @item @file{imenu.el} by Ake Stenhoff and Lars Lindberg @cindex @file{imenu.el} From 131e3a278aa7ffa352ed08b59c05438f9e93b71c Mon Sep 17 00:00:00 2001 From: Bastien Guerry Date: Mon, 26 Dec 2011 14:24:08 +0100 Subject: [PATCH 21/44] org.texi: Split the table to fix the display of items. * org.texi (Plain lists): Split the table to fix the display of items. Thanks to Elias Assarsson for spotting this, and to Takaaki ISHIKAWA for providing a preliminary patch. --- doc/org.texi | 23 +++++++++++++---------- 1 file changed, 13 insertions(+), 10 deletions(-) diff --git a/doc/org.texi b/doc/org.texi index 1a162c9a1..6b189bd6d 100644 --- a/doc/org.texi +++ b/doc/org.texi @@ -1664,12 +1664,15 @@ new item@footnote{If you do not want the item to be split, customize the variable @code{org-M-RET-may-split-line}.}. If this command is executed @emph{before item's body}, the new item is created @emph{before} the current one. +@end table + +@table @kbd @kindex M-S-@key{RET} -@item M-S-@key{RET} +@item M-S-RET Insert a new item with a checkbox (@pxref{Checkboxes}). @kindex S-@key{down} -@item S-@key{up} -@itemx S-@key{down} +@item S-up +@itemx S-down @cindex shift-selection-mode @vindex org-support-shift-select @vindex org-list-use-circular-motion @@ -1681,21 +1684,21 @@ jumping commands like @kbd{C-@key{up}} and @kbd{C-@key{down}} to quite similar effect. @kindex M-@key{up} @kindex M-@key{down} -@item M-@key{up} -@itemx M-@key{down} +@item M-up +@itemx M-down Move the item including subitems up/down@footnote{See @code{org-liste-use-circular-motion} for a cyclic behavior.} (swap with previous/next item of same indentation). If the list is ordered, renumbering is automatic. @kindex M-@key{left} @kindex M-@key{right} -@item M-@key{left} -@itemx M-@key{right} +@item M-left +@itemx M-right Decrease/increase the indentation of an item, leaving children alone. @kindex M-S-@key{left} @kindex M-S-@key{right} -@item M-S-@key{left} -@itemx M-S-@key{right} +@item M-S-left +@itemx M-S-right Decrease/increase the indentation of the item, including subitems. Initially, the item tree is selected based on current indentation. When these commands are executed several times in direct succession, the initially @@ -1738,7 +1741,7 @@ Turn the whole plain list into a subtree of the current heading. Checkboxes (resp. checked). @kindex S-@key{left} @kindex S-@key{right} -@item S-@key{left}/@key{right} +@item S-left/right @vindex org-support-shift-select This command also cycles bullet styles when the cursor in on the bullet or anywhere in an item line, details depending on From 432437ed4a95ae1a3ba9186f66349526170d556c Mon Sep 17 00:00:00 2001 From: Bastien Guerry Date: Mon, 26 Dec 2011 14:39:47 +0100 Subject: [PATCH 22/44] org-mouse.el: Remove useless commented functions. --- lisp/org-mouse.el | 29 ----------------------------- 1 file changed, 29 deletions(-) diff --git a/lisp/org-mouse.el b/lisp/org-mouse.el index f2a43a58f..3a667deee 100644 --- a/lisp/org-mouse.el +++ b/lisp/org-mouse.el @@ -328,7 +328,6 @@ nor a function, elements of KEYWORDS are used directly." (goto-char (match-end (or subexp 0))) (just-one-space))) - (defun org-mouse-keyword-replace-menu (keywords &optional group itemformat nosurround) "A helper function. @@ -394,15 +393,6 @@ DEFAULT is returned if no priority is given in the headline." (match-string 1) (when default (char-to-string org-default-priority))))) -;; (defun org-mouse-at-link () -;; (and (eq (get-text-property (point) 'face) 'org-link) -;; (save-excursion -;; (goto-char (previous-single-property-change (point) 'face)) -;; (or (looking-at org-bracket-link-regexp) -;; (looking-at org-angle-link-re) -;; (looking-at org-plain-link-re))))) - - (defun org-mouse-delete-timestamp () "Deletes the current timestamp as well as the preceding keyword. SCHEDULED: or DEADLINE: or ANYTHINGLIKETHIS:" @@ -453,7 +443,6 @@ SCHEDULED: or DEADLINE: or ANYTHINGLIKETHIS:" ["Align Tags in Buffer" (org-set-tags t t) t] ["Set Tags ..." (org-set-tags) t]))) - (defun org-mouse-set-tags (tags) (save-excursion ;; remove existing tags first @@ -484,7 +473,6 @@ SCHEDULED: or DEADLINE: or ANYTHINGLIKETHIS:" ('occur-tree "Occur tree: ") (t "Agenda command ???"))) - (defun org-mouse-list-options-menu (alloptions &optional function) (let ((options (save-match-data (split-string (match-string-no-properties 1))))) @@ -570,7 +558,6 @@ SCHEDULED: or DEADLINE: or ANYTHINGLIKETHIS:" ["Plain List to Outline" org-mouse-transform-to-outline :visible (org-at-item-p)]))) - (defun org-mouse-get-context (contextlist context) (let ((contextdata (assq context contextlist))) (when contextdata @@ -598,19 +585,16 @@ This means, between the beginning of line and the point." (open-line 1) (org-indent-to-column (- (match-end 0) (match-beginning 0))) (insert "+ ")) - (:middle ; insert after (end-of-line) (newline t) (indent-relative) (insert "+ ")) - (:end ; insert text here (skip-chars-backward " \t") (kill-region (point) (point-at-eol)) (unless (org-looking-back org-mouse-punctuation) (insert (concat org-mouse-punctuation " "))))) - (insert text) (beginning-of-line)) @@ -660,7 +644,6 @@ This means, between the beginning of line and the point." (progn (save-excursion (goto-char (region-beginning)) (insert "[[")) (save-excursion (goto-char (region-end)) (insert "]]")))] ["Insert Link Here" (org-mouse-yank-link ',event)])))) - ((save-excursion (beginning-of-line) (looking-at "#\\+STARTUP: \\(.*\\)")) (popup-menu `(nil @@ -871,18 +854,6 @@ This means, between the beginning of line and the point." (t (org-mouse-popup-global-menu)))))) -;; (defun org-mouse-at-regexp (regexp) -;; (save-excursion -;; (let ((point (point)) -;; (bol (progn (beginning-of-line) (point))) -;; (eol (progn (end-of-line) (point)))) -;; (goto-char point) -;; (re-search-backward regexp bol 1) -;; (and (not (eolp)) -;; (progn (forward-char) -;; (re-search-forward regexp eol t)) -;; (<= (match-beginning 0) point))))) - (defun org-mouse-mark-active () (and mark-active transient-mark-mode)) From f3d63e34beae14ce61ed7ed366ff1605a776bde2 Mon Sep 17 00:00:00 2001 From: Bastien Guerry Date: Mon, 26 Dec 2011 15:12:39 +0100 Subject: [PATCH 23/44] org.el: Also match cumulating properties like ":prop+:". * org.el (org-property-re): Also match cumulating properties like ":prop+:". Thanks to Christoph LANGE for spotting this. --- lisp/org.el | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lisp/org.el b/lisp/org.el index 7e243676a..13a0f44a0 100644 --- a/lisp/org.el +++ b/lisp/org.el @@ -5723,7 +5723,7 @@ Use `org-reduced-level' to remove the effect of `org-odd-levels'." (defvar org-font-lock-keywords nil) -(defconst org-property-re (org-re "^[ \t]*\\(:\\([-[:alnum:]_]+\\):\\)[ \t]*\\([^ \t\r\n].*\\)") +(defconst org-property-re (org-re "^[ \t]*\\(:\\([-[:alnum:]_]+\\+?\\):\\)[ \t]*\\([^ \t\r\n].*\\)") "Regular expression matching a property line.") (defvar org-font-lock-hook nil From 7e950b4fd26fe1fd9dfbf3509dbfea595e91abf0 Mon Sep 17 00:00:00 2001 From: Bastien Guerry Date: Mon, 26 Dec 2011 15:40:02 +0100 Subject: [PATCH 24/44] org-drill.el: fix a few wrong :type spec. * org-drill.el (org-drill-leech-method, org-drill-scope) (org-drill-spaced-repetition-algorithm): Fix wrong :type spec. Thanks to Joost Kremers for spotting this. --- contrib/lisp/org-drill.el | 62 +++++++++++++++++++-------------------- 1 file changed, 30 insertions(+), 32 deletions(-) diff --git a/contrib/lisp/org-drill.el b/contrib/lisp/org-drill.el index 5e8957063..b0223597a 100644 --- a/contrib/lisp/org-drill.el +++ b/contrib/lisp/org-drill.el @@ -1,28 +1,28 @@ -;;; -*- coding: utf-8-unix -*- -;;; org-drill.el - Self-testing using spaced repetition -;;; -;;; Author: Paul Sexton -;;; Version: 2.3.5 -;;; Repository at http://bitbucket.org/eeeickythump/org-drill/ -;;; -;;; -;;; Synopsis -;;; ======== -;;; -;;; Uses the SuperMemo spaced repetition algorithms to conduct interactive -;;; "drill sessions", where the material to be remembered is presented to the -;;; student in random order. The student rates his or her recall of each item, -;;; and this information is used to schedule the item for later revision. -;;; -;;; Each drill session can be restricted to topics in the current buffer -;;; (default), one or several files, all agenda files, or a subtree. A single -;;; topic can also be drilled. -;;; -;;; Different "card types" can be defined, which present their information to -;;; the student in different ways. -;;; -;;; See the file README.org for more detailed documentation. - +;; -*- coding: utf-8-unix -*- +;; org-drill.el - Self-testing using spaced repetition +;; +;; Author: Paul Sexton +;; Version: 2.3.5 +;; Repository at http://bitbucket.org/eeeickythump/org-drill/ +;; +;; This file is not part of GNU Emacs. +;; +;; Synopsis +;; ======== +;; +;; Uses the SuperMemo spaced repetition algorithms to conduct interactive +;; "drill sessions", where the material to be remembered is presented to the +;; student in random order. The student rates his or her recall of each item, +;; and this information is used to schedule the item for later revision. +;; +;; Each drill session can be restricted to topics in the current buffer +;; (default), one or several files, all agenda files, or a subtree. A single +;; topic can also be drilled. +;; +;; Different "card types" can be defined, which present their information to +;; the student in different ways. +;; +;; See the file README.org in the repository for more detailed documentation. (eval-when-compile (require 'cl)) (eval-when-compile (require 'hi-lock)) @@ -37,7 +37,6 @@ :group 'org-link) - (defcustom org-drill-question-tag "drill" "Tag which topics must possess in order to be identified as review topics @@ -54,7 +53,6 @@ Nil means unlimited." :type '(choice integer (const nil))) - (defcustom org-drill-maximum-duration 20 "Maximum duration of a drill session, in minutes. @@ -107,7 +105,7 @@ Possible values: but a warning message is printed when each leech item is presented." :group 'org-drill - :type '(choice (const 'warn) (const 'skip) (const nil))) + :type '(choice (const warn) (const skip) (const nil))) (defface org-drill-visible-cloze-face @@ -262,9 +260,9 @@ directory All files with the extension '.org' in the same ;; 'file-no-restriction' means current file/buffer, ignoring restrictions ;; 'directory' means all *.org files in current directory :group 'org-drill - :type '(choice (const 'file) (const 'tree) (const 'file-no-restriction) - (const 'file-with-archives) (const 'agenda) - (const 'agenda-with-archives) (const 'directory) + :type '(choice (const file) (const tree) (const file-no-restriction) + (const file-with-archives) (const agenda) + (const agenda-with-archives) (const directory) list)) @@ -290,7 +288,7 @@ Available choices are: adjusting intervals when items are reviewed early or late has been taken from SM11, a later version of the algorithm, and included in Simple8." :group 'org-drill - :type '(choice (const 'sm2) (const 'sm5) (const 'simple8))) + :type '(choice (const sm2) (const sm5) (const simple8))) (defcustom org-drill-optimal-factor-matrix From 74ea01d9456cc00ba92a9c6934548d9bf4fec2b5 Mon Sep 17 00:00:00 2001 From: Jambunathan K Date: Thu, 29 Dec 2011 16:24:27 +0530 Subject: [PATCH 25/44] OrgOdtContentTemplate.xml: table-cells are now top aligned by default * etc/styles/OrgOdtContentTemplate.xml (OrgTblCell): Modify style:vertical-align attribute to top. (OrgTblCell*): Inherit from OrgTblCell. (Custom*TableCell): Force style:vertical-align to top. See http://lists.gnu.org/archive/html/emacs-orgmode/2011-12/msg00780.html --- etc/styles/OrgOdtContentTemplate.xml | 72 ++++++++++++++-------------- 1 file changed, 36 insertions(+), 36 deletions(-) diff --git a/etc/styles/OrgOdtContentTemplate.xml b/etc/styles/OrgOdtContentTemplate.xml index 0b62dc247..f4982f620 100644 --- a/etc/styles/OrgOdtContentTemplate.xml +++ b/etc/styles/OrgOdtContentTemplate.xml @@ -54,52 +54,52 @@ - + - - + + - - + + - - + + - - + + - - + + - - + + - - + + - - + + - - + + - - + + - - + + - - + + - - + + - - + + - - + + @@ -160,31 +160,31 @@ - + - + - + - + - + From dc44b5897cf41f330add06bcb0a3b4f919b85c0b Mon Sep 17 00:00:00 2001 From: Bastien Guerry Date: Thu, 29 Dec 2011 17:46:47 +0100 Subject: [PATCH 26/44] org.el (org-map-continue-from): Fix typo in docstring. * org.el (org-map-continue-from): Fix typo in docstring. --- lisp/org.el | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lisp/org.el b/lisp/org.el index 13a0f44a0..14b182bf1 100644 --- a/lisp/org.el +++ b/lisp/org.el @@ -12703,7 +12703,7 @@ ACTION can be `set', `up', `down', or a character." (defvar org-agenda-archives-mode) (defvar org-map-continue-from nil "Position from where mapping should continue. -Can be set by the action argument to `org-scan-tag's and `org-map-entries'.") +Can be set by the action argument to `org-scan-tags' and `org-map-entries'.") (defvar org-scanner-tags nil "The current tag list while the tags scanner is running.") From 1471af0b441f8109404d18d6b914e639440cd65c Mon Sep 17 00:00:00 2001 From: Eric Schulte Date: Thu, 29 Dec 2011 12:46:42 -0700 Subject: [PATCH 27/44] Resolve :noweb-ref when set at the property level during noweb expansion * lisp/ob.el (org-babel-expand-noweb-references): Rather than using a pure regexp solution to resolve noweb references, actually check the information of every code block in the buffer. This will cause a slowdown in noweb reference expansion, but is necessary for correct behavior. --- lisp/ob.el | 26 +++++++++++++------------- 1 file changed, 13 insertions(+), 13 deletions(-) diff --git a/lisp/ob.el b/lisp/ob.el index 991941698..a392c232a 100644 --- a/lisp/ob.el +++ b/lisp/ob.el @@ -2014,8 +2014,6 @@ block but are passed literally to the \"example-block\"." (lang (nth 0 info)) (body (nth 1 info)) (comment (string= "noweb" (cdr (assoc :comments (nth 2 info))))) - (rx-prefix (concat "\\(" org-babel-src-name-regexp "\\|" - ":noweb-ref[ \t]+" "\\)")) (new-body "") index source-name evaluate prefix blocks-in-buffer) (flet ((nb-add (text) (setq new-body (concat new-body text))) (c-wrap (text) @@ -2056,19 +2054,21 @@ block but are passed literally to the \"example-block\"." (when (org-babel-ref-goto-headline-id source-name) (org-babel-ref-headline-body))) ;; find the expansion of reference in this buffer - (let ((rx (concat rx-prefix source-name)) - expansion) + (let (expansion) (save-excursion (goto-char (point-min)) - (while (re-search-forward rx nil t) - (let* ((i (org-babel-get-src-block-info 'light)) - (body (org-babel-expand-noweb-references i))) - (if comment - ((lambda (cs) - (concat (c-wrap (car cs)) "\n" - body "\n" (c-wrap (cadr cs)))) - (org-babel-tangle-comment-links i)) - (setq expansion (concat expansion body)))))) + (org-babel-map-src-blocks nil + (let ((i (org-babel-get-src-block-info 'light))) + (when (equal (or (cdr (assoc :noweb-ref (nth 2 i))) + (nth 4 i)) + source-name) + (let ((body (org-babel-expand-noweb-references i))) + (if comment + ((lambda (cs) + (concat (c-wrap (car cs)) "\n" + body "\n" (c-wrap (cadr cs)))) + (org-babel-tangle-comment-links i)) + (setq expansion (concat expansion body)))))))) expansion) ;; possibly raise an error if named block doesn't exist (if (member lang org-babel-noweb-error-langs) From 7e56afb956f5e61dfe9cf2594473f36fff391795 Mon Sep 17 00:00:00 2001 From: Bastien Guerry Date: Sat, 31 Dec 2011 00:38:06 +0100 Subject: [PATCH 28/44] Fix typos. Fixes already done in Emacs by Paul Eggert. --- lisp/ob-latex.el | 2 +- lisp/org-exp.el | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/lisp/ob-latex.el b/lisp/ob-latex.el index f41475f29..afd8e5f36 100644 --- a/lisp/ob-latex.el +++ b/lisp/ob-latex.el @@ -190,7 +190,7 @@ Extracted from `org-export-as-pdf' in org-latex.el." pdffile))) (defun org-babel-prep-session:latex (session params) - "Return an error because LaTeX doesn't support sesstions." + "Return an error because LaTeX doesn't support sessions." (error "LaTeX does not support sessions")) (provide 'ob-latex) diff --git a/lisp/org-exp.el b/lisp/org-exp.el index eae5be7e9..2f1bccc3f 100644 --- a/lisp/org-exp.el +++ b/lisp/org-exp.el @@ -2333,7 +2333,7 @@ TYPE must be a string, any of: (plist-get org-export-opt-plist (intern (concat ":" key))))) (save-match-data - ;; If arguments are provided, first retreive them properly + ;; If arguments are provided, first retrieve them properly ;; (in ARGS, as a list), then replace them in VAL. (when args (setq args (org-split-string args ",") args2 nil) From b3a18bdea4d585e370277df6836fd1adbca51246 Mon Sep 17 00:00:00 2001 From: Bastien Guerry Date: Sat, 31 Dec 2011 08:59:49 +0100 Subject: [PATCH 29/44] Fix tiny typos. Those have been fixed by Paul Eggert in Emacs first. --- lisp/ob-screen.el | 4 ++-- lisp/org-table.el | 2 +- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/lisp/ob-screen.el b/lisp/ob-screen.el index 3fb7546fd..2b1b25d40 100644 --- a/lisp/ob-screen.el +++ b/lisp/ob-screen.el @@ -37,7 +37,7 @@ (require 'ob-ref) (defvar org-babel-screen-location "screen" - "The command location for screen. + "The command location for screen. In case you want to use a different screen than one selected by your $PATH") (defvar org-babel-default-header-args:screen @@ -111,7 +111,7 @@ In case you want to use a different screen than one selected by your $PATH") (with-temp-file tmpfile (insert body) - ;; org-babel has superflous spaces + ;; org-babel has superfluous spaces (goto-char (point-min)) (delete-matching-lines "^ +$")) tmpfile)) diff --git a/lisp/org-table.el b/lisp/org-table.el index ecc710326..3bb645bbd 100644 --- a/lisp/org-table.el +++ b/lisp/org-table.el @@ -3019,7 +3019,7 @@ them to individual field equations for each field." So @< and $< will always be replaced with @1 and $1, respectively. The advantage of these special markers are that structure editing of the table will not change them, while @1 and $1 will be modified -when a line/row is swaped out of that privileged position. So for +when a line/row is swapped out of that privileged position. So for formulas that use a range of rows or columns, it may often be better to anchor the formula with \"I\" row markers, or to offset from the borders of the table using the @< @> $< $> makers." From 73b1fdb96522d86e8f78d450a20ce2138c9dcf31 Mon Sep 17 00:00:00 2001 From: Carsten Dominik Date: Sat, 31 Dec 2011 09:05:11 +0100 Subject: [PATCH 30/44] Fix clock regexps * lisp/org-clock.el (org-clock-in): (org-clock-find-position): Remove erraneous space in regexp Patch by Joe Vornehm Jr. TINYCHANGE --- lisp/org-clock.el | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lisp/org-clock.el b/lisp/org-clock.el index b29f47b6f..3a0951ecb 100644 --- a/lisp/org-clock.el +++ b/lisp/org-clock.el @@ -1115,7 +1115,7 @@ the clocking selection, associated with the letter `d'." (cond ((and org-clock-in-resume (looking-at - (concat "^[ \t]* " org-clock-string + (concat "^[ \t]*" org-clock-string " \\[\\([0-9]\\{4\\}-[0-9]\\{2\\}-[0-9]\\{2\\}" " *\\sw+\.? +[012][0-9]:[0-5][0-9]\\)\\][ \t]*$"))) (message "Matched %s" (match-string 1)) @@ -1247,7 +1247,7 @@ line and position cursor in that line." (goto-char beg) (when (and find-unclosed (re-search-forward - (concat "^[ \t]* " org-clock-string + (concat "^[ \t]*" org-clock-string " \\[\\([0-9]\\{4\\}-[0-9]\\{2\\}-[0-9]\\{2\\}" " *\\sw+ +[012][0-9]:[0-5][0-9]\\)\\][ \t]*$") end t)) From 9b29bcc7c346e596bc1ad24f316514774937534d Mon Sep 17 00:00:00 2001 From: Carsten Dominik Date: Sat, 31 Dec 2011 09:26:56 +0100 Subject: [PATCH 31/44] Fix bug in mapper function * lisp/org.el (org-scan-tags): Make sure org-map-continue-from is nil at each match --- lisp/org.el | 1 + 1 file changed, 1 insertion(+) diff --git a/lisp/org.el b/lisp/org.el index 14b182bf1..2f6fb0b19 100644 --- a/lisp/org.el +++ b/lisp/org.el @@ -12760,6 +12760,7 @@ only lines with a TODO keyword are included in the output." (org-overview) (org-remove-occur-highlights)) (while (re-search-forward re nil t) + (setq org-map-continue-from nil) (catch :skip (setq todo (if (match-end 1) (org-match-string-no-properties 2)) tags (if (match-end 4) (org-match-string-no-properties 4))) From 339601fe5200c718b0f6789b36413eaa80274fdf Mon Sep 17 00:00:00 2001 From: Bastien Guerry Date: Sat, 31 Dec 2011 11:45:54 +0100 Subject: [PATCH 32/44] org-agenda.el: Use `read-char-exclusive' instead of `read-char'. * org-agenda.el (org-agenda-filter-by-tag): Use `read-char-exclusive' instead of `read-char'. --- lisp/org-agenda.el | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/lisp/org-agenda.el b/lisp/org-agenda.el index 780794e08..a543969cf 100644 --- a/lisp/org-agenda.el +++ b/lisp/org-agenda.el @@ -6187,14 +6187,14 @@ to switch to narrowing." "%s by tag [%s ], [TAB], %s[/]:off, [+-]:narrow, [>==<]:effort: " tag-chars) - (setq char (read-char))) + (setq char (read-char-exclusive))) (when (member char '(?< ?> ?= ??)) ;; An effort operator (setq effort-op (char-to-string char)) @@ -6207,7 +6207,7 @@ to switch to narrowing." (if (= i 9) "0" (int-to-string (1+ i))) "]" (nth i efforts)))) (message "Effort%s: %s " effort-op effort-prompt) - (setq char (read-char)) + (setq char (read-char-exclusive)) (when (or (< char ?0) (> char ?9)) (error "Need 1-9,0 to select effort" )))) (when (equal char ?\t) From f62910082c500c4464ecd9285463fd941019a9f2 Mon Sep 17 00:00:00 2001 From: Bastien Guerry Date: Sat, 31 Dec 2011 11:47:50 +0100 Subject: [PATCH 33/44] org.el (org-show-context): Complete docstring. * org.el (org-show-context): Complete docstring. Thanks to Michael Heerdegen for mentioning this. --- lisp/org.el | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lisp/org.el b/lisp/org.el index 2f6fb0b19..1003164a3 100644 --- a/lisp/org.el +++ b/lisp/org.el @@ -12513,8 +12513,8 @@ starting point when no match is found." (defun org-show-context (&optional key) "Make sure point and context are visible. How much context is shown depends upon the variables -`org-show-hierarchy-above', `org-show-following-heading'. and -`org-show-siblings'." +`org-show-hierarchy-above', `org-show-following-heading', +`org-show-entry-below' and `org-show-siblings'." (let ((heading-p (org-on-heading-p t)) (hierarchy-p (org-get-alist-option org-show-hierarchy-above key)) (following-p (org-get-alist-option org-show-following-heading key)) From 3bd531c9dc764e8ba8d313808b13386caee648ef Mon Sep 17 00:00:00 2001 From: Bastien Guerry Date: Sat, 31 Dec 2011 13:31:02 +0100 Subject: [PATCH 34/44] org-agenda.el: Small code cleanup. * org-agenda.el (org-batch-agenda, org-batch-agenda-csv): Remove deleted function `org-encode-for-stdout'. --- lisp/org-agenda.el | 19 +++++-------------- 1 file changed, 5 insertions(+), 14 deletions(-) diff --git a/lisp/org-agenda.el b/lisp/org-agenda.el index a543969cf..4b7a82196 100644 --- a/lisp/org-agenda.el +++ b/lisp/org-agenda.el @@ -2608,17 +2608,9 @@ before running the agenda command." (org-tags-view nil cmd-key) (org-agenda nil cmd-key))) (set-buffer org-agenda-buffer-name) - (princ (org-encode-for-stdout (buffer-string)))) + (princ (buffer-string))) (def-edebug-spec org-batch-agenda (form &rest sexp)) -;(defun org-encode-for-stdout (string) -; (if (fboundp 'encode-coding-string) -; (encode-coding-string string buffer-file-coding-system) -; string)) - -(defun org-encode-for-stdout (string) - string) - (defvar org-agenda-info nil) ;;;###autoload @@ -2670,11 +2662,10 @@ agenda-day The day in the agenda where this is listed" (setq org-agenda-info (org-fix-agenda-info (text-properties-at 0 line))) (princ - (org-encode-for-stdout - (mapconcat 'org-agenda-export-csv-mapper - '(org-category txt type todo tags date time extra - priority-letter priority agenda-day) - ","))) + (mapconcat 'org-agenda-export-csv-mapper + '(org-category txt type todo tags date time extra + priority-letter priority agenda-day) + ",")) (princ "\n"))))) (def-edebug-spec org-batch-agenda-csv (form &rest sexp)) From b7095d65d85c752ce2f4feca12746809bea3da63 Mon Sep 17 00:00:00 2001 From: Carsten Dominik Date: Sat, 31 Dec 2011 17:04:27 +0100 Subject: [PATCH 35/44] Make Org work with bbdb 3.0 * lisp/org-bbdb.el (org-bbdb-old): New variable. (org-bbdb-store-link): (org-bbdb-open): Check for `org-bbdb-old'. (org-bbdb-open-old): (org-bbdb-open-new): New functions. Patch by Ivan Kanis --- lisp/org-bbdb.el | 71 ++++++++++++++++++++++++++++++++++-------------- 1 file changed, 51 insertions(+), 20 deletions(-) diff --git a/lisp/org-bbdb.el b/lisp/org-bbdb.el index 61f82585e..ddb7e4ab8 100644 --- a/lisp/org-bbdb.el +++ b/lisp/org-bbdb.el @@ -118,6 +118,9 @@ (defvar date) ;; dynamically scoped from Org +;; Support for version 2.35 +(defvar org-bbdb-old (fboundp 'bbdb-record-get-field-internal)) + ;; Customization (defgroup org-bbdb-anniversaries nil @@ -195,8 +198,11 @@ date year)." "Store a link to a BBDB database entry." (when (eq major-mode 'bbdb-mode) ;; This is BBDB, we make this link! - (let* ((name (bbdb-record-name (bbdb-current-record))) - (company (bbdb-record-getprop (bbdb-current-record) 'company)) + (let* ((rec (bbdb-current-record)) + (name (bbdb-record-name rec)) + (company (if org-bbdb-old + (bbdb-record-getprop rec 'company) + (car (bbdb-record-get-field rec 'organization)))) (link (org-make-link "bbdb:" name))) (org-store-link-props :type "bbdb" :name name :company company :link link :description name) @@ -218,24 +224,49 @@ italicized, in all other cases it is left unchanged." (require 'bbdb) (let ((inhibit-redisplay (not debug-on-error)) (bbdb-electric-p nil)) - (catch 'exit - ;; Exact match on name - (bbdb-name (concat "\\`" name "\\'") nil) - (if (< 0 (buffer-size (get-buffer "*BBDB*"))) (throw 'exit nil)) - ;; Exact match on name - (bbdb-company (concat "\\`" name "\\'") nil) - (if (< 0 (buffer-size (get-buffer "*BBDB*"))) (throw 'exit nil)) - ;; Partial match on name - (bbdb-name name nil) - (if (< 0 (buffer-size (get-buffer "*BBDB*"))) (throw 'exit nil)) - ;; Partial match on company - (bbdb-company name nil) - (if (< 0 (buffer-size (get-buffer "*BBDB*"))) (throw 'exit nil)) - ;; General match including network address and notes - (bbdb name nil) - (when (= 0 (buffer-size (get-buffer "*BBDB*"))) - (delete-window (get-buffer-window "*BBDB*")) - (error "No matching BBDB record"))))) + (if org-bbdb-old + (org-bbdb-open-old) + (org-bbdb-open-new)))) + +(defun org-bbdb-open-old () + (catch 'exit + ;; Exact match on name + (bbdb-name (concat "\\`" name "\\'") nil) + (if (< 0 (buffer-size (get-buffer "*BBDB*"))) (throw 'exit nil)) + ;; Exact match on name + (bbdb-company (concat "\\`" name "\\'") nil) + (if (< 0 (buffer-size (get-buffer "*BBDB*"))) (throw 'exit nil)) + ;; Partial match on name + (bbdb-name name nil) + (if (< 0 (buffer-size (get-buffer "*BBDB*"))) (throw 'exit nil)) + ;; Partial match on company + (bbdb-company name nil) + (if (< 0 (buffer-size (get-buffer "*BBDB*"))) (throw 'exit nil)) + ;; General match including network address and notes + (bbdb name nil) + (when (= 0 (buffer-size (get-buffer "*BBDB*"))) + (delete-window (get-buffer-window "*BBDB*")) + (error "No matching BBDB record")))) + +(defun org-bbdb-open-new () + (catch 'exit + ;; Exact match on name + (bbdb-search-name (concat "\\`" name "\\'") nil) + (if (< 0 (buffer-size (get-buffer "*BBDB*"))) (throw 'exit nil)) + ;; Exact match on name + (bbdb-search-organization (concat "\\`" name "\\'") nil) + (if (< 0 (buffer-size (get-buffer "*BBDB*"))) (throw 'exit nil)) + ;; Partial match on name + (bbdb-search-name name nil) + (if (< 0 (buffer-size (get-buffer "*BBDB*"))) (throw 'exit nil)) + ;; Partial match on company + (bbdb-search-organization name nil) + (if (< 0 (buffer-size (get-buffer "*BBDB*"))) (throw 'exit nil)) + ;; General match including network address and notes + (bbdb name nil) + (when (= 0 (buffer-size (get-buffer "*BBDB*"))) + (delete-window (get-buffer-window "*BBDB*")) + (error "No matching BBDB record")))) (defun org-bbdb-anniv-extract-date (time-str) "Convert YYYY-MM-DD to (month date year). From 40976a748037adf5a05e8b8e4fcee138213f1521 Mon Sep 17 00:00:00 2001 From: Nicolas Goaziou Date: Sat, 31 Dec 2011 15:36:53 +0100 Subject: [PATCH 36/44] org-list: Change behaviour of C-c C-c at a list item with an argument * lisp/org-list.el (org-list-write-struct): Add an optional argument for structure changes happening outside the function. * lisp/org.el (org-ctrl-c-ctrl-c): Now, C-u C-c C-c on the first item of a sub-list should toggle check-box presence of every item in the same sub-list. Also fix check-box insertion on a single item. --- lisp/org-list.el | 11 ++++++++--- lisp/org.el | 34 ++++++++++++++++++++++++++-------- 2 files changed, 34 insertions(+), 11 deletions(-) diff --git a/lisp/org-list.el b/lisp/org-list.el index 6d25037a8..415986e55 100644 --- a/lisp/org-list.el +++ b/lisp/org-list.el @@ -1914,16 +1914,21 @@ Initial position of cursor is restored after the changes." (goto-char origin) (move-marker origin nil))) -(defun org-list-write-struct (struct parents) +(defun org-list-write-struct (struct parents &optional old-struct) "Correct bullets, checkboxes and indentation in list at point. + STRUCT is the list structure. PARENTS is the alist of parents, -as returned by `org-list-parents-alist'." +as returned by `org-list-parents-alist'. + +When non-nil, optional argument OLD-STRUCT is the reference +structure of the list. It should be provided whenever STRUCT +doesn't correspond anymore to the real list in buffer." ;; Order of functions matters here: checkboxes and endings need ;; correct indentation to be set, and indentation needs correct ;; bullets. ;; ;; 0. Save a copy of structure before modifications - (let ((old-struct (copy-tree struct))) + (let ((old-struct (or old-struct (copy-tree struct)))) ;; 1. Set a temporary, but coherent with PARENTS, indentation in ;; order to get items endings and bullets properly (org-list-struct-fix-ind struct parents 2) diff --git a/lisp/org.el b/lisp/org.el index 1003164a3..924d5fc0a 100644 --- a/lisp/org.el +++ b/lisp/org.el @@ -18325,12 +18325,19 @@ This command does many different things, depending on context: block-item) ;; Use a light version of `org-toggle-checkbox' to avoid ;; computing list structure twice. - (org-list-set-checkbox (point-at-bol) struct - (cond - ((equal arg '(16)) "[-]") - ((equal arg '(4)) nil) - ((equal "[X]" cbox) "[ ]") - (t "[X]"))) + (let ((new-box (cond + ((equal arg '(16)) "[-]") + ((equal arg '(4)) nil) + ((equal "[X]" cbox) "[ ]") + (t "[X]")))) + (if firstp + ;; If at first item of sub-list, remove check-box from + ;; every item at the same level. + (mapc + (lambda (pos) (org-list-set-checkbox pos struct new-box)) + (org-list-get-all-items + (point-at-bol) struct (org-list-prevs-alist struct))) + (org-list-set-checkbox (point-at-bol) struct new-box))) ;; Replicate `org-list-write-struct', while grabbing a return ;; value from `org-list-struct-fix-box'. (org-list-struct-fix-ind struct parents 2) @@ -18352,9 +18359,20 @@ This command does many different things, depending on context: ;; only if function was called with an argument. Send list only ;; if at top item. (let* ((struct (org-list-struct)) + (new-struct struct) (firstp (= (org-list-get-top-point struct) (point-at-bol)))) - (when arg (org-list-set-checkbox (point-at-bol) struct "[ ]")) - (org-list-write-struct struct (org-list-parents-alist struct)) + (when arg + (setq new-struct (copy-tree struct)) + (if firstp + ;; If at first item of sub-list, add check-box to every + ;; item at the same level. + (mapc + (lambda (pos) (org-list-set-checkbox pos new-struct "[ ]")) + (org-list-get-all-items + (point-at-bol) new-struct (org-list-prevs-alist new-struct))) + (org-list-set-checkbox (point-at-bol) new-struct "[ ]"))) + (org-list-write-struct + new-struct (org-list-parents-alist new-struct) struct) (when arg (org-update-checkbox-count-maybe)) (when firstp (org-list-send-list 'maybe)))) ((save-excursion (beginning-of-line 1) (looking-at org-dblock-start-re)) From 7b512a111146b83f96851226621ae9d97cec15be Mon Sep 17 00:00:00 2001 From: Bastien Guerry Date: Sat, 31 Dec 2011 17:41:23 +0100 Subject: [PATCH 37/44] Fix problem with `org-ctrl-c-ctrl-c' on the checkbox of the first item. * org.el (org-ctrl-c-ctrl-c): Don't make `C-c C-c' special when ticking the checkbox of the first item. --- lisp/org.el | 19 ++++++------------- 1 file changed, 6 insertions(+), 13 deletions(-) diff --git a/lisp/org.el b/lisp/org.el index 924d5fc0a..077fb1942 100644 --- a/lisp/org.el +++ b/lisp/org.el @@ -18325,19 +18325,12 @@ This command does many different things, depending on context: block-item) ;; Use a light version of `org-toggle-checkbox' to avoid ;; computing list structure twice. - (let ((new-box (cond - ((equal arg '(16)) "[-]") - ((equal arg '(4)) nil) - ((equal "[X]" cbox) "[ ]") - (t "[X]")))) - (if firstp - ;; If at first item of sub-list, remove check-box from - ;; every item at the same level. - (mapc - (lambda (pos) (org-list-set-checkbox pos struct new-box)) - (org-list-get-all-items - (point-at-bol) struct (org-list-prevs-alist struct))) - (org-list-set-checkbox (point-at-bol) struct new-box))) + (org-list-set-checkbox (point-at-bol) struct + (cond + ((equal arg '(16)) "[-]") + ((equal arg '(4)) nil) + ((equal "[X]" cbox) "[ ]") + (t "[X]"))) ;; Replicate `org-list-write-struct', while grabbing a return ;; value from `org-list-struct-fix-box'. (org-list-struct-fix-ind struct parents 2) From 1425724d6c954d3b15dd4be4d6e1dec442deb16e Mon Sep 17 00:00:00 2001 From: Bastien Guerry Date: Sat, 31 Dec 2011 17:47:53 +0100 Subject: [PATCH 38/44] Document the new behavior of `C-u C-c C-c' on checkboxes. * org.texi (Checkboxes): Document the new behavior of `C-u C-c C-c' on checkboxes. --- doc/org.texi | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/doc/org.texi b/doc/org.texi index 6b189bd6d..b2a2545b6 100644 --- a/doc/org.texi +++ b/doc/org.texi @@ -1241,8 +1241,8 @@ Reveal context around point, showing the current entry, the following heading and the hierarchy above. Useful for working near a location that has been exposed by a sparse tree command (@pxref{Sparse trees}) or an agenda command (@pxref{Agenda commands}). With a prefix argument show, on each -level, all sibling headings. With double prefix arg, also show the entire -subtree of the parent. +level, all sibling headings. With a double prefix argument, also show the +entire subtree of the parent. @orgcmd{C-c C-k,show-branches} Expose all the headings of the subtree, CONTENT view for just one subtree. @orgcmd{C-c C-x b,org-tree-to-indirect-buffer} @@ -4427,9 +4427,11 @@ off a box while there are unchecked boxes above it. @table @kbd @orgcmd{C-c C-c,org-toggle-checkbox} -Toggle checkbox status or (with prefix arg) checkbox presence at point. With -double prefix argument, set it to @samp{[-]}, which is considered to be an -intermediate state. +Toggle checkbox status or (with prefix arg) checkbox presence at point. +With a single prefix argument, add an empty checkbox or remove the current +one@footnote{`C-u C-c C-c' on the @emph{first} item of a list with no checkbox +will add checkboxes to the rest of the list.}. With a double prefix argument, set it to @samp{[-]}, which is +considered to be an intermediate state. @orgcmd{C-c C-x C-b,org-toggle-checkbox} Toggle checkbox status or (with prefix arg) checkbox presence at point. With double prefix argument, set it to @samp{[-]}, which is considered to be an From a15cb0ad13c60019d575a7c75854e6e74cea00da Mon Sep 17 00:00:00 2001 From: Bastien Guerry Date: Sat, 31 Dec 2011 09:39:58 +0100 Subject: [PATCH 39/44] Be a bit more flexible when matching time values in timestamps. MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * org.el (org-ts-regexp0, org-ts-regexp1): Also match a time value with only one digit for the hours. Thanks to François Pinard for mentioning this. --- lisp/org.el | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/lisp/org.el b/lisp/org.el index 077fb1942..14744e3ad 100644 --- a/lisp/org.el +++ b/lisp/org.el @@ -5209,11 +5209,11 @@ This should be called after the variable `org-link-types' has changed." "Regular expression for fast time stamp matching.") (defconst org-ts-regexp-both "[[<]\\([0-9]\\{4\\}-[0-9]\\{2\\}-[0-9]\\{2\\} ?[^]\r\n>]*?\\)[]>]" "Regular expression for fast time stamp matching.") -(defconst org-ts-regexp0 "\\(\\([0-9]\\{4\\}\\)-\\([0-9]\\{2\\}\\)-\\([0-9]\\{2\\}\\) *\\([^]+0-9>\r\n -]*\\)\\( \\([0-9]\\{2\\}\\):\\([0-9]\\{2\\}\\)\\)?\\)" +(defconst org-ts-regexp0 "\\(\\([0-9]\\{4\\}\\)-\\([0-9]\\{2\\}\\)-\\([0-9]\\{2\\}\\) *\\([^]+0-9>\r\n -]*\\)\\( \\([0-9]\\{1,2\\}\\):\\([0-9]\\{2\\}\\)\\)?\\)" "Regular expression matching time strings for analysis. This one does not require the space after the date, so it can be used on a string that terminates immediately after the date.") -(defconst org-ts-regexp1 "\\(\\([0-9]\\{4\\}\\)-\\([0-9]\\{2\\}\\)-\\([0-9]\\{2\\}\\) *\\([^]+0-9>\r\n -]*\\)\\( \\([0-9]\\{2\\}\\):\\([0-9]\\{2\\}\\)\\)?\\)" +(defconst org-ts-regexp1 "\\(\\([0-9]\\{4\\}\\)-\\([0-9]\\{2\\}\\)-\\([0-9]\\{2\\}\\) *\\([^]+0-9>\r\n -]*\\)\\( \\([0-9]\\{1,2\\}\\):\\([0-9]\\{2\\}\\)\\)?\\)" "Regular expression matching time strings for analysis.") (defconst org-ts-regexp2 (concat "<" org-ts-regexp1 "[^>\n]\\{0,16\\}>") "Regular expression matching time stamps, with groups.") From b77df8397d99a1f6616d4053814afb8ce8b6f17a Mon Sep 17 00:00:00 2001 From: Bastien Guerry Date: Sat, 31 Dec 2011 18:13:23 +0100 Subject: [PATCH 40/44] Revert "Fix problem with `org-ctrl-c-ctrl-c' on the checkbox of the first item." This reverts commit 4789bb5a79f004346c37e3a84d12f90ada24d277. --- lisp/org.el | 19 +++++++++++++------ 1 file changed, 13 insertions(+), 6 deletions(-) diff --git a/lisp/org.el b/lisp/org.el index 14744e3ad..af1c4a505 100644 --- a/lisp/org.el +++ b/lisp/org.el @@ -18325,12 +18325,19 @@ This command does many different things, depending on context: block-item) ;; Use a light version of `org-toggle-checkbox' to avoid ;; computing list structure twice. - (org-list-set-checkbox (point-at-bol) struct - (cond - ((equal arg '(16)) "[-]") - ((equal arg '(4)) nil) - ((equal "[X]" cbox) "[ ]") - (t "[X]"))) + (let ((new-box (cond + ((equal arg '(16)) "[-]") + ((equal arg '(4)) nil) + ((equal "[X]" cbox) "[ ]") + (t "[X]")))) + (if firstp + ;; If at first item of sub-list, remove check-box from + ;; every item at the same level. + (mapc + (lambda (pos) (org-list-set-checkbox pos struct new-box)) + (org-list-get-all-items + (point-at-bol) struct (org-list-prevs-alist struct))) + (org-list-set-checkbox (point-at-bol) struct new-box))) ;; Replicate `org-list-write-struct', while grabbing a return ;; value from `org-list-struct-fix-box'. (org-list-struct-fix-ind struct parents 2) From c535c276feed8f54a8bd3ef2a581445150dbe5bb Mon Sep 17 00:00:00 2001 From: Bastien Guerry Date: Sat, 31 Dec 2011 18:20:30 +0100 Subject: [PATCH 41/44] More small fixes on `C-u C-c C-c' and checkboxes. * org.el (org-ctrl-c-ctrl-c): Preserve symmetry when adding and removing checkboxes with `C-u C-c C-c' on the first item of a list. Also, don't reinitialize checkboxes that are already ticked. Thanks to Nicolas Goaziou for these fixes. --- lisp/org.el | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/lisp/org.el b/lisp/org.el index af1c4a505..659899429 100644 --- a/lisp/org.el +++ b/lisp/org.el @@ -18330,7 +18330,7 @@ This command does many different things, depending on context: ((equal arg '(4)) nil) ((equal "[X]" cbox) "[ ]") (t "[X]")))) - (if firstp + (if (and firstp arg) ;; If at first item of sub-list, remove check-box from ;; every item at the same level. (mapc @@ -18367,7 +18367,9 @@ This command does many different things, depending on context: ;; If at first item of sub-list, add check-box to every ;; item at the same level. (mapc - (lambda (pos) (org-list-set-checkbox pos new-struct "[ ]")) + (lambda (pos) + (unless (org-list-get-checkbox pos new-struct) + (org-list-set-checkbox pos new-struct "[ ]"))) (org-list-get-all-items (point-at-bol) new-struct (org-list-prevs-alist new-struct))) (org-list-set-checkbox (point-at-bol) new-struct "[ ]"))) From 89169dff4cce045d82d2a4cb6880611d5e0029f9 Mon Sep 17 00:00:00 2001 From: Bastien Guerry Date: Mon, 2 Jan 2012 15:28:07 +0100 Subject: [PATCH 42/44] Add a note about :noweb-ref. Thanks to Tomas Grigera for a preliminary patch. --- doc/org.texi | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/doc/org.texi b/doc/org.texi index b2a2545b6..37817de18 100644 --- a/doc/org.texi +++ b/doc/org.texi @@ -13617,7 +13617,9 @@ concatenated together to form the replacement text. By setting this header argument at the sub-tree or file level, simple code block concatenation may be achieved. For example, when tangling the following Org mode file, the bodies of code blocks will be concatenated into -the resulting pure code file. +the resulting pure code file@footnote{(The example needs property inheritance +to be turned on for the @code{noweb-ref} property, see @ref{Property +inheritance}).}. @example #+BEGIN_SRC sh :tangle yes :noweb yes :shebang #!/bin/sh From 926a24aab5963f96f1ce94c9c295e2c7c3273f27 Mon Sep 17 00:00:00 2001 From: Eric Schulte Date: Mon, 2 Jan 2012 11:10:48 -0700 Subject: [PATCH 43/44] documentation of *org-babel-use-quick-and-dirty-noweb-expansion* * doc/org.texi (Noweb reference syntax): Adding documentation of the *org-babel-use-quick-and-dirty-noweb-expansion* variable. --- doc/org.texi | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) diff --git a/doc/org.texi b/doc/org.texi index 37817de18..6eb769a4a 100644 --- a/doc/org.texi +++ b/doc/org.texi @@ -13991,7 +13991,8 @@ When a code block is tangled or evaluated, whether or not ``noweb'' references are expanded depends upon the value of the @code{:noweb} header argument. If @code{:noweb yes}, then a Noweb reference is expanded before evaluation. If @code{:noweb no}, the default, then the reference is not -expanded before evaluation. +expanded before evaluation. See the @ref{noweb-ref} header argument for +a more flexible way to resolve noweb references. Note: the default value, @code{:noweb no}, was chosen to ensure that correct code is not broken in a language, such as Ruby, where @@ -13999,6 +14000,12 @@ correct code is not broken in a language, such as Ruby, where syntactically valid in languages that you use, then please consider setting the default value. +Note: if noweb tangling is slow in large Org-mode files consider setting the +@code{*org-babel-use-quick-and-dirty-noweb-expansion*} variable to true. +This will result in faster noweb reference resolution at the expense of not +correctly resolving inherited values of the @code{:noweb-ref} header +argument. + @node Key bindings and useful functions, Batch execution, Noweb reference syntax, Working With Source Code @section Key bindings and useful functions @cindex code block, key bindings From 2b3534a81f6f4c925f55ed7aaec31ead6f400577 Mon Sep 17 00:00:00 2001 From: Bastien Guerry Date: Tue, 3 Jan 2012 08:31:59 +0000 Subject: [PATCH 44/44] Release 7.8.03 --- README_DIST | 2 +- doc/org.texi | 4 ++-- doc/orgcard.tex | 6 +++--- doc/orgguide.texi | 4 ++-- lisp/ob-fortran.el | 2 +- lisp/org-eshell.el | 2 +- lisp/org.el | 4 ++-- 7 files changed, 12 insertions(+), 12 deletions(-) diff --git a/README_DIST b/README_DIST index 6ef467ff0..ad822658a 100644 --- a/README_DIST +++ b/README_DIST @@ -1,7 +1,7 @@ The is a distribution of Org, a plain text notes and project planning tool for Emacs. -The version of this release is: 7.8.02 +The version of this release is: 7.8.03 The homepage of Org is at http://orgmode.org diff --git a/doc/org.texi b/doc/org.texi index bcb69eb71..6d9a6566d 100644 --- a/doc/org.texi +++ b/doc/org.texi @@ -4,8 +4,8 @@ @setfilename ../../info/org @settitle The Org Manual -@set VERSION 7.8.02 -@set DATE December 2011 +@set VERSION 7.8.03 +@set DATE January 2012 @c Use proper quote and backtick for code sections in PDF output @c Cf. Texinfo manual 14.2 diff --git a/doc/orgcard.tex b/doc/orgcard.tex index d49cd1e62..acea0f124 100644 --- a/doc/orgcard.tex +++ b/doc/orgcard.tex @@ -1,7 +1,7 @@ % Reference Card for Org Mode -\def\orgversionnumber{7.8.02} -\def\versionyear{2011} % latest update -\def\year{2011} % latest copyright year +\def\orgversionnumber{7.8.03} +\def\versionyear{2012} % latest update +\def\year{2012} % latest copyright year %**start of header \newcount\columnsperpage diff --git a/doc/orgguide.texi b/doc/orgguide.texi index 6f71f52a1..ba87661f0 100644 --- a/doc/orgguide.texi +++ b/doc/orgguide.texi @@ -3,8 +3,8 @@ @setfilename ../../info/orgguide @settitle The compact Org-mode Guide -@set VERSION 7.8.02 -@set DATE December 2011 +@set VERSION 7.8.03 +@set DATE January 2012 @c Use proper quote and backtick for code sections in PDF output @c Cf. Texinfo manual 14.2 diff --git a/lisp/ob-fortran.el b/lisp/ob-fortran.el index b2c979096..1b97f8724 100644 --- a/lisp/ob-fortran.el +++ b/lisp/ob-fortran.el @@ -5,7 +5,7 @@ ;; Authors: Sergey Litvinov (based on ob-C.el by Eric Schulte), Eric Schulte ;; Keywords: literate programming, reproducible research, fortran ;; Homepage: http://orgmode.org -;; Version: 7.8.02 +;; Version: 7.8.03 ;; This program is free software; you can redistribute it and/or modify ;; it under the terms of the GNU General Public License as published by diff --git a/lisp/org-eshell.el b/lisp/org-eshell.el index 5486b1e0e..c8754d76b 100644 --- a/lisp/org-eshell.el +++ b/lisp/org-eshell.el @@ -2,7 +2,7 @@ ;; Copyright (C) 2011 Free Software Foundation, Inc. ;; ;; Author: Konrad Hinsen -;; Version: 0.1 +;; Version: 7.8.03 ;; ;; This file is part of GNU Emacs. ;; diff --git a/lisp/org.el b/lisp/org.el index 7163e8f03..3b06347c6 100644 --- a/lisp/org.el +++ b/lisp/org.el @@ -6,7 +6,7 @@ ;; Maintainer: Bastien Guerry ;; Keywords: outlines, hypermedia, calendar, wp ;; Homepage: http://orgmode.org -;; Version: 7.8.02 +;; Version: 7.8.03 ;; ;; This file is part of GNU Emacs. ;; @@ -203,7 +203,7 @@ identifier." ;;; Version -(defconst org-version "7.8.02" +(defconst org-version "7.8.03" "The version number of the file org.el.") (defun org-version (&optional here)