org-src: Use font-lock-ensure to highlight blocks
commiteb3b1046c6cfd30c3810d48ea1db64b2f9a4b22d
authorKyle Meyer <kyle@kyleam.com>
Fri, 29 Jan 2016 05:10:08 +0000 (29 00:10 -0500)
committerKyle Meyer <kyle@kyleam.com>
Fri, 29 Jan 2016 05:28:42 +0000 (29 00:28 -0500)
treebfc6fef4e399e6b57e3b6b8db0c33353710477db
parenta4edee4069007591d0159df518936a2699123c6e
org-src: Use font-lock-ensure to highlight blocks

* lisp/org-src.el (org-src-font-lock-fontify-block): Use
  org-font-lock-ensure instead of font-lock-fontify-buffer.

This replacement has previously been made (f36b19ed81e6b5) and then reverted
(99f9999003a0f1) twice because source blocks were not being reliably
highlighted when font-lock-ensure was used instead of
font-lock-fontify-buffer.  This was due to a bug in font-lock-ensure
that has now been fixed (see Emacs's 21beb19 and bug#22399).

font-lock-ensure was introduced after Emacs 24.5, so this issue only
pertains to users with a developmental version of Emacs.
lisp/org-src.el