Commit Graph

1929 Commits

Author SHA1 Message Date
Bernt Hansen 64d3186ff6 Fix agenda bulk refile bug
Fix bulk refiling in the agenda due to commit
9ec5529 (Fix jumping to last refile location in agenda, 2009-08-20)

This restores the original behaviour.
2009-08-26 10:29:24 -04:00
Carsten Dominik c2265b4145 Improve following links from the agenda
`C-c C-o' in the agenda will now offer links visible in the agenda
line and also links in the entry text of the original outline node.
2009-08-26 13:09:26 +02:00
Carsten Dominik 7284206c6a Merge branch 'for-carsten' of git://git.norang.ca/org-mode
Conflicts:
	lisp/org-agenda.el
2009-08-26 06:40:45 +02:00
Bastien Guerry c34ca53f2f org-notify: bugfix by Bernt Hansen. 2009-08-26 11:28:25 +08:00
Carsten Dominik 8a72889e39 Agenda: Improve of the command `org-agenda-open-link'
It can now handle multiple links in the entry, as well as entry text
pulled in via `E'.
2009-08-25 22:45:58 +02:00
Bernt Hansen 9ec5529af0 Fix jumping to last refile location in agenda
C-u C-u C-c C-w now goes to the last refile location in the agenda.
This is the same behaviour as org-refile (when used in an org file)
2009-08-25 10:05:14 -04:00
Carsten Dominik babb63a27f Simplify storing links from gnus
Patch by Leo, with Tassilo's and Bastien's blessing
2009-08-25 13:43:33 +02:00
Carsten Dominik c03d64ceb2 Merge branch 'fix-plain-links'
Conflicts:
	lisp/ChangeLog
2009-08-25 11:13:27 +02:00
Carsten Dominik 1c8b0c3b41 Do not add extra empty lines for display formulas
Longmin Wang writes:

> Hi,
>
> I am using org-mode integrated in emacs 23.1.1.  When I export
> the org file to html file, the enumerations will be interrupted
> by some displayed math formulae. For example, the codes
>
>  1. The first.
>
>  2. A displayed formula: \[ \int_0^{+\infty} \frac{c}{1+x^2}dx=1. \]
>
>  3. The third.
>
> will generate
>
>   1. The first.
>   2. A displayed formula:
>   <the formula>
>   1. The third.
>
> Is it a bug? Or I made some mistakes in the source file.
2009-08-25 11:05:36 +02:00
Carsten Dominik 0688613ca8 Test implementation for agenda showing some amount of entry text 2009-08-24 18:43:10 +02:00
Carsten Dominik 9eaab0b5cf Visibility Cycling: Allow to show all empty lines after a headline
`org-cycle-separator-lines' can now get a negative value, to indicate
that, if the number of empty lines before a visible entry is greater
than the specified number, then *all* empty lines should be shown.
2009-08-24 14:50:40 +02:00
Carsten Dominik 0f826c4e87 Fix the definition of org-src-language-modes
Patch by Eric Schulte
2009-08-24 12:25:17 +02:00
Carsten Dominik 0b0460703a Fix plain link export 2009-08-24 11:13:00 +02:00
Carsten Dominik 0db9bf496c Remember: Allow to escape % 2009-08-24 07:16:27 +02:00
Bastien Guerry 754694dd4b Use org-notify to show a notification and possibly play a sound. 2009-08-24 02:44:29 +08:00
Bastien Guerry 486e807b1b org-gnus.el: Handle `gnus-summary-mode' and `gnus-article-mode' separately.
Use `gnus-summary-article-header' function when in gnus-summary-mode.
This way the article doesn't get displayed unnecessarily.  We don't use
this function in the gnus-article-mode because it is not reliable.

Thanks to Leo for this suggestion.
2009-08-24 02:28:53 +08:00
Carsten Dominik 5e9fc20394 Allow language names where the major mode name seems unrelated to the language
Eric Schulte writes:

> Attached is a small patch for a small issue.
>
> Sometimes a language uses a major mode which can't be guessed
> from it's name.  This patch introduces the `org-src-lang-modes'
> variable which can be used to map language names to major modes
> when this is the case.  This is used when editing a source-code
> block, or when exporting fontified source-code with htmlize.
>
> So far the only instance of this that I know of is ocaml and
> tuareg-mode, so that's the only thing that `org-src-lang-modes'
> is pre-populated with.  Maybe there are other instances as well?
2009-08-23 19:31:47 +02:00
Carsten Dominik 23e30ef38e Remove forgotten (debug) form. 2009-08-23 19:12:16 +02:00
Carsten Dominik 0a7e8ab221 LaTeX export: Modify the structure of the listings name option.
The variable `org-export-latex-listings-langs' is now an alist.
2009-08-23 19:11:12 +02:00
Carsten Dominik a48fe32c4c LaTeX export: Avoid footnote processing in LATEX_HEADER lines
Nick Dokos writes:

> I define a LaTeX macro at the top of my document, like so:
>
> ,----
> | ...
> | #+LATEX_HEADER: \newcommand{\rowstyle}[1]{\gdef\currentrowstyle{#1}%
> | #+LATEX_HEADER:   #1\ignorespaces
> | #+LATEX_HEADER: }
> | ...
> `----
>
> and export - I get the following inserted:
>
> ,----
> | ...
> | \begin{document}
> |
> |
> |
> |
> |
> | \$\^{}{1}\$ FOOTNOTE DEFINITION NOT FOUND: 1
> | ...
> `----
>
> Obviously, the macro argument spec is mistaken for a footnote.
2009-08-21 06:44:29 +01:00
Bernt Hansen 38f3009927 Skip git-version determination if git command fails
This removes errors generated on a windows system where msysGit is
installed in git bash only and not available from cmd.exe in the
user's PATH.
2009-08-20 15:00:05 -04:00
Bernt Hansen ffaa4ff134 Use lisp cd function to change directories to avoid shell dependencies
This fixes git version determination on windows for cygwin and for msysGit
where git is installed in the user's PATH for the windows command shell.
2009-08-20 15:00:04 -04:00
Carsten Dominik eece1706ff Merge branch 'master' of git+ssh://repo.or.cz/srv/git/org-mode
Conflicts:
	lisp/ChangeLog
2009-08-20 10:19:36 +01:00
Carsten Dominik 62b932c8d5 Make folded blocks searchable
Patch by Eric Schulte
2009-08-20 08:59:34 +01:00
Bastien Guerry c7b7213bed org-flag-drawer: display the position where the error occurs.
Patch by Friedrich Delgado Friedrichs <friedel@nomaden.org>.
2009-08-19 17:05:27 +08:00
Carsten Dominik c2712137be Clean up after John's iswitchb patch 2009-08-19 09:33:17 +01:00
Carsten Dominik c7c1a9ea75 Minor change in wording of privacy prompt 2009-08-19 07:10:41 +01:00
Carsten Dominik 473f1843d9 Minor fix 2009-08-19 00:07:33 +01:00
Carsten Dominik 464210a0d1 New command to submit a bug report 2009-08-18 22:08:42 +01:00
Bernt Hansen a32e8e8fec Add .dirty to git org-version info if files are modified
Shows files as modified by appending .dirty to indicate that
you are running org-mode from a dirty working tree (some tracked
files are modified)
2009-08-18 20:05:56 +01:00
Bernt Hansen a5e87a4723 Add git version number to org-version information
Adds the output of 'git describe' to the org-version string if we are running
from a git repository.  This identifies exactly what commit is checked out in
the org-mode git repository when reporting the org-mode version number.

org-version returns something like:

    Org-mode version 6.29trans (release_6.29c.42.g5996)

which shows 6.29trans (somewhere after the last release tag) which
is 42 commits after release_6.29c at git commit 5996.

The git describe information is not included if org mode is not
running from a git repository.
2009-08-18 20:05:45 +01:00
Carsten Dominik 8c33812854 Improve documentation about hierarchical versus recursive statistics 2009-08-18 15:43:55 +01:00
Carsten Dominik d52aaaf51c Minor fix 2009-08-18 07:55:13 +01:00
Carsten Dominik 0ba7d3d2f9 LaTeX export: Fix problem with emphasis in quotes 2009-08-18 07:45:35 +01:00
Carsten Dominik dec80f2451 LaTeX export: Add support for +strike-through+ emphasis 2009-08-18 07:28:03 +01:00
Carsten Dominik 158a5d8fe6 Improve documentation on inclusion if inactive timestamps. 2009-08-18 07:17:15 +01:00
Carsten Dominik e9cdfce08c Fix indentation in code export
Patch by Eric Schulte.
2009-08-18 06:35:50 +01:00
Carsten Dominik ca699a970d Agenda: Fix problem with block entries.
This bug was caused by commit
8c177dc832, and reported by Matt
Lundin.  The problem was that this commit tried to remove the text
propertes of the MATCH part of an agenda command.  However, in block
commands, the MATCH part is not a string.
2009-08-18 06:31:33 +01:00
Carsten Dominik dbc99e6550 Add MACRO to completion works 2009-08-16 09:48:58 +02:00
Carsten Dominik f7e208da37 Make latex preview also use the packages in `org-export-latex-packages-alist'. 2009-08-16 09:38:03 +02:00
Carsten Dominik 94d91eaf03 HTML export: Fix bugs with footnotes. 2009-08-16 06:41:30 +02:00
Carsten Dominik 05f25b3de4 Remove (debug) form 2009-08-16 05:36:05 +02:00
Carsten Dominik 15227843ab Fix some issues related to the recent iswitchb patch 2009-08-16 00:31:39 +02:00
Carsten Dominik 09acabcfb3 Fix some typos, add a new variable 2009-08-15 08:16:45 +02:00
John Wiegley 5acac25dc1 All completing-read behavior for iswitchb users
This is enabled using org-completion-use-iswitchb, and follows the same
model of usage as for ido users.
2009-08-15 01:14:04 +02:00
Carsten Dominik 7d5fe030e3 Get rid of unnecessary prompt in agenda view
Patch by Bernt Hansen

http://thread.gmane.org/gmane.emacs.orgmode/16485
2009-08-14 20:47:39 +02:00
Carsten Dominik 8c177dc832 Avoid text properties on elements in custom variables 2009-08-14 17:18:14 +02:00
Carsten Dominik 8d59e10a06 Bugfix: Keep todo keyword list valid
An entry `#+TODO:' without content make `M-x org-mode' fail.
While it may cause problems to have no TODO keywords defined, this
should not make entering the mode fail.
2009-08-12 18:38:07 +02:00
Carsten Dominik b069091873 Newlines in macros can de defined using \n 2009-08-12 11:10:30 +02:00
Carsten Dominik 5b7ea02286 Fix typos
Thanks to Nick Dokos.
2009-08-12 10:19:57 +02:00
Carsten Dominik 5834ad01b6 LaTeX snippets: Avoid Overlap
It is possible that the regular expressions for LaTeX snippets match
at nested locations.  For example, Nick Dokos submitted this:

,----
| #+LaTeX_HEADER: \usepackage{amsmath}
|
| * foo
|
| \[
| \begin{matrix}
| 1&d\\
| d&d\\
| \end{matrix}
| \]
|
`----

where the snippet regexps match at \[ ... \] and also at
\\begin{matrix}.

This would lead to two nested overlays being placed.  With this
commit, only the outer one will remain.
2009-08-11 16:32:05 +02:00
Carsten Dominik 1d18043506 LaTeX export: Add more languages for source code publishing 2009-08-11 15:45:10 +02:00
Carsten Dominik 5ad80265af Macros: Fix bugs with macro arguments distributed over lines 2009-08-11 15:29:53 +02:00
Carsten Dominik 59370b6a83 LaTeX export: Remove bug in table export.
A `save-excursion' around a call to org-table-align make point end up
*before* the table.  The reason is that a table align replaces the
entire table, including the newline before it.  When the table is
removed in order to be replaced, the marker created by
`save-excursion' slips.  `org-table-align' has it's own, built-in
`save-excursion' by remembering the line and column where the cursor
was before the align.
2009-08-11 07:51:12 +02:00
Carsten Dominik bd8e4e248a Fix problem with completing #+STARTUP 2009-08-10 14:45:57 +02:00
Carsten Dominik bd8e816ea0 Move constant definition so that org-html does not have to be loaded just for font-locking 2009-08-10 14:02:24 +02:00
Carsten Dominik 05ef736ac0 Allow Macros to span several lines.
However, if you are using arguments, it is required that the opening
parenthesis is attached to the macro name, and that the closing
parenthesis is attached to the three closing braces.
2009-08-10 10:08:34 +02:00
Carsten Dominik b70a5e0357 Merge branch 'master' of git+ssh://repo.or.cz/srv/git/org-mode
Conflicts:
	lisp/ChangeLog
2009-08-09 14:52:25 +02:00
Carsten Dominik c5783bd8bd LaTeX export: Allow export using the listings package
Patch by Eric Schulte, see

http://thread.gmane.org/gmane.emacs.orgmode/16269
2009-08-09 14:51:09 +02:00
Andrew Stribblehill b2743b9e37 Remove some blank leading blank lines from ASCII export.
With the following org file:
------
Foo

In which foos are described.
#+OPTIONS: num:nil author:nil creator:nil timestamp:nil d:nil toc:nil skip:t
#+TITLE:
* The construction of a foo
** Armaments
------
I found exporting to ASCII gave five leading blank lines. The
following patch reduces that to one. (I'd love some help in tracking
down that final one.)
2009-08-09 14:34:05 +02:00
Bastien Guerry 46b89a6030 Bugfix: aborting `org-iswitchb' should not activate iswitchb-mode. 2009-08-08 14:38:28 +08:00
Carsten Dominik 6bd7ffef36 Incorporate Glen Morris' changes in downstream Emacs 2009-08-08 06:34:24 +02:00
Carsten Dominik dfd3749a27 Fix bug with including files without markup
File contents that are included with "#+include: file"
should be processed as normal Org stuff.  This used to be so,
and it is so now again.
2009-08-08 06:10:59 +02:00
Carsten Dominik ab2ed6adb8 Agenda: avoid some duplicate entries
New variable `org-agenda-skip-scheduled-if-deadline-is-shown' to avoid
that a entry shows up in the agenda for today for both a scheduling
and a deadline entry.  See the docstring of the variables for more
details.
2009-08-07 23:59:22 +02:00
Carsten Dominik 76d970b761 Fix bug with C-RET
Leo writes:

> Hi there,
>
> ,----[ (info "(org)Structure editing") ]
> | `C-<RET>'
> |      Just like `M-<RET>', except when adding a new heading below the
> |      current heading, the new heading is placed after the body instead
> |      of before it.  This command works from anywhere in the entry.
> `----
>
> Inside a substree and with the point at the beginning of a line, C-RET
> turns the current line into a heading. In the following example, ><
> indicates where the point is.
>
> ----------------
> * Sample
> <  This is not a heading
> ----------------
>
> After C-RET, it changes to
> ----------------
> * Sample
> * This is not a heading
> ----------------
>
> I can reproduce this with org 6.29c as included in Emacs. Can someone
> else reproduce this bug?
2009-08-07 16:29:43 +02:00
Carsten Dominik 0af5133334 Mark running clock in the agenda.
If the entry currently being clocked is present in the agenda, mark it.
2009-08-07 11:00:16 +02:00
Carsten Dominik 295491a5e8 Add org-track.el. 2009-08-07 07:29:42 +02:00
Carsten Dominik 0622debb55 Agenda: Add a command to toggle the bulk mark. 2009-08-07 07:22:22 +02:00
Carsten Dominik bfdd3d3fd3 Push version number to 6.29trans 2009-08-06 12:07:20 +02:00
Carsten Dominik 0864163024 Release 6.29c 2009-08-06 06:26:23 +02:00
Carsten Dominik c069ebe327 Minor fixes
Patch by Samuel Wales.
2009-08-06 06:23:49 +02:00
Carsten Dominik 8eba33958f LaTeX export: Fix export problems when exporting a region
Dan Griswold writes:

> Hi there,
>
> Well, I think this a bug.
>
> Given this org input file:
>
> ,----
> | * Things
> | ** A Heading
> |    - some
> |    - stuff
> |    - in
> |    - a
> |    - list
> | ** Another heading
> |    - another
> |    - list
> `----
>
> then if I select the level one heading (titled "Things")
> with C-c @, and export to LaTeX using C-c C-e l, I get this
> output:
>
> ,----
> | % Created 2009-07-29 Wed 20:24
> | \documentclass[12pt]{article}
> | \usepackage[utf8]{inputenc}
> | \usepackage[T1]{fontenc}
> | \usepackage{graphicx}
> | \usepackage{longtable}
> | \usepackage{hyperref}
> |
> |
> | \title{Things}
> | \author{Daniel M. Griswold}
> | \date{July 29, 2009}
> |
> | \begin{document}
> |
> | \maketitle
> |
> | ** A Heading
> | \begin{itemize}
> | \item some
> | \item stuff
> | \item in
> | \item a
> | \item list
> | \end{itemize}
> | ** Another heading
> | \begin{itemize}
> | \item another
> | \item list
> | \end{itemize}
> |
> | \end{document}
> `----
>
> Note that the top level headings ("A Heading" and "Another
> Heading") are not exported as \section, but with the
> asterisks they have in the org file:
>
> ,----
> | ** A Heading
> | \begin{itemize}
> |
> |   ... snip ...
> |
> | \end{itemize}
> | ** Another heading
> `----
>
> Exporting the whole file does what it's supposed to do:
> export the headlines as \section and \subsection.

This commit fixes the issue.
2009-08-05 18:18:35 +02:00
Carsten Dominik 00658851ec Remove invalid -E option from dvipng call 2009-08-05 17:53:39 +02:00
Carsten Dominik b3e7b992f8 Minor changes 2009-08-05 17:02:42 +02:00
Carsten Dominik e40370e810 Make #+BIND work correctly, and ask the user to confirm using BIND. 2009-08-05 16:30:02 +02:00
Carsten Dominik 8cd94ce203 Export: Fix bug with #+BIND 2009-08-05 14:43:55 +02:00
Carsten Dominik d6b37ddbea Release 6.29b 2009-08-05 12:34:30 +02:00
Carsten Dominik e5158d35e4 Fix more refile bugs 2009-08-05 12:32:56 +02:00
Carsten Dominik 0728025585 Refile: Fix horrible bug
This bug would make refiling complain about the tree not being a tree
unless the *previous* content of the tree was a tree.  Pretty bad....
2009-08-05 12:08:42 +02:00
Carsten Dominik 386e0dcef6 Fix copyright assignment in org-protocol.el 2009-08-05 00:59:09 +02:00
Carsten Dominik 1c25048e48 Release 6.29a 2009-08-04 23:54:22 +02:00
Carsten Dominik f22be634d2 Fix table mapping 2009-08-04 23:53:41 +02:00
Carsten Dominik d67a9be8a2 Release 6.29 2009-08-04 23:06:39 +02:00
Carsten Dominik babd053bd6 Fix bulk agenda processing with parents and children in the loop
Bernt Hansen writes:

> Every so often I run into a situation where bulk refiling
> doesn't work anymore.
>
> I currently have 15 items in my refile.org file that I want
> to refile to other locations.  I marked a few of them and
> bulk refiled them just fine.  Then I marked a few more and B
> r fails with "Cannot find entry for marker #<marker at
> 297156 in norang.org>"
>
> I think this happens when I mark multiple tasks in the same
> subtree (i.e. the parent and a sibling) and refile both to
> the same location.  After that it gets confused.
>
> If I have a task like this in refile.org
>
> #+FILETAGS: REFILE
> * Test
> ** Test 2
>
> and run a tags match on REFILE I see both tasks.  Mark both
> with m in the agenda and B r to some other location.  It
> refiles the first (and this moves the sibling too) and then
> it's broken after that.
>
> I get the following backtrace
>
> Debugger entered--Lisp error: (error "Cannot find entry for
> marker #<marker at 297156 in norang.org>")

Indeed the happens because, when a parent gets refiled or
achieved, any entries corresponding to its children are
removed from the agenda.

We address this issue by

- sorting the markers, to make sure parents will be handled
  before children

- No longer throwing an error when a bulk action entry no
  longer is present in the agenda - most likely it was taken
  care of together with its parent.
2009-08-04 22:46:08 +02:00
Carsten Dominik 064c7976cf Minor refile fixes 2009-08-04 18:38:14 +02:00
Carsten Dominik 22cb84f74d Allow normal lists completion also when using ido.el
Gregory Grubbs writes:

> When exporting a table with ido-mode active, an error is
> raised in org-ido-completing-read.  I think
> ido-completing-read is being called with incorrect
> arguments, but the fix is beyond me.
>
> Steps to reproduce the error:
> Org-mode version: 6.28trans
> Emacs version: GNU Emacs 23.0.91.1 (i486-pc-linux-gnu, GTK+ Version
> 2.16.0) of 2009-04-05 on palmer, modified by Debian
>
>
> Turn on ido-mode: M-x ido-mode RET
> visit a file using C-x C-f /tmp/test.org RET
> Create a simple table:
> |column a|column b|
> |-
> |one|two|
> |three|four|
>
> Org-magic-tabelize it by hitting TAB somewhere in a column
>
> M-x org-table-export RET /tmp/test.csv
>
> Here's the backtrace I get:
>
> Debugger entered--Lisp error: (wrong-type-argument listp "orgtbl-to-tsv")

This error is due to the fact that org-ido-completing-read does
convert alists to flat lists for completion.  Now we check if the list
really is an alist before converting it.
2009-08-04 17:15:40 +02:00
Carsten Dominik f322206708 Fix parenthesis error in footnote export code 2009-08-04 16:46:34 +02:00
Carsten Dominik 73b6d73aef Minor fix 2009-08-04 13:10:36 +02:00
Carsten Dominik 0d9f114f3b Fix a bug in the advice on outline-end-of-subtree 2009-08-04 10:38:40 +02:00
Carsten Dominik 2ec01a800f Fix cycling bug. 2009-08-04 10:22:08 +02:00
Carsten Dominik a4a8bd2d07 Cycling: Fix bug
The first cycle command on a line did not work correctly, to always
switched to FOLD.  This was due to an error in new, faster code to
find the next visible line.
2009-08-04 08:27:41 +02:00
James TD Smith cd70915e26 Add an option to sort tags automatically. 2009-08-04 07:54:46 +02:00
Carsten Dominik 2eecb4c43c Fix white-space errors 2009-08-03 17:30:30 +02:00
James TD Smith c65fb88796 Bugfixes, documentation and custom options for org-checklist.
* contrib/lisp/org-checklist.el
  - Fix some problems with the print/export feature in org-checklist.
  - Add custom options for this module
  - Fix some interaction with a2ps
  - Only reset checkboxes if TODO state is done.

* lisp/org.el
  - Add org-checklist to org-modules
2009-08-03 16:45:47 +02:00
Carsten Dominik 5dbc23baed Keep compiler happy 2009-08-03 13:28:24 +02:00
Carsten Dominik ee7d1c76fd Fix parenthesis bug in org-exp.el 2009-08-03 12:18:14 +02:00
Carsten Dominik 6a722e5d2e Do not record undo information when adding/remove text properties
When this is done inside org-unmodified, undo information is not recorded.
2009-08-03 11:03:37 +02:00
Carsten Dominik 487f187c19 More minor fixes to org-indent-mode 2009-08-03 10:25:11 +02:00
Carsten Dominik 65cb546662 Minor fixes to `org-indent-mode'. 2009-08-03 10:11:38 +02:00
Carsten Dominik f3345d280e Minor fix 2009-08-03 07:51:01 +02:00
Carsten Dominik 6062cef1c6 Allow export of tables from temporary buffers without a file
Gregory Grubbs writes:

I like to make org-mode tables in arbitrary buffers, then
save them as CVS files. The export fails when done from a
buffer with no associated file.

Here's a little patch that allows exporting a table from
any buffer (org-mode version 6.28trans):
2009-08-03 07:42:40 +02:00
Carsten Dominik 31ceed47ff New minor mode org-indent-mode
This mode implements outline indentation similar to clean view, but in
a dynamic and virtual way, at display time.
2009-08-03 06:24:24 +02:00
Carsten Dominik 7cb52cfb7e Merge branch 'master' of git+ssh://repo.or.cz/srv/git/org-mode
Conflicts:
	lisp/ChangeLog
	lisp/org-exp.el
	lisp/org.el
2009-08-02 23:50:13 +02:00
Bastien Guerry 47994f66d2 Fix "Not on a heading" error when setting priority inside a task
Changing the priority of a task when the point is after the heading
(anywhere inside the task) worked but aligning the tags failed with
a "not on a heading" error due to the save-excursion not including
the tag alignment.  This change moves back to the heading and
includes that during tag alignment to remove the error text.

Patch by Bernt Hansen.
2009-08-03 03:03:43 +08:00
Bastien Guerry 052f6e334d (org-occur): Sends an error when the user inputs an empty string.
Patch by Bernt Hansen.
2009-08-03 02:58:41 +08:00
Bastien Guerry e05c4511af org.el (org-adapt-indentation): Slightly improve the docstring.
Make it clear that "a line starting a column 0" means a line starting
with some text at column 0.
2009-08-03 02:38:09 +08:00
Bastien Guerry fa0ab63be6 Use file-source.org format instead of file.org-source.
This was reported by Hsiu-Khuern Tang.
2009-08-03 02:28:34 +08:00
Carsten Dominik a93815c686 Menu entry for `org-occur-link-in-agenda-files' 2009-08-02 15:56:58 +02:00
Carsten Dominik d8732b3938 Doc fixes 2009-08-02 15:51:59 +02:00
Carsten Dominik 98998abc0d ID links: Honor `org-link-frame-setup'. 2009-08-02 15:51:26 +02:00
Carsten Dominik 7151414aeb Fix file name for source export
Hsiu-Khuern writes:

> Hi all,
>
> The footnote at the bottom of section 13.1.4 ("Publishing
> action") of the Org manual says that publishing org files to
> the same directory using org-publish-org-to-org results in
> files named like file-source.org.  It actually results in
> file.org-source, which is not as nice.  I believe the
> problem is in the org-export-as-org function in org-exp.el.
2009-08-01 23:44:11 +02:00
Carsten Dominik 9f9f2de7d2 Full headline matching cleanup
Write \n instead of \xa in the regexp, this is clearer.
And make the \n optional so that also lines at the end of
the buffers will still be matched as headlines.
2009-08-01 23:36:16 +02:00
Carsten Dominik 8d0acabf2d Modify Bastien's emphasis in verse fix
Instead of making the postmatch optional, we allow backslash in the
postmatch string, so that the match will work before an explicit line
break "\\".
2009-08-01 23:32:28 +02:00
Carsten Dominik 42a5312a57 Read date: Force calendar into current frame 2009-08-01 23:21:49 +02:00
Carsten Dominik 97aa3f5b3b Revert "Bugfix: don't exclude parentheses from org-plain-link-re."
This reverts commit c80e212d57.

Conflicts:

	lisp/ChangeLog
2009-08-01 20:05:40 +02:00
Carsten Dominik 4249cbf454 Merge branch 'master' of git+ssh://repo.or.cz/srv/git/org-mode
Conflicts:
	lisp/ChangeLog
2009-08-01 11:44:55 +02:00
Carsten Dominik 2cc99fbb0a Tables: Relative row references may now cross hlines
A relative row reference like @-1 in a table may now reach across a
horizontal separator line.  I hope this will not break any important
tables out there, but I think it is the right thing to do.

The original reason for not-crossing was to implement running
averages of one column in the next.  This can now be done using field
formulas near the beginning and end of the column, and a column
formula for the central part.

See the variable `org-table-relative-ref-may-cross-hline' for more
details.
2009-08-01 07:56:26 +02:00
Carsten Dominik 09cccb22b3 Tables: Cut or copy single fields if no active region is defined
C-c C-x C-w and C-c C-x M-w now act on single table fields if there is
no active region defined.
2009-07-31 07:35:02 +02:00
Bastien Guerry 567331e169 Switch directly from CHILDREN to FOLDED if there is no subtree.
Also send a meaningful message FOLDED (NO SUBTREE) to avoid confusion.
2009-07-31 09:17:27 +08:00
Bastien Guerry c80e212d57 Bugfix: don't exclude parentheses from org-plain-link-re. 2009-07-31 08:25:04 +08:00
Bastien Guerry e06752ad53 Declare org-show-notification as a function of org-clock.el. 2009-07-30 01:37:55 +08:00
Bastien Guerry 1a79ec6e31 Bugfix: recognize timestamps with an abbreviated format for days.
Emacs recently (when?) changed the abbreviated format for days.
The clock was confused when trying to mach this format.  This patch
by Nicolas Goaziou fixes it.
2009-07-29 13:44:52 +08:00
Bastien Guerry 52302394e7 New option: org-protocol-default-template-key defaults to "w".
The default template "w" used to be hardwired, we have an option now.
2009-07-28 06:02:10 +08:00
Bastien Guerry bfc9e1bcb5 Bugfix: save-excursion before reading the refile target.
Otherwise cursor moves might confuse `org-refile'.
2009-07-27 18:33:06 +08:00
Bastien Guerry 01d84ed000 Bugfix: correctly convert the footnote reference. 2009-07-27 17:59:21 +08:00
Carsten Dominik 6677f745cc LaTeX export: Skip title command when there is no title
Using "#+TITLE:" without a value make the LaTeX export ignore the
value of org-export-latex-title-command.
2009-07-27 08:45:02 +02:00
Carsten Dominik 3788dc336f HTML export: Fix bug with horizontal rules in plain lists.
Brenton Kenkel writes:

> I'm using org-mode 6.28e on Aquamacs (based on GNU Emacs
> 22.3.1) on Mac OS X. I'm having an issue with horizontal
> rules and lists in HTML export. When I export the following
> to HTML, the horizontal rule tag is generated within the
> unordered list, rather than after it ends:
>
> ,-----
> | * test
> |
> | - this is a list
> |
> |
> | -----
> |
> | * next section
> |
> | No list.
> |
> |
> | -----
> |
> `-----
>
> I want the first horizontal rule to be even with the second;
> namely, extending all the way to the left. Any way to do
> this?
2009-07-27 07:06:00 +02:00
Bastien Guerry 90d2a9c645 Autoload new org-timer functions when loading org.el 2009-07-27 12:20:39 +08:00
Bastien Guerry f2d92fa89a Bugfix: correctly convert list items before the first headline. 2009-07-27 11:53:53 +08:00
Bastien Guerry ed0a91e76f New option org-export-html-footnote-format.
This defines the format for the footnote reference.
This string must contain %s which will be replaced by
the footnote reference.
2009-07-27 11:32:52 +08:00
Bastien Guerry da7a640931 org-provide-todo-statistics now alloww a list of TODO keywords.
When such a list is set, only compute statistics against headlines
containing a keyword from this list.  This was requested by Samuel
Wales.
2009-07-27 11:08:51 +08:00
Bastien Guerry 4e27954130 Add autoload cookie to org-timer-set-timer. 2009-07-27 05:27:41 +08:00
Bastien Guerry 03fffc1864 New function `org-occur-link-in-agenda-files'.
This function create a link and search for it in agenda files.
Note that it does not store the link in `org-stored-links'.
2009-07-27 04:14:04 +08:00
Bastien Guerry d8a0f2949d Use the correct keybinding for org-timer-set-timer.
Also use the new variable `org-timer-last-timer' to fix a bug
in `org-timer-show-remaining-time' about not pick up the right
timer.
2009-07-27 04:12:31 +08:00
Bastien Guerry 7cdff7b1eb New timer functionality to set a timer from a headline.
This commit defines three new functions in org-timer.el:

- org-timer-set-timer, bound to `C-c C-x ;' in Org buffers
  and to `;' in Org agenda buffers.   This function sets a
  timer for the headline the cursor is currently it.  Up to
  three timers can be set.

- org-timer-show-remaining-time: this shows the remaining
  time for the last set timer.

- org-timer-reset-timers: this reset all timers.

This functionality was requested by Samuel Wales and emulates
that of tea-time.el -- see the emacswiki doc about tea-time.el:

  http://www.emacswiki.org/emacs/tea-time
2009-07-27 02:54:17 +08:00
Bastien Guerry 7a1a62d2f2 Udate the docstring of org-show-notification. 2009-07-27 01:11:51 +08:00
Bastien Guerry 6ebb5f2304 New value 'all-headlines for `org-provide-todo-statistics'.
When org-provide-todo-statistics is set to 'all-headlines, the
statistics are performed against all headlines, including those
with no TODO keyword.

This was requested by David A. Gershman.
2009-07-27 00:35:48 +08:00
Bastien Guerry 402448cb4c Code cleanup. 2009-07-26 21:00:52 +08:00
Bastien Guerry aed038294a Fix typo. 2009-07-26 20:59:49 +08:00
Bastien Guerry 575192b4a4 Code cleanup. 2009-07-26 20:58:35 +08:00
Carsten Dominik d56f2f4fa5 HTML export: Fix problems with colgroup tags
Special lines with <, >, and <> in tables should trigger colgroup tags.
2009-07-26 08:15:34 +02:00
Bastien Guerry b536686e7d Fix typo in org-provide-checkbox-statistics docstring. 2009-07-26 06:36:41 +08:00
Bastien Guerry 593022a66e Add a new :timestamp option for clock reports.
Using :timetamp t as an option in a clock report now allows
insertion of the timestamp for the clocked entry.  Timestamps
are searched for in this order: SCHEDULING, TIMESTAMP, DEADLINE
and TIMESTAMP_IA.
2009-07-26 06:05:09 +08:00
Bastien Guerry c39f5d632f `org-emph-re' now matches emphasized strings at the end of lines.
We do this by making the last element of org-emph-re optional.
2009-07-26 05:23:56 +08:00
Bastien Guerry 8b840fe73c New function `org-list-make-subtree' bound to C-c C-*
This function convert the plain list at point into a subtree, preserving
the list structure.  Thanks to Ilya Shlyakhter for this suggestion.
2009-07-26 04:48:32 +08:00
Bastien Guerry 157329bb45 Fix the frame selection problem without using a macro.
Do this by restauring the frame focus correctly in
`org-eval-in-calendar'.
2009-07-25 19:32:59 +08:00
Bastien Guerry 4be6a90bd5 Code cleanup. 2009-07-24 03:39:39 +02:00
Bastien Guerry a2d230bdb8 Bugfix: org-list-beginning-re should not use * for list items. 2009-07-24 03:38:26 +02:00
Bastien Guerry 68b65e8f48 org-get-file-contents: Use a new argument: markup.
When markup is passed to org-get-file-contents then this function does
not protect org-like lines, since the exporter should handle them.
2009-07-24 03:16:19 +02:00
Bastien Guerry bd4a9fe510 org-id.el: New option org-id-uuid-program to set uuidgen program.
On some systems, uuidgen is named uuid.
Let the user define the uuidgen program name.
2009-07-24 02:29:56 +02:00
Bastien Guerry 5a7f43293d Enhance export options for code source examples.
Allow whitespace in code references.  Allow the -r switch to remove the
references in the source code even when the lines are not numbered: the
labels can be explicit enough.  Note that "-r -k" is the same than no
switch - as expected.

Thanks to Ulf Stegemann for bring this up.
2009-07-23 21:48:43 +02:00
Bastien Guerry 68ec49e101 New option: org-fontify-whole-heading-line
Non-nil means modify the regexp in org-set-font-lock-defaults so
that headlines are fontified till the end of the line.  This is
useful when setting a background color for the org-level-* faces.
This defaults to nil so that the old behavior is preserved.
2009-07-23 18:46:35 +02:00
Bastien Guerry 12a9381803 Add and use a new option: org-show-notification-handler
This option lets the user customize the notification mechanism.
For example, she might want to use todochiku.el.

This option defaults to nil, hence doesn't change the previous
behavior: if the program notify-send is installed on the system,
use it, and falls back on using (message [notification]) if not.
2009-07-23 17:33:52 +02:00
Carsten Dominik 0eaf3cce4d Speed-up cycling in buffers with *many* siblings, and *many* drawers
For this we took another look at when drawers actually have to be
hidden again and found that CONTENTS view does not need it, and that
CHILDREN view only needs it before the first child.

The second speed-up comes from advising outline-end-of-subtree to use
the Org version when in org-mode.

The third speed-up comes from using a better way to find the next
visible line, using `next-single-char-property-change'.

Finally, `org-forward-same-level' and `org-backward-same-level' are
faster versions of their outline equivalents and are now bound to
`C-c C-f' and `C-c C-b'.
2009-07-23 11:27:34 +02:00
Carsten Dominik 75a26e1c8d Moving subtrees: Speedup when many siblings exist. 2009-07-22 10:24:24 +02:00
Bastien Guerry 898049066a Bugfix about using the calendar on a separate frame.
`org-read-date' was loosing the focus when the calendar was displayed on
a separate frame.  This patch by Robert Goldman solves it by introducing
a new macro `org-save-frame-excursion' which preserve the frame focus.

See this thread: http://article.gmane.org/gmane.emacs.orgmode/15528

(This fixes the issue I was trying to fix in a previous commit.)
2009-07-22 09:42:11 +02:00
Bastien Guerry 3c031462f5 Bugfix about using a separate frame for the Calendar.
When the Calendar is displayed in a separate frame, Org was
confused and could not find it; this tiny change fixes this.
2009-07-21 09:29:55 +02:00
Carsten Dominik 4183124c4b Keep compiler happy 2009-07-20 09:16:28 +02:00
Carsten Dominik 5f87a31fb7 Fix problems in org-mac-message.el
The return value of some functions was not correct because of a
message form at the very end.  Also, Simplified a few functions.
2009-07-20 09:09:42 +02:00
Carsten Dominik 809fcf9d78 Improve refile history to contain exact matches only
This was a proposal by Samuel Wales.  After the user selected a
refiles target, we make sure that the fully qualified target is in the
history, so that next time, UP will bring back exactly this target.
2009-07-20 09:01:33 +02:00
Bastien Guerry e17368ca76 Also use TAB for completion with org-insert-link.
Before this patch the completion mechanism was this: TAB let's you
complete through link prefixes (gnus: file: bbdb: ...) then RET allows
completion if a completion mechanism is available for the chosen prefix.
Navigating through the history of stored links was a separate process,
available through the up/down M-n/M-p keys.

Now TAB not only completes through link prefixes but also through stored
links.  This behavior matches other Emacs completion mechanisms a bit
more closely.
2009-07-19 19:45:06 +02:00
Bastien Guerry ffa046d38b Fix typo in orgstruct++-mode docstring. 2009-07-19 14:37:59 +02:00
Carsten Dominik 8530298b45 Inline tasks: Play along with archiving, refiling, and footnotes, store link. 2009-07-19 09:47:13 +02:00
Carsten Dominik 741b523fa5 Export: Ignore radio matches in links 2009-07-19 08:35:31 +02:00
Carsten Dominik 82dcd80130 HTML export: Fix bug in example line enumeration code 2009-07-19 08:00:53 +02:00
Bastien Guerry 4998a75c30 Fix typo in org-protocol-remember docstring. 2009-07-18 19:58:42 +02:00
Bastien Guerry 57b43866e5 Bugfix: don't ignore case when building the list of targets.
If you have a TODO keyword like "DELEGATED" and an entry like
"* Delegated this stuff to X", then you want this entry to be
in the list of possible targets.  For that we need to distinguish
between DELEGATED as a keyword and "Delegated" as a simple word,
so (case-fold-search nil) seems relevant.
2009-07-18 10:35:59 +02:00
Bastien Guerry 8a15fe867b New option: org-remember-delete-empty-lines-at-end
This default to t, so the default behavior of org-mode doesn't
change.  But the user might want to keep at least one blank line
at the end of the remembered subtree, this option lets her do it.
2009-07-18 10:09:40 +02:00
Carsten Dominik 6596d005ef Minor improvements 2009-07-18 09:30:20 +02:00
Bastien Guerry 57838f8286 Fixed premature deletion of data when scripting org-plot.
This patch was sent by James TD Smith.
2009-07-17 19:02:01 +02:00
Bastien Guerry 14c0c432be Small rewrite of the ChangeLog. 2009-07-17 18:59:51 +02:00
Bastien Guerry 69e14025f4 New option org-tags-sort-function.
This allows tags to be sorted by string<, string> or a custom function.
Patch submitted by James TD Smith.
2009-07-17 18:43:22 +02:00
Bastien Guerry ee402e55c2 Fix typo. 2009-07-17 18:10:56 +02:00
Bastien Guerry fa7e23ec39 Add org-clock-in-prepare-hook. Doc update.
This hook is called in org-clock-in earlier than the existing
org-clock-in-hook.  This is useful for functions that need to
modify the Effort property, for example.
2009-07-17 09:02:56 +02:00
Bastien Guerry 1821a9126d Document indented for org-tags-match-list-sublevels
Thanks to Samuel Wales.
2009-07-16 22:25:09 +02:00
Bastien Guerry f2abe28993 Update the changelog to reflect last commit. 2009-07-16 22:13:46 +02:00
Bastien Guerry 9fc00404ca Bind the "true line boundary first" label to the 'reversed value.
Rainer Stengele raised this issue.  Hopefully it's now clearer.
2009-07-16 22:13:20 +02:00
Bastien Guerry fe4967229a Fix problem when publishing the region to LaTeX.
`org-export-latex-first-lines' was rather stupid and would
discard the end of the region with the region was active.
Thanks to Holst Thomas for this bug report.
2009-07-16 21:39:37 +02:00
Bastien Guerry 0be765f999 Fix problem with line numbering in HTML source examples.
As reported by Ulf Stegemann (09/07/2009) the HTML output
of the example in the manual would result in no number for
the first line.  It is because `org-export-number-lines' is
told to skip one line while the line inserted previously
(i.e. "<pre class ...>") doesn't end with a newline.
2009-07-16 21:07:03 +02:00
Bastien Guerry debebd2082 Fix typos. 2009-07-16 19:56:39 +02:00
Bastien Guerry 4c23afccc5 Fix small typo. 2009-07-15 16:59:33 +02:00
Carsten Dominik b62e7fc5a0 Fix problems with sub and superscript in LaTeX export 2009-07-09 06:29:51 +02:00
Carsten Dominik 7087902788 Fix bug in org-narrow-to-subtree, which could lead to clock errors
Bernt Hansen writes:

> I have a monthly repeated task (Archive tasks) that has lots of
> old clock time on it currently but has never been marked DONE
> since the creation of the property LAST_REPEAT_TIME.  If this
> task is clocking when Emacs exits and you restart emacs and
> answer Yes to continue the clock - the modeline has the total
> time for the parent task (151:04 instead of the total time for
> this task (5:04).  If I clock the task in again the modeline is
> correct.
2009-07-08 14:29:18 +02:00
Carsten Dominik aa9529a5ce Make publishing a little less noisy 2009-07-08 10:09:05 +02:00
Carsten Dominik 6355334c4b org-plot.el: fix bug 2009-07-08 07:50:48 +02:00
Carsten Dominik 9ec9d79adc org-plot: Allow prepending a user script 2009-07-08 07:01:00 +02:00
Bernt Hansen 3e24ccf646 Archive subtree and move to next visible task
This skips over blank lines preceeding the next task when archiving a task or
subtree.  This allows us to use a keyboard macro to remember the archive key
sequence incantation and skips to the next heading so we don't accidentally
archive the wrong task.

This fixes an issue with blank line handling.  Tasks which have blank lines
following them do not include the blank lines -- they are part of the following
task.  This moves the point forward to the next visible headline so that if we
repeat the archive operation it affects the following task and not the previous
one by mistake.
2009-07-08 06:51:20 +02:00
Carsten Dominik 79b70a7e66 Don't use next-line in lisp code if possible 2009-07-07 15:14:05 +02:00
Carsten Dominik 84c3b6f19b Make Org work better with visual line mode
Patch by Rudi Schlatte
2009-07-07 15:12:49 +02:00
Carsten Dominik 67d2a22fb9 Publishing: Clean out timestamp directory with `C-u C-c C-e E'
When changing the publishing setup, old timestamp files can be left
behind.  Forcing publishing of all projects with `C-u C-c C-e E'
will remove all existing timestamp files.
2009-07-07 15:04:37 +02:00
Carsten Dominik 1768f325df Make bullet modification work for ordered lists as well 2009-07-07 13:52:17 +02:00
Carsten Dominik e5c2547bbe Fix typo in plain list demotion code
Reported by Rainer Stengele.
2009-07-07 13:31:55 +02:00
Carsten Dominik ac425d8bd2 Fix problem with GNUS mail header.
Patch by Andreas Rottmann and Tassilo Horn
2009-07-07 13:26:32 +02:00
Carsten Dominik 636c524df3 HTML export: Show UP and HOME links if defined
org-export-html-link-up and org-export-html-link-home are now also
inserted into normal HTML export, above the page title.
2009-07-07 13:20:25 +02:00
Carsten Dominik a5491ec852 Fix typo 2009-07-07 06:08:36 +02:00
Carsten Dominik e16c5b7b64 Fix typos 2009-07-06 22:30:39 +02:00
Carsten Dominik 30d448b2e1 HTML export: More flexibility for preamble and postamble
Andreas Rottmann writes:

> Well, the subject says it all -- attached is a rough patch to
> allow more flexibility with the HTML export; I use it like this:
>
>    (defun rotty/homepage-preamble (opt-plist)
>      (insert "<div id=\"header\">")
>      (insert
>       "
>    <div id=\"navbar\">
>    <a class=\"menu\" href=\"/\">Home</a>
>    | <a class=\"menu\" href=\"/Writings.html\">Writings</a>
>    | <a class=\"menu\" href=\"/Software.html\">Software</a>
>    | <a class=\"menu\" href=\"/blog/\">Blog</a>
>    </div>
>    ")
>      (insert (format
>               "<h1 class=\"title\"><a href=\"/\">rotty</a> &gt; %s</h1>\n"
>               (plist-get opt-plist :title)))
>      (insert "</div>\n")
>      (insert "<div id=\"inner\">\n"))
2009-07-06 18:10:26 +02:00
Carsten Dominik c1d00fa463 Export: General mechanism for local settings
Many different people want to set many different variables in a
buffer-local way for export.  This cannot be done with file variables,
because the Org buffer is not current while the exporter is running.

Lots of variables can be set with the #+OPTIONS lines, but finding
abbreviations goes only so far.

Therefore we have now a general mechanism that can be used to bind
variables during export operations.

a line like:   #+BIND: variable value

will bind the variable to value.  For example,
the line

>>      #+OPTIONS: toc:nil

can now equivalently be written as

>>      #+BIND: org-export-with-toc nil
2009-07-06 17:00:03 +02:00
Carsten Dominik aa6654c9ce Examples: Untabify before re-inserting into Org
Leaving tabs in the code will mess up indentation in Org.
2009-07-06 16:08:49 +02:00
Carsten Dominik 280f8495ed Plain lists: Allow to force bullet type changes during demotion
Rainer Stengele writes:

> using org-mode for quite some time now I always look at
> operations (key sequences) I repeat a lot of times.
>
> A lot of times I start a list with an item and immediately
> indent the next item as subitem.
>
> From
>
> - item 1
> - subitem 11
>
> I go to
>
> - item 1
>  - subitem 11
>
> via "M-right". Then I always want to change the style of the
> subitem list to "*". I do this via "S-right-right".
>
> I wonder how others work. I would like to automatically have
> changed the subitem list type to "*" as soon as I indent via
> "Alt-right". Next indentation should go back to "-". etc.
>
> Maybe we could introduce a variable that sets the order of
> standard list item types, in my case: "- * - * - * - *" as
> in
>
>
> - item 1
>  * subitem 11
>    - subitem 111
>      * subitem 111
> ...
>
> very special I know but I try to reduce the keypressings as
> much as possible. Any other suggestions?

This commits adds the variable
`org-list-demote-modify-bullet' for this purpose.
2009-07-06 15:38:23 +02:00