Finally Found the Error I’ve Been Looking for (or “OSX Error Code Lookup Tool”)
In a recent project, I kept receiving a -10000 error in the console when running my app. Quite frustrating to say the least since the error description was useless, and Google wasn’t any help at all either.
So I was completely thrilled to come across the OSX Error Code Lookup Tool. Download, compile, and plug in [...]
Color Me Crazy (or “When a Color Isn’t Just a Color”)
Ever need to use an image as a background, but can’t figure out how? It’s quite simple — colors aren’t always colors:
UIImage *patternImage = [UIImage imageWithContentsOfFile:[[NSBundle mainBundle] pathForResource:@”patternImage” ofType:@”png”]];
[myView setBackgroundColor:[UIColor colorWithPatternImage: patternImage]];
We are a Billion Fragments (or “Removing URL Fragments with NSURL”)
NSURL is a wonderfully powerful Cocoa object, bet there is at least one thing it leaves out, but I’ll show you how to fix that.
Magpie and Feed Encoding (or “Why are there question marks everywhere?”)
So I’m working on a website that uses MagpieRSS for parsing a feed. The feed had those pretty quotation and apostrophes in it, but when Magpie parses the feed, they all get turned into question marks.
So, for future reference, you can force Magpie to parse the feed according to the encoding you need by [...]
If I Had a Photograph of You (or “How to Cache Images in CocoaTouch”)
A quick note. Wanting to cache images in an iPhone app? Load the image using:
[UIImage imageNamed:]
if you use:
[UIImage imageWithContentsOfFile:]
the image will not be cached.
