GNU bug report logs -
#57813
Icon images are non-functional
Previous Next
Reported by: Juri Linkov <juri <at> linkov.net>
Date: Wed, 14 Sep 2022 19:43:02 UTC
Severity: normal
Fixed in version 29.0.50
Done: Juri Linkov <juri <at> linkov.net>
Bug is archived. No further changes may be made.
Full log
Message #65 received at 57813 <at> debbugs.gnu.org (full text, mbox):
> diff --git a/lisp/emacs-lisp/icons.el b/lisp/emacs-lisp/icons.el
> index ff4f20c207..ccc3657793 100644
> --- a/lisp/emacs-lisp/icons.el
> +++ b/lisp/emacs-lisp/icons.el
> @@ -202,7 +202,11 @@ icons--create
> :height (if (eq height 'line)
> (window-default-line-height)
> height)
> - :scale 1 :ascent 'center)
> + :scale 1
> + :rotation (plist-get keywords :rotation)
Oh, I noticed now this prints a warning in *Messages*:
Invalid image ‘:rotation’ parameter nil
but still continues to work fine.
So maybe the keyword :rotation should be used only on this
condition (plist-member keywords :rotation) instead of:
(create-image file
nil nil
:rotation (plist-get keywords :rotation)
I guess the only way is to convert this function call to 'apply'
with a constructed list of arguments?
Or better to change compute_image_rotation to allow nil in :rotation:
diff --git a/src/image.c b/src/image.c
index 1e323ba66a..6d9316c64b 100644
--- a/src/image.c
+++ b/src/image.c
@@ -2548,6 +2548,8 @@ compute_image_rotation (struct image *img, double *rotation)
Lisp_Object value = image_spec_value (img->spec, QCrotation, &foundp);
if (!foundp)
return;
+ if (NILP (value))
+ return;
if (! NUMBERP (value))
{
image_error ("Invalid image `:rotation' parameter");
This bug report was last modified 2 years and 270 days ago.
Previous Next
GNU bug tracking system
Copyright (C) 1999 Darren O. Benham,
1997,2003 nCipher Corporation Ltd,
1994-97 Ian Jackson.