Flirtations with TextMate: Prologue
I’m a BBEdit guy. I’ve been using BBEdit in various incarnations (BBEdit Lite/TextWrangler/BBEdit proper) for over a decade now. Before that I churned out code in THINK Pascal. I also spent some time with MPW, but MPW and BBEdit share more than a few ideas about text editing. The only real diversion from the BBEdit model I’ve made was a brief foray into the world of Kate on a Linux system. I liked Kate, it had a lot of nice features, but I still came back to BBEdit in the end. I should probably also mention that I keep a copy of SubEthaEdit around so that I can (occasionally) connect up with someone else’s machine and co-operatively debug their code without fighting over a keyboard – it’s a one trick pony for me, and I only need that trick once in a blue moon, but it does the job perfectly when called upon.
But that doesn’t mean I’m not willing to make the jump to another editor if the advantages make it worthwhile. And thus, this brief series of posts. With the release of TextMate 1.5 I have decided to give it a try for, well, two reasons mainly: the first is that it has code folding, and I’ve been finding myself missing code folding in BBEdit more and more of late; the second is the fact that the RoR masses adore it. The first reason is rather more important to me than the second.
Plus, I’m starting the coding phase of a new project this weekend so it seems like an ideal chance to give TextMate the sink or swim test.
But before I leap in, I want to arrange some criteria so that I don’t end up spending €39 based on an ‘ooh, shiny’ reaction only to come back to BBEdit in 3 weeks and realize I wasted my money on something I didn’t need. So, off the top of my head, the major requirements I have in a text editor:
- MPW 9, not anti-aliased. I love this font, it looks awful anti-aliased. I use it everywhere I deal with text, which at the moment is pretty much just BBEdit, Terminal, Apple Mail and MarsEdit. This is a definite dealbreaker, if I can’t have this I won’t even try to work around it. Bonus points will be awarded if I don’t have to fiddle with
defaultsto get it. - Regular Expression based Searching (and Replacing). Approximately 10% of the time I’m in BBEdit is spent with a temporary documents throwing Search and Replace patterns at some text. If an editor can’t do that, I don’t want anything to do with it.
- Syntax Highliting. In my choice of colours. I have the colours I like (pretty much the MPW defaults) and anything else seems wrong. If I have to jump through a lot of hoops to get my colours applied consistently, I won’t bother and I’ll drop the editor.
- Documents Drawer. This is a recent addition to the list, but ever so wonderful. Tabs might work, but the problem is capacity. I just checked, on my 12″ screen BBEdit’s Document drawer holds 34 files without scrolling. I can’t imagine how 34 tabs could be displayed and still be usable. I want a list of files down the side and one editor. When I click a file, it opens in the editor, when I click another file it opens in the same editor, replacing the previous file. They’re both still open, though.
- A Functions Pop-up menu. I need to be able to jump right to a given function/procedure/etc. in a file. This is also a deal-breaker.
- A BBEdit-style header on printouts. BBEdit gives the filename, the time and date of printing and a page n of m entry in the header. If I can’t have that, I’m not interested.
- Width indicator. BBEdit used to have a Phillip Bar, a little indicator that showed the 80th column. in recent versions this changed and beyond the 80th column (or, as I have it set, the 96th column), the background is light grey instead of white. This is really useful for making sure that the text you’re writing will fit the width of the page you’re going to print it out on. It’s also a good indicator that your line of code is too damn long or you’ve nested too many if statements.
And, of course, there’s always a wishlist. This is the stuff I want, but BBEdit doesn’t provide:
- Markdown syntax colouring. BBEdit’s Syntax Colouring Engine can’t do Markdown easily, I accept this because I write most of my Markdown-formatted text in MarsEdit. Still, it would be nice to have.
- A Nested Directory Tree in the Document drawer. I use CakePHP a lot and it has a very specific directory layout and file naming scheme. Which means that in a flat listing, I end up with a lot of files named index.php and show.php with no way of distinguishing them in the list. Having the drawer reflect the directory tree would automagically keep them all organized.
- A Documents Drawer that takes up less space. This is probably a physical impossibility, but it would be a really big feather in the cap of whoever provides it. As I said, I have spend most of my time on a 12″ PowerBook, so screen space is at a premium. I’ll happily auto-hide the Dock, but I just can’t bring myself to hide the Documents Drawer. (Probably because it’s a Drawer and thus the window has to be resized when it’s shown or hidden. So there’s the solution, I guess, a floating Documents Palette that only shows itself when I fling the mouse against the left hand side of the screen. (The mouse gets flung against the right hand side when I want to scroll — getting in the way of my scrolling would just piss me off.))
- Code Folding. This is a major bonus to whoever provides it. It’s the one thing I really miss in BBEdit.
In fact Code Folding is so valuable to me, I’m willing to forget the “It’s time to turn envy into pride and end your desire for Windows- and UNIX-based editors once and for all” ad campaign that heralded the release of TextMate. That campaign left a really bad taste in my mouth. Which is probably the sort of reaction that led to that message getting scrubbed from the face of the Earth. (Note to future Revisionist Historians: the Internet Archive doesn’t store images, so put your questionable slogans in image files. Because once you pull that file off the server, it will linger a while in Google’s cache and then disappear forever.) Just to drive the reasons I am so prejudiced against TextMate home, here’s an excerpt from John Gruber’s Linked List for 6 October, 2004:
TextMate Released ★ Supposed BBEdit-killer from Allan Odgaard. I find it telling that the web page starts with the supposition that Mac users envy Windows text editors.
2lmc Spool on TextMate ★ 10-minute summary. Blech is unimpressed, as am I.
Michael Tsai on TextMate ★ Michael Tsai, in a very astute first look at TextMate:
TextMate doesn’t feel like BBEdit, CodeWarrior, Alpha, QUED/M, or Symantec’s IDE. It also doesn’t feel like ProjectBuilder, Project Builder, Xcode, or third-party NSTextView-based editors such as SubEthaEdit and TeXShop. As a result, I think it feels all wrong, but TextMate wasn’t designed for old Mac hands like me. It was designed for switchers. I would have a hard time switching to another platform if it lacked an editor that felt right, so I can certainly understand MacroMates’ motivation here. I’m rooting for their success in making switchers feel at home on the Mac.
But enough of the past, I’m going to give TextMate an honest going and see how it does.

Enough of the past indeed, here is what John Grubers current linked list says:
TextMate 1.5 ★ Has been in public beta testing for a while as version 1.1, but even 1.5 is a humble version number; TextMate is much improved over 1.0. Also, don’t miss TextMate developer Allan Odgaard’s “Year in Review�, where talks about how he turned developing TextMate into a successful indie Mac software business.
Source: http://daringfireball.net/linked/2006/january#fri-06-textmate
I probably should have included a few balancing quotes to make it clear that there has been a general shift towards a more favourable view of TextMate since its release. I wasn’t intending to cast dispersions on TextMate or Allan Odgaard, I was attempting to provide a source for any anti-TextMate bias that creeps into this or later posts.
Thanks, joachimm, for providing the balance for me!