User Tools

Site Tools


Programming Reference/Librarys

Question & Answer

Q&A is closed



+ (NSValue *)valueWithCGSize:(CGSize)size;

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

Return Value - A new NSValue object.

ObjC Sourcecode Example

    // ** Sample datatype **
    CGSize aSize = CGSizeMake(150.0f, 200.0f);
    // ** Add the value to nsvalue object **
    NSValue *cgSizeValue = [NSValue valueWithCGSize:aSize];
    // ** Output **
    NSLog(@"%@", cgSizeValue);

Output for this example code

2012-12-17 23:25:15.789 NSValueSample[353:11303] NSSize: {150, 200}

on the occasion of the current invasion of Russia in Ukraine

Russian Stop this War
objective-c/foundation.framework/nsvalue.h/valuewithcgsize.txt · Last modified: 2024/02/16 01:12 (external edit)

Impressum Datenschutz