Nico, thanks. neither =verbatim markup= (if that's the usage), nor a non~breaking~space give me, in my output, a plain, unadorned "xxcall_foo()".
i *do* think xxcall_foo() is very intuitive for both sets of people, both those who want xx+results and those who want literal xxcall_foo(). so, probably there's no right, wrong. but, imho, there should be some fairly simple way to export, in the text one wants, a simple literal xxcall_foo() (as well as a simple way to export xx+results). all said and done, probably (aesthetics?) i'd go for using a hash (#) as the "paste" character. i guess it's a bit more complicated than just changing: ---- : (looking-at "\\<[#]?call_\\([^ \t\n[(]+\\)[([]")) ---- in ob-element.el. below is my cut. (i used two invocations of "string-prefix-p" rather than one "string-match", not being sure how expensive the latter is compared to the former.) cheers, Greg
>From e0337aabb13fabcefbb0a9fd65e8d4c9bcd412ee Mon Sep 17 00:00:00 2001 From: Greg Minshall <minsh...@acm.org> Date: Wed, 31 Jan 2018 20:38:35 +0530 Subject: [PATCH] use '#' as a "paste" character (for call_ and src_) --- lisp/org-element.el | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) diff --git a/lisp/org-element.el b/lisp/org-element.el index 5af2d6e..5fc3b2d 100644 --- a/lisp/org-element.el +++ b/lisp/org-element.el @@ -162,7 +162,7 @@ specially in `org-element--object-lex'.") "\\\\\\(?:[a-zA-Z[(]\\|\\\\[ \t]*$\\|_ +\\)" ;; Objects starting with raw text: inline Babel ;; source block, inline Babel call. - "\\(?:call\\|src\\)_")) + "#?\\(?:call\\|src\\)_")) "\\|"))) (org-element--set-regexps) @@ -2878,7 +2878,7 @@ Assume point is at the beginning of the babel call." (save-excursion (catch :no-object (when (let ((case-fold-search nil)) - (looking-at "call_\\([^ \t\n[(]+\\)[([]")) + (looking-at "#?\\<call_\\([^ \t\n[(]+\\)[([]")) (goto-char (match-end 1)) (let* ((begin (match-beginning 0)) (call (match-string-no-properties 1)) @@ -4383,10 +4383,12 @@ to an appropriate container (e.g., a paragraph)." (let ((result (match-string 0))) (setq found (cond - ((string-prefix-p "call_" result t) + ((or (string-prefix-p "call_" result t) + (string-prefix-p "#call_" result t)) (and (memq 'inline-babel-call restriction) (org-element-inline-babel-call-parser))) - ((string-prefix-p "src_" result t) + ((or (string-prefix-p "src_" result t) + (string-prefix-p "#src_" result t)) (and (memq 'inline-src-block restriction) (org-element-inline-src-block-parser))) (t -- 2.7.4