Hello,

when I create an overlay to hide text, move-to-column works differently
depending on the point's position in the current line.

If the point is before the hidden characters, it will move the point to
the N'th visible column (i.e. the one given by column-number-mode), but
when the point is behind the hidden characters, it will move the point
to (point-at-bol) + N.


Consider the following example:

(progn
  (insert "1234567890")
  (let ((overlay (make-overlay (+ (point-at-bol) 2) (+ (point-at-bol) 4))))
    (overlay-put overlay 'invisible t)
    (let ((point-a (save-excursion (beginning-of-line)
                                   (move-to-column 6)
                                   (point)))
          (point-b (save-excursion (end-of-line)
                                   (move-to-column 6)
                                   (point))))
      (delete-overlay overlay)
      (message "%d %d" point-a point-b))))

point-a and point-b should be equal, but they are not.


regards,
Nikolaj Schumacher


_______________________________________________
emacs-pretest-bug mailing list
[email protected]
http://lists.gnu.org/mailman/listinfo/emacs-pretest-bug

Reply via email to