displaying a web image

Devin Asay devin_asay at byu.edu
Thu Feb 14 14:24:01 EST 2002

At 4:57 PM -0800 2/13/02, Geoff Canyon wrote:
>At 3:27 PM -0800 2/13/02, Jeanne A. E. DeVoto wrote:
>>At 9:10 AM -0800 2/13/2002, Devin Asay wrote:
>>>>   set the filename of image "My Image" to 
>>>Thanks, Jeanne.  I was trying to include the URL keyword before the
>>>file name.  But here is a new problem.  The first time I set the
>>>filename of the image to a URL on a web server it works fine.  But if
>>>I try to set it to a different web URL it sticks with the first
>>>image, no matter what.
>>>This is consistent in Rev 1.1.1b1 for Mac OS X and OS 9.2.  It
>>>appears to be a bug.  Can anyone else confirm this and/or tell me
>>>what I'm doing wrong?
>>I confirm this - it does look like a bug. Will report it. Thanks!
>But this does appear to work as it should:
>put url "http://www.example.org/image.gif" into image "My Image"
>Although it doesn't seem to handle animated gifs as it should -- the 
>mergine of the base image of the gif with subsequent frames doesn't 
>display properly.

I confirmed that the "put URL" form works as expected; it also gives 
a clue as to what's wrong with the "set the filename" form.  It 
appears to be related to images stored in the image library (icon 
library?)* of the stack.  Apparently, whatever image is in the first 
position of the stack's image library is the one that gets inserted 
into the image when using the 'set the filename .. to "http://..." ' 
form.  If that library is empty (as it is the first time the command 
is sent) the referenced graphic is inserted into that first slot and 
appears in the image object.  If that library is not empty, for 
instance if there has been a previous "put URL" form used, the "set 
the filename" command looks in that first slot and uses whatever is 
there.  Closing the stack flushes the referenced object out of the 
library so the new image will be displayed when it is re-opened.

*(The images you see when you assign an icon to a button and choose 
the "This Stack" image library.)

Kevin indicated that there are fixes to the image library in the 
works for beta 2, so it is hoped that this will be fixed at that time.


Devin Asay
Humanities Research Center
Brigham Young University

More information about the Use-livecode mailing list