emacs-orgmode
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[O] [PATCH] Strip text properties from string code block arguments


From: Daniel Gerber
Subject: [O] [PATCH] Strip text properties from string code block arguments
Date: Tue, 07 Jan 2014 18:26:09 +0100
User-agent: Mozilla/5.0 (X11; Linux x86_64; rv:24.0) Gecko/20100101 Thunderbird/24.2.0

Hi,

This change in org-babel-python-var-to-python makes python code blocks accept a string with text properties (as one gets when referring another code block). I guess there should be something similar for other languages.

diff --git a/lisp/ob-python.el b/lisp/ob-python.el
index 1457682..baa5764 100644
--- a/lisp/ob-python.el
+++ b/lisp/ob-python.el
@@ -137,7 +137,7 @@ specifying a variable of the same value."
        org-babel-python-hline-to
       (format
(if (and (stringp var) (string-match "[\n\r]" var)) "\"\"%S\"\"" "%S")
-       var))))
+       (if (stringp var) (substring-no-properties var) var)))))

 (defun org-babel-python-table-or-string (results)
   "Convert RESULTS into an appropriate elisp value.




reply via email to

[Prev in Thread] Current Thread [Next in Thread]