all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* [PATCH] Wrap: override default
@ 2012-12-10 21:34 Michael Gauland
  2012-12-13 22:37 ` Bastien
  2012-12-24  8:43 ` Bastien
  0 siblings, 2 replies; 4+ messages in thread
From: Michael Gauland @ 2012-12-10 21:34 UTC (permalink / raw)
  To: emacs-orgmode


* lisp/ob.el (org-babel-insert-result): only wrap if the :wrap value is non-null.

It can be convenient to specify the :wrap property at a higher level (e.g., file
or tree), rather than for each block. This patch allows you to override the
propery by specifying :wrap with no argument.

TINYCHANGE
---
 lisp/ob.el |    3 ++-
 1 files changed, 2 insertions(+), 1 deletions(-)

diff --git a/lisp/ob.el b/lisp/ob.el
index 0aba523..757bc06 100644
--- a/lisp/ob.el
+++ b/lisp/ob.el
@@ -1998,7 +1998,8 @@ code ---- the results are extracted in the syntax of the
source
 		(setq end (point-marker))
 		;; possibly wrap result
 		(cond
-		 ((assoc :wrap (nth 2 info))
+		 ((and (assoc :wrap (nth 2 info))
+		       (cdr (assoc :wrap (nth 2 info))))
 		  (let ((name (or (cdr (assoc :wrap (nth 2 info))) "RESULTS")))
 		    (funcall wrap (concat "#+BEGIN_" name) (concat "#+END_" name))))
 		 ((member "html" result-params)
-- 
1.7.9

^ permalink raw reply related	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2012-12-24 20:16 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-12-10 21:34 [PATCH] Wrap: override default Michael Gauland
2012-12-13 22:37 ` Bastien
2012-12-24  8:43 ` Bastien
2012-12-24 20:15   ` Michael Gauland

Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.