diff options
author | Nicolas Goaziou <n.goaziou@gmail.com> | 2011-07-17 00:48:36 +0200 |
---|---|---|
committer | Nicolas Goaziou <n.goaziou@gmail.com> | 2011-07-17 00:48:36 +0200 |
commit | c59da42c4ecc35f9181fbc7972af0999d66919fd (patch) | |
tree | 897ecf58a23b2514c9e83f320c7018fda999b7ec | |
parent | b9d5e7e85edeceab7b869d3f013eef2e10f8c1fa (diff) | |
download | org-mode-c59da42c4ecc35f9181fbc7972af0999d66919fd.tar.gz |
Fix fontification error
* lisp/org.el (org-fontify-meta-lines-and-blocks-1): blocks cannot be
correctly fontified when the buffer is missing a final newline.
-rw-r--r-- | lisp/org.el | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/lisp/org.el b/lisp/org.el index 4041c02..c66eb06 100644 --- a/lisp/org.el +++ b/lisp/org.el @@ -5207,8 +5207,8 @@ will be prompted for." beg end '(font-lock-fontified t font-lock-multiline t)) (add-text-properties beg beg1 '(face org-meta-line)) - (add-text-properties end1 (+ end 1) '(face org-meta-line)) - ; for end_src + (add-text-properties end1 (min (point-max) (1+ end)) + '(face org-meta-line)) ; for end_src (cond ((and lang (not (string= lang "")) org-src-fontify-natively) (org-src-font-lock-fontify-block lang block-start block-end) @@ -5222,8 +5222,8 @@ will be prompted for." (overlay-put ovl 'face 'org-block-background) (overlay-put ovl 'evaporate t)) ;; make it go away when empty (quoting - (add-text-properties beg1 (+ end1 1) '(face org-block))) - ; end of source block + (add-text-properties beg1 (min (point-max) (1+ end1)) + '(face org-block))) ; end of source block ((not org-fontify-quote-and-verse-blocks)) ((string= block-type "quote") (add-text-properties beg1 (1+ end1) '(face org-quote))) |