David,

> Yes it is. The contents property is generally used to represent bitmapped 
> content of a layer, which in the case of a plain CALayer means that anything 
> drawn via -drawInContext: or -drawLayer:inContext: will be accessible via the 
> contents property.

Thanks for that answer. I would dare a further request for enlightenment ;) 
Does it mean that:

1. by defining a suitable ContentsRect, I can get a clipped area of a CALayer 
just by accessing layer.contents?
2. that I can copy this clipped area into an area the same size on another 
layer defined by another ContentsRect?

More specifically, if I do that:

layer1.contentsRect = CGRectMake(100, 100, 50, 50);
layer2.contentsRect = CGRectMake(0, 0, 50, 50);
layer2.contents = layer1.contents;

does it copy the bitmap contained in layer1 rectangle (100, 100, 50, 50) into 
layer2 rectangle (0, 0, 50, 50)?

Thanks ans cheers from Paris,
Vincent_______________________________________________

Cocoa-dev mailing list ([email protected])

Please do not post admin requests or moderator comments to the list.
Contact the moderators at cocoa-dev-admins(at)lists.apple.com

Help/Unsubscribe/Update your Subscription:
http://lists.apple.com/mailman/options/cocoa-dev/archive%40mail-archive.com

This email sent to [email protected]

Reply via email to