364 |
DISPLAY-STRING-SPEC is the original specification of the display |
DISPLAY-STRING-SPEC is the original specification of the display |
365 |
string in the variables `TeX-fold-macro-spec-list' or |
string in the variables `TeX-fold-macro-spec-list' or |
366 |
`TeX-fold-env-spec-list' and may be a string or an integer." |
`TeX-fold-env-spec-list' and may be a string or an integer." |
367 |
(let ((ov (make-overlay ov-start ov-end (current-buffer) t nil))) |
;; Calculate priority before the overlay is instantiated. We don't |
368 |
|
;; want `TeX-overlay-prioritize' to pick up a non-prioritized one. |
369 |
|
(let ((priority (TeX-overlay-prioritize ov-start ov-end)) |
370 |
|
(ov (make-overlay ov-start ov-end (current-buffer) t nil))) |
371 |
(overlay-put ov 'category 'TeX-fold) |
(overlay-put ov 'category 'TeX-fold) |
372 |
(overlay-put ov 'priority (TeX-overlay-prioritize ov-start ov-end)) |
(overlay-put ov 'priority priority) |
373 |
(overlay-put ov 'evaporate t) |
(overlay-put ov 'evaporate t) |
374 |
(overlay-put ov 'TeX-fold-type type) |
(overlay-put ov 'TeX-fold-type type) |
375 |
(overlay-put ov 'TeX-fold-display-string-spec display-string-spec) |
(overlay-put ov 'TeX-fold-display-string-spec display-string-spec) |