Top "Cocoa-touch" questions

The Cocoa Touch Frameworks that drive iOS apps share many proven patterns found on the Mac, but were built with a special focus on touch-based interfaces and optimization.

Get current NSDate in timestamp format

I have a basic method which gets the current time and sets it in a string. However, how can I …

cocoa cocoa-touch nsdate nsdateformatter unix-timestamp
What does the NS prefix mean?

Many classes in Cocoa/Cocoa Touch have the NS prefix. What does it mean?

ios objective-c cocoa cocoa-touch
Generate a UUID on iOS from Swift

In my iOS Swift app I want to generate random UUID (GUID) strings for use as a table key, and …

ios swift cocoa-touch guid core-foundation
Finding the direction of scrolling in a UIScrollView?

I have a UIScrollView with only horizontal scrolling allowed, and I would like to know which direction (left, right) the …

iphone ios cocoa-touch uiscrollview
How to compare two NSDates: Which is more recent?

I am trying to achieve a dropBox sync and need to compare the dates of two files. One is on …

iphone objective-c cocoa-touch nsdate
Have a reloadData for a UITableView animate when changing

I have a UITableView that has two modes. When we switch between the modes I have a different number of …

cocoa-touch animation
UILabel is not auto-shrinking text to fit label size

I have this strange issue, and im dealing with it for more than 8 hours now.. Depending on situation i have …

iphone objective-c ios cocoa-touch ipad
How to print out the method name and line number and conditionally disable NSLog?

I'm doing a presentation on debugging in Xcode and would like to get more information on using NSLog efficiently. In …

objective-c cocoa cocoa-touch xcode nslog
Get to UIViewController from UIView?

Is there a built-in way to get from a UIView to its UIViewController? I know you can get from UIViewController …

ios objective-c cocoa-touch uiview uiviewcontroller
How to get pixel data from a UIImage (Cocoa Touch) or CGImage (Core Graphics)?

I have a UIImage (Cocoa Touch). From that, I'm happy to get a CGImage or anything else you'd like that's …

cocoa cocoa-touch core-graphics