Commit Graph

6606 Commits

Author SHA1 Message Date
Bastien Guerry 035ab39e63 Another fix to `org-indent-line-function'.
* org.el (orgstruct++-mode): Fix docstring.
(org-fill-paragraph): Use the 'justify parameter when falling
back on `fill-paragraph'.
2012-05-07 01:39:49 +02:00
Matt Lundin d59762b6fa Don't call org-footnote-unique label if using random labels
* lisp/org-footnote.el (org-footnote-new): Don't call
  org-footnote-unique-label if org-footnote-auto-label is set to
  random.

Calling org-footnote-unique-label calls org-footnote-all-labels, which
can dramatically slow down footnote creation in a buffer with many
footnotes.  This is unecessary if org-footnote-auto-label is set to
random.
2012-05-06 10:10:25 +02:00
Bastien Guerry 99c97fbffc Fix bug in `org-indent-line-function'.
* org.el (org-indent-line-function): Use `org-let' instead of
`orgstruct++-ignore-org-filling'.
(org-fill-paragraph, org-auto-fill-function): Ditto.

* org-macs.el (orgstruct++-ignore-org-filling): Delete.
2012-05-06 09:37:14 +02:00
Bastien Guerry 8fb20b7f93 org-table.el: handle =02:34;t durations formula correctly.
* org-table.el (org-table-time-string-to-seconds): Return the
empty string if provided.
(org-table-eval-formula): When assigning a duration string,
handle it correctly -- i.e. don't make any computation on it,
except the one to insert it using the correct duration format.

Thanks to Sébastien Vauban for spotting this.
2012-05-05 16:14:33 +02:00
Bastien Guerry 73ec767458 org.el (org-indent-line-function): Fix bug.
* org.el (org-indent-line-function): Fix bug.

Don't fall back systematically on `org-fb-vars' to do
the indentation.  Only fall back at then end, when no
modification has been done by indenting a la Org.  In
that case, use `indent-according-to-mode' instead of
using `indent-line-function' to avoid a possible loop.

Thanks to Eric Fraga, Christopher Schmidt and Nicolas
Goaziou who reported problems with this.
2012-05-05 15:32:19 +02:00
Bastien Guerry 7c513b3047 New option `org-clock-frame-title-format'.
* org-clock.el (org-frame-title-format-backup): New variable
to store the value of `frame-title-format' before `org-clock'
might replace it by `org-clock-frame-title-format'.
(org-clock-frame-title-format): New option.
(org-frame-title-string): Delete.
(org-clock-update-mode-line): Minor code reformatting.
(org-clock-in, org-clock-out, org-clock-cancel): Use
`org-clock-frame-title-format'.

See http://thread.gmane.org/gmane.emacs.orgmode/55477

Trying to update `frame-title-format' is tricky and error-prone, since
users can set up this variable in many different ways.  AFAIK there is
no equivalent to `global-mode-string' for setting the frame title, we
would use it otherwise.

The user can still configure `org-clock-frame-title-format' the way he
wants.
2012-05-05 14:21:13 +02:00
Bastien Guerry 005576f0b6 org-clock.el (org-clock-get-clock-string): Add a space.
* org-clock.el (org-clock-get-clock-string): Add a space.
2012-05-05 11:30:58 +02:00
Bastien Guerry c465c7bdf0 org-list.el: Return an error when there is no list at point.
* org-list.el (org-mark-list): Return an error when there is
no list at point.
2012-05-05 10:52:57 +02:00
Bastien Guerry 75e1c141f8 org.el: Allow `C-u C-c *' to toggle headings in the whole list at point.
* org.el (org-toggle-heading): Allow `C-u C-c *' to mark the
list at point before converting items to headings.  With a
simple universal-argument, set `current-prefix-arg' to 1,
otherwise keep the numeric value.
2012-05-05 10:50:07 +02:00
Bastien Guerry e508b497a3 org-agenda.el (org-agenda-view-mode-dispatch): message more readable.
* org-agenda.el (org-agenda-view-mode-dispatch): Make the
message more readable.
2012-05-05 09:57:30 +02:00
Bastien Guerry 405eae0497 Fix small typo and rearrange some parentheses. 2012-05-05 09:49:12 +02:00
Bastien Guerry 39204efe9a New command `org-agenda-bulk-mark-all' bound to `*'. Other minor enhancements.
* org-agenda.el (org-agenda-mode-map): New keybinding ̀*' to
mark all entries for bulk action.
(org-agenda-menu): New menu item for marking all entries.
(org-agenda-bulk-mark-all): New function to mark all entries.
(org-agenda-bulk-mark-regexp): Minor docstring fix.
(org-agenda-bulk-unmark): With a prefix argument, unmark all.
Also send a better message.
(org-agenda-bulk-remove-all-marks): Rename to
`org-agenda-bulk-unmark-all'.  Check against
`org-agenda-bulk-marked-entries' before trying to unmark
entries.  Minor docstring fix.
(org-agenda-bulk-unmark-all): Renamed from
̀org-agenda-bulk-remove-all-marks'.
2012-05-05 09:21:22 +02:00
Bastien Guerry a16814a475 New option ̀org-agenda-bulk-mark-char'.
* org-agenda.el (org-agenda-bulk-mark-char): New option.
(org-agenda-bulk-mark): Use the new option.
2012-05-05 09:07:37 +02:00
Bastien Guerry 578a7f5aa5 New option `org-src-prevent-auto-filling' defaulting to nil.
* org.el (org-src-prevent-auto-filling): New option to prevent
auto-filling in src blocks.  This defaults to nil to avoid people
being surprised that no auto-fill occurs in Org buffers where they
use `auto-fill-mode'.
(org-auto-fill-function): Use the new option.

Thanks to Ken Williams for this feature request and to Charles
C. Berry for a preliminary patch for this.
2012-05-05 08:13:43 +02:00
Mark E. Shoulson 61653a2c01 org.el (org-fontify-entities): Hide {} when prettifying entities.
* org.el (org-fontify-entities): Hide {} when prettifying
entities.

TINYCHANGE
2012-05-05 08:07:26 +02:00
Bastien Guerry e7dda77691 Fix `org-set-property'.
* org.el (org-properties-postprocess-alist): Better
customization type.
(org-set-property): Fix the check against
`org-properties-postprocess-alist'.

Thanks to Bill Wishon for testing/spotting this.
2012-05-04 23:58:55 +02:00
Eric Schulte dec32064a7 adding commented out code which should be activated once org-element has been merged
Used to clean up orphaned keywords of blocks removed by
  org-export-blocks-preprocess.
2012-05-04 09:17:36 -04:00
Bastien Guerry ecd4079f0e org-macs.el (orgstruct++-ignore-org-filling): Set `def-edebug-spec' correctly.
* org-macs.el (orgstruct++-ignore-org-filling): Set
`def-edebug-spec' correctly.
2012-05-03 16:44:17 +02:00
Bastien Guerry 3c34028497 Merge branch 'maint' 2012-05-01 19:19:16 +02:00
Bastien Guerry 0dbe17b8e0 org-table.el: Fix bug about handling a negative duration value.
* org-table.el (org-table-time-seconds-to-string): Fix bug
about handling a negative duration value.
2012-05-01 19:19:06 +02:00
Bastien Guerry 805891523c Fix bugs about computing durations in the column view.
* org-colview.el (org-columns-string-to-number): When
computing the values for the colview, match durations and
convert them to HH:MM values.

* org.el (org-duration-string-to-minutes): Match non-round
numbers.  Add a new optional parameter to allow returning the
output as a string.

Thanks to Sébastien for reporting these bugs.
2012-05-01 17:47:13 +02:00
Bastien Guerry 9f3b35a114 Merge branch 'fix-orgstruct' 2012-05-01 15:56:12 +02:00
Bastien Guerry a8c3125a14 Rework `orgstruct++-mode' so that you can turn if off safely.
* org.el (org-auto-fill-fallback-function)
(org-indent-line-fallback-function)
(org-fill-paragraph-fallback-function)
(org-auto-fill-fallback-function)
(org-indent-line-fallback-function)
(org-fill-paragraph-fallback-function): Remove.
(org-fb-vars): New buffer-local variable.
(orgstruct++-mode): Use the fallback variable `org-fb-vars' to
store, use and restore variables if needed.
(org-fill-paragraph): Ignore `orgstruct++-mode' filling
variables when needed.
(org-auto-fill-function, org-indent-line-function): Ditto.

* org-macs.el (orgstruct++-ignore-org-filling): New macro.
2012-05-01 15:55:41 +02:00
Nicolas Goaziou 39fc2c445a Merge branch 'maint' 2012-05-01 15:33:36 +02:00
Nicolas Goaziou eed9350ed9 * lisp/org.el (org-link-expand-abbrev): Fix docstring 2012-05-01 15:32:46 +02:00
Nicolas Goaziou b9d98cf926 * lisp/org.el (org-translate-link): Fix bug 2012-05-01 15:32:04 +02:00
Feng Shu be1727a68f Using 'call-process to launch latex program
* org.el (org-create-formula-image-with-imagemagick): Use 'call-process
to launch latex so that no shell output buffer will be shown when previewing
formulas.
2012-05-01 13:03:43 +02:00
Feng Shu 24dff8f067 spelling fixes
* org.el (org-create-formula-image-with-imagemagick): Fix typo.
2012-05-01 13:03:39 +02:00
Bastien Guerry bf5b4012e9 Use compatibility function for XEmacs.
* lisp/org-exp-block.el: Use `org-find-library-name' instead of `find-library-name'.
2012-05-01 10:40:19 +02:00
Bastien Guerry b3f60f791e Convert compatibility defun to a macro.
* lisp/org-compat.el (org-find-library-name): Convert into a macro to
  avoid compilation of a function from XEmacs in Emacs and vice versa.

Based on a not fully working proposal by A. Gratz to the orgmode
mailing list:
http://lists.gnu.org/archive/html/emacs-orgmode/2012-04/msg00009.html
2012-05-01 10:40:15 +02:00
Bastien Guerry e5c8780e5c Merge branch 'maint' 2012-05-01 10:04:46 +02:00
Bastien Guerry adb10d1543 org-agenda.el (org-agenda-bulk-mark-regexp): Fix bug.
* org-agenda.el (org-agenda-bulk-mark-regexp): Fix bug when
setting the number of marked entries.
2012-05-01 10:04:31 +02:00
Bastien Guerry 8342fdb70a org-table.el: Fix bug in ̀org-table-maybe-eval-formula'.
* org-table.el (org-table-store-formulas): Fix typo.
(org-table-maybe-eval-formula): Fix the regexp to only match
formulas, which never end with the `=' character.  If the
field only contain this character, don't eval either.

Thanks to Thomas S. Dye for reporting this.
2012-05-01 02:03:12 +02:00
Bastien Guerry 1f663e7ab3 Merge branch 'maint' 2012-05-01 01:42:17 +02:00
Bastien Guerry 3053c13d2c org-table.el: Fix bug in a free variable name.
* org-table.el (org-tbl-calc-modes): Rename from
`org-table-modes'.
(org-set-calc-mode, org-table-eval-formula): Use it.

Thanks to Mikkel Kristiansen for reporting this and
to Nick Dokos for tracking down the bug and proposing
a fix.
2012-05-01 01:41:50 +02:00
Bastien Guerry 237c65b1f7 org.el: Fix `org-diary' again by checking `org-agenda-buffer' correctly. 2012-04-30 00:04:20 +02:00
Bastien Guerry 491ce5491d org.el (org-set-property): Minor enhancement.
* org.el (org-set-property): Perform the correct check against
`org-properties-postprocess-alist'.

Thanks to Bill Wishon for spotting this.
2012-04-29 18:07:24 +02:00
Bastien Guerry 9604f522fc org-bbdb.el: Enhance a customization type and suppress (defvar name).
* org-bbdb.el (org-bbdb-anniversary-format-alist): Update the
customization type.
(name): Suppress (defvar 'name) as name is not eval'ed when
setting `org-bbdb-anniversary-format-alist'.
2012-04-29 17:00:16 +02:00
Bastien Guerry 6732d633af Make (org-version) always returns a string, use it in exporters.
* org.el (org-version): When called non-interactively, insert
the short version string, otherwise send a message with the
complete version string.

* org-odt.el (org-odt-update-meta-file): Use (org-version) and
delegate checking whether `org-version' is known as a variable
there.

* org-html.el (org-export-as-html): Use (org-version).

* org-docbook.el (org-export-as-docbook): Ditto.

* org-latex.el (org-export-latex-make-header): Ditto.
2012-04-29 12:17:00 +02:00
Eric Schulte 4eb4010a97 Merge branch 'origin-maint'
Conflicts:
	lisp/ob.el
2012-04-28 18:03:23 -04:00
Bastien Guerry c306dbe388 org-clock.el: Fix bug in `org-clocktable-write-default'.
* org-clock.el (org-clocktable-write-default): Temporarily
disable `delete-active-region' so that we don't accidently
delete an active region when exporting a subtree/region.

Thanks to Mike McLean for the detailed bug report.
2012-04-29 01:18:35 +02:00
Eric Schulte 604a55edd6 fixes a bug finding empty named results
* lisp/ob.el (org-babel-find-named-result): Fix bug finding empty
  named results.
2012-04-28 18:02:13 -04:00
Bastien Guerry 008689cc79 org-clock.el: Use `executable-find' instead of `org-program-exists'.
* org-clock.el (org-program-exists): Remove.
(org-show-notification, org-clock-play-sound): Use
`executable-find' instead of `org-program-exists'.

Thanks to Sébastien Vauban for pointing this.
2012-04-28 23:43:10 +02:00
Bastien Guerry 0678e0e359 Merge branch 'master' of orgmode.org:org-mode 2012-04-28 23:35:01 +02:00
Bastien Guerry d7dfe9fd69 org-table.el: Fix `org-table-store-formulas'.
The bug was introduced by this commit:
http://orgmode.org/w/?p=org-mode.git;a=commit;h=1c203d

Thanks to Matt Lundin who reported this nasty/stupid bug.
2012-04-28 23:34:51 +02:00
Nicolas Goaziou f9d4069033 Merge branch 'maint' 2012-04-28 22:37:23 +02:00
Nicolas Goaziou 7f2e22339c Fix `org-planning-or-clock-line-re' regexp
* lisp/org.el (org-set-regexps-and-options): Fix
  `org-planning-or-clock-line-re' regexp.  Indeed "\\>" will never
  match since time keywords must end with colons, which are not word
  constituent.
2012-04-28 22:34:36 +02:00
Bastien Guerry 982b7b972f Merge branch 'fix-org-diary-bug' into fix-compiler-warnings 2012-04-28 22:23:40 +02:00
Bastien Guerry 4b8359a395 org-agenda.el: Prevent org-diary to fail.
* org-agenda.el (org-diary): Prevent failure from
`org-compile-prefix-format' when there is no agenda buffer.

Thanks to Rafael who reported this.
2012-04-28 22:23:08 +02:00
Bastien Guerry c5f73635d0 Replace obsolete variable `buffer-substring-filters'.
* org-agenda.el (org-agenda-mode): Replace obsolete variable
`buffer-substring-filters'.

* org-indent.el (org-indent-mode): Ditto.
2012-04-28 21:36:58 +02:00