Commit Graph

5605 Commits

Author SHA1 Message Date
Bastien Guerry a46f58e7d0 * org.el: Declare external function `cdlatex-compute-tables'.
* org.el (cdlatex-compute-tables): Declare external function
`cdlatex-compute-tables'.
2011-10-22 15:01:02 +02:00
Bastien Guerry 28e5997b26 org-latex.el: Fix problem when matching #+LaTeX_CLASS.
* org-latex.el: (org-export-latex-set-initial-vars): Fix problem when
  matching #+LaTeX_CLASS.

Thanks to Torsten Wagner for spotting this.
2011-10-22 12:07:43 +02:00
Tassilo Horn 4bbdfd229d Replace org-mode-p with usual (eq major-mode 'org-mode) check
Additionally, replace one

  (or (org-mode-p) (derived-mode-p 'org-mode))

with

  (derived-mode-p 'org-mode)

cause that is reflexive anyway (returns true, if the current mode is
org-mode).

Delete one check testing for org-mode or org derived mode
2011-10-22 11:29:24 +02:00
Rafael Laboissiere aa2ebf4f7b Fix typos in variable description
* lisp/org.el (org-link-search-must-match-exact-headline): Fix typos.

TINYCHANGE
2011-10-22 11:15:42 +02:00
Bastien Guerry 8d84173873 org-latex.el (org-export-latex-make-header): Add some hyperref options.
* org-latex.el (org-export-latex-make-header): Add some hyperref
  options.

Thanks to Mikhail Titov for a preliminary version of this patch.
2011-10-22 11:05:28 +02:00
Kai Tetzlaff af0789a5a8 Variable publishing-directory? (resent with patch as attachment)
Bastien <bzg@altern.org> writes:

Hi Bastien,

> The patch looks good but I'd like to understand it better.
> Can you send an example configuration working with your patch?

In org-publish-project-alist, i have HTML publishing projects which
should be published to different target directories depending on e.g.
where emacs is running (which i determine in my init files using the MAC
address of the default GW, the name the machine, ...).

Here is an example: At home, i publish to a local directory
(:publishing-directory "~/tmp/publish-test") but at work i would like to
publish directly to a webserver (:publishing-directory
"/plinkx:doxydoc:~/public_html/publish-test" - this is on w32, using
tramps PuTTY/plink). To avoid having to change the definition of the
publishing project when i change locations i would like to construct the
actual value of :publishing-directory by calling a function:

         ("publishing-dir-test"
         :base-directory "~/Documents/Work/RS"
         :recursive t
         :base-extension "org"
         :exclude-tags ("intern")
         :publishing-directory '(expand-file-name "publish-test" kt:org-default-publishing-dir)
         :publishing-function org-publish-org-to-html)

Depending on the location i'm in, 'kt:org-default-publishing-dir' would
be set to either "~/tmp" or "/plinkx:doxydoc:~/public_html". Without the
patch, the example above does not work as the value of
:publishing-directory does not get evaluated.

> Also, please try to send git patch using these conventions:
> http://orgmode.org/worg/org-contribute.html#sec-5
>
> Thanks a lot!

Thanks for the hint. I've attached a revised version of the patch which
includes a changelog/commit msg - i hope that works for you.

Publish: allow dynamic construction of the publish destination.

* org-publish.el (org-publish-file): Added 'eval'ing the value of the
 :publishing-directory property before using it as destination of the
 publishing project. This allows to construct the publish destination
 directory dynamically at run-time using the return value of a
 function.

TINYCHANGE
2011-10-22 10:41:15 +02:00
Bastien Guerry 989b079dd7 org-agenda.el (org-agenda-list-stuck-projects): Fix tiny bug.
* org-agenda.el (org-agenda-list-stuck-projects): Fix tiny bug.

This bug was introduced by a typo in Michael's patch for XEmacs
compatibility.
2011-10-22 10:13:11 +02:00
Carsten Dominik 0c8b9711a3 Agenda: Add missing option, document time stamp movement to future
* lisp/org-agenda.el (org-agenda-move-date-from-past-immediately-to-today):
New option.
(org-agenda-date-later): Improve the logical structure.

* doc/org.texi (Agenda commands): Document that S-right on a line
representing a past date will immediately shift that date to today.
2011-10-22 08:39:54 +02:00
Carsten Dominik 8d1b48fd5f Merge branch 'master' of orgmode.org:org-mode 2011-10-21 23:32:35 +02:00
Carsten Dominik 54a9cb0d99 Maintain XEmacs compatibility
* lisp/ob-calc.el (featurep): Require calc-store.
* lisp/org-agenda.el (org-agenda-list-stuck-projects): Fix regexp
special handling.
* lisp/org-compat.el (fboundp): Support for XEmacs.
* lisp/org-exp.el (org-export): Protect XEmacs from `(redisplay)' call.
* lisp/org-footnote.el (org-footnote-re): Optimize macro processing.
* lisp/org.el (org-set-autofill-regexps): Xemacs compatibility.

Patch by Michael Sperber, checked and slightly modified by Carsten.
2011-10-21 22:36:53 +02:00
Eric Schulte 93bdeb9212 two more quick fixes
* lisp/ob.el (org-babel-balanced-split): Balance both [] and ()
  groupings.
  (org-babel-parse-header-arguments): Be sure to replace removed ":"
  characters.
2011-10-21 11:36:06 -06:00
Eric Schulte 0bcb248ee6 quick fix for a tiny bug
* lisp/ob.el (org-babel-parse-header-arguments): Quick fix for a tiny bug.
2011-10-21 11:21:39 -06:00
Eric Schulte 4c3d289faf Now allow multiple "var" specifications behind a single ":var"
* lisp/ob.el (org-babel-params-from-properties): Now splits multiple
  var arguments behind a single ":var".
  (org-babel-balanced-split): Separated balanced splitting of strings
  out into a new function.
  (org-babel-parse-multiple-vars): Splits multiple var arguments
  behind a single ":var".
2011-10-21 11:15:18 -06:00
Bastien Guerry f796790779 Merge branch 'master' of orgmode.org:org-mode 2011-10-21 17:57:40 +02:00
Bastien Guerry 5091facd7f org.el: Enable recursive minibuffers in `org-completing-read'.
org.el: (org-completing-read): Enable recursive minibuffers and add
the `C-c !' key in the minibuffer local map.

Thanks to Skip Collins for the idea and to Nick Dokos for the
implementation.
2011-10-21 17:46:37 +02:00
Carsten Dominik a1ebd4e207 Merge branch 'master' of orgmode.org:org-mode 2011-10-21 16:58:01 +02:00
Bastien Guerry b2632dc458 org.el: Remap `outline-promote' and `outline-demote' keys.
* org.el: Remap `outline-promote' and `outline-demote' keys to
`org-promote-subtree' and `org-demote-subtree'.

Thanks to Michael Brand for the suggestion.
2011-10-21 16:21:49 +02:00
Leo 5e67e9d824 Check if marker is valid before use
* lisp/org-agenda.el (org-agenda-do-context-action): Check if marker
is valid before use.
2011-10-21 10:09:40 +02:00
Carsten Dominik 7caa7e1ff7 Fix shifting of data ranges.
* lisp/org-agenda.el (org-agenda-date-later): Fix shifting of date ranges.

Patch based on code by Niels Giesen.
TINYCHANGE
2011-10-21 10:07:02 +02:00
Eric Schulte 080e2decbc removing `org-babel-params-from-buffer' and #+PROPERTIES: entirely
* lisp/ob.el: Removing `org-babel-params-from-buffer' and
  #+PROPERTIES: entirely.
* lisp/ob-exp.el (org-babel-exp-src-block): Removing
  `org-babel-params-from-buffer' and #+PROPERTIES: entirely.
* lisp/ob-lob.el (org-babel-lob-execute): Removing
  `org-babel-params-from-buffer' and #+PROPERTIES: entirely.
2011-10-20 15:26:43 -06:00
Eric Schulte 04a978fde5 removing #+BABEL: lines in favor of general #+PROPERTIES: lines
* lisp/ob.el (org-babel-params-from-buffer): Removing #+BABEL: lines
  in favor of general #+PROPERTIES: lines.

* doc/org.texi (Buffer-wide header arguments): Removing documentation
  of the defunct #+BABEL: structure.
2011-10-20 13:42:31 -06:00
Carsten Dominik 619da643a3 Merge branch 'master' of orgmode.org:org-mode 2011-10-20 09:39:30 +02:00
Eric Schulte 92a01caa6d ob-sql: insert into a temporary buffer
* lisp/ob-sql.el (org-babel-execute:sql): Insert into a temporary
  buffer.
2011-10-19 12:07:48 -06:00
Carsten Dominik d622d2f709 Make sure cdlatex customization is taken into account properly
* lisp/org.el (org-cdlatex-mode): Run cdlatex-mode-hook and update
the internal cdlatex tables.
2011-10-19 18:56:13 +02:00
Eric Schulte faaa881c50 ob-sql returns literal results when requested
* lisp/ob-sql.el (org-babel-execute:sql): Respect literal-results options.
2011-10-18 10:15:04 -06:00
Eric Schulte c1ac640944 fix multi-table bug in code block colname and rowname handling
Thanks to Nick Dokos for suggesting this fix

* lisp/ob.el (org-babel-disassemble-tables): Fix multi-table bug in
  code block colname and rowname handling.
2011-10-18 10:08:48 -06:00
Carsten Dominik 35d924cc80 Fix bug in regexp for #+include
* lisp/org-publish.el (org-publish-cache-file-needs-publishing): Fix regexp
to not inlcude newlines.
2011-10-16 20:00:23 +02:00
Carsten Dominik a9a304d938 Keep byte compiler happy 2011-10-16 16:54:52 +02:00
Carsten Dominik 782a172110 Fix parenthesis error 2011-10-16 16:51:13 +02:00
Carsten Dominik 9a132f3164 Remove table overlays before restart
* lisp/org.el (org-ctrl-c-ctrl-c): Remove table overlays before restart.
2011-10-16 13:38:48 +02:00
Carsten Dominik a9689b8750 Match entities before number, so that \sim2 is fontified correctly
* lisp/org.el (org-fontify-entities): Match entities before numbers, as in
`\sim2'.
2011-10-16 13:23:02 +02:00
Carsten Dominik f20eef318e Agenda: New behaviour when shifting scheduled date forward.
* lisp/org-agenda.el (org-agenda-date-later): Make pushing forward
a past date to jump immedialtely to today.
2011-10-16 11:09:45 +02:00
Carsten Dominik 85cce6fa85 Move some of the new defcustoms to the customization section 2011-10-16 10:57:21 +02:00
Carsten Dominik 2e93c951e5 Parse and store both col align and col width spec for later use
* lisp/org-exp.el (org-store-forced-table-alignment): Parse
the column cookie for both alignment and width specification.
Store the resulting value in `org-col-cookies' property.
Retire the previously used `org-forced-aligns' property for
consistency.  Renamed local variable `aligns' to `cookies'.
* lisp/org-html.el (org-format-org-table-html): Use
`org-col-cookies'.  Renamed local variable forced-aligns to
col-cookies.

This is a preparatory patch.  A backend can look at the colwidth
specification and (at it's discretion) use it to control relative
sizes of individual columns in a table.  At this moment, it is unclear
whether the widths used to control the display of table in Org buffer
can be overloaded to also control the formatting of table in a
backend.

Refer following discussion with Matt Price:
http://lists.gnu.org/archive/html/emacs-orgmode/2011-08/msg01053.html
2011-10-16 10:54:20 +02:00
Carsten Dominik 4f2f222c00 Add support for LaTeX to MathML conversion
* lisp/org.el (org-latex-to-mathml-jar-file)
(org-latex-to-mathml-convert-command): New user-customizable
variables.
(org-format-latex-mathml-available-p, org-create-math-formula)
(org-format-latex-as-mathml): New functions.
(org-format-latex): Add a new local variable block-type that
notes the nature of the equation - inline or display.
Associate it's value to `org-latex-src-embed-type' property of
dvipng links.  Add mathml as new processing type.

Patch by Jambunathan.
2011-10-16 10:52:32 +02:00
Sébastien Vauban 05ead2de3b Rebase: Add tree name to prompt
* lisp/org.el (org-refile): Add tree name to prompt.
2011-10-14 11:20:35 +02:00
Carsten Dominik 54d7df6774 Make it possible to place table captions below the table
* lisp/org-latex.el (org-export-latex-tables): Honor
`org-export-latex-table-caption-above'
(org-export-latex-table-caption-above): New option.

Patch by Thomas Dye.
2011-10-10 21:05:03 +02:00
Eric Schulte 3e86300d6d now including language specific header arg values in insertion options
* lisp/ob.el (org-babel-insert-header-arg): Now including language
  specific header arg values in insertion options.
2011-10-09 09:31:32 -06:00
Eric Schulte d7d0230bf4 Fixed typo in org-babel-insert-header-arg.
Thanks to Torsten Wagner for pointing this out and for suggesting
  the original feature.

* lisp/ob.el (org-babel-insert-header-arg): Fixed typo.
2011-10-09 09:11:10 -06:00
Carsten Dominik 9bd1c338a0 Merge branch 'master' of orgmode.org:org-mode 2011-10-09 13:17:58 +02:00
Jambunathan K f8cd4a3793 org-odt help
> I would like to submit 2 more patches - one to the manual and other to
> org-exp.el.

I am attaching the promised patch to org-exp.el. Can someone review and
commit this change?

Please note that I have withheld the changes to org-odt & co which make
use of this change.

ps: The patch to org.texi will follow soon - maybe in a day or two.

>From 39ab2a263336ba077c7cd6627a3203c55c5bddba Mon Sep 17 00:00:00 2001
From: Jambunathan K <kjambunathan@gmail.com>
Date: Tue, 4 Oct 2011 23:32:35 +0530
Subject: [PATCH] org-exp.el: Enhance `org-export-number-lines' to support odt export

* lisp/org-exp.el (org-export-number-lines): Modified.  Add a
new parameter `preprocess' and use this for backend-agnostic
handling of literal examples.

This parameter is currently exercised only by the odt exporter.  Hint:
See future commits.
2011-10-09 13:17:08 +02:00
Nicolas Goaziou 8e358f2cef Allow subscripts and superscripts to start at bol
* lisp/org.el (org-match-substring-regexp,
  org-match-substring-with-braces-regexp): Allow subscripts and
  superscripts to start at beginning of line.
2011-10-09 09:35:27 +02:00
Eric Schulte 4a7dd1e087 binding new code block header argument helper function to C-c C-v h 2011-10-08 16:38:32 -06:00
Eric Schulte 9135ec76dd New helper function for inserting common code block header arguments
* lisp/ob.el (org-babel-common-header-args-w-values): New variable to
  hold common header arguments and their default values.
  (org-babel-header-arg-names): Redefined using the new common header
  arg variable.
  (org-babel-insert-header-arg): New function to help when inserting
  header arguments.
2011-10-08 16:31:50 -06:00
David Maus 85d0a9fc05 Remove unnecessary protection markers
* org-html.el (org-html-handle-links): Remove unnecessary protection
markers when publishing link in default format.

Left-over from the mess that was 7.5's HTML export.
2011-10-08 21:18:57 +02:00
Pieter Praet 7e5c0263fc org-crypt: when running `org-decrypt-entry', only run `auto-save-mode' check if on an encrypted entry
* lisp/org-crypt.el (org-crypt-check-auto-save): New function, see next change.
* lisp/org-crypt.el (org-decrypt-entry): Break the auto-save-mode check out
  into a separate function, and call it at a later point, to assure it only
  runs when visiting an encrypted entry.

Currently `org-decrypt-entry' is doing the auto-save-mode check whenever
it's run, regardless of context, while this only makes sense when run on
an entry which is actually encrypted (or looks like it, at least).

TINYCHANGE
2011-10-08 18:10:37 +02:00
John J Foerch a5d4783a7e Short timestamp in org-log-note-headings
Two new format codes support insertion of a short-format time stamp.
%d for an inactive time stamp, and %D for an active one.

* lisp/org.el (org-log-note-headings): Document new %d and %D escapes.
(org-store-log-note): Implement new %d and %D escapes.

TINYCHANGE
2011-10-08 17:55:17 +02:00
niels giesen a6d74af2b9 Continue numbering from any previous numbered snippet with +n, even when previous numbered snippet does not immediately precede it.
* org-mode/lisp/org-exp.el (org-export-number-lines):

  Check whether number parameter (this is a numbered block!) is
  non-nil as well as whether cont is nil (this numbered block should
  *not* continue numbering where we left off before!) before resetting
  the count to zero.

  From the docs:

    If you use a `+n' switch, the numbering from the previous
    numbered snippet will be continued in the current one.

  With this change I believe the code complies with the docs.
2011-10-08 16:30:56 +02:00
Carsten Dominik 468aa115ef Merge branch 'master' of orgmode.org:org-mode 2011-10-08 09:02:36 +02:00
Dave Abrahams e53f62eba9 Add indirect agenda follow mode
* lisp/org-agenda.el (org-agenda-follow-indirect): New option.
(org-agenda-follow-mode): Call `org-agenda-do-context-action' fro
follow mode.
(org-agenda-do-context-action): Also do indirect follow mode action.

By setting `org-agenda-follow-indirect' to a non-nil value,
`org-agenda-follow-mode' will use an indirect buffer to display only
the current item, rather than the whole agenda file in which it lives
2011-10-08 09:01:50 +02:00
Eric Schulte 32a6752267 fix typo in new sbe specification
* lisp/ob-table.el (sbe): Fix typo in new sbe specification.
2011-10-07 12:22:04 -06:00
Eric Schulte 75e65de150 sbe now allows specification of header arguments
* lisp/ob-table.el (sbe): If first variable is a string and not a cons
  cell, then interpret it as a string of header arguments to be passed
  to the code block.
2011-10-07 12:18:00 -06:00
Eric Schulte 623dd10c96 ob-shen: fix build error
* lisp/ob-shen.el (shen-eval-defun): Declare external function.
  (org-babel-execute:shen): Move requirement of inf-shen into the
  function in which it is used to fix build error.
2011-10-07 09:09:49 -06:00
Eric Schulte 53573d6e28 adding initial support for evaluation of shen code blocks 2011-10-06 19:55:47 -06:00
Carsten Dominik 5147f6b008 Make org-open-at-point only ask once whether new header should be created
* lisp/org.el (org-open-at-point): Make org-open-at-point only ask once
about creating a new headline

When following "thisfile" links org-open-at-point is kind enough to
retry org-link-search again after widening the buffer it can't be
found. However org-link-search also asks the question "No match -
create this as a new heading? (y or n)" when target can't be
found. This means that the question is asked twice when following a
nonexistent link and answering no.

This is fixed by setting org-link-search-inhibit-query in first try,
so only second invocation asks the question.

TINYCHANGE

Patch by Anders Waldenborg
2011-10-06 10:53:31 +02:00
Nick Dokos 1d65423da8 Bug: org-refile-targets doesn't say whether it's AND or OR [7.7 (release_7.7.351.gb8b5)]
Dave Abrahams <dave@boostpro.com> wrote:

> I would change the doc for org-refile-targets to say that the resulting
> list of targets is the union of all the targets matched by each cons
> cell.  I think you could take that pretty much verbatim.
>

How's this?

Nick

---------------------------------------------------------------------------
>From f853b04fb474493b3b7b8857794c9f120c5f7822 Mon Sep 17 00:00:00 2001
From: Nick Dokos <nick@dokosmarshall.org>
Date: Wed, 28 Sep 2011 23:49:13 -0400
Subject: [PATCH] Amplify the doc for org-refile-targets

* lisp/org.el: (org-refile-targets) Elaborated the documentation of
               the variable as suggested by Dave Abrahams.

TINYCHANGE
2011-10-06 10:13:05 +02:00
Carsten Dominik 2978501ad0 Bugfix for alignment of tag next to header name
* lisp/org.el (org-align-tags-here): Allow tags to be placed right
after heading.
(org-tags-column): Document the meaning of tags column 0.

Patch by Michael Brand.

TINYCHANGE
2011-10-06 09:44:08 +02:00
niels giesen 3d83564b7d Time range end in agenda view not displayed
Giovanni Ridolfi <giovanni.ridolfi@yahoo.it> writes:

> michael holzer <michi_holzer_news@gmx.at> writes:
>
>> When I have an entry that contains a time range, for example:
>>
>> * timerange
>>   <2011-09-30 Fri 14:00>--<2011-09-30 Fri 18:00>
>>
>> this shows up in the agenda view as:
>>
>>   uni:        14:00...... timerange
>>
>> while I would expect something like:
>>
>>   uni:        14:00-18:00 timerange
>>
>
> |the manual says:
> |Time ranges can be specified with two timestamps,
> |like ‘<2005-05-10 Tue 20:30>--<2005-05-10 Tue 22:15>’.
> |
> | 20:30-22:15 Marvin escorts the Hitchhikers to the bridge
>
> I confirm this bug.
>
> Org-mode version 7.7 0e9d401519
> GNU Emacs 23.3.1 (i386-mingw-nt5.1.2600) of 2011-03-10 on 3249CTO
>
> Giovanni
>
>

Funny enough, I noticed this too last week, so I whipped up this patch.
It inserts the range when start date is the same as the end date. Please
test (it's still young) && include in Org if you so please.

#+begin_src diff
>From dcf81753aa5cab311f2a3a0272e4691e4bc6ea38 Mon Sep 17 00:00:00 2001
From: Niels Giesen <niels.giesen@gmail.com>
Date: Mon, 26 Sep 2011 11:43:55 +0200
Subject: [PATCH] Show timestamp ranges in agenda

* lisp/org-agenda.el (org-agenda-get-blocks): Show timestamp ranges in
  agenda if start day is same as end day
2011-10-05 16:46:18 +02:00
Carsten Dominik 1790d6c073 Make org-refile interface for jumping to a target work before first heading
* lisp/org.el (org-refile-get-location): Ignore errors when
collection heading to be excluded.
2011-10-05 16:23:03 +02:00
Carsten Dominik ee3a68216b Revert "Avoid XHTML strict problems by not enclosing special blocks in paragraph tags"
This reverts commit 4e3cc81a2e.
2011-10-04 23:31:43 +02:00
Carsten Dominik 4e3cc81a2e Avoid XHTML strict problems by not enclosing special blocks in paragraph tags
* lisp/org-special-blocks.el (org-special-blocks-convert-html-special-cookies):
Avoid XHTML strict problems by not enclosing special blocks in
paragraph tags.
2011-10-04 16:22:27 +02:00
Bernt Hansen 106993d310 Check argument is a string before calling string-match
* lisp/org-html.el (org-export-as-html): Check string-match argument
(org-html-handle-time-stamps): Check string-match argument

Avoid wrong-type-argument errors during exporting.
2011-10-04 14:35:33 +02:00
Carsten Dominik aefd49b909 Change default value of `org-agenda-skip-additional-timestamps-same-entry'
* lisp/org-agenda.el (org-agenda-skip-additional-timestamps-same-entry):
Change default value.
2011-10-04 14:30:32 +02:00
Carsten Dominik 620913e596 Improve error reporting on bad time stamps during agenda construction
* lisp/org.el (org-time-string-to-time):
(org-time-string-to-absolute): Add optional arguments BUFFER and POS
for error reporting.
* lisp/org-agenda.el (org-get-all-dates):
(org-agenda-get-timestamps):
(org-agenda-get-deadlines):
(org-agenda-get-scheduled):
(org-agenda-get-blocks): Call time stamp parsing functions with
information on where the timestamp was taken from.
2011-10-04 14:12:11 +02:00
Carsten Dominik a33fc1ce7d Fix typo in previous commit 2011-10-04 10:00:10 +02:00
Carsten Dominik 3268d3b48f Run `org-cycle-hook' after `show-all' in indirect buffer
* lisp/org.el (org-tree-to-indirect-buffer): Run `org-cycle-hook' after `show-all'
in indirect buffer.
2011-10-04 09:57:02 +02:00
Nicolas Goaziou 809318dd5b Better handling of ill-formed lists
* lisp/org-list.el (org-list-parents-alist): When no parent is found
  for an item, set it as the closest less indented item above.  If
  none is found, make it a top level item.
(org-list-write-struct): Externalize code.
(org-list-struct-fix-item-end): New function.
(org-list-struct): Remove a now useless fix.
* lisp/org.el (org-ctrl-c-ctrl-c): Use new function.
2011-10-02 23:17:11 +02:00
Nicolas Goaziou 824e06752b `org-special-ctrl-a/e' effectively behaves specially on items
* lisp/org.el (org-end-of-line): When on an item, move point at the
  end of the line, but before any hidden text.  Thus, it's still
  possible to use commands, like C-c C-c, acting at items.  This is
  still disabled if `org-special-ctrl-a/e' ignores C-e.
2011-10-01 20:37:16 +02:00
Nicolas Goaziou 0fff59cd43 org-footnote: Small refactoring
* lisp/org-footnote.el (org-footnote-renumber-fn:N): Small
  refactoring.
2011-10-01 08:57:33 +02:00
Nicolas Goaziou 0e9d401519 org-footnote: Fix an infloop
* lisp/org-footnote.el (org-footnote-renumber-fn:N): Fix an infloop
  introduced by commit 1effad02be.
2011-09-29 22:53:45 +02:00
Nicolas Goaziou a77117ba80 org-footnote: Remove useless org-re
* lisp/org-footnote.el (org-footnote-at-definition-p): remove useless
  org-re.
2011-09-29 22:44:58 +02:00
Nicolas Goaziou 1effad02be org-footnote: Only renumber real footnotes references or definitions
* lisp/org-footnote.el (org-footnote-renumber-fn:N): Verify point is
  at a real footnote reference or definition before renumbering it.
2011-09-29 22:34:15 +02:00
Tassilo Horn 2e2bd083da Fix renumbering for footnotes at BOL.
Hi all,

org-footnote-renumber-fn:N invalidates footnotes that appear as the
first thing on a line.  Here's a test file including the recipe.

--8<---------------cut here---------------start------------->8---
* Bla

  This is a line in which the following footnote that is inserted exactly
  [fn:1] is the first thing in that line.  And now invoke
  org-footnote-renumber-fn:N and see it breaking.

* Footnotes

[fn:1] Test
--8<---------------cut here---------------end--------------->8---

Note, that in larger org files, it's likely that you don't even notice
that the footnotes break.

Once I added a patch on patchwork that fixed this issue, and that's
shown as "accepted".

  http://patchwork.newartisans.com/patch/705/

I think, I've marked it as deferred or so myself because I've thought
the issue was fixed in the meantime, but that doesn't seem to be true.

Here's an updated patch.
2011-09-29 15:55:30 +02:00
Nicolas Goaziou c00fe037be org-footnote: Don't offer to create a footnote when it already exists
* lisp/org-footnote.el (org-footnote-goto-definition): This patch
  makes sure the function says when a definition has been found.
  Thus, moving from the reference to the definition doesn't offer to
  create the latter again.
2011-09-29 15:30:46 +02:00
Nicolas Goaziou c7abf641eb org-footnote: fix commit 774f9cb8e6
* lisp/org-footnote.el (org-footnote-create-definition): Explicitely
  move point after tag, if it has just been inserted.
2011-09-29 15:20:34 +02:00
Eric Schulte dec0b8e975 gnuplot, don't quote file names on Windows systems
Thanks to Alex Vorobiev for suggesting this change

* lisp/ob-gnuplot.el (org-babel-execute:gnuplot): Don't quote file
  names on Windows systems.
2011-09-29 06:54:49 -06:00
Nicolas Goaziou 774f9cb8e6 org-footnote: ensure footnote tag is inserted after footnotes in non-Org buffers
* lisp/org-footnote.el (org-footnote-create-definition): When the tag
  is missing, it is created before any existing footnote, or at end of
  buffer.  In the latter case, the marker pointing at the position
  where the new footnote is going to be inserted (at end of buffer)
  stays before the tag.  This patch makes sure that the marker will be
  kept after the tag.
2011-09-28 19:07:38 +02:00
Eli Zaretskii 1a97f29c34 Force left-to-right paragraphs in Org buffers.
* org.el (org-mode): Force left-to-right paragraphs in Org
buffers.  For a related discussions, see
https://lists.gnu.org/archive/html/emacs-devel/2011-09/msg00349.html.
2011-09-27 19:33:09 +02:00
Nicolas Goaziou e9ce64c8bb ob-asymptote: silence byte-compiler
* lisp/ob-asymptote.el (org-babel-asymptote-define-type): silence byte-compiler.
2011-09-25 16:19:27 +02:00
John Wiegley 706de59f07 Fixed an incorrect paren placement 2011-09-24 12:06:25 -05:00
Eric Schulte ad21eeff85 fix bug in R session evaluation
* lisp/ob-R.el (org-babel-R-evaluate): Fix bug in R session
  evaluation.
2011-09-21 09:10:21 -06:00
John Wiegley 0c09937069 New vars: org-habit-today-glyph, org-habit-completed-glyph 2011-09-21 04:09:49 -05:00
Eric Schulte 4fbefd87aa configurable property name for bibtex entry types
* lisp/org-bibtex.el (org-bibtex-type-property-name): Configurable
  property name for bibtex entry types.
  (org-bibtex-headline): Use new configurable property name.
  (org-bibtex-check): Use new configurable property name.
  (org-bibtex-create): Use new configurable property name.
  (org-bibtex-write): Use new configurable property name.
2011-09-20 09:20:53 -06:00
Bastien Guerry fcdbb5e6c9 org.el (org-paste-subtree): Remove useless (concat ...).
* org.el (org-paste-subtree): Remove useless (concat ...).

See change from Stefan Monnier here:
https://lists.gnu.org/archive/html/emacs-diffs/2011-09/msg00224.html
2011-09-20 08:38:34 +02:00
Eric Schulte 1b11c7e6a0 replacing usage of characterp with integerp (which should work w/Emacs22)
* contrib/babel/langs/ob-fortran.el (org-babel-fortran-var-to-fortran):
  Replacing usage of characterp with integerp (which should work w/Emacs22).
* lisp/ob-C.el (org-babel-C-var-to-C): Replacing usage of characterp
  with integerp (which should work w/Emacs22).
2011-09-17 14:52:29 -06:00
Nicolas Goaziou 1e1cde7546 org-footnote: check context around definition at a proper place
* lisp/org-footnote.el (org-footnote-at-definition-p): Context must be
  valid at the beginning of line, not at point.
2011-09-17 12:01:54 +02:00
Eric Schulte 647849dff9 better delimiting of Org-mode text preceding a code block
Thanks to Christopher Genovese for this change

* lisp/ob-tangle.el (org-babel-tangle-collect-blocks): Better
  delimiting of Org-mode text preceding a code block.
2011-09-16 09:52:34 -06:00
Eric Schulte 6844094edb Don't delete variable values when checking for assignment.
* lisp/ob.el (org-babel-get-src-block-info): Fixing bug, accidentally
  deleted variable values.
2011-09-16 09:52:34 -06:00
Eric Schulte b9922ba879 customizable processing of Org-mode text used as comments in tangled source-code files
* lisp/ob-tangle.el (org-babel-process-comment-text): Customizable
  function to process comment text.
  (org-babel-tangle-collect-blocks): Make use of new customizable
  processing function.
  (org-babel-spec-to-string): Call customizable function rather than
  `org-babel-trim'.
2011-09-16 09:52:34 -06:00
Eric Schulte 65d05b00b0 ob-R: don't process output when "scalar" or "verbatim"
* lisp/ob-R.el (org-babel-execute:R): Collect and pass along the
  result-params.
  (org-babel-R-evaluate): Accept result-params and if "scalar" or
  "verbatim" don't process output.
  (org-babel-R-evaluate-session): Accept result-params and if "scalar"
  or "verbatim" don't process output.
2011-09-15 15:43:35 -06:00
Eric Schulte 267015b24a differentiate between result types and wrappers
* lisp/ob.el (org-babel-merge-params): Differentiate between result
  types and wrappers.
2011-09-15 15:22:14 -06:00
Eric Schulte 11f07576cb Check that functional-syntax variables are initialized.
* lisp/ob.el (org-babel-get-src-block-info): Check that
  functional-syntax variables are initialized.
2011-09-15 09:24:29 -06:00
Eric Schulte f075ada9a1 Adding a note for a future enhancement.
* lisp/ob.el (org-babel-check-src-block): Adding a note for a future
  enhancement.
2011-09-15 09:11:12 -06:00
Carsten Dominik 11dec73c0c Merge branch 'master' of orgmode.org:org-mode 2011-09-14 08:54:53 +02:00
Carsten Dominik a3c3ff3fde Restore point when exporting a subtree
* lisp/org-exp.el (org-export): Restore point when exporting a subtree.
2011-09-14 07:48:49 +02:00
Eric Schulte 0037ef9261 more robust to code blocks with empty bodies
* lisp/ob.el (org-babel-parse-src-block-match): More robust to code
  blocks with empty bodies.
2011-09-13 09:36:03 -06:00
Eric Schulte 597e1eb4fe Don't error on empty code block body.
* lisp/ob.el (org-babel-parse-src-block-match): Don't error on empty
  code block body.
2011-09-13 08:57:29 -06:00
David Maus 4122a51366 Unescape plain link before open
* org.el (org-open-at-point): Unescape plain link.

This should fix a problem with open plain links reported by
Sebastien Vauban.
2011-09-11 16:51:23 +02:00
David Maus 5a373f649e Remove unnecessary link unescape
* org-html.el (org-html-handle-links): Remove unnecessary link
unescape.

PATH is already unescaped and should never be escaped twice. Big
thanks to Jambunathan K for analyzing the problem.
2011-09-11 16:50:43 +02:00
Bastien Guerry 28ae6b4de1 Revert "org.el (org-fixup-indentation): Correctly indent meta lines."
This reverts commit 6b04befa48.
2011-09-09 19:47:41 +02:00