1
0
mirror of https://git.savannah.gnu.org/git/emacs/org-mode.git synced 2024-11-25 07:27:57 +00:00
Commit Graph

10856 Commits

Author SHA1 Message Date
Nicolas Calderon Asselin
db2bf2a818 Added checks to determine which idle time to use
* lisp/org-clock.el (org-clock-idle-time): Org-mode assumed that x11idle
  was an available command, and returned an idle time of 0 if it was not
  (never idle). Added checks so that org-idle-time will come from emacs'
  own current-idle-time if x11idle cannot be found or if it cannot
  retrieve the idle time from X11

TINYCHANGE
2012-07-24 17:10:10 +02:00
Nicolas Calderon Asselin
49994a4c3e Made x11idle more robust
* UTILITIES/x11idle.c (org-clock-idle-time): Added multiple checks to
  functions return values to prevent segfault. Also "fixed" return codes
  to fail unless the value could be printed, in which case the program
  succeeds.

TINYCHANGE
2012-07-24 17:08:33 +02:00
Giovanni Ridolfi
12a53c7161 org.texi: Update the key sequence for org-clock-in-last' and org-clock-cancel'.
* doc/org.texi (org-clock-in-last and org-clock-cancel): Update the
  defkeys.

TINYCHANGE

After commit fea1b82bef the manual has not been updated, let's do it now.
2012-07-24 17:05:16 +02:00
Nicolas Goaziou
b0f2e083b7 org-export: Update docstrings 2012-07-23 19:32:57 +02:00
Nicolas Goaziou
2b21bb4e52 export back-ends: Remove unused translators functions 2012-07-23 17:53:55 +02:00
Nicolas Goaziou
a13a51e812 org-export: Add :export-block keyword to `org-export-define-derived-backend'
* contrib/lisp/org-export.el (org-export-define-derived-backend):
  Add :export-block keyword.  Also fix a generated doc-string.
* contrib/lisp/org-e-beamer.el: Use new keyword.
2012-07-23 14:19:51 +02:00
Nicolas Goaziou
6ea9d8c827 org-export: `org-export-define-backend': the standard way to create a back-end
* contrib/lisp/org-export.el (org-export-define-backend): New macro.
* contrib/lisp/org-e-ascii.el: Use new macro.
* contrib/lisp/org-e-html.el: Use new macro.
* contrib/lisp/org-e-latex.el: Use new macro.
* contrib/lisp/org-e-odt.el: Use new macro.
* contrib/lisp/org-element.el (org-element-block-name-alist): Remove
  hard-coded export block names from variable, since they are added
  automatically by `org-export-define-backend'.
* testing/lisp/test-org-element.el: Update test.
2012-07-23 14:12:14 +02:00
Nicolas Goaziou
9a2e479b32 org-e-beamer: Fix docstring typo 2012-07-23 09:51:55 +02:00
Nicolas Goaziou
611075db0b org-e-html: Remove an useless argument
* contrib/lisp/org-e-html.el (org-e-html-export-as-html): Remove
  PUB-DIR, which doesn't make sense in that function.
* contrib/lisp/org-export.el: Apply change in function declaration.
2012-07-23 09:51:45 +02:00
Nicolas Goaziou
3a633732b7 org-e-ascii: Fix typo
* contrib/lisp/org-e-ascii.el (org-e-ascii-horizontal-rule): Fix typo.
2012-07-23 09:43:29 +02:00
Nicolas Goaziou
c92913b5f9 org-e-latex: Allow multiple objects and spaces in sub/superscript
* contrib/lisp/org-e-latex.el (org-e-latex-subscript,
  org-e-latex-superscript): Allow multiple objects and spaces in
  sub/superscript.
2012-07-22 13:55:10 +02:00
Nicolas Goaziou
1b64d9582e org-export: Add optional argument to `org-export-read-attribute'
* contrib/lisp/org-export.el (org-export-read-attribute): Add optional
  argument to `org-export-read-attribute'.
* contrib/lisp/org-e-ascii.el (org-e-ascii-horizontal-rule): Use
  additional argument.
2012-07-21 15:12:08 +02:00
Nicolas Goaziou
86ff4cde98 org-export: Silence byte-compiler 2012-07-20 19:37:22 +02:00
Nicolas Goaziou
eed478ffaa org-e-beamer: Small docstring changes
* contrib/lisp/org-e-beamer.el (org-e-beamer-export-as-latex,
  org-e-beamer-export-to-pdf): Small docstring changes.
2012-07-20 13:48:19 +02:00
Nicolas Goaziou
8478fac4a5 Add autoload and a commands to export to temporary buffer in export back-ends
* contrib/lisp/org-e-ascii.el (org-e-ascii-export-as-ascii): New
  function.
(org-e-ascii-export-to-ascii): Now autoloaded.
* contrib/lisp/org-e-latex.el (org-e-latex-export-as-latex): New
  function.
(org-e-latex-export-to-pdf): Now autoloaded.
(org-e-latex--collect-errors): Renamed from
`org-e-latex-collect-errors'.
(org-e-latex-compile): Apply renaming.
* contrib/lisp/org-e-html.el (org-e-html-export-as-html): New
  function.
(org-e-html-export-to-html): Fix docstring.
* contrib/lisp/org-export.el (org-export-dispatch): Use new functions.
2012-07-20 13:48:05 +02:00
Jambunathan K
99ef5728a2 org-e-odt.el: Fix more compilation errors 2012-07-19 23:15:44 +05:30
Jambunathan K
dc92a8dbff org-e-odt.el: Fix all compilation errors
Rearrange and rename for greater consistency and clarity.  More cleanups
will follow.
2012-07-19 22:15:30 +05:30
Jambunathan K
f4148cf525 Merge origin/maint 2012-07-19 19:29:24 +05:30
Jambunathan K
16d23c07dd org-compat.el: Augment earlier commit
* lisp/org-compat.el (org-condition-case-unless-debug): Alias
to `condition-case' when both `condition-case-no-debug' and
`condition-case-unless-debug' is unavailable.
2012-07-19 19:15:42 +05:30
Jambunathan K
137cd87e4d org-odt.el: Replace `flet' with equivalent construct
* lisp/org-odt.el (org-odt-do-image-size): Replace `flet' with
equivalent construct.
2012-07-19 19:04:14 +05:30
Bastien Guerry
7cc0eda245 New alias `org-condition-case-unless-debug'.
* org-odt.el (org-odt-cleanup-xml-buffers): Use the new alias.

* org-compat.el: Alias `org-condition-case-unless-debug' to
`condition-case-unless-debug' or `condition-case-no-debug'.
2012-07-19 19:00:12 +05:30
Nicolas Goaziou
070e03011d org-element: Rename a few internal functions
* contrib/lisp/org-element.el (org-element--parse-elements): Renamed
  from `org-element-parse-elements'.
(org-element--parse-objects): Renamed from `org-element-parse-objects'.
(org-element--get-next-object-candidates): Renamed from
`org-element-get-next-object-candidates'.
(org-element--interpret-affiliated-keywords): Renamed from
`org-element-interpret--affiliated-keywords'.
(org-element--current-element): Renamed from
`org-element-current-element'.
(org-element--collect-affiliated-keywords): Renamed from
`org-element-collect-affiliated-keywords'.
(org-element-center-block-parser, org-element-drawer-parser,
org-element-dynamic-block-parser,
org-element-footnote-definition-parser, org-element-inlinetask-parser,
org-element-plain-list-parser, org-element-quote-block-parser,
org-element-special-block-parser, org-element-comment-parser,
org-element-comment-block-parser, org-element-example-block-parser,
org-element-export-block-parser, org-element-fixed-width-parser,
org-element-horizontal-rule-parser,
org-element-latex-environment-parser, org-element-paragraph-parser,
org-element-src-block-parser, org-element-table-parser,
org-element-verse-block-parser, org-element-fill-paragraph,
org-element-context, org-element-at-point, org-element-interpret-data,
org-element-parse-secondary-string, org-element-parse-buffer): Apply
name change.
* contrib/lisp/org-export.el (org-export-get-buffer-attributes): Apply
  name change.
* testing/lisp/test-org-element.el: Update tests accordingly.
* testing/lisp/test-org-export.el: Update tests accordingly.
2012-07-19 11:23:43 +02:00
Nicolas Goaziou
ea7b5a327f org-e-ascii: Fix link description in empty section
* contrib/lisp/org-e-ascii.el (org-e-ascii-headline): Fix link
  description in empty section.
2012-07-18 19:24:11 +02:00
Nicolas Goaziou
17b865ddd0 org-element: Fix first section parsing
* contrib/lisp/org-element.el (org-element-current-element): Use a new
  special mode symbol to treat section before first headline
  differently.  In this case, its boundaries must be computed since it
  has not been limited by headline container.
(org-element-parse-elements): Use new special mode symbol.
2012-07-18 19:17:12 +02:00
Nicolas Goaziou
8bf8cf8223 org-element: Allow links and export snippets in descriptions lists items tag
* contrib/lisp/org-element.el (org-element-object-restrictions): Allow
  links and export snippets in descriptions lists items tag.
2012-07-18 18:23:26 +02:00
Nicolas Goaziou
d80661e764 org-e-latex: Don't use mathrm in sub/superscripts with a single LaTeX command or entity
* contrib/lisp/org-e-latex.el (org-e-latex-subscript,
  org-e-latex-superscript): Don't use mathrm in sub/superscripts with
  a single LaTeX command or entity.
2012-07-18 17:02:08 +02:00
Nicolas Goaziou
8769f9d014 org-element: Fix tests
* testing/lisp/test-org-element.el: Fix tests.  Some were failing with
  emacs 23.
2012-07-18 11:25:29 +02:00
Nicolas Goaziou
3e76a25f7c org-element: Fix inlinetask parsing
* contrib/lisp/org-element.el (org-element-inlinetask-parser): Fix
  inlinetask parsing.
2012-07-18 11:24:40 +02:00
Nicolas Goaziou
66767db56c org-export: Replace member with memq when possible
* contrib/lisp/org-element.el (org-element-set-element): Replace
  member with memq.
* contrib/lisp/org-export.el (org-export-get-min-level,
  org-export--skip-p, org-export-data, org-export-table-cell-width,
  org-export-table-cell-alignment): Replace member with memq.
2012-07-17 20:49:31 +02:00
Nicolas Goaziou
8a9429f9c3 org-element: Fix timestamp interpreter
* contrib/lisp/org-element.el (org-element-timestamp-interpreter): Fix
  timestamp interpreter.
2012-07-17 20:47:01 +02:00
Achim Gratz
9f2594f6d0 show DESTDIR in make config
* targets.mk: Show $(DESTDIR) in 'make config'.
2012-07-17 19:55:08 +02:00
Nicolas Goaziou
528b17ea15 org-export: Adapt back-ends to timestamp object change
* contrib/lisp/org-e-ascii.el (org-e-ascii-timestamp): Use :range-end
  property when applicable.
* contrib/lisp/org-e-html.el (org-e-html-timestamp): Use :range-end
  property when applicable.
* contrib/lisp/org-e-latex.el (org-e-latex-timestamp): Use :range-end
  property when applicable.
* contrib/lisp/org-e-odt.el (org-e-odt-timestamp): Use :range-end
  property when applicable.
2012-07-17 17:03:29 +02:00
Nicolas Goaziou
a1634b4489 org-element: Store parsed timestamps without the bracket markers
* contrib/lisp/org-element.el (org-element-planning-parser): Store
  parsed timestamps without the bracket markers.
(org-element-timestamp-interpreter): Store parsed timestamps without
  the bracket markers.  Also provide a new property: `:range-end'.
(org-element-planning-interpreter, org-element-timestamp-interpreter):
Apply changes to parsers.
* testing/lisp/test-org-element.el: Add test.
2012-07-17 16:51:19 +02:00
Nicolas Goaziou
e4a300d90d org-element: Fix error when parsing a line-break
* contrib/lisp/org-element.el (org-element-line-break-parser)
(org-element-line-break-interpreter): Line-break object ends where the
line ends.  It doesn't contain the next newline character.
(org-element-parse-objects): Refactoring.
2012-07-17 11:53:41 +02:00
Nicolas Goaziou
69af0913b2 org-element: Normalize contents of elements in place
* contrib/lisp/org-element.el (org-element-normalize-contents):
  Normalize contents of elements in place.  This is required to be
  sure that a normalized element still is `eq' to its equivalent in
  the parse tree.
2012-07-17 00:46:08 +02:00
Nicolas Goaziou
4cf88ac31d org-e-ascii: Fix export of tables with a special column or a top-left corner
* contrib/lisp/org-e-ascii.el (org-e-ascii--table-cell-width,
  org-e-ascii-table-row): Fix export of tables with a special column
  or a top-left angle.
2012-07-16 22:53:53 +02:00
Nicolas Goaziou
5dbd1386f3 org-e-ascii: Comment fix 2012-07-16 18:17:56 +02:00
Nicolas Goaziou
95cd07d058 org-export: Use eq' instead of equal' when possible
* contrib/lisp/org-export.el (org-export-data,
  org-export-footnote-first-reference-p,
  org-export-get-footnote-number, org-export-get-ordinal,
  org-export-get-loc, org-export-table-row-group,
  org-export-table-cell-starts-colgroup-p,
  org-export-table-cell-ends-colgroup-p,
  org-export-table-cell-address): Use `eq' instead of `equal' when
  possible.
* contrib/lisp/org-e-ascii.el (org-e-ascii-table-row):
* contrib/lisp/org-e-beamer.el (org-e-beamer-select-environment):
* contrib/lisp/org-e-html.el (org-e-html-footnote-section,
  org-e-html-latex-environment, org-e-html-paragraph): Use `eq'
  instead of `equal' when possible.
* contrib/lisp/org-e-latex.el (org-e-latex--get-footnote-counter):
* contrib/lisp/org-e-odt.el (org-e-odt-do-format-code,
  org-e-odt-footnote-def, org-e-odt-item, org-e-odt-latex-environment,
  org-e-odt-latex-fragment, org-e-odt-plain-list, org-e-odt-table,
  org-e-odt-enumerate-element): Use `eq' instead of `equal' when
  possible.

In particular, comparing elements shouldn't be done with `equal' since
they are circular lists.  On the other hand, using `eq' is fine if
they belong to the same tree.
2012-07-16 16:28:06 +02:00
Jambunathan K
4a53af87de org-e-odt.el: Fix previous commit 2012-07-16 03:43:01 +05:30
Jambunathan K
4aec2e6937 org-e-odt.el: Refactor and rearrange 2012-07-16 03:38:07 +05:30
Nicolas Goaziou
5a3617c6be org-export: Allow anonymous functions in translate alists
* contrib/lisp/org-export.el (org-export-transcoder, org-export-data):
  Allow anonymous functions in translate alists.
* testing/lisp/test-org-export.el: Update tests.
2012-07-15 21:29:38 +02:00
Achim Gratz
0c9ba74955 provide for .el files that should be installed, but not compiled
* lisp/Makefile: Add LISPN (empty by default) which is used to filter
  out files from LISPC.  This means that install will not fail due to
  a corresponding .elc missing.  This might become useful if lisp
  source files set "no-byte-compile: t" for whatever reason.
2012-07-15 18:31:37 +02:00
Achim Gratz
8db7b8fc19 Makefile: fix whitespace error
* targets.mk: Fix whitespace error.
2012-07-15 18:21:42 +02:00
Achim Gratz
472647fd5c Makefile: add new target cleantesting
* targets.mk: Add new target 'cleantesting', remove remnants from testing/.
* Makefile: Document new target.
2012-07-15 18:18:45 +02:00
Achim Gratz
0e03e06703 add hints for R testing
* default.mk: Add hints for what is required to test with ob-R enabled.
2012-07-15 18:03:36 +02:00
Nicolas Goaziou
a605067181 org-element: Silence byte-compiler 2012-07-15 14:35:04 +02:00
Achim Gratz
6fbc226ca5 further cleanup for org version
* UTILITIES/org-fixup.el (org-make-org-version): Provide feature
  'org-version.
* lisp/org-compat.el (org-check-version): New macro.  Check if
  org-version.el exists and provide autoloads to that. Otherwise check
  if org-fixup.el exists and use it to provide definitions.  Finally
  if nothing worked, complain about a botched installation and provide
  fallback definitions.
* lisp/org.el: Use org-check-version.

This should finally provide the correct behaviour in all supported
use-cases as well as a few corner scenarios that were reported on the
mailing list and allow to always build on Git, ELPA and Emacs Bzr
correctly.  The file org-version.el must be added to the Emacs sources
and should be re-generated each time orgmode Git is synced to Emacs
Bzr (it would be best to automate this).

Note that the internal functions (org-release) and (org-git-release)
are not autoloaded when org-version is not present and become only
available when org.el is loaded.  This should pose no problem since
they are only used by (org-version), which is autoloaded from org.el.
2012-07-15 13:53:53 +02:00
Nicolas Goaziou
e6a88820bf org-export: Fix a docstring
* contrib/lisp/org-export.el (org-export-translate): Fix docstring.
2012-07-15 12:39:44 +02:00
Nicolas Goaziou
b6edf5649c org-element: Inline accessors
* contrib/lisp/org-element.el (org-element-type, org-element-property,
  org-element-contents, org-element-restriction): Inline functions.
2012-07-15 12:27:54 +02:00
Nicolas Goaziou
ebad68a059 org-export: Fix table test failure
* contrib/lisp/org-element.el (org-element-center-block-parser,
  org-element-drawer-parser, org-element-dynamic-block-parser,
  org-element-footnote-definition-parser, org-element-headline-parser,
  org-element-inlinetask-parser, org-element-item-parser,
  org-element-plain-list-parser, org-element-quote-block-parser,
  org-element-section-parser, org-element-special-block-parser,
  org-element-babel-call-parser, org-element-clock-parser,
  org-element-comment-parser, org-element-comment-block-parser,
  org-element-example-block-parser, org-element-export-block-parser,
  org-element-fixed-width-parser, org-element-horizontal-rule-parser,
  org-element-keyword-parser, org-element-latex-environment-parser,
  org-element-paragraph-parser, org-element-planning-parser,
  org-element-property-drawer-parser,
  org-element-quote-section-parser, org-element-src-block-parser,
  org-element-table-parser, org-element-table-row-parser,
  org-element-verse-block-parser, org-element-bold-parser,
  org-element-code-parser, org-element-entity-parser,
  org-element-export-snippet-parser,
  org-element-footnote-reference-parser,
  org-element-inline-babel-call-parser,
  org-element-inline-src-block-parser, org-element-italic-parser,
  org-element-latex-fragment-parser, org-element-line-break-parser,
  org-element-link-parser, org-element-macro-parser,
  org-element-radio-target-parser,
  org-element-statistics-cookie-parser,
  org-element-strike-through-parser, org-element-subscript-parser,
  org-element-superscript-parser, org-element-table-cell-parser,
  org-element-target-parser, org-element-timestamp-parser,
  org-element-underline-parser, org-element-verbatim-parser): Use
  `list' instead of backquotes to avoid using a quoted constant list
  as a non-last argument to `nconc'.
2012-07-15 12:25:09 +02:00