[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: Redisplay slower in Emacs 28 than Emacs 27
From: |
Lars Ingebrigtsen |
Subject: |
Re: Redisplay slower in Emacs 28 than Emacs 27 |
Date: |
Tue, 08 Dec 2020 00:02:06 +0100 |
User-agent: |
Gnus/5.13 (Gnus v5.13) Emacs/28.0.50 (gnu/linux) |
Gregory Heytings <ghe@sdf.org> writes:
> Hmmm... this fails with:
>
> Loading /home/ghe/local/src/emacs/lisp/indent.el (source)...
> Loading /home/ghe/local/src/emacs/lisp/emacs-lisp/cl-generic.el (source)...
> Eager macro-expansion failure: (void-variable image-load-path)
> Eager macro-expansion failure: (void-variable image-load-path)
> Eager macro-expansion failure: (void-variable image-load-path)
> Eager macro-expansion failure: (void-variable image-load-path)
> Eager macro-expansion failure: (void-variable image-load-path)
> Eager macro-expansion failure: (void-variable image-load-path)
> Eager macro-expansion failure: (void-variable image-load-path)
> Eager macro-expansion failure: (void-variable image-load-path)
> Symbol’s value as variable is void: image-load-path
Hm. Does adding a (require 'image) help? Like this:
diff --git a/lisp/tool-bar.el b/lisp/tool-bar.el
index 8456216430..2d929214d5 100644
--- a/lisp/tool-bar.el
+++ b/lisp/tool-bar.el
@@ -141,6 +141,8 @@ tool-bar-add-item
To define items in any other map, use `tool-bar-local-item'."
(apply #'tool-bar-local-item icon def key tool-bar-map props))
+(require 'image)
+
(defun tool-bar--image-expression (icon)
"Return an expression that evaluates to an image spec for ICON."
(let* ((fg (face-attribute 'tool-bar :foreground))
@@ -154,12 +156,12 @@ tool-bar--image-expression
(concat icon ".pbm")) colors))
(xbm-spec (append (list :type 'xbm :file
(concat icon ".xbm")) colors)))
- `(find-image (cond ((not (display-color-p))
- ',(list pbm-spec xbm-spec xpm-lo-spec xpm-spec))
- ((< (display-color-cells) 256)
- ',(list xpm-lo-spec xpm-spec pbm-spec xbm-spec))
- (t
- ',(list xpm-spec pbm-spec xbm-spec))))))
+ `(cond ((not (display-color-p))
+ ',(find-image (list pbm-spec xbm-spec xpm-lo-spec xpm-spec)))
+ ((< (display-color-cells) 256)
+ ',(find-image (list xpm-lo-spec xpm-spec pbm-spec xbm-spec)))
+ (t
+ ',(find-image (list xpm-spec pbm-spec xbm-spec))))))
;;;###autoload
(defun tool-bar-local-item (icon def key map &rest props)
--
(domestic pets only, the antidote for overdose, milk.)
bloggy blog: http://lars.ingebrigtsen.no
- Re: Redisplay slower in Emacs 28 than Emacs 27, (continued)
- Re: Redisplay slower in Emacs 28 than Emacs 27, Gregory Heytings, 2020/12/07
- Re: Redisplay slower in Emacs 28 than Emacs 27, Lars Ingebrigtsen, 2020/12/07
- Re: Redisplay slower in Emacs 28 than Emacs 27, Alan Third, 2020/12/07
- Re: Redisplay slower in Emacs 28 than Emacs 27, Lars Ingebrigtsen, 2020/12/07
- Re: Redisplay slower in Emacs 28 than Emacs 27, Lars Ingebrigtsen, 2020/12/07
- Re: Redisplay slower in Emacs 28 than Emacs 27, Gregory Heytings, 2020/12/07
- Re: Redisplay slower in Emacs 28 than Emacs 27, Gregory Heytings, 2020/12/07
- Re: Redisplay slower in Emacs 28 than Emacs 27, Lars Ingebrigtsen, 2020/12/07
- Re: Redisplay slower in Emacs 28 than Emacs 27, Lars Ingebrigtsen, 2020/12/07
- Re: Redisplay slower in Emacs 28 than Emacs 27, Gregory Heytings, 2020/12/07
- Re: Redisplay slower in Emacs 28 than Emacs 27,
Lars Ingebrigtsen <=
- Re: Redisplay slower in Emacs 28 than Emacs 27, Gregory Heytings, 2020/12/07
- Re: Redisplay slower in Emacs 28 than Emacs 27, Lars Ingebrigtsen, 2020/12/07
- Re: Redisplay slower in Emacs 28 than Emacs 27, Lars Ingebrigtsen, 2020/12/07
- Re: Redisplay slower in Emacs 28 than Emacs 27, Gregory Heytings, 2020/12/07
- Re: Redisplay slower in Emacs 28 than Emacs 27, Lars Ingebrigtsen, 2020/12/07
- Re: Redisplay slower in Emacs 28 than Emacs 27, Gregory Heytings, 2020/12/07
- Re: Redisplay slower in Emacs 28 than Emacs 27, Lars Ingebrigtsen, 2020/12/07
- Re: Redisplay slower in Emacs 28 than Emacs 27, Lars Ingebrigtsen, 2020/12/07
- Re: Redisplay slower in Emacs 28 than Emacs 27, Lars Ingebrigtsen, 2020/12/07
- Re: Redisplay slower in Emacs 28 than Emacs 27, João Távora, 2020/12/08