5 years agoorg-agenda.el: Fix bug about restoring existing window conf release_7.9
Bastien Guerry [Fri, 24 Aug 2012 13:54:58 +0000 (15:54 +0200)]
org-agenda.el: Fix bug about restoring existing window conf

* org-agenda.el (org-prepare-agenda-window): Use
`org-pre-agenda-window-conf' if already set.
(org-agenda-Quit): Set `org-pre-agenda-window-conf' to nil
when quitting.
(org-agenda-quit): Ditto.

Thanks to Moritz Ulrich for reporting a bug about this.

5 years agoorg-capture.el: Protect the text used for replacement from being further replaced
Bastien Guerry [Fri, 24 Aug 2012 13:45:03 +0000 (15:45 +0200)]
org-capture.el: Protect the text used for replacement from being further replaced

* org-capture.el (org-capture-fill-template): Protect the text
used for replacement from being further replaced.

Thanks to Moritz Ulrich for reporting this bug.

5 years agoFix comment auto-filling
Nicolas Goaziou [Fri, 24 Aug 2012 12:57:00 +0000 (14:57 +0200)]
Fix comment auto-filling

* lisp/org.el (org-set-autofill-regexps): Install new comment line
  break function.
(org-comment-line-break-function): New function.
(org-mode): Remove unnecessary line.

5 years agoMerge branch 'master' of
Bastien Guerry [Fri, 24 Aug 2012 12:23:07 +0000 (14:23 +0200)]
Merge branch 'master' of

5 years agoorg.el: Fix the contextual check against a function
Bastien Guerry [Fri, 24 Aug 2012 12:22:45 +0000 (14:22 +0200)]
org.el: Fix the contextual check against a function

* org.el (org-contextualize-validate-key): Fix the check
against a function.

5 years agoDo not fill verse blocks contents
Nicolas Goaziou [Fri, 24 Aug 2012 10:55:25 +0000 (12:55 +0200)]
Do not fill verse blocks contents

* lisp/org.el (org-fill-context-prefix, org-fill-paragraph): Do not
  fill verse blocks contents.  Verse blocks can be used to format
  free-form poetry, so filling has to be done manually.
* testing/lisp/test-org.el: Remove unnecessary tests.

5 years agoAuto-filling must not break current paragraph
Nicolas Goaziou [Fri, 24 Aug 2012 10:17:22 +0000 (12:17 +0200)]
Auto-filling must not break current paragraph

* lisp/org.el (org-fill-paragraph-separate-nobreak-p): New function.
(org-set-autofill-regexps): Introduce new predicate.
(org-fill-item-nobreak-p): Remove function.

5 years agoorg-element: Paragraphs don't end at incomplete latex environments
Nicolas Goaziou [Fri, 24 Aug 2012 10:15:53 +0000 (12:15 +0200)]
org-element: Paragraphs don't end at incomplete latex environments

* lisp/org-element.el (org-element-paragraph-separate): Since this
  variable is meant to be searched forward, \end{...} shouldn't
  trigger the end of a paragraph before checking if it is the end of
  a complete environment.
(org-element-latex-environment-parser): Slight change to the regexp
matching the beginning of a latex environment.
(org-element-paragraph-parser): Paragraphs don't end at incomplete
latex environments.
(org-element-latex-or-entity-successor): Remove paragraph environments
from latex fragment search.

5 years agoUpdate the handling of agenda/capture keys contextualization.
Bastien Guerry [Fri, 24 Aug 2012 10:14:54 +0000 (12:14 +0200)]
Update the handling of agenda/capture keys contextualization.

* org.el (org-contextualize-keys): Rename from
`org-contextualize-agenda-or-capture'.  Fix normalization to
handle empty key replacement string.
(org-contextualize-validate-key): Rename from
`org-contexts-validate'.  Allow checking against a custom

* org-agenda.el (org-agenda-custom-commands-contexts): Update.
(org-agenda): Use `org-contextualize-keys'.

* org-capture.el (org-capture-templates-contexts): Ditto.

* org.texi (Templates in contexts, Setting Options): Update to
reflect changes in how contexts options are processed.

5 years agoorg.el (org-contextualize-agenda-or-capture): Normalize contexts
Bastien Guerry [Thu, 23 Aug 2012 23:48:45 +0000 (01:48 +0200)]
org.el (org-contextualize-agenda-or-capture): Normalize contexts

* org.el (org-contextualize-agenda-or-capture): Normalize

5 years agoImplement key replacement depending on the contexts.
Bastien Guerry [Thu, 23 Aug 2012 15:04:43 +0000 (17:04 +0200)]
Implement key replacement depending on the contexts.

* org.el (org-contextualize-agenda-or-capture): Handle key
replacement depending on the contexts.

* org-capture.el (org-capture-templates-contexts): Allow to
use the context as a way to replace one capture template by
another one.

* org-agenda.el (org-agenda-custom-commands-contexts): Allow
to use the context as a way to replace one agenda custom
command by another one.

* org.texi (Templates in contexts): Document the new structure
of the variables `org-agenda-custom-commands-contexts' and

In the setup below, X is not a real capture template, it is just
an alias to templates A and B in .txt and .el files.  A and B are
deactivated by default in all files.

(setq org-capture-templates
      '(("X" "Nothing but an alias")
("A" "AAAA" entry (file+headline [...]))
("B" "BBBB" entry (file+headline [...]))))

(setq org-capture-templates-contexts
      '(("A" "A" ((not-in-file . ".*")))
("B" "B" ((not-in-file . ".*")))
("X" "A" ((in-file . "\\.txt")))
("X" "B" ((in-file . "\\.el")))))

Thanks to Carsten for suggesting this "key-replacement" idea!

5 years agoorg-e-texinfo.el: Tiny formatting and code fix
Bastien Guerry [Fri, 24 Aug 2012 09:21:24 +0000 (11:21 +0200)]
org-e-texinfo.el: Tiny formatting and code fix

* org-e-texinfo.el (org-e-texinfo-table-column-widths): Remove
a quote before a lambda expression.

5 years agoorg-export: Small clean-up
Nicolas Goaziou [Fri, 24 Aug 2012 08:44:05 +0000 (10:44 +0200)]
org-export: Small clean-up

5 years agoorg-export: Make sure back-end specific filters do not make any back-end check
Nicolas Goaziou [Fri, 24 Aug 2012 08:41:41 +0000 (10:41 +0200)]
org-export: Make sure back-end specific filters do not make any back-end check

* contrib/lisp/org-e-ascii.el (org-e-ascii-filter-headline-blank-lines):
  Remove backend check.
* contrib/lisp/org-e-texinfo.el (org-e-texinfo-filter-section-blank-lines):
  Remove backend check.
* contrib/lisp/org-export.el (org-export-define-backend): Update
  docstring accordingly.

5 years agoorg-export: Run export hook with current back-end as argument
Nicolas Goaziou [Fri, 24 Aug 2012 08:06:14 +0000 (10:06 +0200)]
org-export: Run export hook with current back-end as argument

* contrib/lisp/org-export.el (org-export-as): Run export hook with
  current back-end as argument.
* testing/lisp/test-org-export.el: Update test.

5 years agoorg-export: Nil value from a filter means filter will be skipped
Nicolas Goaziou [Wed, 22 Aug 2012 11:48:12 +0000 (13:48 +0200)]
org-export: Nil value from a filter means filter will be skipped

* contrib/lisp/org-export.el (org-export-filter-apply-functions): Nil
  value from a filter means filter will be skipped. To ignore the
  current element or object, the filter has to return the empty string

This change is done to ease filter writing. When writing
a backend-specific filter (and I guess most are), there's no more need
for the somewhat contrived:

  (if (not (eq backend 'e-latex)) data
    ... filter's job...)

A more straightforward:

  (when (eq backend 'e-latex)
    ... filter's job...)

is now enough.

On the other hand, it is not possible anymore to specify 'ignore as
a filter to ignore every element or object of a given type. To
achieve that goal, one can now write, for example:

  (add-to-list 'org-export-filter-example-block-functions
                 (lambda (value backend info)
                   (when (eq backend 'e-html) "")))

It will ignore every example block in the `e-html' export back-end.

5 years agoorg-export: Limit depth of headline collection to headline level
Nicolas Goaziou [Fri, 24 Aug 2012 07:33:58 +0000 (09:33 +0200)]
org-export: Limit depth of headline collection to headline level

* contrib/lisp/org-export.el (org-export-collect-headlines): By
  default, limit depth of headline collection to last headline level.
* contrib/lisp/org-e-html.el (org-e-html-toc): Small refactoring.

5 years agoorg-e-html: Fix TOC generation with a non numeric value
Nicolas Goaziou [Thu, 23 Aug 2012 19:24:38 +0000 (21:24 +0200)]
org-e-html: Fix TOC generation with a non numeric value

* contrib/lisp/org-e-html.el (org-e-html-toc): Accept non numeric
  values for depth.
(org-e-html-template): Call previous function even when depth isn't
a number.
(org-e-html-keyword): Call previous function even when depth isn't
a number.  Also react on #+HTML keywords, not #+LATEX.

5 years agoMakefile: remove circular dependency created by robo-changing UTILITIES->utils
Achim Gratz [Thu, 23 Aug 2012 15:59:23 +0000 (17:59 +0200)]
Makefile: remove circular dependency created by robo-changing UTILITIES->utils

* Remove circular dependency created by robo-changing

Fortunately this was non-fatal since direct circular dependencies are
ignored by GNU Make.  Must happen more often... :-)

5 years agocontrib/lisp/org-e-texinfo: Ensure valid export of escaped characters
Jonathan Leech-Pepin [Thu, 23 Aug 2012 14:50:24 +0000 (10:50 -0400)]
contrib/lisp/org-e-texinfo: Ensure valid export of escaped characters
and remove invalid characters from menu items

* contrib/lisp/org-e-texinfo.el (org-e-texinfo--sanitize-menu): Remove
  invalid characters from menu entries and nodes.
(org-e-texinfo--sanitize-contents): Ensure @ { and } are properly
escaped in text and headlines.
(org-e-texinfo--generate-menu-items): Strip invalid characters from
menu titles.
(org-e-texinfo-fixed-width): Escape @ { and } in fixed-width
(org-e-texinfo-headline): Ensure nodes do not have invalid characters
and escape @ { and } in section titles.
(org-e-texinfo-plain-text): Use proper escape character for @ { and }.

5 years agocontrib/lisp/org-e-texinfo: Remove markup from headlines when
Jonathan Leech-Pepin [Thu, 23 Aug 2012 13:20:02 +0000 (09:20 -0400)]
contrib/lisp/org-e-texinfo: Remove markup from headlines when
exporting to ensure info can process them properly

* contrib/lisp/org-e-texinfo.el (org-e-texinfo--generate-menu-items):
  Use org-e-texinfo--sanitize-headline to ensure markup is stripped
  before being used for sectioning and menu information.  Nodes and
  menus can fail because of formatting and section titles do not show
  any formatting when viewed in an info-viewer.
(org-e-texinfo--sanitize-headline): Wrapper function for
(org-e-texinfo--sanitize-headline-contents): Strips markup from
headlines.  It treats content recursively to ensure nested formatting
is removed as well.

5 years agocontrib/lisp/org-e-texinfo: Improve error reporting after makeinfo
Jonathan Leech-Pepin [Thu, 23 Aug 2012 12:36:15 +0000 (08:36 -0400)]
contrib/lisp/org-e-texinfo: Improve error reporting after makeinfo

* contrib/lisp/org-e-texinfo.el (org-e-texinfo-collect-errors): Fixed
  error checking to actually return an error message.

5 years agoAdd eldo.el to utils/
Bastien Guerry [Thu, 23 Aug 2012 10:55:45 +0000 (12:55 +0200)]
Add eldo.el to utils/

eldo.el allows to write documentation from Elisp files in an org file.

5 years agoRename UTILITIES/ to utils/
Bastien Guerry [Thu, 23 Aug 2012 10:47:10 +0000 (12:47 +0200)]
Rename UTILITIES/ to utils/

5 years implement `cleanrel´ here
Achim Gratz [Wed, 22 Aug 2012 06:04:56 +0000 (08:04 +0200)] implement `cleanrel´ here

* Remove `cleanrel´.

* UTILITIES/ Implement `cleanrel´, use only the names that
  will be produced by

5 years agoMakefile: adding files from contrib
Achim Gratz [Wed, 22 Aug 2012 06:04:56 +0000 (08:04 +0200)]
Makefile: adding files from contrib

* Add customizatin variable ORG_ADD_CONTRIB with
  descriptiona and commented example.

* Strip leading path and trailing suffix from all elements
  of ORG_ADD_CONTRIB, then prefix with contrib/lisp and do wildcard
  expansion (this will also remove any invalid names); store the
  result in ORG_FROM_CONTRIB.  Strip /contrib from ORG_FROM_CONTRIB
  and store the result in ORG_TO_LISP.  If these are non-empty, copy
  the files from contrib/lisp/ into lisp/ before compilation and
  remove them when cleanlisp is called.

5 years agoRevert " implement `cleanrel´ here"
Bastien Guerry [Thu, 23 Aug 2012 10:31:44 +0000 (12:31 +0200)]
Revert " implement `cleanrel´ here"

This reverts commit ddcf4f851154e8b13065cb8de162470827b04ca1.

5 years implement `cleanrel´ here
Achim Gratz [Wed, 22 Aug 2012 06:04:56 +0000 (08:04 +0200)] implement `cleanrel´ here

* Remove `cleanrel´.

* UTILITIES/ Implement `cleanrel´, use only the names that
  will be produced by

5 years agoMerge branch 'master' of
Bastien Guerry [Thu, 23 Aug 2012 09:51:24 +0000 (11:51 +0200)]
Merge branch 'master' of

5 years agoImplement context filtering for agenda commands and capture templates.
Bastien Guerry [Thu, 23 Aug 2012 09:08:47 +0000 (11:08 +0200)]
Implement context filtering for agenda commands and capture templates.

* org.el (org-contextualize-agenda-or-capture)
(org-rule-validate): New functions, implement context
filtering for agenda commands and capture templates.

* org-agenda.el (org-agenda-custom-commands-contexts): New
(org-agenda): Use it.

* org-capture.el (org-capture-templates-contexts): New option.
(org-capture-select-template): Use it.

* org.texi (Templates in contexts): Document the new option
(Storing searches): Document the new option

This idea comes from Sylvain Rousseau, who implemented a similar
feature with org-context.el:

This implementation is a bit simpler and more general.  Simpler
because it relies on existing templates, no need to define other
contextual ones.  More general because contexts can be defined
wrt files and modes.

Thanks *very much* to Sylvain for paving the way -- certainly a
great addition to Org.

5 years agoorg-export: Fix reference to a free variable in macros
Nicolas Goaziou [Thu, 23 Aug 2012 09:03:09 +0000 (11:03 +0200)]
org-export: Fix reference to a free variable in macros

* contrib/lisp/org-export.el (org-export-define-backend,
  org-export-define-derived-backend): Fix reference to a free variable
  in macro.

5 years fix release archive names
Achim Gratz [Wed, 22 Aug 2012 06:04:56 +0000 (08:04 +0200)] fix release archive names

* UTILITIES/ Strip "release_" prefix from $(GITVERSION) when
  making the archive names.

5 years fix typo
Achim Gratz [Wed, 22 Aug 2012 06:04:56 +0000 (08:04 +0200)] fix typo

* UTILITIES/ Change ORGRDIR->ORGDIR everywhere.

5 years agoMakefile: avoid a superfluous fork
Achim Gratz [Wed, 22 Aug 2012 06:04:56 +0000 (08:04 +0200)]
Makefile: avoid a superfluous fork

* Avoid superfluous fork in implementation of clean

5 years agoMakefile: error out on invalid values of ORGCM
Achim Gratz [Wed, 22 Aug 2012 16:43:03 +0000 (18:43 +0200)]
Makefile: error out on invalid values of ORGCM

* lisp/Makefile: Check validity of value given in ORGCM and terminate
  with an error message if an illegal value is used.

5 years agocontrib/lisp/org-e-texinfo.el: Fix export bugs
Jonathan Leech-Pepin [Wed, 22 Aug 2012 15:06:07 +0000 (11:06 -0400)]
contrib/lisp/org-e-texinfo.el: Fix export bugs

* contrib/lisp/org-e-texinfo.el (org-e-texinfo--generate-detailed): Do
  not run if there are no headlines in the file.
(org-e-texinfo-template): Generate menu and detailed menu in initial
let form.  Only insert them if non-empty.
(org-e-texinfo-headline): Ensure that %'s are properly escaped in
@node's to prevent parse errors.
(org-e-texinfo-make-menu): Do not insert "detailed" if menu is empty,
return empty entry instead.

Thanks to Bastien for reporting the failures with headline-less files
and simple "%" in the headline.

5 years agoorg.el: Delete `org-beginning-of-defun' and `org-end-of-defun'
Bastien Guerry [Wed, 22 Aug 2012 17:02:39 +0000 (19:02 +0200)]
org.el: Delete `org-beginning-of-defun' and `org-end-of-defun'

* org.el (org-beginning-of-defun, org-end-of-defun): Delete.
(org-mode): Set `beginning-of-defun-function' and
`end-of-defun-function' directly.

5 years agoorg-e-beamer: Do not normalize empty arguments
Nicolas Goaziou [Wed, 22 Aug 2012 15:45:18 +0000 (17:45 +0200)]
org-e-beamer: Do not normalize empty arguments

* contrib/lisp/org-e-beamer.el (org-e-beamer--normalize-argument): Do
  not normalize empty arguments.

5 years agoorg-e-latex: Fix bug when exporting empty items
Nicolas Goaziou [Wed, 22 Aug 2012 14:55:18 +0000 (16:55 +0200)]
org-e-latex: Fix bug when exporting empty items

* contrib/lisp/org-e-latex.el (org-e-latex-item): Fix bug when
  exporting empty items.

5 years agoorg-e-beamer: Fix bug with default value for outline frame options
Nicolas Goaziou [Wed, 22 Aug 2012 14:31:51 +0000 (16:31 +0200)]
org-e-beamer: Fix bug with default value for outline frame options

* contrib/lisp/org-e-beamer.el (org-e-beamer-outline-frame-options):
  Value must be a string, so make default value an empty string
  instead of nil.

5 years agoMerge branch 'master' of
Bastien Guerry [Wed, 22 Aug 2012 10:25:44 +0000 (12:25 +0200)]
Merge branch 'master' of

5 years agoorg.el: Fix bug: include links abbreviations when completing
Bastien Guerry [Wed, 22 Aug 2012 10:24:14 +0000 (12:24 +0200)]
org.el: Fix bug: include links abbreviations when completing

* org.el (org-insert-link): Fix bug: include links
abbreviations when completing.

5 years agoorg-e-latex: Fix typo in a docstring
Nicolas Goaziou [Wed, 22 Aug 2012 07:34:24 +0000 (09:34 +0200)]
org-e-latex: Fix typo in a docstring

* contrib/lisp/org-e-latex.el (org-e-latex--delayed-footnotes-definitions):
  Fix typo in a docstring.

5 years agoorg-icalendar.el: Fix bug.
Bastien Guerry [Wed, 22 Aug 2012 00:41:18 +0000 (02:41 +0200)]
org-icalendar.el: Fix bug.

* org-icalendar.el (org-icalendar-print-entries): Fix bug:
when `org-icalendar-use-plain-timestamp' is nil, scheduled and
deadline items should not be ignored.

Thanks to Friedrich Delgado for reporting this.

5 years agoorg.el: Small docstring clean-up
Bastien Guerry [Wed, 22 Aug 2012 00:39:18 +0000 (02:39 +0200)]
org.el: Small docstring clean-up

* org.el (org-ds-keyword-length, org-make-tags-matcher):
Docstring clean-up.

5 years agoorg-freemind.el: Fix bug when converting links
Bastien Guerry [Tue, 21 Aug 2012 22:42:02 +0000 (00:42 +0200)]
org-freemind.el: Fix bug when converting links

* org-freemind.el (org-freemind-convert-links-from-org):
Replace literally to prevent errors when replacing with string
containing backslashes.

Thanks to Martin Beck for reporting this.

5 years agoorg-pcomplete.el: Allow to match and complete a "thing" containing dashes
Bastien Guerry [Tue, 21 Aug 2012 22:20:09 +0000 (00:20 +0200)]
org-pcomplete.el: Allow to match and complete a "thing" containing dashes

* org-pcomplete.el (org-thing-at-point): Allow to match (and
then complete) a "thing" containing dashes.

Thanks to Aidan Gauland for reporting this problem.

5 years agoorg.texi (Advanced features): Fix error in table
Charles [Tue, 21 Aug 2012 22:12:21 +0000 (00:12 +0200)]
org.texi (Advanced features): Fix error in table

* org.texi (Advanced features): Fix error in table.


5 years agoMakefile: add link to Worg to `make help´
Achim Gratz [Sun, 19 Aug 2012 10:21:33 +0000 (12:21 +0200)]
Makefile: add link to Worg to `make help´

* Makefile: Add link to documentation for the build system on Worg.

5 years implement ELPA
Achim Gratz [Sun, 19 Aug 2012 10:21:33 +0000 (12:21 +0200)] implement ELPA

* UTILITIES/ Add ELPA archive generation.

5 years agoMakefile: fix some errors
Achim Gratz [Sun, 19 Aug 2012 16:54:15 +0000 (18:54 +0200)]
Makefile: fix some errors

* Repair .PHONY target.  Correctly group ORed parameters
  in find calls.  Introduce $(CLEANDIRS) and use variable instead of
  literals.  Have a command succeed at the end of `config-*´ so that
  no spurious warning is given by make.

5 years agoMakefile: implement different compilation methods, rename _COMPILE_ to ORGCM
Achim Gratz [Sun, 19 Aug 2012 10:21:33 +0000 (12:21 +0200)]
Makefile: implement different compilation methods, rename _COMPILE_ to ORGCM

*,, lisp/Makefile: Rename _COMPILE_ to ORGCM.

* Define ORGCM=dirall, show other possible values as

* Implement target `single´, temporarily set
  ORGCM (overriding configuration).  Show newly introduced
  configuration variables with `check-*´.

* lisp/Makefile: Implement dispatch for compile based on ORGCM.
  Output header that contains the target for easier debugging.

* Makefile: Document target `single´.

5 years agoRevert "Revert "Makefile: allow for different compilation methods""
Achim Gratz [Sun, 19 Aug 2012 10:20:47 +0000 (12:20 +0200)]
Revert "Revert "Makefile: allow for different compilation methods""

This reverts commit 510f6464b06932406051fd0983586f6c1680e098.

5 years agoorg-table.el: Better message when interactively toggling Row/Col display
Bastien Guerry [Tue, 21 Aug 2012 18:09:25 +0000 (20:09 +0200)]
org-table.el: Better message when interactively toggling Row/Col display

* org-table.el (org-table-toggle-coordinate-overlays): Better
message when interactively toggling.

5 years agoorg-colview.el: Make sure to add a face to a string that has no face
Jay McCarthy [Tue, 21 Aug 2012 18:05:34 +0000 (20:05 +0200)]
org-colview.el: Make sure to add a face to a string that has no face

* org-colview.el (org-columns-new-overlay): Make sure to add a
face to a string that has no face.


See the description of the bug here:

5 years agoorg-e-latex: Display nicer horizontal rules
Nicolas Goaziou [Tue, 21 Aug 2012 16:53:14 +0000 (18:53 +0200)]
org-e-latex: Display nicer horizontal rules

* contrib/lisp/org-e-latex.el (org-e-latex-horizontal-rule): Display
  nicer horizontal rules. Support :width and :thickness attributes.

5 years agoorg-table.el: Minor docstring update
Bastien Guerry [Tue, 21 Aug 2012 16:31:12 +0000 (18:31 +0200)]
org-table.el: Minor docstring update

* org-table.el (org-table-number-regexp): Update the docstring
to show an example of a decimal number using the comma as a
separation mark.

5 years agoorg.texi (Formula syntax for Lisp): Reformat
Bastien Guerry [Tue, 21 Aug 2012 16:28:35 +0000 (18:28 +0200)]
org.texi (Formula syntax for Lisp): Reformat

* org.texi (Formula syntax for Lisp): Reformat.

5 years agoMerge branch 'master' of
Bastien Guerry [Tue, 21 Aug 2012 16:16:11 +0000 (18:16 +0200)]
Merge branch 'master' of

5 years agoorg-agenda.el: Fix a bug in category filtering
Bastien Guerry [Tue, 21 Aug 2012 16:12:16 +0000 (18:12 +0200)]
org-agenda.el: Fix a bug in category filtering

* org-agenda.el (org-prepare-agenda): Minor code clean-up.
(org-agenda-filter-by-category): Filtering must be turned off
only when a category filter has been set and this filter is
not empty.

5 years agoorg-agenda.el: Code clean-up
Bastien Guerry [Tue, 21 Aug 2012 16:01:30 +0000 (18:01 +0200)]
org-agenda.el: Code clean-up

* org-agenda.el (org-search-view, org-agenda-get-todos)
(org-agenda-get-timestamps, org-agenda-get-sexps)
(org-agenda-get-progress, org-agenda-get-deadlines)
(org-agenda-get-scheduled, org-agenda-get-blocks): Use
`category-pos' instead of `org-category-pos'.

5 years agoorg-table: Accept comma as a decimal mark to represent numbers
Nicolas Goaziou [Tue, 21 Aug 2012 11:53:57 +0000 (13:53 +0200)]
org-table: Accept comma as a decimal mark to represent numbers

* lisp/org-table.el (org-table-number-regexp): By default, accept
  comma as a decimal mark to represent numbers.

5 years agoReplace "ob-" by "org-babel-" as a prefix for two functions
Bastien Guerry [Tue, 21 Aug 2012 11:17:08 +0000 (13:17 +0200)]
Replace "ob-" by "org-babel-" as a prefix for two functions

* ob-fortran.el (org-babel-fortran-transform-list): Rename
from `ob-fortran-transform-list'.
(org-babel-fortran-var-to-fortran): Use the new function's

* ob-calc.el (org-babel-calc-maybe-resolve-var): Rename from
(org-babel-execute:calc): Use the new function's name.

5 years agoAdd licenses to embedded and external javascript code.
Bastien Guerry [Tue, 21 Aug 2012 10:37:32 +0000 (12:37 +0200)]
Add licenses to embedded and external javascript code.

* org-jsinfo.el (org-infojs-template): Add a license.
(org-infojs-handle-options): Replace all template elements.

* org-html.el (org-export-html-scripts): Add a license.
(org-export-html-mathjax-config): Replace all template
(org-export-html-mathjax-template): Add a license.
(org-export-as-html): Minor code clean-up.

5 years agocontrib/: Update the README
Bastien Guerry [Tue, 21 Aug 2012 10:34:53 +0000 (12:34 +0200)]
contrib/: Update the README

5 years agocontrib/: Delete useless files
Bastien Guerry [Tue, 21 Aug 2012 10:34:37 +0000 (12:34 +0200)]
contrib/: Delete useless files

Delete these files:

5 years agoorg.el: Add "#+MATHJAX" and "#+INFOJS_OPT" to the list of keywords for completion
Bastien Guerry [Tue, 21 Aug 2012 10:34:02 +0000 (12:34 +0200)]
org.el: Add "#+MATHJAX" and "#+INFOJS_OPT" to the list of keywords for completion

* org.el (org-options-keywords): Add "#+MATHJAX" and
"#+INFOJS_OPT" to the list of keywords for completion.

5 years agoorg.el (org-src-prevent-auto-filling): Remove unused and useless option
Bastien Guerry [Mon, 20 Aug 2012 17:22:26 +0000 (19:22 +0200)]
org.el (org-src-prevent-auto-filling): Remove unused and useless option

* org.el (org-src-prevent-auto-filling): Remove unused and
useless option.

5 years agoorg.texi: Fix reference to an unknown variable
Nicolas Goaziou [Mon, 20 Aug 2012 14:53:21 +0000 (16:53 +0200)]
org.texi: Fix reference to an unknown variable

* doc/org.texi (Literal examples): Remove reference to unknown
  `org-export-latex-minted' variable. Also simplify footnote since
  `org-export-latex-listings' documentation is exhaustive already.

5 years agotesting/: Update two tests
Bastien Guerry [Mon, 20 Aug 2012 12:24:14 +0000 (14:24 +0200)]
testing/: Update two tests

The current Emacs trunk bumped to version >24.2.50 because a new
release Emacs 24.2 has been decided.  `cl-map' is not an alias for
`map' in Emacs < 24.2.50 -- so take this into account in some tests.

5 years agocontrib/lisp/: Replace the deleted function `org-make-link' by `concat'
Bastien Guerry [Mon, 20 Aug 2012 12:03:15 +0000 (14:03 +0200)]
contrib/lisp/: Replace the deleted function `org-make-link' by `concat'

* org-notmuch.el (org-notmuch-store-link)
(org-notmuch-search-store-link): Use `concat' instead of

* org-git-link.el (org-git-create-git-link)
(org-git-insert-link-interactively): Ditto.

* org-bookmark.el (org-bookmark-store-link): Ditto.

Thanks to Friedrich Delgado for reporting this.

5 years agoorg.el: Autoload `org-element-at-point' instead of requiring org-element it in some...
Bastien Guerry [Mon, 20 Aug 2012 11:30:43 +0000 (13:30 +0200)]
org.el: Autoload `org-element-at-point' instead of requiring org-element it in some commands

* org.el (org-element-at-point): Autoload.
(org-element-up): Remove useless declaration.
(org-fill-context-prefix, org-fill-paragraph)
(org-mark-element, org-narrow-to-element)
(org-transpose-element, org-unindent-buffer): Do not require

5 years agoorg-element: Fix comment typo
Nicolas Goaziou [Mon, 20 Aug 2012 09:21:16 +0000 (11:21 +0200)]
org-element: Fix comment typo

* lisp/org-element.el (org-element-map): Fix comment typo.

5 years agoorg-export: Fix code comments
Nicolas Goaziou [Mon, 20 Aug 2012 08:25:05 +0000 (10:25 +0200)]
org-export: Fix code comments

5 years agoorg-element: Add a couple of autoload cookies
Nicolas Goaziou [Mon, 20 Aug 2012 08:16:21 +0000 (10:16 +0200)]
org-element: Add a couple of autoload cookies

5 years agoorg.el (org-fill-paragraph): Require org-element
Bastien Guerry [Mon, 20 Aug 2012 06:35:54 +0000 (08:35 +0200)]
org.el (org-fill-paragraph): Require org-element

* org.el (org-fill-paragraph): Require org-element.

5 years agoorg-agenda.el (org-agenda-persistent-marks): Minor docstring enhancement
Bastien Guerry [Mon, 20 Aug 2012 06:02:36 +0000 (08:02 +0200)]
org-agenda.el (org-agenda-persistent-marks): Minor docstring enhancement

* org-agenda.el (org-agenda-persistent-marks): Minor docstring enhancement.

5 years agoDon't use :version "24.3" until Emacs 24.3 is released and/or Org sync'ed in Emacs
Bastien Guerry [Mon, 20 Aug 2012 05:49:16 +0000 (07:49 +0200)]
Don't use :version "24.3" until Emacs 24.3 is released and/or Org sync'ed in Emacs

5 years agoAlways use the compatibility function `org-region-active-p'
Bastien Guerry [Mon, 20 Aug 2012 03:45:25 +0000 (05:45 +0200)]
Always use the compatibility function `org-region-active-p'

* org.el (org-create-math-formula): Use the compatibility
function `org-region-active-p'.

* org-odt.el (org-export-as-odf): Ditto.

* ob.el (org-babel-demarcate-block): Ditto.

5 years agoorg.el: Fix bug in `org-mark-subtree'
Bastien Guerry [Mon, 20 Aug 2012 03:40:25 +0000 (05:40 +0200)]
org.el: Fix bug in `org-mark-subtree'

* org.el (org-mark-subtree): Maybe call `org-mark-element'
(org-mark-element): Only mark further elements when called

For example, M-x org-export RET calls `org-mark-subtree' and
should not mark the further element when an element is already

Thanks To Bernt Hansen for reporting a bug related to this.

5 years agoorg.el: Add (require 'org-element) for more org-element commands
Bastien Guerry [Mon, 20 Aug 2012 02:36:38 +0000 (04:36 +0200)]
org.el: Add (require 'org-element) for more org-element commands

* org.el (org-mark-element, org-narrow-to-element)
(org-transpose-element): Require org-element.

5 years agoMerge branch 'master' of
Luis Anaya [Sun, 19 Aug 2012 23:42:45 +0000 (19:42 -0400)]
Merge branch 'master' of

5 years agoorg-agenda.el: New 'warntime property for agenda entries
Bastien Guerry [Sun, 19 Aug 2012 19:48:52 +0000 (21:48 +0200)]
org-agenda.el: New 'warntime property for agenda entries

* org-agenda.el (org-agenda-get-timestamps)
(org-agenda-get-sexps, org-agenda-get-deadlines)
(org-agenda-get-scheduled): Add the 'warntime as a text
property, getting its value from the APPT_WARNTIME property.
(org-agenda-to-appt): Use the 'warntime text property.

Thanks to Ivan Kanis for reporting a bug related to this.

5 years agoMerge branch 'master' of
Luis Anaya [Sun, 19 Aug 2012 17:14:05 +0000 (13:14 -0400)]
Merge branch 'master' of

5 years agoorg-capture.el (org-capture-place-table-line): Fix bug
Bastien Guerry [Sun, 19 Aug 2012 15:41:01 +0000 (17:41 +0200)]
org-capture.el (org-capture-place-table-line): Fix bug

* org-capture.el (org-capture-place-table-line): Fix bug.

Thanks to Ian Barton for reporting this.

5 years agoMerge branch 'master' of
Bastien Guerry [Sun, 19 Aug 2012 14:57:28 +0000 (16:57 +0200)]
Merge branch 'master' of

# Please enter a commit message to explain why this merge is necessary,
# especially if it merges an updated upstream into a topic branch.
# Lines starting with '#' will be ignored, and an empty message aborts
# the commit.

5 years agoorg.el: Don't activate a plain link when it is part of a bracketed link
Bastien Guerry [Sun, 19 Aug 2012 14:56:52 +0000 (16:56 +0200)]
org.el: Don't activate a plain link when it is part of a bracketed link

* org.el (org-activate-plain-links): Don't activate a plain
link when it is part of a bracketed link, unless bracketed
links are not enlisted in `org-activate-links'.
(org-open-at-point): Don't consider the text immediately after
a bracketed link is part of a plain link.

This fixes a bug when fontifying [[][Org]]Mode --
where "Mode" should not be fontified, because it is not part of the
bracketed link.

Note that there was another related bug: C-c C-o on "Mode" used to
try opening a plain link.  Also fixed in this commit.

5 years agoorg-md: Fix export of paragraph starting with an hash sign
Nicolas Goaziou [Sun, 19 Aug 2012 13:59:24 +0000 (15:59 +0200)]
org-md: Fix export of paragraph starting with an hash sign

* contrib/lisp/org-md.el (org-md-paragraph): Fix export of paragraph
  starting with an hash sign.

5 years agoForgot a `save-excursion'
Nicolas Goaziou [Sun, 19 Aug 2012 13:51:55 +0000 (15:51 +0200)]
Forgot a `save-excursion'

* lisp/org.el (org-fill-paragraph): Add a `save-excursion' to avoid
  returning funny results.

5 years agoTry to be smarter when filling paragraphs in message-mode
Nicolas Goaziou [Sun, 19 Aug 2012 12:45:31 +0000 (14:45 +0200)]
Try to be smarter when filling paragraphs in message-mode

* lisp/org.el (org-fill-paragraph): Try not to include message header
  and citation lines in a paragraph when filling it.

5 years agoRemove useless (t nil) sexps at the end of some (cond ...) constructs
Bastien Guerry [Sun, 19 Aug 2012 12:42:54 +0000 (14:42 +0200)]
Remove useless (t nil) sexps at the end of some (cond ...) constructs

* org.el (org-compute-latex-and-specials-regexp)
(org-paste-subtree, org-sort-entries, org-store-link)
(org-open-at-point, org-file-remote-p, org-add-log-setup)
(org-set-tags-to, org-fast-tag-selection)
(org-diary-sexp-entry): Ditto.

* org-agenda.el (org-agenda-get-blocks, org-cmp-priority)
(org-cmp-effort, org-cmp-todo-state, org-cmp-alpha)
(org-cmp-tag, org-cmp-time): Remove useless (t nil) sexps at
the end of (cond ...) constructs.

* org-mobile.el (org-mobile-create-index-file): Ditto.

* org-lparse.el (org-lparse-format-table-row): Ditto.

* org-list.el (org-sort-list): Ditto.

* org-id.el (org-id-get): Ditto.

* org-html.el (org-export-html-preprocess): Ditto.

* org-exp.el (org-default-export-plist)
(org-table-clean-before-export): Ditto.

(t nil) in (cond (...) (...) (t nil)) has no other meaning that to
remind the developer that the cond sexp returns nil in case no condition
is matched.  For several (cond ...) constructs this is obvious from reading
the code.  For others, the reminder might be useful and we leave it.

See the discussion about this on emacs-devel:

5 years agoFix filling in in a narrowed buffer
Nicolas Goaziou [Sun, 19 Aug 2012 10:56:57 +0000 (12:56 +0200)]
Fix filling in in a narrowed buffer

* lisp/org.el (org-fill-paragraph): Fix filling in a narrowed buffer.
(org-fill-context-prefix): Fill prefix doesn't depend on current
* testing/lisp/test-org.el: Add test.

5 years agoLine with a single hash sign on it is a comment
Nicolas Goaziou [Sun, 19 Aug 2012 09:07:50 +0000 (11:07 +0200)]
Line with a single hash sign on it is a comment

* lisp/org.el (org-mode): Line with a single hash sign on it is a comment.

5 years agoFix comment fontification
Nicolas Goaziou [Sun, 19 Aug 2012 08:25:39 +0000 (10:25 +0200)]
Fix comment fontification

* lisp/org.el (org-set-font-lock-defaults): Fix comment fontification.

5 years agoMerge branch 'holidays-fixes'
Bastien Guerry [Sun, 19 Aug 2012 08:16:19 +0000 (10:16 +0200)]
Merge branch 'holidays-fixes'

5 years agoorg.el: Be more strict about matching option keywords
Bastien Guerry [Sun, 19 Aug 2012 08:15:59 +0000 (10:15 +0200)]
org.el: Be more strict about matching option keywords

* org.el (org-options-keywords): Add "TODO".
(org-make-options-regexp): Make the hashtag mandatory for
options and don't allow whitespaces between the hashtag and
the plus sign.

5 years agoorg.el: Allow lowercase "#+category" and "#+begin:" dynamic blocks
Bastien Guerry [Sun, 19 Aug 2012 06:48:53 +0000 (08:48 +0200)]
org.el: Allow lowercase "#+category" and "#+begin:" dynamic blocks

* org.el (org-refresh-category-properties)
(org-find-dblock, org-dblock-start-re, org-dblock-end-re):
Allow lowercase "#+category" and "#+begin:" dynamic blocks.

5 years agoorg.el: Use case-folding when trying to match clocktables and source blocks contexts
Bastien Guerry [Sun, 19 Aug 2012 06:26:35 +0000 (08:26 +0200)]
org.el: Use case-folding when trying to match clocktables and source blocks contexts

* org.el (org-context): Use case-folding when trying to match
clocktables and source blocks contexts.

5 years agoorg-clock.el: Fix clock overlays bug
Bastien Guerry [Sun, 19 Aug 2012 06:01:43 +0000 (08:01 +0200)]
org-clock.el: Fix clock overlays bug

* org-clock.el (org-clock-put-overlay): Put the overlay on the
whole headline, not only on the last character.  This fixes a
bug with overlays on headlines ending with a bracketed link.

Thanks to Ryan Kaskel for reporting this.

5 years agoFix HTML export bug for empty headlines when `org-export-with-priority' is nil
Bastien Guerry [Sat, 18 Aug 2012 16:44:56 +0000 (18:44 +0200)]
Fix HTML export bug for empty headlines when `org-export-with-priority' is nil

* org-html.el (org-export-as-html): Make sure we always
process a string.

* org-exp.el (org-export-cleanup-toc-line): Always return a

Thanks to Friedrich Delgado for reporting this.