Commit 23726fba authored by Pontus Freyhult's avatar Pontus Freyhult

Use lyskom-aliases instead of runtime test for image functions that

are new in GNU Emacs 21.
parent 827d20d8
2004-10-29 Pontus Freyhult <pont@pontus.its.uu.se>
* lyskom-rest.el (lyskom-format-image): Disabled run time
test for image functions, use aliases instead.
* compatibility.el (display-images-p): New alias.
(put-image): New alias.
(create-image): New alias.
2004-10-29 Pontus Freyhult <pont@soua.net>
* lyskom-rest.el (lyskom-format-image): Bugix: Used let instead
......
......@@ -345,6 +345,13 @@ See `walk-windows' for the meaning of MINIBUF and FRAME."
windows))
; ==================================================================
; Image display
(lyskom-function-alias display-images-p () nil)
(lyskom-function-alias put-image (what where) nil)
(lyskom-function-alias create-image (file-or-data) nil)
;;; ================================================================
;;; Color stuff
......
......@@ -2249,14 +2249,13 @@ in lyskom-messages."
(make-extent (point) (point-max))
(make-glyph
(make-image-instance (vector imagetype :data imagedata))))
(if (not (and (fboundp 'display-images-p) ; GNU Emacs
(fboundp 'put-image)
(fboundp 'create-image)
(display-images-p)
(put-image (create-image imagedata imagetype t)
(point-max))))
(setq msg (lyskom-get-string 'image-no-show))))
; Errors just marks it as a no show
; GNU Emacs
(unless (and (lyskom-display-images-p)
(lyskom-put-image
(lyskom-create-image imagedata imagetype t)
(point-max)))
(setq msg (lyskom-get-string 'image-no-show))))
; Errors just marks it as a no show
(error (setq msg (lyskom-get-string 'image-no-show))))
(lyskom-signal-reformatted-text 'reformat-image)
msg)))
......
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