Archive for August 23, 2007

Thursday, August 23, 2007

How to Implement a Basic Bitmap Brush

Andy Finnell:

To go along with this article I have created some sample code that will demonstrate everything I talk about. It’s a mixture of Cocoa and Quartz, although the ideas should work in any environment; only the API calls will change. This is within reason of course: Quartz takes care of a lot of complicated things like alpha blending and antialiasing, and if your API (like QuickDraw, GDI) can’t deal with that, then you’ll have a lot more work to do.

Numbers Rocks

Mac Thought Crime:

There’s a generous helping of functions, and for obvious reasons, they have the same syntax as in Excel. Not nearly all of Excel’s functions are present, though. Worse, I’ve been relying heavily on Excel’s extensive help system when constructing a function: as you type, it displays the syntax for you, and mousing over each part will show you additional details. It’s very easy to get specific help for each function. Not so in Numbers: you’re pretty much on your own, and help is awkward. Functions are probably also considered an advanced feature that relatively few users would be interested in. Hopefully, Apple will beef up this part of Numbers for the next version.

There is one very useful feature, though, that immediately made me a fan (that is, if one can get fanatic about spreadsheets). Select a few cells in Excel, and the application will display the sum of all the numbers in them. Numbers takes this concept a step further: not only does it display their sum, count, average, minimum and maximum, but also lets you drag these to your table, as a really quick and easy way to create a summary field. Well done, that one!

URL Shortening: Hashes in Practice

Jeff Atwood:

My guess is the aggressive URL shortening services are doing a simple iteration across every permutation of the available characters they have as the URLs come in. Each new URL gets a unique three character combination until no more are left.

Little Shops of Horrors

Khoi Vinh:

Faced with unexpectedly effective pressure from Blockbuster Video (who have turned Netflix’s own mail order model on its head by allowing their customers to return movies not just by mail but at the rental chains’ physical locations as well), Netflix has counter-intuitively invested millions of dollars in domestic telephone support facilities and staff.