Commit eff756af authored by Glenn Morris's avatar Glenn Morris

(fancy-diary-display): Use calendar-make-temp-face.

parent aafb0703
......@@ -939,30 +939,10 @@ To use this function, add it to `diary-display-hook'."
:type 'diary-entry)
(insert this-entry ?\n))
(let* ((marks (nth 4 entry))
(faceinfo marks)
(let ((marks (nth 4 entry))
(when marks
;; FIXME duplicate code with calendar.el.
(setq temp-face (make-symbol
'concat "temp-face-"
(mapcar (lambda (sym)
(if (stringp sym)
(symbol-name sym)))
(make-face temp-face)
;; Remove :face info from the marks,
;; copy the face info into temp-face
(while (setq faceinfo (memq :face faceinfo))
;; FIXME not read.
(copy-face (read (nth 1 faceinfo)) temp-face)
(setcar faceinfo nil)
(setcar (cdr faceinfo) nil))
(setq marks (delq nil marks))
;; Apply the font aspects.
(apply 'set-face-attribute temp-face nil marks)
(setq temp-face (calendar-make-temp-face marks))
(search-backward this-entry)
(make-overlay (match-beginning 0) (match-end 0))
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment