User Tools

Site Tools


Sidebar

Programming Reference/Librarys

Question & Answer

Q&A is closed







objective-c:foundation.framework:nsvalue.h:valuewithcgpoint

valueWithCGPoint

 
+ (NSValue *)valueWithCGPoint:(CGPoint)point;
 

Creates and returns an NSValue object that contains the value of a CGPoint.

Return Value - A new NSValue object.

ObjC Sourcecode Example

    // ** Sample datatype **
    CGPoint aPoint = CGPointMake(150.0f, 200.0f);
 
    // ** Create nsvalue object **
    NSValue *cgPointValue = [NSValue valueWithCGPoint:aPoint];
 
    // ** Output **
    NSLog(@"%@", cgPointValue);

Output for this example code

2012-12-17 22:59:51.672 NSValueSample[306:11303] NSPoint: {150, 200}
advertising
objective-c/foundation.framework/nsvalue.h/valuewithcgpoint.txt · Last modified: 2012/12/20 12:24 (external edit)

Impressum Datenschutz