# HG changeset patch # User Oleksandr Gavenko # Date 1324499721 -7200 # Node ID 410c26a389a608b69700383e63c8901b0ea8a83e # Parent 80146b5ba6e65a141c7e51cd7788f08f124be049 Fix highlighting near beginning and end of buffer. diff -r 80146b5ba6e6 -r 410c26a389a6 obsolete/dict-c5-mode.el --- a/obsolete/dict-c5-mode.el Wed Dec 21 21:49:03 2011 +0200 +++ b/obsolete/dict-c5-mode.el Wed Dec 21 22:35:21 2011 +0200 @@ -29,14 +29,11 @@ (defun dict-c5-font-lock-extend-region () "Look for '_____' expression and extend `font-lock-beg' and `font-lock-end'." - ;; (message "%d, %d:%d" (point) font-lock-beg font-lock-end) - ;; (message "lines: %d" (count-lines font-lock-beg font-lock-end)) + ;; (message "%d:%d, %d lines" font-lock-beg font-lock-end (count-lines font-lock-beg font-lock-end)) (cond ((and (< (count-lines font-lock-beg font-lock-end) 5) - (< font-lock-end (point-max)) - (< (point-min) font-lock-beg)) - (message "XXX") + (not (and (<= (point-max) font-lock-end) (<= font-lock-beg (point-min)) ))) (save-excursion (goto-char font-lock-beg) (forward-line -2)