Commit graph

6653 commits

Author SHA1 Message Date
Carsten Dominik 9dc28ea0ed Merge branch 'master' of git+ssh://repo.or.cz/srv/git/org-mode 2010-10-22 09:20:05 +02:00
Carsten Dominik ca991d2ad4 HTML export: Improved support for field alignment, including centering
* doc/org.texi: Document the <c> cookie.
* lisp/org-exp.el (org-store-forced-table-alignment):
(org-export-remove-special-table-lines): Allow the "c" cookie for
table alignment.
* lisp/org-html.el (org-export-table-header-tags):
(org-export-table-data-tags): Add another %s format for the alignment.
(org-export-html-table-align-individual-fields): New option.
(org-format-org-table-html): Implement field-by-field alignment and
support centering.
(org-format-table-table-html): Make sure the new table tag formats
don't break this function.
* lisp/org-table.el (org-table-cookie-line-p):
(org-table-align): Allow for the <c> cookie.
* lisp/org.el (org-set-font-lock-defaults): Allow for the <c> cookie.
2010-10-22 09:19:39 +02:00
David Maus 8d85a67deb Skip normalization of plain links that are part of another link
* org-exp.el (org-export-normalize-links): Skip normalization of plain
links that are part of another link.
2010-10-22 06:22:41 +02:00
Dan Davison d8634bab85 babel: R: Fix bug in treatment of :file argument
* ob-R.el (org-babel-expand-body:R): Fix bug in let binding.

This was preventing graphical output from being captured.
2010-10-21 23:29:43 +01:00
Carsten Dominik b0fae37687 Merge branch 'master' of git+ssh://repo.or.cz/srv/git/org-mode 2010-10-21 19:35:09 +02:00
Carsten Dominik e40903a6b6 lisp/org-indent.el: Fix bug in org-indent that changes the selection
* lisp/org-indent.el: (org-indent-add-properties): Use
`with-silent-modificaitons'.
(org-indent-remove-properties): Use `with-silent-modificaitons'.

Julien Danjou writes:

> I'm using org 7.01h with Emacs 24 trunk. When I set org-startup-indented
> to t, I observe the following:
>
> ** TODO Some stuff
>
> I select "stuff" and press M-w. Then I go the the line under and press
> C-y (org-yank).
>
> Now I got:
>
> ** TODO Some stuff
> ** TODO Some
>
> instead of:
>
> ** TODO Some stuff
> stuff
>
> Note that after M-w, `kill-ring' has a correct first entry of "stuff":
>
>   (#("stuff" 0 5
>      (fontified t face org-level-2))
>    ...)
>
> But on C-y (org-yank) something happens, and it paste the wrong text. I
> think it's trying to be smart but it's not.
>
> I've found that setting org-startup-indented to nil fix that behaviour.
2010-10-21 18:26:31 +02:00
Carsten Dominik 52b07a584c Manual: Minor improvement in priority section 2010-10-21 17:47:57 +02:00
Carsten Dominik 5591fb2cde Merge branch 'master' of git+ssh://repo.or.cz/srv/git/org-mode 2010-10-21 16:28:52 +02:00
Carsten Dominik 7712d78ab4 HTML export: Use forced alignment like <l> or <r> in tables
* lisp/org-table.el (org-table-cookie-line-p): Fix indentation.
* lisp/org-exp.el (org-store-forced-table-alignment): New function.
(org-export-preprocess-string): Call `org-store-forced-table-alignment'.
* lisp/org-html.el (org-format-org-table-html): Use stored
alignment information.
2010-10-21 16:28:06 +02:00
Eric Schulte 3852a905b8 testing: noted incompatible testing change in Changes.org 2010-10-21 08:00:38 -06:00
Eric Schulte 3c6e4fdfb0 babel: mention improved caching changes in Changes.org 2010-10-21 07:58:12 -06:00
Eric Schulte 6599e17654 babel: uncomment test-ob-lob.el test which seems to have stochastic failures 2010-10-21 07:53:33 -06:00
Eric Schulte d87e33ea19 babel: ob-execute-src-block respects prefix argument (which forces re-calculation)
* lisp/ob.el (org-babel-execute-src-block): respects prefix argument
  (which forces re-calculation)
2010-10-21 07:50:32 -06:00
Eric Schulte 3fd8d906e4 babel: removed needless param sorting from ob-execute-src-block
* lisp/ob.el (org-babel-execute-src-block): removed needless param
  sorting from ob-execute-src-block, the params are sorted already by
  ob-sha1-hash
2010-10-21 07:44:34 -06:00
Eric Schulte 9d71c8a9dd babel: Changes.org now discusses recent babel developments 2010-10-21 07:36:28 -06:00
Eric Schulte 09758a4b81 babel: updating tests 2010-10-21 07:11:27 -06:00
Eric Schulte b664510ec4 babel: ensure that info is sorted at the header argument level
* lisp/ob.el (org-babel-sha1-hash): ensure that info is sorted at the
  header argument level
2010-10-21 07:11:13 -06:00
Dan Davison 7c44c8ca7d babel: Make test for identical input more stringent when hashing
* ob.el (org-babel-sha1-hash): Consider words in different
	order as different input.
2010-10-21 07:02:50 -06:00
Dan Davison f2e547c657 babel: Fix check for zero length sequences when constructing hash key
* ob.el (org-babel-sha1-hash): Fix check for zero length
	sequences
2010-10-21 07:02:22 -06:00
Eric Schulte 65217b7fb4 tangle: ensure that full info (with expanded variables) for tangling blocks 2010-10-21 07:00:39 -06:00
Dan Davison db68b1fbf5 babel: Handle non-nested list values in shell
* ob-sh.el (org-babel-sh-var-to-sh): Ensure value has the
	structure of an Org-mode table (list of lists)

Non-nested lists can arise either by explicit assignment,
e.g. :var '(1 2), or by assigning a one-dimensional slice of a table.
2010-10-21 13:06:56 +01:00
Dan Davison 35b0d6b1d4 babel: Fix bug in `org-babel-tangle-collect-blocks'
* ob-tangle.el (org-babel-tangle-collect-blocks): Fix
    bug (reference to unassigned variable `src-lang' and avoid
    calling org-babel-get-src-block-info twice
2010-10-21 13:06:56 +01:00
Eric Schulte 91f8cfaebb ob: ob-demarcate updated to reflect the new info list contents
* lisp/ob.el (org-babel-demarcate-block): updated to reflect the new
  info list contents
2010-10-21 13:06:56 +01:00
Eric Schulte 6fa1ae974a minor test cleanup 2010-10-21 13:06:56 +01:00
Dan Davison 60423d2805 Avoid resolving babel references with C-c '
* org-src.el (org-edit-src-code): Supply non-nil argument to
	`org-babel-get-src-block-info' to avoid resolving variable
	references
2010-10-21 13:06:56 +01:00
Eric Schulte b50125a1ac fixed minor bug in and improved efficiency of org-babel-map-src-blocks
* lisp/ob.el (org-babel-map-src-blocks): fixed minor bug in and
  improved efficiency of org-babel-map-src-blocks
2010-10-21 13:06:56 +01:00
Eric Schulte 5bdc043919 careful not to needlessly execute blocks during tangling
* lisp/ob-tangle.el (org-babel-tangle-collect-blocks): now explicitly
  checks that a code block will actually be tangled before collecting
  it's full information (a process which could involve the execution
  of other code blocks)
2010-10-21 13:06:55 +01:00
Dan Davison 4247150094 babel: Don't resolve variable references during `org-babel-demarcate-block'
* ob.el (org-babel-demarcate-block): Use light version of
	`org-babel-get-src-block-info'
2010-10-21 13:06:55 +01:00
Eric Schulte 24cde316a1 beefing up the docs of the org-babel-tangle-comment-format-* variables 2010-10-21 13:06:55 +01:00
Eric Schulte e905dbe0f6 babel hashing now handles more complex types in params
* lisp/ob.el (org-babel-sha1-hash): now handles more complex types in
  params
* testing/examples/babel.org: whitespace
* testing/lisp/test-ob.el (test-org-babel/sha1-hash): new test for
  babel hashing
2010-10-21 13:06:55 +01:00
Eric Schulte cea9fd7421 sanding off some rough corners left by the reworking of process-params
* lisp/ob.el (org-babel-execute-src-block): generally using the new
  more informative params
  (org-babel-process-params): don't forget the :var portion of
  variable assignments
2010-10-21 13:06:55 +01:00
Eric Schulte c60e09eaa4 ob-table: simplified to reflect to var resolution
* lisp/ob-table.el (sbe): simplified to reflect to var resolution
2010-10-21 13:06:55 +01:00
Eric Schulte 8562273b27 ob-ref: don't forget arguments to referenced code blocks
* lisp/ob-ref.el (org-babel-ref-resolve): bringing the referent
  arguments back to their params before evaluation
2010-10-21 13:06:55 +01:00
Eric Schulte dc9401f95b ob-ref: cleanup of variable usage and indentation
* lisp/ob-ref.el (org-babel-ref-resolve): cleanup of variable usage
and indentation
2010-10-21 13:06:55 +01:00
Dan Davison a5ac523ec9 babel: Update sbe macro to new parameter processing
* ob-table.el (sbe): Use `org-babel-process-params params'
	instead of `org-babel-expand-variables'.
2010-10-21 13:06:54 +01:00
Dan Davison 369cf54146 babel:removing calls to ob-process-params, and updating use of results
* lisp/ob-C.el (org-babel-C-execute): removing call to
      org-babel-process-params which should no longer be called from
      within a language file
    * lisp/ob-R.el (org-babel-execute:R): removing call to
      org-babel-process-params which should no longer be called from
      within a language file
      (org-babel-R-variable-assignments): removing call to
      org-babel-process-params which should no longer be called from
      within a language file
    * lisp/ob-asymptote.el (org-babel-execute:asymptote): removing call to
      org-babel-process-params which should no longer be called from
      within a language file
    * lisp/ob-clojure.el (org-babel-execute:clojure): removing call to
      org-babel-process-params which should no longer be called from
      within a language file
    * lisp/ob-dot.el (org-babel-execute:dot): removing call to
      org-babel-process-params which should no longer be called from
      within a language file
    * lisp/ob-emacs-lisp.el (org-babel-expand-body:emacs-lisp): removing
      call to org-babel-process-params which should no longer be called
      from within a language file
      (org-babel-execute:emacs-lisp): removing call to
      org-babel-process-params which should no longer be called from
      within a language file
    * lisp/ob-haskell.el (org-babel-execute:haskell): removing call to
      org-babel-process-params which should no longer be called from
      within a language file
    * lisp/ob-js.el (org-babel-execute:js): removing call to
      org-babel-process-params which should no longer be called from
      within a language file
    * lisp/ob-lisp.el (org-babel-execute:lisp): removing call to
      org-babel-process-params which should no longer be called from
      within a language file
    * lisp/ob-ocaml.el (org-babel-execute:ocaml): removing call to
      org-babel-process-params which should no longer be called from
      within a language file
    * lisp/ob-octave.el (org-babel-execute:octave): removing call to
      org-babel-process-params which should no longer be called from
      within a language file
    * lisp/ob-perl.el (org-babel-execute:perl): removing call to
      org-babel-process-params which should no longer be called from
      within a language file
    * lisp/ob-python.el (org-babel-execute:python): removing call to
      org-babel-process-params which should no longer be called from
      within a language file
    * lisp/ob-ruby.el (org-babel-execute:ruby): removing call to
      org-babel-process-params which should no longer be called from
      within a language file
    * lisp/ob-scheme.el (org-babel-execute:scheme): removing call to
      org-babel-process-params which should no longer be called from
      within a language file
    * lisp/ob-screen.el (org-babel-execute:screen): removing call to
      org-babel-process-params which should no longer be called from
      within a language file
      (org-babel-prep-session:screen): removing call to
      org-babel-process-params which should no longer be called from
      within a language file
    * lisp/ob-sh.el (org-babel-execute:sh): removing call to
      org-babel-process-params which should no longer be called from
      within a language file
    * lisp/ob-sql.el (org-babel-execute:sql): removing call to
      org-babel-process-params which should no longer be called from
      within a language file
    * ob-haskell.el (org-babel-execute:haskell): Remove reference
      to processed params
    * ob-clojure.el (org-babel-execute:clojure): Remove reference
      to processed params
    * ob-R.el (org-babel-execute:R): Remove reference to processed
      params
2010-10-21 13:06:54 +01:00
Dan Davison 542f77d3f5 babel: sql: Use generic expansion function
* ob-sql.el (org-babel-execute:sql): Use generic expansion
	function
	(org-babel-expand-body:sql): Delete function
2010-10-21 13:06:03 +01:00
Dan Davison 07c84b293c babel: shell: New variable assignment and expansion scheme
* ob-sh.el (org-babel-execute:sh): Use generic expansion
	function
	(org-babel-expand-body:sh): Delete function
	(org-babel-prep-session:sh): Change name of called function
	(org-babel-variable-assignments:sh): Change function name
2010-10-21 13:06:03 +01:00
Dan Davison 19081f12f7 babel: screen: New variable assignment and expansion scheme
* ob-screen.el (org-babel-execute:screen): Use generic
	expansion function
	(org-babel-expand-body:screen): Delete function
	(org-babel-prep-session:screen): Remove references to
	processed params
2010-10-21 13:06:03 +01:00
Dan Davison c1ad98ae0e babel: sass: Use generic expansion function
* ob-sass.el (org-babel-execute:sass): Use generic expansion
	function
	(org-babel-expand-body:sass): Delete function
2010-10-21 13:06:03 +01:00
Dan Davison 2fc9b08a23 babel: ruby: New variable assignment and expansion scheme
* ob-ruby.el (org-babel-execute:ruby): Use generic expansion
	function
	(org-babel-prep-session:ruby): Use new variable assignment
	function
	(org-babel-variable-assignments:ruby): New function
	(org-babel-expand-body:ruby): Delete function
2010-10-21 13:06:03 +01:00
Dan Davison 2699f4e9bc babel: python: New variable assignment and expansion scheme
* ob-python.el (org-babel-execute:python): Use generic
	expansion function
	(org-babel-prep-session:python): Change name of called function
	(org-babel-variable-assignments:python): Change function name
	(org-babel-expand-body:python): Delete function
2010-10-21 13:06:03 +01:00
Dan Davison 33f836e701 babel: plantuml: Delete unnecessary language-specific expansion function
* ob-plantuml.el (org-babel-expand-body:plantuml): Delete
    function (automatically handled by generic version)
2010-10-21 13:06:02 +01:00
Dan Davison 84dd553936 babel: perl: New variable assignment and expansion scheme
* ob-perl.el (org-babel-execute:perl): Use generic expansion
	function
	(org-babel-expand-body:perl): Delete function
	(org-babel-variable-assignments:perl): New function
2010-10-21 13:06:02 +01:00
Dan Davison ee5d7af7b9 babel: org: Delete unnecessary language-specific expansion function
* ob-org.el (org-babel-expand-body:org): Delete
    function (automatically handled by generic version)
2010-10-21 13:06:02 +01:00
Dan Davison 58a24fa325 babel: octave and matlab: New variable assignment and expansion scheme
* ob-octave.el (org-babel-execute:octave): Use generic
	expansion function
	(org-babel-variable-assignments:octave): Change name of
	function
	(org-babel-variable-assignments:matlab): New defalias
	(org-babel-prep-session:octave): Change name of function
	(org-babel-expand-body:matlab): Delete function
	(org-babel-expand-body:octave): Delete function
2010-10-21 13:06:02 +01:00
Dan Davison 590fae34e1 babel: ocaml: New variable assignment and expansion scheme
* ob-ocaml.el (org-babel-execute:ocaml): Use generic expansion
	function
	(org-babel-variable-assignments:ocaml): New function
	(org-babel-expand-body:ocaml): Delete function
2010-10-21 13:06:02 +01:00
Dan Davison 42ddb16dbf babel: mscgen: Delete unnecessary language-specific expansion function
* ob-mscgen.el (org-babel-expand-body:mscgen): Delete
    function (automatically handled by generic version)
2010-10-21 13:06:02 +01:00
Dan Davison 67fd5e730e babel: javascript: New variable assignment and expansion scheme
* ob-js.el (org-babel-execute:js): Use new variable assignment
	function
	(org-babel-expand-body:js): Delete function
	(org-babel-prep-session:js): Use new variable assignment
	function
	(org-babel-variable-assignments:js): New function
2010-10-21 13:06:02 +01:00
Dan Davison 1ab30746dc babel: haskell: New variable assignment scheme
* ob-haskell.el (org-babel-execute:haskell): Use generic
	expansion function
	(org-babel-expand-body:haskell): Delete function
	(org-babel-prep-session:haskell): Use variable assignment function
	(org-babel-variable-assignments:haskell): New function
2010-10-21 13:06:02 +01:00