1 |
;;; cpp.el --- highlight or hide text according to cpp conditionals |
;;; cpp.el --- highlight or hide text according to cpp conditionals |
2 |
|
|
3 |
;; Copyright (C) 1994, 1995 Free Software Foundation |
;; Copyright (C) 1994, 1995, 2003 Free Software Foundation |
4 |
|
|
5 |
;; Author: Per Abrahamsen <abraham@dina.kvl.dk> |
;; Author: Per Abrahamsen <abraham@dina.kvl.dk> |
6 |
;; Keywords: c, faces, tools |
;; Keywords: c, faces, tools |
379 |
(defun cpp-make-overlay-hidden (overlay) |
(defun cpp-make-overlay-hidden (overlay) |
380 |
;; Make overlay hidden and intangible. |
;; Make overlay hidden and intangible. |
381 |
(overlay-put overlay 'invisible 'cpp) |
(overlay-put overlay 'invisible 'cpp) |
|
(overlay-put overlay 'intangible t) |
|
|
;; Unfortunately `intangible' is not implemented for overlays yet, |
|
|
;; so we make is read-only instead. |
|
382 |
(overlay-put overlay 'modification-hooks '(cpp-signal-read-only)) |
(overlay-put overlay 'modification-hooks '(cpp-signal-read-only)) |
383 |
(overlay-put overlay 'insert-in-front-hooks '(cpp-signal-read-only))) |
(overlay-put overlay 'insert-in-front-hooks '(cpp-signal-read-only))) |
384 |
|
|