bug#3874: 23.1.50; Overlays before-string and after-string does not obey buffer-visibility-spec

Lennart Borgman <[email protected]>
Newsgroups gmane.emacs.bugs,gmane.emacs.pretest.bugs
Message-ID <[email protected]>
To show this use this code

;;;; Eval this defun, place point at the end of the buffer and call
;;;; it. It inserts text and an overlay in the buffer.
;;;;
;;;; Play with the different buffer invis specs. It looks like the
;;;; overlay is not affected by the specs.

(defun my-test-inv ()
  (interactive)
  (let ((b "some invis parts")
        (ovl (make-overlay (point) (point))))
    (add-text-properties 5 10 '(face secondary-selection
                                     font-lock-face highlight
                                     invisible (my-invis))
                         b)
    (insert ";;;;;;;;;;;; START OF INSERTED TEXT+OVERLAY
;;;;;;;;;;;;;;;;;;;;\n")
    (insert ";; Text: " b "\n")
    (move-overlay ovl (point-max) (point-max))
    (overlay-put ovl 'before-string (propertize "Overlay: " 'face
'secondary-selection))
    (overlay-put ovl 'after-string b)
    ))

;;;;;;; Test these, none affects the overlays `before-string' or `after-string':
;; (setq buffer-invisibility-spec '((my-invis . t) t))
;; (setq buffer-invisibility-spec '((my-invis) t))
;; (setq buffer-invisibility-spec '(t))  ;; This does not work, bug??
;; (setq buffer-invisibility-spec t)
;; (setq buffer-invisibility-spec '(other-invis))

;;;;;;; Delete overlays here:
;; (dolist (ovl (overlays-in (point-min) (point-max))) (delete-overlay ovl))



In GNU Emacs 23.1.50.1 (i386-mingw-nt5.1.2600)
 of 2009-06-30
Windowing system distributor `Microsoft Corp.', version 5.1.2600
configured using `configure --with-gcc (3.4) --no-opt --cflags
-Ic:/g/include -fno-crossjumping'
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.