CALayer Properties cannot be accessed in XCode 4.2 Lion

I am using XCode 4.2 with Lion 1.7


Property 'anchorPoint' cannot be found in forward class object 'CALayer *'
Property 'cornerRadius' cannot be found in forward class object 'CALayer *'
Property 'borderWidth' cannot be found in forward class object 'CALayer *'

This was the error I was getting when ever I was trying to access the properties of layer class. Just one import solved all my problems and I got the things working

Import the QuartzCore.framework in your resources and you need to import the following in the class you want to access the properties of layer.

#import

I hope this helps

Advertisements

One comment

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s