bug-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

bug#26978: 25.2; incomplete display of SVG image


From: Lars Ingebrigtsen
Subject: bug#26978: 25.2; incomplete display of SVG image
Date: Thu, 26 Sep 2019 17:50:22 +0200
User-agent: Gnus/5.13 (Gnus v5.13) Emacs/27.0.50 (gnu/linux)

Lars Ingebrigtsen <larsi@gnus.org> writes:

> So I'm wondering whether there's something we can tell the rsvg library
> to make it find these sub-images, or something. 

This works correctly:

(insert-image (create-image "/tmp/test-svg/sample-png.svg"))

The problem is that when you C-x C-f the image, then this code fails,
sort of::

static bool
svg_load (struct frame *f, struct image *img)
{
  bool success_p = 0;
  Lisp_Object file_name;

  /* If IMG->spec specifies a file name, create a non-file spec from it.  */
  file_name = image_spec_value (img->spec, QCfile, NULL);
  if (STRINGP (file_name))

Because the image is in the buffer already, we don't tell the rsvg
library what the file name is, and so it can't find the sub-images in
question.

Hm...  hang on...  I'm getting spurious results here.  I think
image-mode is supposed to pass the file name into create-image in most
cases...  but I'm getting sporadic failures: Sometimes it works and
sometimes it doesn't.  Can't see any pattern, really.

-- 
(domestic pets only, the antidote for overdose, milk.)
   bloggy blog: http://lars.ingebrigtsen.no





reply via email to

[Prev in Thread] Current Thread [Next in Thread]