mirror of
https://git.savannah.gnu.org/git/emacs/org-mode.git
synced 2024-11-26 07:33:39 +00:00
org-compat: Use different font-lock-ensure alias
* lisp/org-compat.el (org-font-lock-ensure): Remove in favor of
font-lock-ensure alias from dcbaebc.
Instead of org-font-lock-ensure alias introduced in dcbaebc ("Backport
commit 6711a21 from Emacs master branch", 2014-05-28), use
font-lock-ensure alias added in e6883dd
("org-compat: Provide
compatibility definition for font-lock-ensure", 2014-06-01).
This commit is contained in:
parent
d81e6b52b7
commit
c115c7b4e8
@ -1929,7 +1929,7 @@ fontified, and then returned."
|
|||||||
(org-mode)
|
(org-mode)
|
||||||
(org-create-dblock props)
|
(org-create-dblock props)
|
||||||
(org-update-dblock)
|
(org-update-dblock)
|
||||||
(org-font-lock-ensure)
|
(font-lock-ensure)
|
||||||
(forward-line 2)
|
(forward-line 2)
|
||||||
(buffer-substring (point) (progn
|
(buffer-substring (point) (progn
|
||||||
(re-search-forward "^[ \t]*#\\+END" nil t)
|
(re-search-forward "^[ \t]*#\\+END" nil t)
|
||||||
|
@ -418,6 +418,10 @@ Pass BUFFER to the XEmacs version of `move-to-column'."
|
|||||||
(unless (fboundp 'user-error)
|
(unless (fboundp 'user-error)
|
||||||
(defalias 'user-error 'error))
|
(defalias 'user-error 'error))
|
||||||
|
|
||||||
|
;; `font-lock-ensure' is only available from 24.4.50 on
|
||||||
|
(unless (fboundp 'font-lock-ensure)
|
||||||
|
(defalias 'font-lock-ensure 'font-lock-fontify-buffer))
|
||||||
|
|
||||||
(defmacro org-no-popups (&rest body)
|
(defmacro org-no-popups (&rest body)
|
||||||
"Suppress popup windows.
|
"Suppress popup windows.
|
||||||
Let-bind some variables to nil around BODY to achieve the desired
|
Let-bind some variables to nil around BODY to achieve the desired
|
||||||
@ -474,11 +478,6 @@ LIMIT."
|
|||||||
(looking-at (concat "\\(?:" regexp "\\)\\'")))))
|
(looking-at (concat "\\(?:" regexp "\\)\\'")))))
|
||||||
(not (null pos)))))
|
(not (null pos)))))
|
||||||
|
|
||||||
(defalias 'org-font-lock-ensure
|
|
||||||
(if (fboundp 'org-font-lock-ensure)
|
|
||||||
#'font-lock-ensure
|
|
||||||
(lambda (_beg _end) (font-lock-fontify-buffer))))
|
|
||||||
|
|
||||||
(defun org-floor* (x &optional y)
|
(defun org-floor* (x &optional y)
|
||||||
"Return a list of the floor of X and the fractional part of X.
|
"Return a list of the floor of X and the fractional part of X.
|
||||||
With two arguments, return floor and remainder of their quotient."
|
With two arguments, return floor and remainder of their quotient."
|
||||||
|
@ -921,7 +921,7 @@ fontification of code blocks see `org-src-fontify-block' and
|
|||||||
(delete-region (point-min) (point-max))
|
(delete-region (point-min) (point-max))
|
||||||
(insert string " ") ;; so there's a final property change
|
(insert string " ") ;; so there's a final property change
|
||||||
(unless (eq major-mode lang-mode) (funcall lang-mode))
|
(unless (eq major-mode lang-mode) (funcall lang-mode))
|
||||||
(org-font-lock-ensure)
|
(font-lock-ensure)
|
||||||
(setq pos (point-min))
|
(setq pos (point-min))
|
||||||
(while (setq next (next-single-property-change pos 'face))
|
(while (setq next (next-single-property-change pos 'face))
|
||||||
(put-text-property
|
(put-text-property
|
||||||
|
@ -6371,7 +6371,7 @@ needs to be inserted at a specific position in the font-lock sequence.")
|
|||||||
(insert s)
|
(insert s)
|
||||||
(let ((org-odd-levels-only odd-levels))
|
(let ((org-odd-levels-only odd-levels))
|
||||||
(org-mode)
|
(org-mode)
|
||||||
(org-font-lock-ensure)
|
(font-lock-ensure)
|
||||||
(buffer-string))))
|
(buffer-string))))
|
||||||
|
|
||||||
(defvar org-m nil)
|
(defvar org-m nil)
|
||||||
|
@ -1855,7 +1855,7 @@ is the language used for CODE, as a string, or nil."
|
|||||||
(funcall lang-mode)
|
(funcall lang-mode)
|
||||||
(insert code)
|
(insert code)
|
||||||
;; Fontify buffer.
|
;; Fontify buffer.
|
||||||
(org-font-lock-ensure)
|
(font-lock-ensure)
|
||||||
;; Remove formatting on newline characters.
|
;; Remove formatting on newline characters.
|
||||||
(save-excursion
|
(save-excursion
|
||||||
(let ((beg (point-min))
|
(let ((beg (point-min))
|
||||||
|
@ -3139,7 +3139,7 @@ and prefix with \"OrgSrc\". For example,
|
|||||||
(with-temp-buffer
|
(with-temp-buffer
|
||||||
(insert code)
|
(insert code)
|
||||||
(funcall lang-mode)
|
(funcall lang-mode)
|
||||||
(org-font-lock-ensure)
|
(font-lock-ensure)
|
||||||
(buffer-string))))
|
(buffer-string))))
|
||||||
(fontifier (if use-htmlfontify-p 'org-odt-htmlfontify-string
|
(fontifier (if use-htmlfontify-p 'org-odt-htmlfontify-string
|
||||||
'org-odt--encode-plain-text))
|
'org-odt--encode-plain-text))
|
||||||
|
@ -254,7 +254,7 @@ Return output file name."
|
|||||||
(work-buffer (or visitingp (find-file-noselect filename)))
|
(work-buffer (or visitingp (find-file-noselect filename)))
|
||||||
newbuf)
|
newbuf)
|
||||||
(with-current-buffer work-buffer
|
(with-current-buffer work-buffer
|
||||||
(org-font-lock-ensure)
|
(font-lock-ensure)
|
||||||
(show-all)
|
(show-all)
|
||||||
(org-show-block-all)
|
(org-show-block-all)
|
||||||
(setq newbuf (htmlize-buffer)))
|
(setq newbuf (htmlize-buffer)))
|
||||||
|
Loading…
Reference in New Issue
Block a user