emacs-devel
[Top][All Lists]
Advanced

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

Re: image-size


From: Eli Zaretskii
Subject: Re: image-size
Date: Fri, 21 Jun 2013 09:12:38 +0300

> From: Lars Magne Ingebrigtsen <address@hidden>
> Date: Thu, 20 Jun 2013 23:06:45 +0200
> Cc: address@hidden
> 
> I think I found the culprit:
> 
>       /* Try to create a x pixmap to hold the imagemagick pixmap.  */
>       if (!x_create_x_image_and_pixmap (f, width, height, 0,
>                                         &ximg, &img->pixmap))
> 
> way down in imagemagick_load_image.  Hm.  Also in xpm_load_image.  And
> pbm_load.  Or does it do something else?  Hm...  I know nothing about X,
> but it looks pretty X-ey:
> 
>   *ximg = XCreateImage (display, DefaultVisualOfScreen (screen),
>                       depth, ZPixmap, 0, NULL, width, height,
>                       depth > 16 ? 32 : depth > 8 ? 16 : 8, 0);

That's _after_ we already know the size of the image, so the
suggestion I made earlier, which is ask each 'load' method to return
right after computing the size, given a flag parameter in a call,
would solve this problem.



reply via email to

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