Always use the compatibility function `org-region-active-p'

* org.el (org-create-math-formula): Use the compatibility
function `org-region-active-p'.

* org-odt.el (org-export-as-odf): Ditto.

* ob.el (org-babel-demarcate-block): Ditto.
This commit is contained in:
Bastien Guerry 2012-08-20 05:45:25 +02:00
parent 58a6d823ee
commit 8393a76f78
3 changed files with 4 additions and 4 deletions

View File

@ -1685,13 +1685,13 @@ region is not active then the point is demarcated."
""
(concat "\n" (make-string (current-column) ? )))))))
(move-end-of-line 2))
(sort (if (region-active-p) (list (mark) (point)) (list (point))) #'>))
(sort (if (org-region-active-p) (list (mark) (point)) (list (point))) #'>))
(let ((start (point))
(lang (org-icompleting-read "Lang: "
(mapcar (lambda (el) (symbol-name (car el)))
org-babel-load-languages)))
(body (delete-and-extract-region
(if (region-active-p) (mark) (point)) (point))))
(if (org-region-active-p) (mark) (point)) (point))))
(insert (concat (if (looking-at "^") "" "\n")
(if arg (concat stars "\n") "")
"#+begin_src " lang "\n"

View File

@ -2796,7 +2796,7 @@ MathML source to kill ring, if `org-export-copy-to-kill-ring' is
non-nil."
(interactive
`(,(let (frag)
(setq frag (and (setq frag (and (region-active-p)
(setq frag (and (setq frag (and (org-region-active-p)
(buffer-substring (region-beginning)
(region-end))))
(loop for e in org-latex-regexps

View File

@ -17394,7 +17394,7 @@ write the results in to that file. When invoked as an
interactive command, prompt for LATEX-FRAG, with initial value
set to the current active region and echo the results for user
inspection."
(interactive (list (let ((frag (when (region-active-p)
(interactive (list (let ((frag (when (org-region-active-p)
(buffer-substring-no-properties
(region-beginning) (region-end)))))
(read-string "LaTeX Fragment: " frag nil frag))))