Snapshot problems

Scott Rossi scott at tactilemedia.com
Fri Nov 20 18:45:59 EST 2009


Recently, Howard Bornstein wrote:

> This does work. I sure wish I could wrap my head around *why* it works
> however.

When it comes to snapshots, you can think of a group as a sheet of glass --
all objects on the glass will be captured in your "photograph", but the
glass (group) itself won't.  In this case, since the snapshot is is targeted
specifically at the container group (the "glass"), the snapshot will only
capture the objects in the group, nothing else.  In the code below, if you
changed the "of grp 'container'" to read "of this cd", the snapshot would
capture everything all the way down to the card level.

Hope this helps.

Regards,

Scott Rossi
Creative Director
Tactile Media, Multimedia & Design



> On Fri, Nov 13, 2009 at 12:57 PM, Scott Rossi <scott at tactilemedia.com>wrote:
> 
>> Recently, Howard Bornstein wrote:
>> 
>>> I am trying to do a similar thing. In my case I have some content in a
>> group
>>> that is larger than the group rectangle, so it scrolls within the group.
>>> However, I'd like to be able to take a snapshot of the entire group
>>> contents, even the parts that extend beyond the rectangle (and can only
>> be
>>> seen by scrolling).
>> 
>> Here's one way, although it may be a pain for you:
>> 
>> Group the objects within the group, so you wind up with a group within a
>> group.  Call the inner group "container".  Then script:
>> 
>>  import snapshot from rect (rect of grp "container") of grp "container"
>> 
>> If necessary, you might group when taking a snapshot only, and then ungroup
>> when completed.  Either way, referencing the container group should work.





More information about the use-livecode mailing list