Matt Gemmell

My new book CHANGER is out now!

An action-thriller novel — book 1 in the KESTREL series.

★★★★★ — Amazon

HUD controls framework for Leopard

development & source 1 min read

Just a note that fellow developer Tim Davis has released a framework of HUD-style controls for Leopard, called BGHUDAppKit. You can download it and see some screenshots here. The framework is notable in that it uses native Cocoa drawing methods (NSBezierPath etc) to draw all the controls, and does not rely on embedded images, like many such frameworks.

BGHUDAppKit is released under a BSD license (though if you download it within about an hour of the date of this blog post, you may see headers mentioning the GPL - don’t panic, Tim is updating the copy in his subversion repo as we speak to be BSD, and I’m sure he’ll provide a GPL’d copy for you if you need it).

I’ve had a little input into the framework and I think it’s a great resource, given we’ve now got native HUD windows in Leopard but no HUD-style controls yet. Swing by Tim’s site and leave him a note of thanks if you use the framework, and be sure to credit him in your app!

Oh, and one other thing: I’m asked quite frequently about subclassing NSScroller, and how to make it (1) draw properly at all without tearing to pieces during scrolling, and (2) draw with a transparent background in the scroll-well/slot. I contributed some code to Tim’s HUD-style NSScroller subclass for those very things, so check it out for an example.