Smultron is an open source text editor available for Macintosh that is simple to use and is straight to the point. Smultron has some great features such as Syntax Highlighting, line numbering, code snippets, multi-document searching, project saving, an organized and clear way of managing files, and more.
The amount of features that Smultron has is very large and some are extremely helpful for programming. For example, the removal of whitespace will remove any possible spaces or tabs after the text and before the line break. Or there is the code snippet options that “you can temporarily or permanently store snippets of code that you will use again. Drag text to the drawer to create a new or add text to an existing, or press the + button to create a blank. Press the – button to remove a snippet.”
You can grab a copy for Macintosh and even download the source files of Smultron. It was developed using Cocoa for use with Mac OS X Panther.