mirror of
https://github.com/ryuslash/mode-icons.git
synced 2024-11-21 17:40:30 +01:00
Fix image call by adding data argument
-Also make sure image type is specified
This commit is contained in:
parent
3d9d4c5a63
commit
f03ae96e95
1 changed files with 9 additions and 7 deletions
|
@ -478,7 +478,8 @@ ACTIVE is an indicator that the current window is active."
|
|||
(create-image (mode-icons-desaturate-xpm icon-path face)
|
||||
(or (and (fboundp 'imagemagick-types)
|
||||
(memq 'png (imagemagick-types)) 'imagemagick)
|
||||
'xpm) t :ascent 'center
|
||||
'xpm) t
|
||||
:ascent 'center
|
||||
:height (window-mode-line-height)
|
||||
:face face :icon icon))
|
||||
(t
|
||||
|
@ -487,6 +488,7 @@ ACTIVE is an indicator that the current window is active."
|
|||
(memq (or (and (eq type 'jpg) 'jpeg) type) (imagemagick-types))
|
||||
'imagemagick)
|
||||
(or (and (eq type 'jpg) 'jpeg) type))
|
||||
nil
|
||||
:height (window-mode-line-height)
|
||||
:ascent 'center :face face :icon icon)))))
|
||||
((and (eq type 'emoji) (setq tmp (mode-icons--get-emoji " " (list "" icon type) face)))
|
||||
|
@ -1011,9 +1013,9 @@ ACTIVE is a flag telling if the current window is active."
|
|||
(create-image png
|
||||
;; use imagemagick if available and supports PNG images
|
||||
;; (allows resizing images)
|
||||
(when (and (fboundp 'imagemagick-types)
|
||||
(or (and (and (fboundp 'imagemagick-types)
|
||||
(memq 'png (imagemagick-types)))
|
||||
'imagemagick)
|
||||
'imagemagick) 'png)
|
||||
nil
|
||||
:height (window-mode-line-height)
|
||||
:ascent 'center
|
||||
|
@ -1064,9 +1066,9 @@ ACTIVE is a flag for if the current window is active."
|
|||
(create-image image-file
|
||||
;; use imagemagick if available and supports PNG images
|
||||
;; (allows resizing images)
|
||||
(when (and (fboundp 'imagemagick-types)
|
||||
(or (and (and (fboundp 'imagemagick-types)
|
||||
(memq image-type (imagemagick-types)))
|
||||
'imagemagick)
|
||||
'imagemagick) 'png)
|
||||
nil
|
||||
:ascent 'center
|
||||
:heuristic-mask t
|
||||
|
|
Loading…
Reference in a new issue