BrT

Musings about technology and other neat stuff

BrT random header image

WILTAC #5: zero is a special case

December 9th, 2008 · No Comments

I spent a few minutes today trying to figure out why, when setting a value to zero in an NSTableView, the number formatter I had associated with that column (to add a percentage sign to each number) was not being applied. Eventually, I realized that zero is a special case for NSNumberFormatter, and by default [...]

[Read more →]

Tags: · · ·

WILTAC #4: Undo

November 19th, 2008 · No Comments

Today I learned how to add support for undo/redo operations using NSUndoManager. This was completely new to me, and I was surprised at how cleverly done it is – essentially, for every operation that you want to undo, you provide the “inverse” operation, and NSUndoManager takes care of keeping them in appropriate stacks for undo/redo, [...]

[Read more →]

Tags: · · ·

The Mac Developer Network Book Review: Pragmatic Version Control Using Git – My review of the book "Pragmatic Version Control Using Git" for the Mac Developer Network. (tags: git versioncontrol programming development reviews )
(0)




Commodore BASIC as a Scripting Language for UNIX and Windows – now Open Source – A port of the Commodore BASIC interpreter, now as a script interpreter for Linux, OSX and Windows. Very cool. The memories… (tags: programming commodore c64 nostalgia scripting osx )
(0)







WILTAC #3: NSZombieEnabled

October 17th, 2008 · 2 Comments

I learned today about the NSZombieEnabled environment variable (this is its correct name, and not NSZombiesEnabled as stated in Hillegass’ book). If you set it to YES, whenever you try to send a message to a deallocated object you will get a message like this in the console:

message sent to deallocated instance 0xe02b790

And the debugger [...]

[Read more →]

Tags: · ·

WILTAC #2: Designated initializers

October 10th, 2008 · No Comments

I learned today the term designated initializer:

When a class has multiple initializers, the designated initializer is the one that actually does the work, normally the one with the most parameters. All other initializers call the designated one, providing different amounts of default parameter values.

I was aware of the concept – many classes have [...]

[Read more →]

Tags: · · · ·

WILTAC #1: invoking methods on nil in Objective-C

October 7th, 2008 · No Comments

Welcome to the first installment of “What I learned today about Cocoa” (WILTAC).
I have recently started reading Aaron Hillegass’ excellent Cocoa Programming for Mac OS X, third edition, with the intention of brushing up my very lacking Cocoa skills (all of them learned empirically by looking at other people’s code and reading the documentation). To [...]

[Read more →]

Tags: · · · ·

Tim Dysinger Installing GIT on Mac OS X 10.5 Leopard – Instructions for building git from source, a link to the pre-built git installer package, and (most valuable for me) a list of interesting configuration settings for git. (tags: git howto tutorial macosx tips programming )
(0)




XML Alternatives – Interesting list of data formats that can be used instead of XML (tags: markup programming tools xml )
(0)