How to NSLog a CGRect [duplicate]

You need to use NSStringFromCGRect which will convert the CG structs into NSString, Refer below:-

NSLog(@"%@", NSStringFromCGRect(frame));

Also below are the following other functions which can be used for NSLog CG Structs as well:-

NSStringFromCGPoint  
NSStringFromCGSize  
NSStringFromCGRect  
NSStringFromCGAffineTransform  
NSStringFromUIEdgeInsets

Leave a Comment

Hata!: SQLSTATE[HY000] [1045] Access denied for user 'divattrend_liink'@'localhost' (using password: YES)