A few years ago, I wrote RoaringDiff because I missed xxdiff when working on my Macs and compiling xxdiff on the Mac is a non-trivial exercise. Plus, I had always wanted to write a differ, so what better way to spend my vacation after I quit my job than to write a differ? Yeah, I couldn’t think of anything better either.
Anyway, I’ve been using RoaringDiff pretty heavily for the last few months and it’s getting high time to set aside a few days and fix some bugs in it. I was inspired to write this rant about my own code when I discovered yesterday that I don’t provide a way for the user to set the text color. What the hell? Sure, set the background color, but it had better have good contrast with black, because you’re stuck with black for the foreground. While we’re on the subject of color, where the heck is the “reset to defaults” button in the color preferences?
One of the premises of RoaringDiff is that it’s a GUI differ but ideally suited for driving it from the command line. I’ve been reconfiguring my office, getting ready to buckle down for 4 months of hard coding. As I mentioned in a previous post, this has included spending ~$4000 on all new monitors. With the new video configuration, I’m really missing a -geometry argument from RoaringDiff, an issue I’ve known about from the get-go. The lack of a -geometry argument might be excused if the tool would remember the last window position, but it doesn’t. It always maximizes on the main graphics device.
It’s also time to update the text rendering to use Quartz instead of QuickDraw. In Leopard, running the differ from the shell spams the user with:
2008-04-07 22:11:33.068 RoaringDiff[5645:10b] Warning once: This application, or a library it uses, is using NSQuickDrawView, which has been deprecated. Apps should cease use of QuickDraw and move to Quartz.
Not very inspiring, especially when traversing a few dozen files with svn diff.
Also, why does the differ insist on showing the “open these files to diff” window when launched from the command line? Why doesn’t it quit when the user closes the window? Why do the line numbers in the gutter look foolish? Should there be a gutter on the right side of the window too, so that when the user stretches the diff view across two identical width displays, the center of the diff is, uh, in the center? How come the differ doesn’t show the differences within the line (like xxdiff does)? (Answer: Vacation ended.) Granted, the differ does show the cool “stacked” view at the bottom of the selected line, which is better than nothing, and is better than any other differ I’ve seen when you want to carefully compare two specific lines. But when someone renames 40 variables in a file, the individual line-by-line examination is too tedious to use.
Expect an updated differ soon.