emacs-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: bug in forward-visible-line: Patch


From: Luc Teirlinck
Subject: Re: bug in forward-visible-line: Patch
Date: Thu, 22 May 2003 19:03:32 -0500 (CDT)

This would be a corrected version of line-move-invisible:

(defun line-move-invisible (pos)
  "Return non-nil if the character after POS is currently invisible."
  (let ((prop (get-char-property pos 'invisible)))
    (cond
     ((null prop) nil)
     ((eq buffer-invisibility-spec t))
     ((memq prop buffer-invisibility-spec))
     ((assq prop buffer-invisibility-spec))
     ((listp prop)
      (catch 'found
        (dolist (var prop)
          (if (or (memq var buffer-invisibility-spec)
                  (assq var buffer-invisibility-spec))
              (throw 'found t)))))
     (t nil))))

I could double-check this carefully (I did not) and send a diff, but
as Stefan pointed out, it might be better to implement this function
in C.

Sincerely,

Luc.






reply via email to

[Prev in Thread] Current Thread [Next in Thread]