hi rob, thanks for this answer.  i forgot to mention that it is for
UIView on iPhone OS.  i just found a super simple way of managing this
using the backgroundColor property of the view:

self.backgroundColor = [UIColor colorWithPatternImage:[UIImage
imageNamed:@"image.png"]];



On Fri, Jun 19, 2009 at 4:24 AM, Rob Keniger<r...@menumachine.com> wrote:
>
> On 19/06/2009, at 6:14 PM, Chunk 1978 wrote:
>
>> i have this image ("image.png") that i would like to tile throughout
>> the view...
>>
>> i've read the Quartz 2D programming guide... ok, ok, i breezed thru
>> it, i admit... but i couldn't seem to find an easy way of repeating an
>> image through out a view without actually drawing the image
>> programatically...
>
>
> It's actually a little complicated, you need to create an NSColor instance
> using a pattern image and then when you draw it you need to set the
> patternPhase of the current NSGraphicsContext so that your image is drawn in
> the correct place.
>
> Have a look at Dave Batton's excellent DBBackgroundView:
>
> http://www.mere-mortal-software.com/blog/details.php?d=2007-01-16&c=show
>
> --
> Rob Keniger
>
>
>
> _______________________________________________
>
> Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)
>
> 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/chunk1978%40gmail.com
>
> This email sent to chunk1...@gmail.com
>
_______________________________________________

Cocoa-dev mailing list (Cocoa-dev@lists.apple.com)

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 arch...@mail-archive.com

Reply via email to