Merge branch 'master-group-tags2'
This commit is contained in:
commit
78959943e2
6
README
6
README
|
@ -1,9 +1,11 @@
|
|||
The is a distribution of Org, a plain text notes and project planning
|
||||
tool for Emacs.
|
||||
|
||||
The version of this release is: 7.9.1
|
||||
The homepage of Org is at:
|
||||
http://orgmode.org
|
||||
|
||||
The homepage of Org is at http://orgmode.org
|
||||
The installations instructions are at:
|
||||
http://orgmode.org/org.html#Installation
|
||||
|
||||
This distribution contains:
|
||||
|
||||
|
|
|
@ -1,11 +1,15 @@
|
|||
This is the Emacs Org project, an Emacs library for organizing your life.
|
||||
|
||||
The homepage of Org is at http://orgmode.org
|
||||
The homepage of Org is at:
|
||||
http://orgmode.org
|
||||
|
||||
Installations instructions are at:
|
||||
http://orgmode.org/org.html#Installation
|
||||
|
||||
This distribution contains an ELPA packaged version of Org.
|
||||
"ELPA" stands for the "Emacs Lisp Package Archive".
|
||||
The GNU ELPA is here:
|
||||
|
||||
The GNU ELPA is at:
|
||||
http://elpa.gnu.org
|
||||
|
||||
It contains the org-*.tar package, containing only the org files
|
||||
|
|
|
@ -1,6 +1,6 @@
|
|||
# -*- mode:org -*-
|
||||
|
||||
#+TITLE: Maintainer tasks
|
||||
#+TITLE: Org maintainer tasks
|
||||
#+STARTUP: noindent
|
||||
|
||||
This document describes the tasks the Org-mode maintainer has to do
|
||||
|
@ -37,7 +37,7 @@ branch back into maint to synchronize the two.
|
|||
|
||||
** Minor release
|
||||
|
||||
The release number for minor releases look like this: =7.13.01=
|
||||
The release number for minor releases look like this: =7.13.1=
|
||||
|
||||
Minor releases are small amends to main releases. Usually they fix
|
||||
critical bugs discovered in a main release. Minor bugs are usually
|
||||
|
@ -50,8 +50,8 @@ maint then merged in master.
|
|||
|
||||
** Tagging the release
|
||||
|
||||
When doing a major and a minor release, after all necessary merging
|
||||
is done, tag the _maint_ branch for the release with:
|
||||
When doing a major and a minor release, after all necessary merging is
|
||||
done, tag the _maint_ branch for the release with:
|
||||
|
||||
git tag -a "Adding release tag" release_7.9.1
|
||||
|
||||
|
@ -59,6 +59,10 @@ and push tags with
|
|||
|
||||
git push --tags
|
||||
|
||||
We also encourage you to sign release tags like this:
|
||||
|
||||
git tag -a "Adding release tag" -s release_7.9.1
|
||||
|
||||
** Uploading the release files from the orgmode.org server
|
||||
|
||||
Log on the orgmode.org server as the emacs user and cd to
|
||||
|
@ -72,92 +76,6 @@ From there do
|
|||
to create the .tar.gz and .zip files, the documentation, and to
|
||||
upload everything at the right place.
|
||||
|
||||
* Working with patchwork
|
||||
|
||||
John Wiegley is running a patchwork server that looks at the
|
||||
emacs-orgmode mailing list and extracts patches. The maintainer and
|
||||
his helpers should work through such patches, give feedback on them
|
||||
and apply the ones which are good and done. A task for the maintainer
|
||||
is to every now and then try to get old stuff out of that list, by
|
||||
asking some helpers to investigate the patch, by rejecting or
|
||||
accepting it.
|
||||
|
||||
I have found that the best workflow for this is using the pw script by
|
||||
Nate Case, with the modifications for Org-mode made by John Wiegley
|
||||
and Carsten Dominik. The correct version of this script that should
|
||||
be used with Org mode is distributed in the =mk/= directory of the Org
|
||||
mode distribution. Here is the basic workflow for this.
|
||||
|
||||
** Access to the patchwork server
|
||||
|
||||
If you want to work on patchwork patches, you need write access at the
|
||||
patchwork server. You need to contact John Wiegley to get this
|
||||
access.
|
||||
|
||||
There is a web interface to look at the patches and to change the
|
||||
status of patches. This interface is self-explanatory. There is also
|
||||
a command line script which can be very convenient to use.
|
||||
|
||||
** Testing patches
|
||||
|
||||
To start testing a patch, first assign it to yourself
|
||||
|
||||
: pw update -s "Under Review" -d DELEGATE-NAME NNN
|
||||
|
||||
where =NNN= is a patch number and =DELEGATE-NAME= is your user name on
|
||||
the patchwork server.
|
||||
|
||||
The get the patch into a branch:
|
||||
|
||||
: pw branch NNN
|
||||
|
||||
This will create a local topic branch in your git repository with the
|
||||
name =t/patchNNN=. You will also be switched to the branch so that
|
||||
you can immediately start testing it. Quite often small amends need
|
||||
to be made, or documentation has to be added. Also, many contributors
|
||||
do not yet provide the proper ChangeLog-like entries in the commit
|
||||
message for the patch. As a maintainer, you have two options here.
|
||||
Either ask the contributor to make the changes and resubmit the patch,
|
||||
or fix it yourself. In principle, asking to contributor to change the
|
||||
patch until it is complete is the best route, because it will educate
|
||||
the contributor and minimize the work for the maintainer. However,
|
||||
sometimes it can be less hassle to fix things directly and commit the
|
||||
changes to the same branch =t/patchNNN=.
|
||||
|
||||
If you ask the contributor to make the changes, the patch should be
|
||||
marked on the patchwork server as "changes requested".
|
||||
|
||||
: pw update -s "Changes Requested" -m "What to change" NNN
|
||||
|
||||
This will send an email to the contributor and the mailing list with a
|
||||
request for changes. The =-m= message should not be more than one
|
||||
sentence and describe the requested changes. If you need to explain
|
||||
in more detail, write a separate email to the contributor.
|
||||
|
||||
When a new version of the patch arrives, you mark the old one as
|
||||
superseded
|
||||
|
||||
: pw update -s "Superseded" NNN
|
||||
|
||||
and start working at the new one.
|
||||
|
||||
** Merging a final patch
|
||||
|
||||
Once the patch has been iterated and is final (including the
|
||||
ChangeLog-like entries in the commit message), it should be merged.
|
||||
The assumption here is that the final version of the patch is given by
|
||||
the HEAD state in the branch =t/patchNNN=. To merge, do this:
|
||||
|
||||
: pw merge -m "maintainer comment" NNN
|
||||
|
||||
This will merge the patch into master, switch back to master and send
|
||||
an email to both contributor and mailing list stating that this change
|
||||
has been accepted, along with the comment given in the =-m= message.
|
||||
|
||||
At some point you might then want to remove the topic branch
|
||||
|
||||
: git branch -d t/patchNNN
|
||||
|
||||
* Synchonization with Emacs
|
||||
|
||||
This is still a significant headache. Some hand work is needed here.
|
||||
|
@ -253,16 +171,19 @@ So the way I have been doing things with Emacs is this:
|
|||
|
||||
* Copyright assignments
|
||||
|
||||
The maintainer needs to keep track of copyright assignments. Even
|
||||
better, find a volunteer to do this.
|
||||
The maintainer needs to keep track of copyright assignments.
|
||||
Even better, find a volunteer to do this.
|
||||
|
||||
The assignment form is included in the repository as a file that
|
||||
you can send to contributors: =request-assign-future.txt=
|
||||
|
||||
The list of all contributors from who we have the papers is kept on
|
||||
Worg at http://orgmode.org/worg/org-contribute.php, so that
|
||||
Worg at http://orgmode.org/worg/org-contribute.html, so that
|
||||
committers can check if a patch can go into the core.
|
||||
|
||||
The assignment process does not allways go smoothly, and it has
|
||||
happened several times that it gets stuck or forgotten at the FSF.
|
||||
The contact at the FSF for this is: copyright-clerk@fsf.org
|
||||
The contact at the FSF for this is: mailto:copyright-clerk@fsf.org
|
||||
|
||||
Emails from the paper submitter have been ignored in the past, but
|
||||
an email from me (Carsten) as the maintainer of Org mode has usually
|
||||
|
|
|
@ -59,7 +59,7 @@
|
|||
(defun org-confluence-bold (bold contents info)
|
||||
(format "*%s*" contents))
|
||||
|
||||
(defun org-confluence-empty (empy contents info)
|
||||
(defun org-confluence-empty (empty contents info)
|
||||
"")
|
||||
|
||||
(defun org-confluence-example-block (example-block contents info)
|
||||
|
|
336
doc/org.texi
336
doc/org.texi
|
@ -437,6 +437,7 @@ Tags
|
|||
|
||||
* Tag inheritance:: Tags use the tree structure of the outline
|
||||
* Setting tags:: How to assign tags to a headline
|
||||
* Tag groups:: Use one tag to search for several tags
|
||||
* Tag searches:: Searching for combinations of tags
|
||||
|
||||
Properties and columns
|
||||
|
@ -1608,15 +1609,15 @@ a sparse tree matching the string @samp{FIXME}.
|
|||
The other sparse tree commands select headings based on TODO keywords,
|
||||
tags, or properties and will be discussed later in this manual.
|
||||
|
||||
@kindex C-c C-e v
|
||||
@kindex C-c C-e C-v
|
||||
@cindex printing sparse trees
|
||||
@cindex visible text, printing
|
||||
To print a sparse tree, you can use the Emacs command
|
||||
@code{ps-print-buffer-with-faces} which does not print invisible parts
|
||||
of the document @footnote{This does not work under XEmacs, because
|
||||
XEmacs uses selective display for outlining, not text properties.}.
|
||||
Or you can use the command @kbd{C-c C-e v} to export only the visible
|
||||
part of the document and print the resulting file.
|
||||
Or you can use @kbd{C-c C-e C-v} to export only the visible part of
|
||||
the document and print the resulting file.
|
||||
|
||||
@node Plain lists, Drawers, Sparse trees, Document Structure
|
||||
@section Plain lists
|
||||
|
@ -1642,12 +1643,12 @@ is supported, it may be better to not use it for plain list items.} as
|
|||
bullets.
|
||||
@item
|
||||
@vindex org-plain-list-ordered-item-terminator
|
||||
@vindex org-alphabetical-lists
|
||||
@vindex org-list-allow-alphabetical
|
||||
@emph{Ordered} list items start with a numeral followed by either a period or
|
||||
a right parenthesis@footnote{You can filter out any of them by configuring
|
||||
@code{org-plain-list-ordered-item-terminator}.}, such as @samp{1.} or
|
||||
@samp{1)}@footnote{You can also get @samp{a.}, @samp{A.}, @samp{a)} and
|
||||
@samp{A)} by configuring @code{org-alphabetical-lists}. To minimize
|
||||
@samp{A)} by configuring @code{org-list-allow-alphabetical}. To minimize
|
||||
confusion with normal text, those are limited to one character only. Beyond
|
||||
that limit, bullets will automatically fallback to numbers.}. If you want a
|
||||
list to start with a different value (e.g., 20), start the text of the item
|
||||
|
@ -1667,11 +1668,11 @@ line. In particular, if an ordered list reaches number @samp{10.}, then the
|
|||
list. An item ends before the next line that is less or equally indented
|
||||
than its bullet/number.
|
||||
|
||||
@vindex org-empty-line-terminates-plain-lists
|
||||
@vindex org-list-empty-line-terminates-plain-lists
|
||||
A list ends whenever every item has ended, which means before any line less
|
||||
or equally indented than items at top level. It also ends before two blank
|
||||
lines@footnote{See also @code{org-empty-line-terminates-plain-lists}.}. In
|
||||
that case, all items are closed. Here is an example:
|
||||
lines@footnote{See also @code{org-list-empty-line-terminates-plain-lists}.}.
|
||||
In that case, all items are closed. Here is an example:
|
||||
|
||||
@example
|
||||
@group
|
||||
|
@ -4593,7 +4594,7 @@ checked.
|
|||
@cindex statistics, for checkboxes
|
||||
@cindex checkbox statistics
|
||||
@cindex property, COOKIE_DATA
|
||||
@vindex org-hierarchical-checkbox-statistics
|
||||
@vindex org-checkbox-hierarchical-statistics
|
||||
The @samp{[2/4]} and @samp{[1/3]} in the first and second line are cookies
|
||||
indicating how many checkboxes present in this entry have been checked off,
|
||||
and the total number of checkboxes present. This can give you an idea on how
|
||||
|
@ -4601,7 +4602,7 @@ many checkboxes remain, even without opening a folded entry. The cookies can
|
|||
be placed into a headline or into (the first line of) a plain list item.
|
||||
Each cookie covers checkboxes of direct children structurally below the
|
||||
headline/item on which the cookie appears@footnote{Set the variable
|
||||
@code{org-hierarchical-checkbox-statistics} if you want such cookies to
|
||||
@code{org-checkbox-hierarchical-statistics} if you want such cookies to
|
||||
count all checkboxes below the cookie, not just those belonging to direct
|
||||
children.}. You have to insert the cookie yourself by typing either
|
||||
@samp{[/]} or @samp{[%]}. With @samp{[/]} you get an @samp{n out of m}
|
||||
|
@ -4688,6 +4689,7 @@ You may specify special faces for specific tags using the variable
|
|||
@menu
|
||||
* Tag inheritance:: Tags use the tree structure of the outline
|
||||
* Setting tags:: How to assign tags to a headline
|
||||
* Tag groups:: Use one tag to search for several tags
|
||||
* Tag searches:: Searching for combinations of tags
|
||||
@end menu
|
||||
|
||||
|
@ -4745,7 +4747,7 @@ with inherited tags. Set @code{org-agenda-use-tag-inheritance} to control
|
|||
this: the default value includes all agenda types, but setting this to nil
|
||||
can really speed up agenda generation.
|
||||
|
||||
@node Setting tags, Tag searches, Tag inheritance, Tags
|
||||
@node Setting tags, Tag groups, Tag inheritance, Tags
|
||||
@section Setting tags
|
||||
@cindex setting tags
|
||||
@cindex tags, setting
|
||||
|
@ -4766,6 +4768,7 @@ to @code{org-tags-column}. When called with a @kbd{C-u} prefix, all
|
|||
tags in the current buffer will be aligned to that column, just to make
|
||||
things look nice. TAGS are automatically realigned after promotion,
|
||||
demotion, and TODO state changes (@pxref{TODO basics}).
|
||||
|
||||
@orgcmd{C-c C-c,org-set-tags-command}
|
||||
When the cursor is in a headline, this does the same as @kbd{C-c C-q}.
|
||||
@end table
|
||||
|
@ -4916,17 +4919,55 @@ alternatively with @kbd{C-c C-c C-c w}. Adding the non-predefined tag
|
|||
|
||||
@vindex org-fast-tag-selection-single-key
|
||||
If you find that most of the time you need only a single key press to
|
||||
modify your list of tags, set the variable
|
||||
@code{org-fast-tag-selection-single-key}. Then you no longer have to
|
||||
press @key{RET} to exit fast tag selection---it will immediately exit
|
||||
after the first change. If you then occasionally need more keys, press
|
||||
@kbd{C-c} to turn off auto-exit for the current tag selection process
|
||||
(in effect: start selection with @kbd{C-c C-c C-c} instead of @kbd{C-c
|
||||
C-c}). If you set the variable to the value @code{expert}, the special
|
||||
window is not even shown for single-key tag selection, it comes up only
|
||||
when you press an extra @kbd{C-c}.
|
||||
modify your list of tags, set @code{org-fast-tag-selection-single-key}.
|
||||
Then you no longer have to press @key{RET} to exit fast tag selection---it
|
||||
will immediately exit after the first change. If you then occasionally
|
||||
need more keys, press @kbd{C-c} to turn off auto-exit for the current tag
|
||||
selection process (in effect: start selection with @kbd{C-c C-c C-c}
|
||||
instead of @kbd{C-c C-c}). If you set the variable to the value
|
||||
@code{expert}, the special window is not even shown for single-key tag
|
||||
selection, it comes up only when you press an extra @kbd{C-c}.
|
||||
|
||||
@node Tag searches, , Setting tags, Tags
|
||||
@node Tag groups, Tag searches, Setting tags, Tags
|
||||
@section Tag groups
|
||||
|
||||
@cindex group tags
|
||||
@cindex tags, groups
|
||||
In a set of mutually exclusive tags, the first tag can be defined as a
|
||||
@emph{group tag}. When you search for a group tag, it will return matches
|
||||
for all members in the group. In an agenda view, filtering by a group tag
|
||||
will display headlines tagged with at least one of the members of the
|
||||
group. This makes tag searches and filters even more flexible.
|
||||
|
||||
You can set group tags by inserting a colon between the group tag and other
|
||||
tags, like this:
|
||||
|
||||
@example
|
||||
#+TAGS: @{ @@read : @@read_book @@read_ebook @}
|
||||
@end example
|
||||
|
||||
In this example, @samp{@@read} is a @emph{group tag} for a set of three
|
||||
tags: @samp{@@read}, @samp{@@read_book} and @samp{@@read_ebook}.
|
||||
|
||||
You can also use the @code{:grouptags} keyword directly when setting
|
||||
@var{org-tag-alist}:
|
||||
|
||||
@lisp
|
||||
(setq org-tag-alist '((:startgroup . nil)
|
||||
("@@read" . nil)
|
||||
(:grouptags . nil)
|
||||
("@@read_book" . nil)
|
||||
("@@read_ebook" . nil)
|
||||
(:endgroup . nil)))
|
||||
@end lisp
|
||||
|
||||
@kindex C-c C-x q
|
||||
@vindex org-group-tags
|
||||
If you want to ignore group tags temporarily, toggle group tags support
|
||||
with @command{org-toggle-tags-groups}, bound to @kbd{C-c C-x q}. If you
|
||||
want to disable tag groups completely, set @var{org-group-tags} to nil.
|
||||
|
||||
@node Tag searches, , Tag groups, Tags
|
||||
@section Tag searches
|
||||
@cindex tag searches
|
||||
@cindex searching for tags
|
||||
|
@ -7833,16 +7874,21 @@ commands}.
|
|||
@subsubheading Match syntax
|
||||
|
||||
@cindex Boolean logic, for tag/property searches
|
||||
A search string can use Boolean operators @samp{&} for AND and @samp{|} for
|
||||
OR@. @samp{&} binds more strongly than @samp{|}. Parentheses are currently
|
||||
not implemented. Each element in the search is either a tag, a regular
|
||||
expression matching tags, or an expression like @code{PROPERTY OPERATOR
|
||||
VALUE} with a comparison operator, accessing a property value. Each element
|
||||
may be preceded by @samp{-}, to select against it, and @samp{+} is syntactic
|
||||
sugar for positive selection. The AND operator @samp{&} is optional when
|
||||
@samp{+} or @samp{-} is present. Here are some examples, using only tags.
|
||||
A search string can use Boolean operators @samp{&} for @code{AND} and
|
||||
@samp{|} for @code{OR}@. @samp{&} binds more strongly than @samp{|}.
|
||||
Parentheses are not implemented. Each element in the search is either a
|
||||
tag, a regular expression matching tags, or an expression like
|
||||
@code{PROPERTY OPERATOR VALUE} with a comparison operator, accessing a
|
||||
property value. Each element may be preceded by @samp{-}, to select
|
||||
against it, and @samp{+} is syntactic sugar for positive selection. The
|
||||
@code{AND} operator @samp{&} is optional when @samp{+} or @samp{-} is
|
||||
present. Here are some examples, using only tags.
|
||||
|
||||
@table @samp
|
||||
@item work
|
||||
Select headlines tagged @samp{:work:}.
|
||||
@item work&boss
|
||||
Select headlines tagged @samp{:work:} and @samp{:boss:}.
|
||||
@item +work-boss
|
||||
Select headlines tagged @samp{:work:}, but discard those also tagged
|
||||
@samp{:boss:}.
|
||||
|
@ -7859,6 +7905,13 @@ braces. For example,
|
|||
@samp{work+@{^boss.*@}} matches headlines that contain the tag
|
||||
@samp{:work:} and any tag @i{starting} with @samp{boss}.
|
||||
|
||||
@cindex group tags, as regular expressions
|
||||
Group tags (@pxref{Tag groups}) are expanded as regular expressions. E.g.,
|
||||
if @samp{:work:} is a group tag for the group @samp{:work:lab:conf:}, then
|
||||
searching for @samp{work} will search for @samp{@{\(?:work\|lab\|conf\)@}}
|
||||
and searching for @samp{-work} will search for all headlines but those with
|
||||
one of the tag in the group (i.e., @samp{-@{\(?:work\|lab\|conf\)@}}).
|
||||
|
||||
@cindex TODO keyword matching, with tags search
|
||||
@cindex level, require for tags/property match
|
||||
@cindex category, require for tags/property match
|
||||
|
@ -8739,7 +8792,7 @@ calendars.
|
|||
@orgcmd{H,org-agenda-holidays}
|
||||
Show holidays for three months around the cursor date.
|
||||
|
||||
@item M-x org-export-icalendar-combine-agenda-files
|
||||
@item M-x org-icalendar-combine-agenda-files
|
||||
Export a single iCalendar file containing entries from all agenda files.
|
||||
This is a globally available command, and also available in the agenda menu.
|
||||
|
||||
|
@ -9833,18 +9886,19 @@ If $a^2=b$ and \( b=2 \), then the solution must be
|
|||
either $$ a=+\sqrt@{2@} $$ or \[ a=-\sqrt@{2@} \].
|
||||
@end example
|
||||
|
||||
@noindent
|
||||
@vindex org-format-latex-options
|
||||
If you need any of the delimiter ASCII sequences for other purposes, you
|
||||
can configure the option @code{org-format-latex-options} to deselect the
|
||||
ones you do not wish to have interpreted by the @LaTeX{} converter.
|
||||
@c FIXME
|
||||
@c @noindent
|
||||
@c @vindex org-format-latex-options
|
||||
@c If you need any of the delimiter ASCII sequences for other purposes, you
|
||||
@c can configure the option @code{org-format-latex-options} to deselect the
|
||||
@c ones you do not wish to have interpreted by the @LaTeX{} converter.
|
||||
|
||||
@vindex org-export-with-LaTeX-fragments
|
||||
@vindex org-export-with-latex
|
||||
@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 ASCII and @LaTeX{}
|
||||
backends. You can also set this variable on a per-file basis using one of
|
||||
these lines:
|
||||
@code{org-export-with-latex}. The default setting is @code{t} which means
|
||||
@file{MathJax} for HTML, and no processing for ASCII and @LaTeX{} backends.
|
||||
You can also set this variable on a per-file basis using one of these
|
||||
lines:
|
||||
|
||||
@example
|
||||
#+OPTIONS: LaTeX:t @r{Do the right thing automatically (MathJax)}
|
||||
|
@ -10011,7 +10065,7 @@ Finally, all subtrees that are marked by any of the @emph{exclude} tags will
|
|||
be removed from the export buffer.
|
||||
@end enumerate
|
||||
|
||||
The variable @code{org-export-with-tasks} can be configured to select which
|
||||
The variable @var{org-export-with-tasks} can be configured to select which
|
||||
kind of tasks should be included for export. See the docstring of the
|
||||
variable for more information.
|
||||
|
||||
|
@ -10027,14 +10081,11 @@ C-e t}. For individual lines, a good way to make sure the keyword is
|
|||
correct is to type @samp{#+} and then use @kbd{M-@key{TAB}} completion
|
||||
(@pxref{Completion}). For a summary of other in-buffer settings not
|
||||
specifically related to export, see @ref{In-buffer settings}.
|
||||
|
||||
In particular, note that you can place commonly-used (export) options in
|
||||
a separate file which can be included using @code{#+SETUPFILE}.
|
||||
|
||||
@table @kbd
|
||||
@orgcmd{C-c C-e t,org-insert-export-options-template}
|
||||
Insert template with export options, see example below.
|
||||
@end table
|
||||
|
||||
@cindex #+TITLE
|
||||
@cindex #+AUTHOR
|
||||
@cindex #+DATE
|
||||
|
@ -10045,15 +10096,17 @@ Insert template with export options, see example below.
|
|||
@cindex #+TEXT
|
||||
@cindex #+OPTIONS
|
||||
@cindex #+BIND
|
||||
@cindex #HTML_HEAD
|
||||
@cindex #+HTML_LINK_UP
|
||||
@cindex #+HTML_LINK_HOME
|
||||
@cindex #+SELECT_TAGS
|
||||
@cindex #+EXCLUDE_TAGS
|
||||
@cindex #+LaTeX_HEADER
|
||||
@cindex #+LaTeX_HEADER_EXTRA
|
||||
@vindex user-full-name
|
||||
@vindex user-mail-address
|
||||
@vindex org-export-default-language
|
||||
@vindex org-export-date-timestamp-format
|
||||
@c FIXME New name? @vindex org-export-date-timestamp-format
|
||||
@example
|
||||
#+TITLE: the title to be shown (default is the buffer name)
|
||||
#+AUTHOR: the author (default taken from @code{user-full-name})
|
||||
|
@ -10062,14 +10115,15 @@ Insert template with export options, see example below.
|
|||
#+DESCRIPTION: the page description, e.g., for the XHTML meta tag
|
||||
#+KEYWORDS: the page keywords, e.g., for the XHTML meta tag
|
||||
#+LANGUAGE: language for HTML, e.g., @samp{en} (@code{org-export-default-language})
|
||||
#+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., @code{org-latex-image-default-option width=.7\\linewidth}
|
||||
@r{You need to confirm using these, or configure @code{org-export-allow-BIND}}
|
||||
#+HTML_HEAD: Additional line to the @samp{<head>...</head>} of the HTML output
|
||||
#+HTML_LINK_UP: the ``up'' link of an exported page
|
||||
#+HTML_LINK_HOME: the ``home'' link of an exported page
|
||||
#+LaTeX_HEADER: extra line(s) for the @LaTeX{} header, like \usepackage@{xyz@}
|
||||
@c FIXME
|
||||
#+LaTeX_HEADER_EXTRA: extra line(s) for the @LaTeX{} header, used in special contexts
|
||||
#+SELECT_TAGS: Tags that select a tree for export
|
||||
#+EXCLUDE_TAGS: Tags that exclude a tree from export
|
||||
@end example
|
||||
|
@ -10155,14 +10209,13 @@ the subtrees are exported.
|
|||
|
||||
@table @kbd
|
||||
@orgcmd{C-c C-e,org-export}
|
||||
@vindex org-export-run-in-background
|
||||
Dispatcher for export and publishing commands. Displays a help-window
|
||||
listing the additional key(s) needed to launch an export or publishing
|
||||
command. The prefix arg is passed through to the exporter. A double prefix
|
||||
@kbd{C-u C-u} causes most commands to be executed in the background, in a
|
||||
separate Emacs process@footnote{To make this behavior the default, customize
|
||||
the variable @code{org-export-run-in-background}.}.
|
||||
@orgcmd{C-c C-e v,org-export-visible}
|
||||
@orgcmd{C-c C-e C-v,org-export-visible}
|
||||
Like @kbd{C-c C-e}, but only export the text that is currently visible
|
||||
(i.e., not hidden by outline visibility).
|
||||
@orgcmd{C-u C-u C-c C-e,org-export}
|
||||
|
@ -10186,7 +10239,7 @@ with special characters and symbols available in these encodings.
|
|||
@cindex active region
|
||||
@cindex transient-mark-mode
|
||||
@table @kbd
|
||||
@orgcmd{C-c C-e a,org-export-as-ascii}
|
||||
@orgcmd{C-c C-e t a,org-ascii-export-to-ascii}
|
||||
@cindex property, EXPORT_FILE_NAME
|
||||
Export as an ASCII file. For an Org file, @file{myfile.org}, the ASCII file
|
||||
will be @file{myfile.txt}. The file will be overwritten without
|
||||
|
@ -10197,41 +10250,36 @@ current subtree, use @kbd{C-c @@}.}, the tree head will
|
|||
become the document title. If the tree head entry has or inherits an
|
||||
@code{EXPORT_FILE_NAME} property, that name will be used for the
|
||||
export.
|
||||
@orgcmd{C-c C-e A,org-export-as-ascii-to-buffer}
|
||||
@orgcmd{C-c C-e t A,org-ascii-export-as-ascii}
|
||||
Export to a temporary buffer. Do not create a file.
|
||||
@orgcmd{C-c C-e n,org-export-as-latin1}
|
||||
@xorgcmd{C-c C-e N,org-export-as-latin1-to-buffer}
|
||||
Like the above commands, but use Latin-1 encoding.
|
||||
@orgcmd{C-c C-e u,org-export-as-utf8}
|
||||
@xorgcmd{C-c C-e U,org-export-as-utf8-to-buffer}
|
||||
Like the above commands, but use UTF-8 encoding.
|
||||
@item C-c C-e v a/n/u
|
||||
@item C-c C-e C-v t a/t A
|
||||
Export only the visible part of the document.
|
||||
@end table
|
||||
|
||||
@cindex headline levels, for exporting
|
||||
In the exported version, the first 3 outline levels will become
|
||||
headlines, defining a general document structure. Additional levels
|
||||
will be exported as itemized lists. If you want that transition to occur
|
||||
at a different level, specify it with a prefix argument. For example,
|
||||
@c FIXME Exporting sublevels
|
||||
@c @cindex headline levels, for exporting
|
||||
@c In the exported version, the first 3 outline levels will become
|
||||
@c headlines, defining a general document structure. Additional levels
|
||||
@c will be exported as itemized lists. If you want that transition to occur
|
||||
@c at a different level, specify it with a prefix argument. For example,
|
||||
|
||||
@example
|
||||
@kbd{C-1 C-c C-e a}
|
||||
@end example
|
||||
@c @example
|
||||
@c @kbd{C-1 C-c C-e a}
|
||||
@c @end example
|
||||
|
||||
@noindent
|
||||
creates only top level headlines and exports the rest as items. When
|
||||
headlines are converted to items, the indentation of the text following
|
||||
the headline is changed to fit nicely under the item. This is done with
|
||||
the assumption that the first body line indicates the base indentation of
|
||||
the body text. Any indentation larger than this is adjusted to preserve
|
||||
the layout relative to the first line. Should there be lines with less
|
||||
indentation than the first one, these are left alone.
|
||||
@c @noindent
|
||||
@c creates only top level headlines and exports the rest as items. When
|
||||
@c headlines are converted to items, the indentation of the text following
|
||||
@c the headline is changed to fit nicely under the item. This is done with
|
||||
@c the assumption that the first body line indicates the base indentation of
|
||||
@c the body text. Any indentation larger than this is adjusted to preserve
|
||||
@c the layout relative to the first line. Should there be lines with less
|
||||
@c indentation than the first one, these are left alone.
|
||||
|
||||
@vindex org-export-ascii-links-to-notes
|
||||
@vindex org-ascii-links-to-notes
|
||||
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.
|
||||
@code{org-ascii-links-to-notes} for details and other options.
|
||||
|
||||
@node HTML export, @LaTeX{} and PDF export, ASCII/Latin-1/UTF-8 export, Exporting
|
||||
@section HTML export
|
||||
|
@ -10261,7 +10309,7 @@ language, but with additional support for tables.
|
|||
@cindex active region
|
||||
@cindex transient-mark-mode
|
||||
@table @kbd
|
||||
@orgcmd{C-c C-e h,org-export-as-html}
|
||||
@orgcmd{C-c C-e h h,org-html-export-to-html}
|
||||
@cindex property, EXPORT_FILE_NAME
|
||||
Export as a HTML file. For an Org file @file{myfile.org},
|
||||
the HTML file will be @file{myfile.html}. The file will be overwritten
|
||||
|
@ -10271,38 +10319,27 @@ exported. If the selected region is a single tree@footnote{To select the
|
|||
current subtree, use @kbd{C-c @@}.}, the tree head will become the document
|
||||
title. If the tree head entry has, or inherits, an @code{EXPORT_FILE_NAME}
|
||||
property, that name will be used for the export.
|
||||
@orgcmd{C-c C-e b,org-export-as-html-and-open}
|
||||
@kbd{C-c C-e h o}
|
||||
Export as a HTML file and immediately open it with a browser.
|
||||
@orgcmd{C-c C-e H,org-export-as-html-to-buffer}
|
||||
@orgcmd{C-c C-e h H,org-html-export-as-html}
|
||||
Export to a temporary buffer. Do not create a file.
|
||||
@orgcmd{C-c C-e R,org-export-region-as-html}
|
||||
Export the active region to a temporary buffer. With a prefix argument, do
|
||||
not produce the file header and footer, but just the plain HTML section for
|
||||
the region. This is good for cut-and-paste operations.
|
||||
@item C-c C-e v h/b/H/R
|
||||
@item C-c C-e C-v h H/h h/h o
|
||||
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 in 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
|
||||
code.
|
||||
@end table
|
||||
|
||||
@cindex headline levels, for exporting
|
||||
In the exported version, the first 3 outline levels will become headlines,
|
||||
defining a general document structure. Additional levels will be exported as
|
||||
itemized lists. If you want that transition to occur at a different level,
|
||||
specify it with a numeric prefix argument. For example,
|
||||
@c FIXME Exporting sublevels
|
||||
@c @cindex headline levels, for exporting
|
||||
@c In the exported version, the first 3 outline levels will become headlines,
|
||||
@c defining a general document structure. Additional levels will be exported as
|
||||
@c itemized lists. If you want that transition to occur at a different level,
|
||||
@c specify it with a numeric prefix argument. For example,
|
||||
|
||||
@example
|
||||
@kbd{C-2 C-c C-e b}
|
||||
@end example
|
||||
|
||||
@noindent
|
||||
creates two levels of headings and does the rest as items.
|
||||
@c @example
|
||||
@c @kbd{C-2 C-c C-e b}
|
||||
@c @end example
|
||||
|
||||
@c @noindent
|
||||
@c creates two levels of headings and does the rest as items.
|
||||
|
||||
@node HTML preamble and postamble, Quoting HTML tags, HTML Export commands, HTML export
|
||||
@subsection HTML preamble and postamble
|
||||
|
@ -10682,7 +10719,7 @@ be correctly exported: respect the hierarchy of sections.
|
|||
@cindex active region
|
||||
@cindex transient-mark-mode
|
||||
@table @kbd
|
||||
@orgcmd{C-c C-e l,org-export-as-latex}
|
||||
@orgcmd{C-c C-e l l,org-latex-export-to-latex}
|
||||
@cindex property EXPORT_FILE_NAME
|
||||
Export as a @LaTeX{} file. For an Org file
|
||||
@file{myfile.org}, the @LaTeX{} file will be @file{myfile.tex}. The file will
|
||||
|
@ -10692,40 +10729,34 @@ exported. If the selected region is a single tree@footnote{To select the
|
|||
current subtree, use @kbd{C-c @@}.}, the tree head will become the document
|
||||
title. If the tree head entry has or inherits an @code{EXPORT_FILE_NAME}
|
||||
property, that name will be used for the export.
|
||||
@orgcmd{C-c C-e L,org-export-as-latex-to-buffer}
|
||||
@orgcmd{C-c C-e l L,org-latex-export-as-latex}
|
||||
Export to a temporary buffer. Do not create a file.
|
||||
@item C-c C-e v l/L
|
||||
@item C-c C-e C-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 in 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{}
|
||||
code.
|
||||
@orgcmd{C-c C-e p,org-export-as-pdf}
|
||||
@orgcmd{C-c C-e l p,org-latex-export-to-pdf}
|
||||
Export as @LaTeX{} and then process to PDF.
|
||||
@orgcmd{C-c C-e d,org-export-as-pdf-and-open}
|
||||
@kbd{C-c C-e l o}
|
||||
Export as @LaTeX{} and then process to PDF, then open the resulting PDF file.
|
||||
@end table
|
||||
|
||||
@cindex headline levels, for exporting
|
||||
@vindex org-latex-low-levels
|
||||
In the exported version, the first 3 outline levels will become
|
||||
headlines, defining a general document structure. Additional levels
|
||||
will be exported as description lists. The exporter can ignore them or
|
||||
convert them to a custom string depending on
|
||||
@code{org-latex-low-levels}.
|
||||
@c FIXME Exporting sublevels
|
||||
@c @cindex headline levels, for exporting
|
||||
@c @vindex org-latex-low-levels
|
||||
@c In the exported version, the first 3 outline levels will become
|
||||
@c headlines, defining a general document structure. Additional levels
|
||||
@c will be exported as description lists. The exporter can ignore them or
|
||||
@c convert them to a custom string depending on
|
||||
@c @code{org-latex-low-levels}.
|
||||
|
||||
If you want that transition to occur at a different level, specify it
|
||||
with a numeric prefix argument. For example,
|
||||
@c If you want that transition to occur at a different level, specify it
|
||||
@c with a numeric prefix argument. For example,
|
||||
|
||||
@example
|
||||
@kbd{C-2 C-c C-e l}
|
||||
@end example
|
||||
@c @example
|
||||
@c @kbd{C-2 C-c C-e l}
|
||||
@c @end example
|
||||
|
||||
@noindent
|
||||
creates two levels of headings and does the rest as items.
|
||||
@c @noindent
|
||||
@c 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
|
||||
@subsection Header and sectioning structure
|
||||
|
@ -11058,14 +11089,14 @@ output. Check the availability of this program before proceeding further.
|
|||
@cindex active region
|
||||
@cindex transient-mark-mode
|
||||
@table @kbd
|
||||
@orgcmd{C-c C-e o,org-export-as-odt}
|
||||
@orgcmd{C-c C-e o o,org-odt-export-to-odt}
|
||||
@cindex property EXPORT_FILE_NAME
|
||||
|
||||
Export as OpenDocument Text file.
|
||||
|
||||
@vindex org-export-odt-preferred-output-format
|
||||
If @code{org-export-odt-preferred-output-format} is specified, automatically
|
||||
convert the exported file to that format. @xref{x-export-to-other-formats, ,
|
||||
If @code{org-preferred-output-format} is specified, automatically convert
|
||||
the exported file to that format. @xref{x-export-to-other-formats, ,
|
||||
Automatically exporting to other formats}.
|
||||
|
||||
For an Org file @file{myfile.org}, the ODT file will be
|
||||
|
@ -11077,13 +11108,13 @@ tree head will become the document title. If the tree head entry has, or
|
|||
inherits, an @code{EXPORT_FILE_NAME} property, that name will be used for the
|
||||
export.
|
||||
|
||||
@orgcmd{C-c C-e O,org-export-as-odt-and-open}
|
||||
@kbd{C-c C-e o O}
|
||||
Export as an OpenDocument Text file and open the resulting file.
|
||||
|
||||
@vindex org-export-odt-preferred-output-format
|
||||
If @code{org-export-odt-preferred-output-format} is specified, open the
|
||||
converted file instead. @xref{x-export-to-other-formats, , Automatically
|
||||
exporting to other formats}.
|
||||
@vindex org-odt-preferred-output-format
|
||||
If @code{org-preferred-output-format} is specified, open the converted file
|
||||
instead. @xref{x-export-to-other-formats, , Automatically exporting to
|
||||
other formats}.
|
||||
@end table
|
||||
|
||||
@node Extending ODT export, Applying custom styles, ODT export commands, OpenDocument Text export
|
||||
|
@ -11964,19 +11995,19 @@ In this way the UID remains unique, but a synchronization program can still
|
|||
figure out from which entry all the different instances originate.
|
||||
|
||||
@table @kbd
|
||||
@orgcmd{C-c C-e i,org-export-icalendar-this-file}
|
||||
Create iCalendar entries for the current file and store them in the same
|
||||
@orgcmd{C-c C-e c f,org-icalendar-export-to-ics}
|
||||
Create iCalendar entries for the current buffer and store them in the same
|
||||
directory, using a file extension @file{.ics}.
|
||||
@orgcmd{C-c C-e I, org-export-icalendar-all-agenda-files}
|
||||
@orgcmd{C-c C-e c a, org-icalendar-export-agenda-files}
|
||||
@vindex org-agenda-files
|
||||
Like @kbd{C-c C-e i}, but do this for all files in
|
||||
Like @kbd{C-c C-e c f}, but do this for all files in
|
||||
@code{org-agenda-files}. For each of these files, a separate iCalendar
|
||||
file will be written.
|
||||
@orgcmd{C-c C-e c,org-export-icalendar-combine-agenda-files}
|
||||
@vindex org-combined-agenda-icalendar-file
|
||||
@orgcmd{C-c C-e c c,org-icalendar-combine-agenda-files}
|
||||
@vindex org-icalendar-combined-agenda-file
|
||||
Create a single large iCalendar file from all files in
|
||||
@code{org-agenda-files} and write it to the file given by
|
||||
@code{org-combined-agenda-icalendar-file}.
|
||||
@code{org-icalendar-combined-agenda-file}.
|
||||
@end table
|
||||
|
||||
@vindex org-use-property-inheritance
|
||||
|
@ -12186,7 +12217,7 @@ respective variable for details.
|
|||
@vindex org-export-with-done-tasks
|
||||
@vindex org-export-with-priority
|
||||
@vindex org-export-with-TeX-macros
|
||||
@vindex org-export-with-LaTeX-fragments
|
||||
@vindex org-export-with-latex
|
||||
@vindex org-export-skip-text-before-1st-heading
|
||||
@vindex org-export-with-fixed-width
|
||||
@vindex org-export-with-timestamps
|
||||
|
@ -12233,7 +12264,7 @@ respective variable for details.
|
|||
@item @code{:tasks} @tab @code{org-export-with-tasks}
|
||||
@item @code{:priority} @tab @code{org-export-with-priority}
|
||||
@item @code{:TeX-macros} @tab @code{org-export-with-TeX-macros}
|
||||
@item @code{:LaTeX-fragments} @tab @code{org-export-with-LaTeX-fragments}
|
||||
@item @code{:LaTeX-fragments} @tab @code{org-export-with-latex}
|
||||
@item @code{:latex-listings} @tab @code{org-latex-listings}
|
||||
@item @code{:skip-before-1st-heading} @tab @code{org-export-skip-text-before-1st-heading}
|
||||
@item @code{:fixed-width} @tab @code{org-export-with-fixed-width}
|
||||
|
@ -12509,13 +12540,13 @@ right place on the web server, and publishing images to it.
|
|||
Once properly configured, Org can publish with the following commands:
|
||||
|
||||
@table @kbd
|
||||
@orgcmd{C-c C-e X,org-publish}
|
||||
@orgcmd{C-c C-e P x,org-publish}
|
||||
Prompt for a specific project and publish all files that belong to it.
|
||||
@orgcmd{C-c C-e P,org-publish-current-project}
|
||||
@orgcmd{C-c C-e P p,org-publish-current-project}
|
||||
Publish the project containing the current file.
|
||||
@orgcmd{C-c C-e F,org-publish-current-file}
|
||||
@orgcmd{C-c C-e P f,org-publish-current-file}
|
||||
Publish only the current file.
|
||||
@orgcmd{C-c C-e E,org-publish-all}
|
||||
@orgcmd{C-c C-e P a,org-publish-all}
|
||||
Publish every project.
|
||||
@end table
|
||||
|
||||
|
@ -14868,10 +14899,11 @@ this file, and (potentially) the corresponding @emph{fast tag selection}
|
|||
keys. The corresponding variable is @code{org-tag-alist}.
|
||||
@item #+TBLFM:
|
||||
This line contains the formulas for the table directly above the line.
|
||||
@item #+TITLE:, #+AUTHOR:, #+EMAIL:, #+LANGUAGE:, #+TEXT:, #+DATE:,
|
||||
@item #+TITLE:, #+AUTHOR:, #+EMAIL:, #+LANGUAGE:, #+DATE:,
|
||||
@itemx #+OPTIONS:, #+BIND:,
|
||||
@itemx #+DESCRIPTION:, #+KEYWORDS:,
|
||||
@itemx #+LaTeX_HEADER:, #+HTML_HEAD:, #+HTML_LINK_UP:, #+HTML_LINK_HOME:,
|
||||
@itemx #+LaTeX_HEADER:, #+LaTeX_HEADER_EXTRA:,
|
||||
@itemx #+HTML_HEAD:, #+HTML_LINK_UP:, #+HTML_LINK_HOME:,
|
||||
@itemx #+SELECT_TAGS:, #+EXCLUDE_TAGS:
|
||||
These lines provide settings for exporting files. For more details see
|
||||
@ref{Export options}.
|
||||
|
|
|
@ -98,7 +98,7 @@ modify this GNU manual.''
|
|||
* Working With Source Code:: Source code snippets embedded in Org
|
||||
* Miscellaneous:: All the rest which did not fit elsewhere
|
||||
|
||||
* GNU Free Documentation License:: This manual license.
|
||||
* GNU Free Documentation License:: This manual license.
|
||||
|
||||
@detailmenu
|
||||
--- The Detailed Node Listing ---
|
||||
|
@ -148,6 +148,7 @@ Tags
|
|||
* Tag inheritance:: Tags use the tree structure of the outline
|
||||
* Setting tags:: How to assign tags to a headline
|
||||
* Tag searches:: Searching for combinations of tags
|
||||
* Tag searches:: Searching for combinations of tags
|
||||
|
||||
Dates and Times
|
||||
|
||||
|
@ -158,7 +159,7 @@ Dates and Times
|
|||
|
||||
Capture - Refile - Archive
|
||||
|
||||
* Capture::
|
||||
* Capture:: Capturing new stuff
|
||||
* Refile and copy:: Moving a tree from one place to another
|
||||
* Archiving:: What to do with finished projects
|
||||
|
||||
|
@ -1110,6 +1111,7 @@ Tags will by default be in bold face with the same color as the headline.
|
|||
* Tag inheritance:: Tags use the tree structure of the outline
|
||||
* Setting tags:: How to assign tags to a headline
|
||||
* Tag searches:: Searching for combinations of tags
|
||||
* Tag searches:: Searching for combinations of tags
|
||||
@end menu
|
||||
|
||||
@node Tag inheritance, Setting tags, Tags, Tags
|
||||
|
@ -1189,7 +1191,46 @@ can instead set the TAGS option line as:
|
|||
#+TAGS: @@work(w) @@home(h) @@tennisclub(t) laptop(l) pc(p)
|
||||
@end smallexample
|
||||
|
||||
@node Tag searches, , Setting tags, Tags
|
||||
@node Tag searches, Tag searches, Setting tags, Tags
|
||||
@section Tag groups
|
||||
|
||||
@cindex group tags
|
||||
@cindex tags, groups
|
||||
In a set of mutually exclusive tags, the first tag can be defined as a
|
||||
@emph{group tag}. When you search for a group tag, it will return matches
|
||||
for all members in the group. In an agenda view, filtering by a group tag
|
||||
will display headlines tagged with at least one of the members of the
|
||||
group. This makes tag searches and filters even more flexible.
|
||||
|
||||
You can set group tags by inserting a colon between the group tag and other
|
||||
tags, like this:
|
||||
|
||||
@example
|
||||
#+TAGS: @{ @@read : @@read_book @@read_ebook @}
|
||||
@end example
|
||||
|
||||
In this example, @samp{@@read} is a @emph{group tag} for a set of three
|
||||
tags: @samp{@@read}, @samp{@@read_book} and @samp{@@read_ebook}.
|
||||
|
||||
You can also use the @code{:grouptags} keyword directly when setting
|
||||
@var{org-tag-alist}:
|
||||
|
||||
@lisp
|
||||
(setq org-tag-alist '((:startgroup . nil)
|
||||
("@@read" . nil)
|
||||
(:grouptags . nil)
|
||||
("@@read_book" . nil)
|
||||
("@@read_ebook" . nil)
|
||||
(:endgroup . nil)))
|
||||
@end lisp
|
||||
|
||||
@kindex C-c C-x q
|
||||
@vindex org-group-tags
|
||||
If you want to ignore group tags temporarily, toggle group tags support
|
||||
with @command{org-toggle-tags-groups}, bound to @kbd{C-c C-x q}. If you
|
||||
want to disable tag groups completely, set @var{org-group-tags} to nil.
|
||||
|
||||
@node Tag searches, , Tag searches, Tags
|
||||
@section Tag searches
|
||||
|
||||
Once a system of tags has been set up, it can be used to collect related
|
||||
|
@ -1518,8 +1559,8 @@ projects need to be moved around. Moving completed project trees to an
|
|||
archive file keeps the system compact and fast.
|
||||
|
||||
@menu
|
||||
* Capture::
|
||||
* Refiling notes:: Moving a tree from one place to another
|
||||
* Capture:: Capturing new stuff
|
||||
* Refile and copy:: Moving a tree from one place to another
|
||||
* Archiving:: What to do with finished projects
|
||||
@end menu
|
||||
|
||||
|
|
|
@ -519,7 +519,7 @@ can not be resolved.")
|
|||
"Number of initial characters to show of a hidden results hash.")
|
||||
|
||||
(defvar org-babel-hash-show-time nil
|
||||
"When not nil show the time the code block was evaluated in the result hash.")
|
||||
"Non-nil means show the time the code block was evaluated in the result hash.")
|
||||
|
||||
(defvar org-babel-after-execute-hook nil
|
||||
"Hook for functions to be called after `org-babel-execute-src-block'")
|
||||
|
@ -2641,14 +2641,17 @@ Emacs shutdown."))
|
|||
Passes PREFIX and SUFFIX directly to `make-temp-file' with the
|
||||
value of `temporary-file-directory' temporarily set to the value
|
||||
of `org-babel-temporary-directory'."
|
||||
(let ((temporary-file-directory
|
||||
(if (file-remote-p default-directory)
|
||||
(concat (file-remote-p default-directory) "/tmp")
|
||||
(if (file-remote-p default-directory)
|
||||
(let ((prefix
|
||||
(concat (file-remote-p default-directory)
|
||||
(expand-file-name prefix temporary-file-directory))))
|
||||
(make-temp-file prefix nil suffix))
|
||||
(let ((temporary-file-directory
|
||||
(or (and (boundp 'org-babel-temporary-directory)
|
||||
(file-exists-p org-babel-temporary-directory)
|
||||
org-babel-temporary-directory)
|
||||
temporary-file-directory))))
|
||||
(make-temp-file prefix nil suffix)))
|
||||
temporary-file-directory)))
|
||||
(make-temp-file prefix nil suffix))))
|
||||
|
||||
(defun org-babel-remove-temporary-directory ()
|
||||
"Remove `org-babel-temporary-directory' on Emacs shutdown."
|
||||
|
|
|
@ -1702,7 +1702,7 @@ range, respectively."
|
|||
(string :tag "Format string")
|
||||
(function))))
|
||||
|
||||
(defcustom org-agenda-scheduled-leaders '(" Scheduled: " "Sched.%3dx: ")
|
||||
(defcustom org-agenda-scheduled-leaders '("Scheduled: " "Sched.%3dx:")
|
||||
"Text preceding scheduled items in the agenda view.
|
||||
This is a list with two strings. The first applies when the item is
|
||||
scheduled on the current day. The second applies when it has been scheduled
|
||||
|
@ -1726,7 +1726,7 @@ These entries are added to the agenda when pressing \"[\"."
|
|||
(string :tag "Scheduled today ")
|
||||
(string :tag "Scheduled previously")))
|
||||
|
||||
(defcustom org-agenda-deadline-leaders '(" Deadline: " " In %3d d.: " "%3d d. ago: ")
|
||||
(defcustom org-agenda-deadline-leaders '("Deadline: " "In %3d d.: " "%3d d. ago:")
|
||||
"Text preceding deadline items in the agenda view.
|
||||
This is a list with three strings. The first applies when the item has its
|
||||
deadline on the current day. The second applies when the deadline is in the
|
||||
|
@ -4753,8 +4753,6 @@ The prefix arg TODO-ONLY limits the search to TODO entries."
|
|||
buffer)
|
||||
(when (and (stringp match) (not (string-match "\\S-" match)))
|
||||
(setq match nil))
|
||||
(setq matcher (org-make-tags-matcher match)
|
||||
match (car matcher) matcher (cdr matcher))
|
||||
(catch 'exit
|
||||
(if org-agenda-sticky
|
||||
(setq org-agenda-buffer-name
|
||||
|
@ -4762,7 +4760,11 @@ The prefix arg TODO-ONLY limits the search to TODO entries."
|
|||
(format "*Org Agenda(%s:%s)*"
|
||||
(or org-keys (or (and todo-only "M") "m")) match)
|
||||
(format "*Org Agenda(%s)*" (or (and todo-only "M") "m")))))
|
||||
;; Prepare agendas (and `org-tag-alist-for-agenda') before
|
||||
;; expanding tags within `org-make-tags-matcher'
|
||||
(org-agenda-prepare (concat "TAGS " match))
|
||||
(setq matcher (org-make-tags-matcher match)
|
||||
match (car matcher) matcher (cdr matcher))
|
||||
(org-compile-prefix-format 'tags)
|
||||
(org-set-sorting-strategy 'tags)
|
||||
(setq org-agenda-query-string match)
|
||||
|
@ -7373,7 +7375,7 @@ to switch to narrowing."
|
|||
((equal char ?\r)
|
||||
(org-agenda-filter-show-all-tag)
|
||||
(when org-agenda-auto-exclude-function
|
||||
(setq org-agenda-tag-filter '())
|
||||
(setq org-agenda-tag-filter nil)
|
||||
(dolist (tag (org-agenda-get-represented-tags))
|
||||
(let ((modifier (funcall org-agenda-auto-exclude-function tag)))
|
||||
(if modifier
|
||||
|
@ -7430,37 +7432,59 @@ to switch to narrowing."
|
|||
(interactive "P")
|
||||
(org-agenda-filter-by-tag strip char 'refine))
|
||||
|
||||
(defun org-agenda-filter-make-matcher ()
|
||||
(defun org-agenda-filter-make-matcher (filter type)
|
||||
"Create the form that tests a line for agenda filter."
|
||||
(let (f f1)
|
||||
;; first compute the tag-filter matcher
|
||||
(dolist (x (delete-dups
|
||||
(append (get 'org-agenda-tag-filter
|
||||
:preset-filter) org-agenda-tag-filter)))
|
||||
(if (member x '("-" "+"))
|
||||
(setq f1 (if (equal x "-") 'tags '(not tags)))
|
||||
(if (string-match "[<=>?]" x)
|
||||
(setq f1 (org-agenda-filter-effort-form x))
|
||||
(setq f1 (list 'member (downcase (substring x 1)) 'tags)))
|
||||
(if (equal (string-to-char x) ?-)
|
||||
(setq f1 (list 'not f1))))
|
||||
(push f1 f))
|
||||
;; then compute the category-filter matcher
|
||||
(dolist (x (delete-dups
|
||||
(append (get 'org-agenda-category-filter
|
||||
:preset-filter) org-agenda-category-filter)))
|
||||
(if (equal "-" (substring x 0 1))
|
||||
(setq f1 (list 'not (list 'equal (substring x 1) 'cat)))
|
||||
(setq f1 (list 'equal (substring x 1) 'cat)))
|
||||
(push f1 f))
|
||||
;; Finally compute the regexp filter
|
||||
(dolist (x (delete-dups
|
||||
(append (get 'org-agenda-regexp-filter
|
||||
:preset-filter) org-agenda-regexp-filter)))
|
||||
(if (equal "-" (substring x 0 1))
|
||||
(setq f1 (list 'not (list 'string-match (substring x 1) 'txt)))
|
||||
(setq f1 (list 'string-match (substring x 1) 'txt)))
|
||||
(push f1 f))
|
||||
(cond
|
||||
;; Tag filter
|
||||
((eq type 'tag)
|
||||
(setq filter
|
||||
(delete-dups
|
||||
(append (get 'org-agenda-tag-filter :preset-filter)
|
||||
filter)))
|
||||
(dolist (x filter)
|
||||
(let ((nfilter (org-agenda-filter-expand-tags filter)) nf nf1
|
||||
(ffunc
|
||||
(lambda (nf0 nf01 fltr notgroup op)
|
||||
(dolist (x fltr)
|
||||
(if (member x '("-" "+"))
|
||||
(setq nf01 (if (equal x "-") 'tags '(not tags)))
|
||||
(if (string-match "[<=>?]" x)
|
||||
(setq nf01 (org-agenda-filter-effort-form x))
|
||||
(setq nf01 (list 'member (downcase (substring x 1))
|
||||
'tags)))
|
||||
(when (equal (string-to-char x) ?-)
|
||||
(setq nf01 (list 'not nf01))
|
||||
(when (not notgroup) (setq op 'and))))
|
||||
(push nf01 nf0))
|
||||
(if notgroup
|
||||
(push (cons 'and nf0) f)
|
||||
(push (cons (or op 'or) nf0) f)))))
|
||||
(if (equal nfilter filter)
|
||||
(funcall ffunc f1 f filter t nil)
|
||||
(funcall ffunc nf1 nf nfilter nil nil)))))
|
||||
;; Category filter
|
||||
((eq type 'category)
|
||||
(setq filter
|
||||
(delete-dups
|
||||
(append (get 'org-agenda-category-filter :preset-filter)
|
||||
filter)))
|
||||
(dolist (x filter)
|
||||
(if (equal "-" (substring x 0 1))
|
||||
(setq f1 (list 'not (list 'equal (substring x 1) 'cat)))
|
||||
(setq f1 (list 'equal (substring x 1) 'cat)))
|
||||
(push f1 f)))
|
||||
;; Regexp filter
|
||||
((eq type 'regexp)
|
||||
(setq filter
|
||||
(delete-dups
|
||||
(append (get 'org-agenda-regexp-filter :preset-filter)
|
||||
filter)))
|
||||
(dolist (x filter)
|
||||
(if (equal "-" (substring x 0 1))
|
||||
(setq f1 (list 'not (list 'string-match (substring x 1) 'txt)))
|
||||
(setq f1 (list 'string-match (substring x 1) 'txt)))
|
||||
(push f1 f))))
|
||||
(cons 'and (nreverse f))))
|
||||
|
||||
(defun org-agenda-filter-effort-form (e)
|
||||
|
@ -7485,12 +7509,31 @@ If the line does not have an effort defined, return nil."
|
|||
(funcall op (or eff (if org-sort-agenda-noeffort-is-high 32767 0))
|
||||
value))))
|
||||
|
||||
(defun org-agenda-filter-expand-tags (filter &optional no-operator)
|
||||
"Expand group tags in FILTER for the agenda.
|
||||
When NO-OPERATOR is non-nil, do not add the + operator to returned tags."
|
||||
(if org-group-tags
|
||||
(let ((case-fold-search t) rtn)
|
||||
(mapc
|
||||
(lambda (f)
|
||||
(let (f0 dir)
|
||||
(if (string-match "^\\([+-]\\)\\(.+\\)" f)
|
||||
(setq dir (match-string 1 f) f0 (match-string 2 f))
|
||||
(setq dir (if no-operator "" "+") f0 f))
|
||||
(setq rtn (append (mapcar (lambda(f1) (concat dir f1))
|
||||
(org-tags-expand f0 t t))
|
||||
rtn))))
|
||||
filter)
|
||||
(reverse rtn))
|
||||
filter))
|
||||
|
||||
(defun org-agenda-filter-apply (filter type)
|
||||
"Set FILTER as the new agenda filter and apply it."
|
||||
;; Deactivate `org-agenda-entry-text-mode' when filtering
|
||||
(if org-agenda-entry-text-mode (org-agenda-entry-text-mode))
|
||||
(let (tags cat txt)
|
||||
(setq org-agenda-filter-form (org-agenda-filter-make-matcher))
|
||||
(setq org-agenda-filter-form
|
||||
(org-agenda-filter-make-matcher filter type))
|
||||
(if (and (eq type 'category)
|
||||
(not (equal (substring (car filter) 0 1) "-")))
|
||||
;; Only set `org-agenda-filtered-by-category' to t
|
||||
|
@ -7502,7 +7545,11 @@ If the line does not have an effort defined, return nil."
|
|||
(while (not (eobp))
|
||||
(if (org-get-at-bol 'org-marker)
|
||||
(progn
|
||||
(setq tags (org-get-at-bol 'tags) ; used in eval
|
||||
(setq tags ; used in eval
|
||||
(apply 'append
|
||||
(mapcar (lambda (f)
|
||||
(org-agenda-filter-expand-tags (list f) t))
|
||||
(org-get-at-bol 'tags)))
|
||||
cat (get-text-property (point) 'org-category)
|
||||
txt (get-text-property (point) 'txt))
|
||||
(if (not (eval org-agenda-filter-form))
|
||||
|
|
|
@ -160,7 +160,7 @@
|
|||
;; Lists.
|
||||
(let ((term (case org-plain-list-ordered-item-terminator
|
||||
(?\) ")") (?. "\\.") (otherwise "[.)]")))
|
||||
(alpha (and org-alphabetical-lists "\\|[A-Za-z]")))
|
||||
(alpha (and org-list-allow-alphabetical "\\|[A-Za-z]")))
|
||||
(concat "\\(?:[-+*]\\|\\(?:[0-9]+" alpha "\\)" term "\\)"
|
||||
"\\(?:[ \t]\\|$\\)"))
|
||||
"\\)\\)")
|
||||
|
|
|
@ -790,6 +790,13 @@ level org-n-level-faces"
|
|||
:version "24.4"
|
||||
:package-version '(Org . "8.0"))
|
||||
|
||||
(defface org-tag-group
|
||||
(org-compatible-face 'org-tag nil)
|
||||
"Face for group tags."
|
||||
:group 'org-faces
|
||||
:version "24.4"
|
||||
:package-version '(Org . "8.0"))
|
||||
|
||||
(org-copy-face 'mode-line 'org-mode-line-clock
|
||||
"Face used for clock display in mode line.")
|
||||
(org-copy-face 'mode-line 'org-mode-line-clock-overrun
|
||||
|
|
|
@ -217,7 +217,8 @@ Valid values are ?. and ?\). To get both terminators, use t."
|
|||
(const :tag "paren like in \"2)\"" ?\))
|
||||
(const :tag "both" t)))
|
||||
|
||||
(org-defvaralias 'org-alphabetical-lists 'org-list-allow-alphabetical) ;; Since 8.0
|
||||
(define-obsolete-variable-alias 'org-alphabetical-lists
|
||||
'org-list-allow-alphabetical "24.4") ; Since 8.0
|
||||
(defcustom org-list-allow-alphabetical nil
|
||||
"Non-nil means single character alphabetical bullets are allowed.
|
||||
Both uppercase and lowercase are handled. Lists with more than
|
||||
|
@ -239,8 +240,8 @@ spaces instead of one after the bullet in each item of the list."
|
|||
(const :tag "never" nil)
|
||||
(regexp)))
|
||||
|
||||
(org-defvaralias 'org-empty-line-terminates-plain-lists
|
||||
'org-list-empty-line-terminates-plain-lists) ;; Since 8.0
|
||||
(define-obsolete-variable-alias 'org-empty-line-terminates-plain-lists
|
||||
'org-list-empty-line-terminates-plain-lists "24.4") ;; Since 8.0
|
||||
(defcustom org-list-empty-line-terminates-plain-lists nil
|
||||
"Non-nil means an empty line ends all plain list levels.
|
||||
Otherwise, two of them will be necessary."
|
||||
|
@ -293,8 +294,8 @@ This hook runs even if checkbox rule in
|
|||
implement alternative ways of collecting statistics
|
||||
information.")
|
||||
|
||||
(org-defvaralias 'org-hierarchical-checkbox-statistics
|
||||
'org-checkbox-hierarchical-statistics) ;; Since 8.0
|
||||
(define-obsolete-variable-alias 'org-hierarchical-checkbox-statistics
|
||||
'org-checkbox-hierarchical-statistics "24.4") ;; Since 8.0
|
||||
(defcustom org-checkbox-hierarchical-statistics t
|
||||
"Non-nil means checkbox statistics counts only the state of direct children.
|
||||
When nil, all boxes below the cookie are counted.
|
||||
|
@ -363,10 +364,10 @@ specifically, type `block' is determined by the variable
|
|||
|
||||
;;; Predicates and regexps
|
||||
|
||||
(defconst org-list-end-re (if org-empty-line-terminates-plain-lists "^[ \t]*\n"
|
||||
(defconst org-list-end-re (if org-list-empty-line-terminates-plain-lists "^[ \t]*\n"
|
||||
"^[ \t]*\n[ \t]*\n")
|
||||
"Regex corresponding to the end of a list.
|
||||
It depends on `org-empty-line-terminates-plain-lists'.")
|
||||
It depends on `org-list-empty-line-terminates-plain-lists'.")
|
||||
|
||||
(defconst org-list-full-item-re
|
||||
(concat "^[ \t]*\\(\\(?:[-+*]\\|\\(?:[0-9]+\\|[A-Za-z]\\)[.)]\\)\\(?:[ \t]+\\|$\\)\\)"
|
||||
|
@ -386,7 +387,7 @@ group 4: description tag")
|
|||
((= org-plain-list-ordered-item-terminator ?\)) ")")
|
||||
((= org-plain-list-ordered-item-terminator ?.) "\\.")
|
||||
(t "[.)]")))
|
||||
(alpha (if org-alphabetical-lists "\\|[A-Za-z]" "")))
|
||||
(alpha (if org-list-allow-alphabetical "\\|[A-Za-z]" "")))
|
||||
(concat "\\([ \t]*\\([-+]\\|\\(\\([0-9]+" alpha "\\)" term
|
||||
"\\)\\)\\|[ \t]+\\*\\)\\([ \t]+\\|$\\)")))
|
||||
|
||||
|
@ -400,7 +401,7 @@ group 4: description tag")
|
|||
(save-excursion
|
||||
(goto-char (match-end 0))
|
||||
(let ((counter-re (concat "\\(?:\\[@\\(?:start:\\)?"
|
||||
(if org-alphabetical-lists
|
||||
(if org-list-allow-alphabetical
|
||||
"\\([0-9]+\\|[A-Za-z]\\)"
|
||||
"[0-9]+")
|
||||
"\\][ \t]*\\)")))
|
||||
|
@ -1208,7 +1209,7 @@ some heuristics to guess the result."
|
|||
(point))))))))
|
||||
(cond
|
||||
;; Trivial cases where there should be none.
|
||||
((or org-empty-line-terminates-plain-lists (not insert-blank-p)) 0)
|
||||
((or org-list-empty-line-terminates-plain-lists (not insert-blank-p)) 0)
|
||||
;; When `org-blank-before-new-entry' says so, it is 1.
|
||||
((eq insert-blank-p t) 1)
|
||||
;; `plain-list-item' is 'auto. Count blank lines separating
|
||||
|
@ -1613,7 +1614,7 @@ bullets between START and END."
|
|||
|
||||
STRUCT is list structure. PREVS is the alist of previous items,
|
||||
as returned by `org-list-prevs-alist'."
|
||||
(and org-alphabetical-lists
|
||||
(and org-list-allow-alphabetical
|
||||
(catch 'exit
|
||||
(let ((item first) (ascii 64) (case-fold-search nil))
|
||||
;; Pretend that bullets are uppercase and check if alphabet
|
||||
|
@ -2429,7 +2430,7 @@ With optional prefix argument ALL, do this for the whole buffer."
|
|||
(let ((cookie-re "\\(\\(\\[[0-9]*%\\]\\)\\|\\(\\[[0-9]*/[0-9]*\\]\\)\\)")
|
||||
(box-re "^[ \t]*\\([-+*]\\|\\([0-9]+\\|[A-Za-z]\\)[.)]\\)[ \t]+\\(?:\\[@\\(?:start:\\)?\\([0-9]+\\|[A-Za-z]\\)\\][ \t]*\\)?\\(\\[[- X]\\]\\)")
|
||||
(recursivep
|
||||
(or (not org-hierarchical-checkbox-statistics)
|
||||
(or (not org-checkbox-hierarchical-statistics)
|
||||
(string-match "\\<recursive\\>"
|
||||
(or (org-entry-get nil "COOKIE_DATA") ""))))
|
||||
(bounds (if all
|
||||
|
|
|
@ -239,6 +239,7 @@ When completing for #+STARTUP, for example, this function returns
|
|||
(cond
|
||||
((eq :startgroup (car x)) "{")
|
||||
((eq :endgroup (car x)) "}")
|
||||
((eq :grouptags (car x)) ":")
|
||||
((eq :newline (car x)) "\\n")
|
||||
((cdr x) (format "%s(%c)" (car x) (cdr x)))
|
||||
(t (car x))))
|
||||
|
|
290
lisp/org.el
290
lisp/org.el
|
@ -126,10 +126,12 @@ Stars are put in group 1 and the trimmed body in group 2.")
|
|||
(declare-function org-beamer-mode "ox-beamer" ())
|
||||
(declare-function org-table-edit-field "org-table" (arg))
|
||||
(declare-function org-table-justify-field-maybe "org-table" (&optional new))
|
||||
(declare-function org-table-set-constants "org-table" ())
|
||||
(declare-function org-id-get-create "org-id" (&optional force))
|
||||
(declare-function org-id-find-id-file "org-id" (id))
|
||||
(declare-function org-tags-view "org-agenda" (&optional todo-only match))
|
||||
(declare-function org-agenda-list "org-agenda" (&optional arg start-day span))
|
||||
(declare-function org-agenda-redo "org-agenda" (&optional all))
|
||||
(declare-function org-table-align "org-table" ())
|
||||
(declare-function org-table-paste-rectangle "org-table" ())
|
||||
(declare-function org-table-maybe-eval-formula "org-table" ())
|
||||
|
@ -1324,9 +1326,9 @@ and a boolean flag as CDR. The cdr may also be the symbol `auto', in
|
|||
which case Org will look at the surrounding headings/items and try to
|
||||
make an intelligent decision whether to insert a blank line or not.
|
||||
|
||||
For plain lists, if the variable `org-empty-line-terminates-plain-lists' is
|
||||
set, the setting here is ignored and no empty line is inserted, to avoid
|
||||
breaking the list structure."
|
||||
For plain lists, if `org-list-empty-line-terminates-plain-lists' is set,
|
||||
the setting here is ignored and no empty line is inserted to avoid breaking
|
||||
the list structure."
|
||||
:group 'org-edit-structure
|
||||
:type '(list
|
||||
(cons (const heading)
|
||||
|
@ -2288,7 +2290,12 @@ taken from the (otherwise obsolete) variable `org-todo-interpretation'."
|
|||
(defvar org-done-keywords-for-agenda nil)
|
||||
(defvar org-drawers-for-agenda nil)
|
||||
(defvar org-todo-keyword-alist-for-agenda nil)
|
||||
(defvar org-tag-alist-for-agenda nil)
|
||||
(defvar org-tag-alist-for-agenda nil
|
||||
"Alist of all tags from all agenda files.")
|
||||
(defvar org-tag-groups-alist-for-agenda nil
|
||||
"Alist of all groups tags from all current agenda files.")
|
||||
(defvar org-tag-groups-alist nil)
|
||||
(make-variable-buffer-local 'org-tag-groups-alist)
|
||||
(defvar org-agenda-contributing-files nil)
|
||||
(defvar org-not-done-keywords nil)
|
||||
(make-variable-buffer-local 'org-not-done-keywords)
|
||||
|
@ -3170,6 +3177,8 @@ See the manual for details."
|
|||
(list :tag "Start radio group"
|
||||
(const :startgroup)
|
||||
(option (string :tag "Group description")))
|
||||
(list :tag "Group tags delimiter"
|
||||
(const :grouptags))
|
||||
(list :tag "End radio group"
|
||||
(const :endgroup)
|
||||
(option (string :tag "Group description")))
|
||||
|
@ -3192,6 +3201,7 @@ To disable these tags on a per-file basis, insert anywhere in the file:
|
|||
(cons (string :tag "Tag name")
|
||||
(character :tag "Access char"))
|
||||
(const :tag "Start radio group" (:startgroup))
|
||||
(const :tag "Group tags delimiter" (:grouptags))
|
||||
(const :tag "End radio group" (:endgroup))
|
||||
(const :tag "New line" (:newline)))))
|
||||
|
||||
|
@ -4730,8 +4740,97 @@ This regexp can match any headline with the specified keyword, or
|
|||
without a keyword. The keyword isn't in any group by default,
|
||||
but the stars and the body are.")
|
||||
|
||||
(defcustom org-group-tags t
|
||||
"When non-nil (the default), use group tags.
|
||||
This can be turned on/off through `org-toggle-tags-groups'."
|
||||
:group 'org-tags
|
||||
:group 'org-startup
|
||||
:type 'boolean)
|
||||
|
||||
(defun org-toggle-tags-groups ()
|
||||
"Toggle support for group tags.
|
||||
Support for group tags is controlled by the option
|
||||
`org-group-tags', which is non-nil by default."
|
||||
(interactive)
|
||||
(setq org-group-tags (not org-group-tags))
|
||||
(if (and (derived-mode-p 'org-agenda-mode)
|
||||
org-group-tags)
|
||||
(org-agenda-redo))
|
||||
(when (derived-mode-p 'org-mode)
|
||||
(org-set-regexps-and-options-for-tags)
|
||||
(org-set-regexps-and-options))
|
||||
(message "Groups tags support has been turned %s"
|
||||
(if org-group-tags "on" "off")))
|
||||
|
||||
(defun org-set-regexps-and-options-for-tags ()
|
||||
"Precompute regular expressions used for tags in the current buffer."
|
||||
(when (derived-mode-p 'org-mode)
|
||||
(org-set-local 'org-file-tags nil)
|
||||
(let ((re (org-make-options-regexp '("FILETAGS" "TAGS")))
|
||||
(splitre "[ \t]+")
|
||||
tags ftags key value
|
||||
(start 0))
|
||||
(save-excursion
|
||||
(save-restriction
|
||||
(widen)
|
||||
(goto-char (point-min))
|
||||
(while (re-search-forward re nil t)
|
||||
(setq key (upcase (org-match-string-no-properties 1))
|
||||
value (org-match-string-no-properties 2))
|
||||
(if (stringp value) (setq value (org-trim value)))
|
||||
(cond
|
||||
((equal key "TAGS")
|
||||
(setq tags (append tags (if tags '("\\n") nil)
|
||||
(org-split-string value splitre))))
|
||||
((equal key "FILETAGS")
|
||||
(when (string-match "\\S-" value)
|
||||
(setq ftags
|
||||
(append
|
||||
ftags
|
||||
(apply 'append
|
||||
(mapcar (lambda (x) (org-split-string x ":"))
|
||||
(org-split-string value)))))))))))
|
||||
;; Process the file tags.
|
||||
(and ftags (org-set-local 'org-file-tags
|
||||
(mapcar 'org-add-prop-inherited ftags)))
|
||||
(org-set-local 'org-tag-groups-alist nil)
|
||||
;; Process the tags.
|
||||
;; FIXME
|
||||
(when tags
|
||||
(let (e tgs g)
|
||||
(while (setq e (pop tags))
|
||||
(cond
|
||||
((equal e "{")
|
||||
(progn (push '(:startgroup) tgs)
|
||||
(when (equal (nth 1 tags) ":")
|
||||
(push (list (replace-regexp-in-string
|
||||
"(.+)$" "" (nth 0 tags)))
|
||||
org-tag-groups-alist)
|
||||
(setq g 0))))
|
||||
((equal e ":") (push '(:grouptags) tgs))
|
||||
((equal e "}") (push '(:endgroup) tgs) (if g (setq g nil)))
|
||||
((equal e "\\n") (push '(:newline) tgs))
|
||||
((string-match (org-re "^\\([[:alnum:]_@#%]+\\)(\\(.\\))$") e)
|
||||
(push (cons (match-string 1 e)
|
||||
(string-to-char (match-string 2 e))) tgs)
|
||||
(if (and g (> g 0))
|
||||
(setcar org-tag-groups-alist
|
||||
(append (car org-tag-groups-alist)
|
||||
(list (match-string 1 e)))))
|
||||
(if g (setq g (1+ g))))
|
||||
(t (push (list e) tgs)
|
||||
(if (and g (> g 0))
|
||||
(setcar org-tag-groups-alist
|
||||
(append (car org-tag-groups-alist) (list e))))
|
||||
(if g (setq g (1+ g))))))
|
||||
(org-set-local 'org-tag-alist nil)
|
||||
(while (setq e (pop tgs))
|
||||
(or (and (stringp (car e))
|
||||
(assoc (car e) org-tag-alist))
|
||||
(push e org-tag-alist))))))))
|
||||
|
||||
(defun org-set-regexps-and-options ()
|
||||
"Precompute regular expressions for current buffer."
|
||||
"Precompute regular expressions used in the current buffer."
|
||||
(when (derived-mode-p 'org-mode)
|
||||
(org-set-local 'org-todo-kwd-alist nil)
|
||||
(org-set-local 'org-todo-key-alist nil)
|
||||
|
@ -4742,16 +4841,15 @@ but the stars and the body are.")
|
|||
(org-set-local 'org-todo-sets nil)
|
||||
(org-set-local 'org-todo-log-states nil)
|
||||
(org-set-local 'org-file-properties nil)
|
||||
(org-set-local 'org-file-tags nil)
|
||||
(let ((re (org-make-options-regexp
|
||||
'("CATEGORY" "TODO" "COLUMNS" "STARTUP" "ARCHIVE" "FILETAGS"
|
||||
"TAGS" "LINK" "PRIORITIES" "CONSTANTS" "PROPERTY" "DRAWERS"
|
||||
'("CATEGORY" "TODO" "COLUMNS" "STARTUP" "ARCHIVE"
|
||||
"LINK" "PRIORITIES" "CONSTANTS" "PROPERTY" "DRAWERS"
|
||||
"SETUPFILE" "OPTIONS")
|
||||
"\\(?:[a-zA-Z][0-9a-zA-Z_]*_TODO\\)"))
|
||||
(splitre "[ \t]+")
|
||||
(scripts org-use-sub-superscripts)
|
||||
kwds kws0 kwsa key log value cat arch tags const links hw dws
|
||||
tail sep kws1 prio props ftags drawers ext-setup-or-nil setup-contents
|
||||
kwds kws0 kwsa key log value cat arch const links hw dws
|
||||
tail sep kws1 prio props drawers ext-setup-or-nil setup-contents
|
||||
(start 0))
|
||||
(save-excursion
|
||||
(save-restriction
|
||||
|
@ -4776,9 +4874,6 @@ but the stars and the body are.")
|
|||
;; general TODO-like setup
|
||||
(push (cons (intern (downcase (match-string 1 key)))
|
||||
(org-split-string value splitre)) kwds))
|
||||
((equal key "TAGS")
|
||||
(setq tags (append tags (if tags '("\\n") nil)
|
||||
(org-split-string value splitre))))
|
||||
((equal key "COLUMNS")
|
||||
(org-set-local 'org-columns-default-format value))
|
||||
((equal key "LINK")
|
||||
|
@ -4793,14 +4888,6 @@ but the stars and the body are.")
|
|||
(setq props (org-update-property-plist (match-string 1 value)
|
||||
(match-string 2 value)
|
||||
props))))
|
||||
((equal key "FILETAGS")
|
||||
(when (string-match "\\S-" value)
|
||||
(setq ftags
|
||||
(append
|
||||
ftags
|
||||
(apply 'append
|
||||
(mapcar (lambda (x) (org-split-string x ":"))
|
||||
(org-split-string value)))))))
|
||||
((equal key "DRAWERS")
|
||||
(setq drawers (delete-dups (append org-drawers (org-split-string value splitre)))))
|
||||
((equal key "CONSTANTS")
|
||||
|
@ -4824,7 +4911,9 @@ but the stars and the body are.")
|
|||
((equal key "OPTIONS")
|
||||
(if (string-match "\\([ \t]\\|\\`\\)\\^:\\(t\\|nil\\|{}\\)" value)
|
||||
(setq scripts (read (match-string 2 value)))))
|
||||
((equal key "SETUPFILE")
|
||||
((and (equal key "SETUPFILE")
|
||||
;; Prevent checking in Gnus messages
|
||||
(not buffer-read-only))
|
||||
(setq setup-contents (org-file-contents
|
||||
(expand-file-name
|
||||
(org-remove-double-quotes value))
|
||||
|
@ -4856,8 +4945,6 @@ but the stars and the body are.")
|
|||
(org-set-local 'org-lowest-priority (nth 1 prio))
|
||||
(org-set-local 'org-default-priority (nth 2 prio)))
|
||||
(and props (org-set-local 'org-file-properties (nreverse props)))
|
||||
(and ftags (org-set-local 'org-file-tags
|
||||
(mapcar 'org-add-prop-inherited ftags)))
|
||||
(and drawers (org-set-local 'org-drawers drawers))
|
||||
(and arch (org-set-local 'org-archive-location arch))
|
||||
(and links (setq org-link-abbrev-alist-local (nreverse links)))
|
||||
|
@ -4908,26 +4995,6 @@ but the stars and the body are.")
|
|||
org-todo-kwd-alist (nreverse org-todo-kwd-alist)
|
||||
org-todo-key-trigger (delq nil (mapcar 'cdr org-todo-key-alist))
|
||||
org-todo-key-alist (org-assign-fast-keys org-todo-key-alist)))
|
||||
|
||||
;; Process the tags.
|
||||
(when tags
|
||||
(let (e tgs)
|
||||
(while (setq e (pop tags))
|
||||
(cond
|
||||
((equal e "{") (push '(:startgroup) tgs))
|
||||
((equal e "}") (push '(:endgroup) tgs))
|
||||
((equal e "\\n") (push '(:newline) tgs))
|
||||
((string-match (org-re "^\\([[:alnum:]_@#%]+\\)(\\(.\\))$") e)
|
||||
(push (cons (match-string 1 e)
|
||||
(string-to-char (match-string 2 e)))
|
||||
tgs))
|
||||
(t (push (list e) tgs))))
|
||||
(org-set-local 'org-tag-alist nil)
|
||||
(while (setq e (pop tgs))
|
||||
(or (and (stringp (car e))
|
||||
(assoc (car e) org-tag-alist))
|
||||
(push e org-tag-alist)))))
|
||||
|
||||
;; Compute the regular expressions and other local variables.
|
||||
;; Using `org-outline-regexp-bol' would complicate them much,
|
||||
;; because of the fixed white space at the end of that string.
|
||||
|
@ -5028,10 +5095,7 @@ but the stars and the body are.")
|
|||
(if (or (not file)
|
||||
(not (file-readable-p file)))
|
||||
(if noerror
|
||||
(progn
|
||||
(message "Cannot read file \"%s\"" file)
|
||||
(ding) (sit-for 2)
|
||||
"")
|
||||
(message "Cannot read file \"%s\"" file)
|
||||
(error "Cannot read file \"%s\"" file))
|
||||
(with-temp-buffer
|
||||
(insert-file-contents file)
|
||||
|
@ -5064,7 +5128,7 @@ This will extract info from a string like \"WAIT(w@/!)\"."
|
|||
Respect keys that are already there."
|
||||
(let (new e (alt ?0))
|
||||
(while (setq e (pop alist))
|
||||
(if (or (memq (car e) '(:newline :endgroup :startgroup))
|
||||
(if (or (memq (car e) '(:newline :grouptags :endgroup :startgroup))
|
||||
(cdr e)) ;; Key already assigned.
|
||||
(push e new)
|
||||
(let ((clist (string-to-list (downcase (car e))))
|
||||
|
@ -5208,6 +5272,7 @@ The following commands are available:
|
|||
org-ellipsis)))
|
||||
(if (stringp org-ellipsis) org-ellipsis "..."))))
|
||||
(setq buffer-display-table org-display-table))
|
||||
(org-set-regexps-and-options-for-tags)
|
||||
(org-set-regexps-and-options)
|
||||
(when (and org-tag-faces (not org-tags-special-faces-re))
|
||||
;; tag faces set outside customize.... force initialization.
|
||||
|
@ -5672,7 +5737,7 @@ by a #."
|
|||
(error (message "org-mode fontification error"))))
|
||||
|
||||
(defun org-fontify-meta-lines-and-blocks-1 (limit)
|
||||
"Fontify #+ lines and blocks, in the correct ways."
|
||||
"Fontify #+ lines and blocks."
|
||||
(let ((case-fold-search t))
|
||||
(if (re-search-forward
|
||||
"^\\([ \t]*#\\(\\(\\+[a-zA-Z]+:?\\| \\|$\\)\\(_\\([a-zA-Z]+\\)\\)?\\)[ \t]*\\(\\([^ \t\n]*\\)[ \t]*\\(.*\\)\\)\\)"
|
||||
|
@ -6088,6 +6153,12 @@ needs to be inserted at a specific position in the font-lock sequence.")
|
|||
'(org-font-lock-add-priority-faces)
|
||||
;; Tags
|
||||
'(org-font-lock-add-tag-faces)
|
||||
;; Tags groups
|
||||
(if (and org-group-tags org-tag-groups-alist)
|
||||
(list (concat org-outline-regexp-bol ".+\\(:"
|
||||
(regexp-opt (mapcar 'car org-tag-groups-alist))
|
||||
":\\).*$")
|
||||
'(1 'org-tag-group prepend)))
|
||||
;; Special keywords
|
||||
(list (concat "\\<" org-deadline-string) '(0 'org-special-keyword t))
|
||||
(list (concat "\\<" org-scheduled-string) '(0 'org-special-keyword t))
|
||||
|
@ -11044,9 +11115,10 @@ on the system \"/user@host:\"."
|
|||
(let (marker)
|
||||
(catch 'exit
|
||||
(while (and set (setq marker (nth 3 (pop set))))
|
||||
;; if org-refile-use-outline-path is 'file, marker may be nil
|
||||
;; If `org-refile-use-outline-path' is 'file, marker may be nil
|
||||
(when (and marker (null (marker-buffer marker)))
|
||||
(message "not found") (sit-for 3)
|
||||
(message "Please regenerate the refile cache with `C-0 C-c C-w'")
|
||||
(sit-for 3)
|
||||
(throw 'exit nil)))
|
||||
t)))
|
||||
|
||||
|
@ -12017,8 +12089,7 @@ For calling through lisp, arg is also interpreted in the following way:
|
|||
(not org-todo-key-trigger)))
|
||||
;; Read a state with completion
|
||||
(org-icompleting-read
|
||||
"State: " (mapcar (lambda(x) (list x))
|
||||
org-todo-keywords-1)
|
||||
"State: " (mapcar 'list org-todo-keywords-1)
|
||||
nil t))
|
||||
((eq arg 'right)
|
||||
(if this
|
||||
|
@ -13828,7 +13899,7 @@ See also `org-scan-tags'.
|
|||
"
|
||||
(declare (special todo-only))
|
||||
(unless (boundp 'todo-only)
|
||||
(error "org-make-tags-matcher expects todo-only to be scoped in"))
|
||||
(error "`org-make-tags-matcher' expects todo-only to be scoped in"))
|
||||
(unless match
|
||||
;; Get a new match request, with completion
|
||||
(let ((org-last-tags-completion-table
|
||||
|
@ -13844,6 +13915,8 @@ See also `org-scan-tags'.
|
|||
tagsmatch todomatch tagsmatcher todomatcher kwd matcher
|
||||
orterms term orlist re-p str-p level-p level-op time-p
|
||||
prop-p pn pv po gv rest)
|
||||
;; Expand group tags
|
||||
(setq match (org-tags-expand match))
|
||||
(if (string-match "/+" match)
|
||||
;; match contains also a todo-matching request
|
||||
(progn
|
||||
|
@ -13950,6 +14023,54 @@ See also `org-scan-tags'.
|
|||
matcher)))
|
||||
(cons match0 matcher)))
|
||||
|
||||
(defun org-tags-expand (match &optional single-as-list downcased)
|
||||
"Expand group tags in MATCH.
|
||||
|
||||
This replaces every group tag in MATCH with a regexp tag search.
|
||||
For example, a group tag \"Work\" defined as { Work : Lab Conf }
|
||||
will be replaced like this:
|
||||
|
||||
Work => {\(?:Work\|Lab\|Conf\}
|
||||
+Work => +{\(?:Work\|Lab\|Conf\}
|
||||
-Work => -{\(?:Work\|Lab\|Conf\}
|
||||
|
||||
Replacing by a regexp preserves the structure of the match.
|
||||
E.g., this expansion
|
||||
|
||||
Work|Home => {\(?:Work\|Lab\|Conf\}|Home
|
||||
|
||||
will match anything tagged with \"Lab\" and \"Home\", or tagged
|
||||
with \"Conf\" and \"Home\" or tagged with \"Work\" and \"home\".
|
||||
|
||||
When the optional argument SINGLE-AS-LIST is non-nil, MATCH is
|
||||
assumed to be a single group tag, and the function will return
|
||||
the list of tags in this group.
|
||||
|
||||
When DOWNCASE is non-nil, expand downcased TAGS."
|
||||
(if org-group-tags
|
||||
(let* ((case-fold-search t)
|
||||
(tal (or org-tag-groups-alist-for-agenda
|
||||
org-tag-groups-alist))
|
||||
(tal (if downcased (mapcar (lambda(tg) (mapcar 'downcase tg)) tal) tal))
|
||||
(tml (mapcar 'car tal))
|
||||
(rtnmatch match) rpl)
|
||||
(while (and tml (string-match
|
||||
(concat "\\(?1:[+-]?\\)\\(?2:" (regexp-opt tml) "\\)")
|
||||
rtnmatch))
|
||||
(let* ((dir (match-string 1 rtnmatch))
|
||||
(tag (match-string 2 rtnmatch))
|
||||
(tag (if downcased (downcase tag) tag)))
|
||||
(setq tml (delete tag tml))
|
||||
(setq rpl (append (org-uniquify rpl) (assoc tag tal)))
|
||||
(setq rtnmatch
|
||||
(replace-match
|
||||
(concat dir "{" (regexp-opt rpl) "}") t t rtnmatch))))
|
||||
(if single-as-list
|
||||
(or (reverse rpl) (list rtnmatch))
|
||||
rtnmatch))
|
||||
(if single-as-list (list (if downcased (downcase match) match))
|
||||
match)))
|
||||
|
||||
(defun org-op-to-function (op &optional stringp)
|
||||
"Turn an operator into the appropriate function."
|
||||
(setq op
|
||||
|
@ -14346,15 +14467,14 @@ This works in the agenda, and also in an org-mode buffer."
|
|||
rtn)
|
||||
((eq flag t)
|
||||
;; all-completions
|
||||
(all-completions s2 ctable confirm)
|
||||
)
|
||||
(all-completions s2 ctable confirm))
|
||||
((eq flag 'lambda)
|
||||
;; exact match?
|
||||
(assoc s2 ctable)))
|
||||
))
|
||||
(assoc s2 ctable)))))
|
||||
|
||||
(defun org-fast-tag-insert (kwd tags face &optional end)
|
||||
"Insert KDW, and the TAGS, the latter with face FACE. Also insert END."
|
||||
"Insert KDW, and the TAGS, the latter with face FACE.
|
||||
Also insert END."
|
||||
(insert (format "%-12s" (concat kwd ":"))
|
||||
(org-add-props (mapconcat 'identity tags " ") nil 'face face)
|
||||
(or end "")))
|
||||
|
@ -14370,6 +14490,7 @@ This works in the agenda, and also in an org-mode buffer."
|
|||
(insert (org-add-props " Next change exits" nil 'face 'org-warning)))))
|
||||
|
||||
(defun org-set-current-tags-overlay (current prefix)
|
||||
"Add an overlay to CURRENT tag with PREFIX."
|
||||
(let ((s (concat ":" (mapconcat 'identity current ":") ":")))
|
||||
(if (featurep 'xemacs)
|
||||
(org-overlay-display org-tags-overlay (concat prefix s)
|
||||
|
@ -14452,6 +14573,7 @@ Returns the new tags string, or nil to not change the current settings."
|
|||
(while (equal (car tbl) '(:newline))
|
||||
(insert "\n")
|
||||
(setq tbl (cdr tbl)))))
|
||||
((equal e '(:grouptags)) nil)
|
||||
(t
|
||||
(setq tg (copy-sequence (car e)) c2 nil)
|
||||
(if (cdr e)
|
||||
|
@ -14467,11 +14589,13 @@ Returns the new tags string, or nil to not change the current settings."
|
|||
(setq c (or c2 char)))
|
||||
(if ingroup (push tg (car groups)))
|
||||
(setq tg (org-add-props tg nil 'face
|
||||
(cond
|
||||
((not (assoc tg table))
|
||||
(org-get-todo-face tg))
|
||||
((member tg current) c-face)
|
||||
((member tg inherited) i-face))))
|
||||
(cond
|
||||
((not (assoc tg table))
|
||||
(org-get-todo-face tg))
|
||||
((member tg current) c-face)
|
||||
((member tg inherited) i-face))))
|
||||
(if (equal (caar tbl) :grouptags)
|
||||
(org-add-props tg nil 'face 'org-tag-group))
|
||||
(if (and (= cnt 0) (not ingroup)) (insert " "))
|
||||
(insert "[" c "] " tg (make-string
|
||||
(- fwidth 4 (length tg)) ?\ ))
|
||||
|
@ -17120,7 +17244,7 @@ When SUPPRESS-TMP-DELAY is non-nil, suppress delays like \"--2d\"."
|
|||
;; Maybe adjust the closest clock in `org-clock-history'
|
||||
(when org-clock-adjust-closest
|
||||
(if (not (and (org-at-clock-log-p)
|
||||
(< 1 (length (delq nil (mapcar (lambda(m) (marker-position m))
|
||||
(< 1 (length (delq nil (mapcar 'marker-position
|
||||
org-clock-history))))))
|
||||
(message "No clock to adjust")
|
||||
(cond ((save-excursion ; fix previous clock?
|
||||
|
@ -17747,7 +17871,9 @@ When a buffer is unmodified, it is just killed. When modified, it is saved
|
|||
(inhibit-read-only t)
|
||||
(org-inhibit-startup org-agenda-inhibit-startup)
|
||||
(rea (concat ":" org-archive-tag ":"))
|
||||
file re)
|
||||
file re org-tag-alist)
|
||||
(setq org-tag-alist-for-agenda nil
|
||||
org-tag-groups-alist-for-agenda nil)
|
||||
(save-excursion
|
||||
(save-restriction
|
||||
(while (setq file (pop files))
|
||||
|
@ -17757,6 +17883,7 @@ When a buffer is unmodified, it is just killed. When modified, it is saved
|
|||
(org-check-agenda-file file)
|
||||
(set-buffer (org-get-agenda-file-buffer file)))
|
||||
(widen)
|
||||
(org-set-regexps-and-options-for-tags)
|
||||
(org-refresh-category-properties)
|
||||
(org-refresh-properties org-effort-property 'org-effort)
|
||||
(org-refresh-properties "APPT_WARNTIME" 'org-appt-warntime)
|
||||
|
@ -17770,6 +17897,10 @@ When a buffer is unmodified, it is just killed. When modified, it is saved
|
|||
(append org-drawers-for-agenda org-drawers))
|
||||
(setq org-tag-alist-for-agenda
|
||||
(append org-tag-alist-for-agenda org-tag-alist))
|
||||
(if org-group-tags
|
||||
(setq org-tag-groups-alist-for-agenda
|
||||
(org-uniquify-alist
|
||||
(append org-tag-groups-alist-for-agenda org-tag-groups-alist))))
|
||||
(org-with-silent-modifications
|
||||
(save-excursion
|
||||
(remove-text-properties (point-min) (point-max) pall)
|
||||
|
@ -17787,8 +17918,7 @@ When a buffer is unmodified, it is just killed. When modified, it is saved
|
|||
(setq org-todo-keywords-for-agenda
|
||||
(org-uniquify org-todo-keywords-for-agenda))
|
||||
(setq org-todo-keyword-alist-for-agenda
|
||||
(org-uniquify org-todo-keyword-alist-for-agenda)
|
||||
org-tag-alist-for-agenda (org-uniquify org-tag-alist-for-agenda))))
|
||||
(org-uniquify org-todo-keyword-alist-for-agenda))))
|
||||
|
||||
|
||||
;;;; CDLaTeX minor mode
|
||||
|
@ -18735,6 +18865,7 @@ BEG and END default to the buffer boundaries."
|
|||
(org-defkey org-mode-map "\C-c\C-xa" 'org-toggle-archive-tag)
|
||||
(org-defkey org-mode-map "\C-c\C-xA" 'org-archive-to-archive-sibling)
|
||||
(org-defkey org-mode-map "\C-c\C-xb" 'org-tree-to-indirect-buffer)
|
||||
(org-defkey org-mode-map "\C-c\C-xq" 'org-toggle-tags-groups)
|
||||
(org-defkey org-mode-map "\C-c\C-j" 'org-goto)
|
||||
(org-defkey org-mode-map "\C-c\C-t" 'org-todo)
|
||||
(org-defkey org-mode-map "\C-c\C-q" 'org-set-tags-command)
|
||||
|
@ -21382,6 +21513,27 @@ for the search purpose."
|
|||
(mapc (lambda (x) (add-to-list 'res x 'append)) list)
|
||||
res))
|
||||
|
||||
(defun org-uniquify-alist (alist)
|
||||
"Merge duplicate elements of an alist.
|
||||
|
||||
For example, in this alist:
|
||||
|
||||
\(org-uniquify-alist '((a 1) (b 2) (a 3)))
|
||||
=> '((a 1 3) (b 2))
|
||||
|
||||
merge (a 1) and (a 3) into (a 1 3) and return the new alist."
|
||||
(let (rtn)
|
||||
(mapc
|
||||
(lambda (e)
|
||||
(let (n)
|
||||
(if (not (assoc (car e) rtn))
|
||||
(push e rtn)
|
||||
(setq n (cons (car e) (append (cdr (assoc (car e) rtn)) (cdr e))))
|
||||
(setq rtn (assq-delete-all (car e) rtn))
|
||||
(push n rtn))))
|
||||
alist)
|
||||
rtn))
|
||||
|
||||
(defun org-delete-all (elts list)
|
||||
"Remove all elements in ELTS from LIST."
|
||||
(while elts
|
||||
|
|
|
@ -117,9 +117,11 @@ cleanrel:
|
|||
|
||||
doc-up: info pdf card html
|
||||
$(MAKE) -C doc manual guide
|
||||
$(CP) doc/org.html $(SERVROOT)
|
||||
$(CP) doc/manual/* $(SERVROOT)/manual
|
||||
$(CP) doc/guide/* $(SERVROOT)/guide
|
||||
$(CP) doc/org.html $(SERVROOT)
|
||||
$(CP) doc/org.pdf $(SERVROOT)
|
||||
$(CP) doc/orgguide.pdf $(SERVROOT)
|
||||
$(CP) doc/manual/* $(SERVROOT)/manual
|
||||
$(CP) doc/guide/* $(SERVROOT)/guide
|
||||
|
||||
upload: cleanall rel-up doc-up elpa-up elpaplus-up
|
||||
upload-elpa: cleanall elpa-up
|
||||
|
|
|
@ -2703,7 +2703,7 @@ Paragraph \\alpha."
|
|||
(org-test-with-temp-text "- Para1\n\n- Para2"
|
||||
(progn (forward-line)
|
||||
(org-element-type
|
||||
(let ((org-empty-line-terminates-plain-lists nil))
|
||||
(let ((org-list-empty-line-terminates-plain-lists nil))
|
||||
(org-element-at-point)))))))
|
||||
;; Special case: at the last blank line in a plain list, return it
|
||||
;; instead of the last item.
|
||||
|
|
|
@ -174,12 +174,12 @@
|
|||
(let ((org-plain-list-ordered-item-terminator 41))
|
||||
(org-cycle-list-bullet)
|
||||
(buffer-string)))))
|
||||
;; When `org-alphabetical-lists' is non-nil, cycle to alpha bullets.
|
||||
;; When `org-list-allow-alphabetical' is non-nil, cycle to alpha bullets.
|
||||
(should
|
||||
(equal "a. item"
|
||||
(org-test-with-temp-text "1) item"
|
||||
(let ((org-plain-list-ordered-item-terminator t)
|
||||
(org-alphabetical-lists t))
|
||||
(org-list-allow-alphabetical t))
|
||||
(org-cycle-list-bullet)
|
||||
(buffer-string)))))
|
||||
;; Do not cycle to alpha bullets when list has more than 26
|
||||
|
@ -214,7 +214,7 @@
|
|||
26) item 26
|
||||
27) item 27"
|
||||
(let ((org-plain-list-ordered-item-terminator t)
|
||||
(org-alphabetical-lists t))
|
||||
(org-list-allow-alphabetical t))
|
||||
(org-cycle-list-bullet)
|
||||
(buffer-substring (point) (line-end-position)))))))
|
||||
|
||||
|
@ -482,7 +482,7 @@
|
|||
"- item 2\n- item 1\n - sub-item 1")))
|
||||
;; Preserve blank lines.
|
||||
(org-test-with-temp-text "- item 1\n\n- item 2"
|
||||
(let ((org-empty-line-terminates-plain-lists nil)) (org-move-item-down))
|
||||
(let ((org-list-empty-line-terminates-plain-lists nil)) (org-move-item-down))
|
||||
(should (equal (buffer-string) "- item 2\n\n- item 1")))
|
||||
;; Error when trying to move the last item...
|
||||
(org-test-with-temp-text "- item 1\n- item 2"
|
||||
|
@ -567,7 +567,7 @@
|
|||
;; Preserve blank lines.
|
||||
(org-test-with-temp-text "- item 1\n\n- item 2"
|
||||
(search-forward "- item 2")
|
||||
(let ((org-empty-line-terminates-plain-lists nil)) (org-move-item-up))
|
||||
(let ((org-list-empty-line-terminates-plain-lists nil)) (org-move-item-up))
|
||||
(should (equal (buffer-string) "- item 2\n\n- item 1")))
|
||||
;; Error when trying to move the first item...
|
||||
(org-test-with-temp-text "- item 1\n- item 2"
|
||||
|
@ -631,10 +631,10 @@
|
|||
;; Blank lines specifications.
|
||||
;;
|
||||
;; Non-nil `org-blank-before-new-entry': insert a blank line, unless
|
||||
;; `org-empty-line-terminates-plain-lists' is non-nil.
|
||||
;; `org-list-empty-line-terminates-plain-lists' is non-nil.
|
||||
(should
|
||||
(org-test-with-temp-text "- a"
|
||||
(let ((org-empty-line-terminates-plain-lists nil)
|
||||
(let ((org-list-empty-line-terminates-plain-lists nil)
|
||||
(org-blank-before-new-entry '((plain-list-item . t))))
|
||||
(end-of-line)
|
||||
(org-insert-item)
|
||||
|
@ -642,7 +642,7 @@
|
|||
(looking-at "$"))))
|
||||
(should-not
|
||||
(org-test-with-temp-text "- a"
|
||||
(let ((org-empty-line-terminates-plain-lists t)
|
||||
(let ((org-list-empty-line-terminates-plain-lists t)
|
||||
(org-blank-before-new-entry '((plain-list-item . t))))
|
||||
(end-of-line)
|
||||
(org-insert-item)
|
||||
|
@ -651,7 +651,7 @@
|
|||
;; Nil `org-blank-before-new-entry': do not insert a blank line.
|
||||
(should-not
|
||||
(org-test-with-temp-text "- a"
|
||||
(let ((org-empty-line-terminates-plain-lists nil)
|
||||
(let ((org-list-empty-line-terminates-plain-lists nil)
|
||||
(org-blank-before-new-entry '((plain-list-item . nil))))
|
||||
(end-of-line)
|
||||
(org-insert-item)
|
||||
|
@ -661,7 +661,7 @@
|
|||
;; line already in the sole item, do not insert one.
|
||||
(should-not
|
||||
(org-test-with-temp-text "- a"
|
||||
(let ((org-empty-line-terminates-plain-lists nil)
|
||||
(let ((org-list-empty-line-terminates-plain-lists nil)
|
||||
(org-blank-before-new-entry '((plain-list-item . auto))))
|
||||
(end-of-line)
|
||||
(org-insert-item)
|
||||
|
@ -671,7 +671,7 @@
|
|||
;; line in the sole item, insert another one.
|
||||
(should
|
||||
(org-test-with-temp-text "- a\n\n b"
|
||||
(let ((org-empty-line-terminates-plain-lists nil)
|
||||
(let ((org-list-empty-line-terminates-plain-lists nil)
|
||||
(org-blank-before-new-entry '((plain-list-item . auto))))
|
||||
(goto-char (point-max))
|
||||
(org-insert-item)
|
||||
|
@ -681,7 +681,7 @@
|
|||
;; a blank line, preserve it.
|
||||
(should
|
||||
(org-test-with-temp-text "- a\n\n"
|
||||
(let ((org-empty-line-terminates-plain-lists nil)
|
||||
(let ((org-list-empty-line-terminates-plain-lists nil)
|
||||
(org-blank-before-new-entry '((plain-list-item . auto))))
|
||||
(goto-char (point-max))
|
||||
(org-insert-item)
|
||||
|
@ -691,7 +691,7 @@
|
|||
;; are already separated by blank lines, insert one.
|
||||
(should
|
||||
(org-test-with-temp-text "- a\n\n- b"
|
||||
(let ((org-empty-line-terminates-plain-lists nil)
|
||||
(let ((org-list-empty-line-terminates-plain-lists nil)
|
||||
(org-blank-before-new-entry '((plain-list-item . auto))))
|
||||
(goto-char (point-max))
|
||||
(org-insert-item)
|
||||
|
@ -699,14 +699,14 @@
|
|||
(looking-at "$"))))
|
||||
(should
|
||||
(org-test-with-temp-text "- a\n\n- b"
|
||||
(let ((org-empty-line-terminates-plain-lists nil)
|
||||
(let ((org-list-empty-line-terminates-plain-lists nil)
|
||||
(org-blank-before-new-entry '((plain-list-item . auto))))
|
||||
(org-insert-item)
|
||||
(forward-line)
|
||||
(looking-at "$"))))
|
||||
(should
|
||||
(org-test-with-temp-text "- a\n #+BEGIN_EXAMPLE\n\n x\n #+END_EXAMPLE"
|
||||
(let ((org-empty-line-terminates-plain-lists nil)
|
||||
(let ((org-list-empty-line-terminates-plain-lists nil)
|
||||
(org-blank-before-new-entry '((plain-list-item . auto))))
|
||||
(goto-char (point-max))
|
||||
(org-insert-item)
|
||||
|
|
Loading…
Reference in New Issue