NSRectDescription

A string from an NSRect (for logging).

Trivial, and unnecessary, since NSGeometry.h defines a NSStringFromRect() function, but putting it here saves me retyping it in the future.

NSString* NSRectDescription(NSRect rect){ return [NSString stringWithFormat: @"{%f %f %f %f}", rect.origin.x, rect.origin.y, rect.size.width, rect.size.height]; }
Cocoa Fragments

Page last modified July 4, 2006