all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* imagemagick format detection code
@ 2013-08-11 21:14 Lars Magne Ingebrigtsen
  2013-08-11 21:27 ` Lars Magne Ingebrigtsen
  0 siblings, 1 reply; 10+ messages in thread
From: Lars Magne Ingebrigtsen @ 2013-08-11 21:14 UTC (permalink / raw)
  To: emacs-devel

duckduckgo outputs images as gzipped .ico files, and eww can now almost
display them.  But!  If I create the image from the data in the buffer,
I just get a square which imagemagick uses to tell us "nuh-huh; don't
understand": 

(with-temp-buffer
  (set-buffer-multibyte nil)
  (insert-file-contents-literally "/tmp/b.ico")
  (let ((image (create-image (buffer-string) 'imagemagick t)))
    (pop-to-buffer "*image*")
    (insert-image image "*")))

However, if I create the image with

(create-image "/tmp/b.ico" 'imagemagick)

then it works fine.

Does anybody have any, er, insights to offer here?

-- 
(domestic pets only, the antidote for overdose, milk.)
  No Gnus T-Shirt for sale: http://ingebrigtsen.no/no.php
  and http://lars.ingebrigtsen.no/2013/08/twenty-years-of-september.html




^ permalink raw reply	[flat|nested] 10+ messages in thread

end of thread, other threads:[~2013-08-13 19:05 UTC | newest]

Thread overview: 10+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-08-11 21:14 imagemagick format detection code Lars Magne Ingebrigtsen
2013-08-11 21:27 ` Lars Magne Ingebrigtsen
2013-08-12  1:06   ` Stefan Monnier
2013-08-12 15:17     ` Lars Magne Ingebrigtsen
2013-08-12 17:43       ` Thien-Thi Nguyen
2013-08-13 14:23       ` Stefan Monnier
2013-08-13 18:14         ` Lars Magne Ingebrigtsen
2013-08-13 18:19           ` Lars Magne Ingebrigtsen
2013-08-13 18:56           ` Stefan Monnier
2013-08-13 19:05             ` Lars Magne Ingebrigtsen

Code repositories for project(s) associated with this external index

	https://git.savannah.gnu.org/cgit/emacs.git
	https://git.savannah.gnu.org/cgit/emacs/org-mode.git

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.