Subject: Re: bug#4016: Acknowledgement (23.1.50; docview: scrolling up breaks after setting a slice)

From: Tassilo Horn <[email-masked]>
Date: Mon, 03 Aug 2009 08:46:27 +0200

Paer Kurlberg <[email-masked]> writes:

> In case it might be helpful: below is a backtrace.  It seems that the
> problem is that image-get-display-property (called in the function
> image-next-line) returns the list
>
> ((slice 0 0 1100 1600) (image :type png :file
>   "/tmp/docview1000/arnold.dvi-b04e9949bb98146d331479915a45fc5b/page-1.png"
>   :pointer arrow))
>
> and therefore image-size complains since a "proper image" should be a
> list whose car equals 'image.

I can reproduce the error.  But I'm not too sure where the bug is
located.  According to the docs, the display property may be a single
display spec, or a list or vector of such.

,----[ (info "(elisp)Display Property") ]
| The value of the `display' property should be a display specification,
| or a list or vector containing several display specifications.
`----

So in that respect the slice + image spec are ok.

I think that maybe the C function

  int valid_image_p (object) Lisp_Object object;

in image.c should be adapted to accept lists/vectors including one image
spec.

Bye,
Tassilo