Let #+DRAWERS append new drawers to `org-drawers', instead of replacing them.

* org.el (org-set-regexps-and-options): Set the value of
`org-drawers' by adding the value of the infile #+DRAWERS
option to that of the existing `org-drawers'.

* org.texi (Drawers): Clearly states that #+DRAWERS will add
drawers to the one originally listed in `org-drawers'.
This commit is contained in:
Bastien Guerry 2012-01-26 09:42:04 +01:00
parent 3639bf7593
commit 5bb59a3fdf
2 changed files with 5 additions and 5 deletions

View File

@ -1773,8 +1773,8 @@ numerically, alphabetically, by time, or by custom function.
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}.
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
@code{org-drawers}@footnote{You can define additional drawers on a
per-file basis with a line like @code{#+DRAWERS: HIDDEN STATE}}. Drawers
look like this:
@example
@ -14433,8 +14433,8 @@ Set tags that can be inherited by any entry in the file, including the
top-level entries.
@item #+DRAWERS: NAME1 .....
@vindex org-drawers
Set the file-local set of drawers. The corresponding global variable is
@code{org-drawers}.
Set the file-local set of additional drawers. The corresponding global
variable is @code{org-drawers}.
@item #+LINK: linkword replace
@vindex org-link-abbrev-alist
These lines (several are allowed) specify link abbreviations.

View File

@ -4547,7 +4547,7 @@ but the stars and the body are.")
(mapcar (lambda (x) (org-split-string x ":"))
(org-split-string value)))))))
((equal key "DRAWERS")
(setq drawers (org-split-string value splitre)))
(setq drawers (append org-drawers (org-split-string value splitre))))
((equal key "CONSTANTS")
(setq const (append const (org-split-string value splitre))))
((equal key "STARTUP")