Archive for June, 2004

Pre-WWDC Notes

Friday, June 25th, 2004

Well, WWDC is fast approaching, the Tiger preview is in the can, and Mac geeks from all over the world are descending on “The City™” for five days of peace and programming.

Meanwhile, I’m just finishing my masterful (ha!) planning for the unofficial WWDC Weblogger Dinner, which seems have stabilized somewhere around 25 attendees. If anyone wants to attend and hasn’t let me know, now is the time (I’ve told Buca di Beppo we will be seating approximately 25, but I plan to call them tomorrow with an absolute, firm count).

Also, it looks like I will be at the Student Developer Career Reception event on Sunday night, so if you’ll be there, you might drop by and say hello. I’ll be the guy in the black t-shirt and jeans. What? Not specific enough? Alright—I’ll be the short guy in a black t-shirt and jeans.

I really look forward to meeting everyone, and particularly to hearing peoples’ reactions to Tiger. It should be a great show.

Understanding a Song’s Logic

Friday, June 25th, 2004

One of the things I’ve noticed about myself is that often the music I end up liking best isn’t music that immediately appeals to me. The new Wilco album, A Ghost Is Born, is a case in point. Unlike Yankee Hotel Foxtrot, which I found to be instantly accessible and endlessly playable, I initially thought of A Ghost is Born as a bit of a letdown. Now that I’ve been a patient listener, however, and really tried to “get” the music rather than expecting an instant, visceral fix, I’m finding it rewarding on a much deeper emotional level.

My favorite track on the album so far is a spare, downbeat, piano-driven song called “Hell Is Chrome.” It sounds like a fairly unremarkable track—until you begin to listen to the lyrics, which describe the songwriter’s encounter with the devil (who is not red, as is popularly imagined, but rather chrome) and his subsequent introduction to a hell that is more a state of eternal numbness than physical torment. Once you ponder this, the song’s deflationary, Lou Reed-esque dynamics make perfect sense, and, in fact, serve to place you effectively in the songwriter’s frame of mind.

The best phrase I can come up with to describe this process is that I begin to understand a song’s “logic.” Sometimes it takes some work to get there, but it’s usually worth the effort.

Feed Freakout

Monday, June 21st, 2004

I have to apologize to anyone who has been polling my RSS feed tonight. I decided to go live with a new Blosxom plugin I’ve been working on (more details tomorrow), and inadvertently managed to do quite a number on my Blosxom installation’s all-important entries_index cache in the process.

A word of advice to Blosxom users: changing Blosxom’s $datadir path after you’ve already been using entries_index can cause erratic behaviour (including the appearance of duplicate posts) since entries_index uses full paths to story files as hash keys in a post date lookup table. Oops.

News from Home

Monday, June 14th, 2004

When I first moved to California, I made a real effort to stay abreast of what was going on back home in Colorado. Now that I’ve lived here for a good 9 months, though, I can’t say that I’m very good about keeping up with the Denver news. In fact, most of what I hear about these days comes in the form of oddball news items forwarded to me by friends and co-workers, which tend to reinforce a decidedly South Park-ish view of the 38th state. A few cases in point:

  • In Granby, a small mountain town near the west entrance of Rocky Mountain National Park, a man “barricaded inside a fortified bulldozer” went on a rampage, firing shots and knocking down walls from five buildings. This event was especially odd given that it wasn’t the first time such a thing has happened in Colorado—a man in Alma used a front-end loader to do the same thing in 1998. No word yet on whether either was yelling “they took our jobs!” (Thanks to Ammon for the link.)

  • My Mom tells me that the local TV news does a story on this at least once a year, but I personally had never heard of Bishop’s Castle until Ammon Skidmore forwarded me a link he saw on Metafilter. Basically, it’s a huge, 30+ year, one-man building project—sort of like the Watts Towers in LA, the Coral Castle in Florida, or Opus 40 in upstate New York. Odd, quixotic, yet somehow inspiring and definitely on my itinerary next time I visit Southern Colorado.

  • In other architectural news, a link I saw on the front page of del.icio.us awhile ago alerted me to an odd development in suburban Denver that will surely be a source of great angst to urban hipsters everywhere: someone has actually built a subdivision of single family homes designed to resemble old factory buildings converted into lofts. Yes, Baudrillard would have a field day.

  • Meanwhile, in the world of politics, Jens Alfke’s del.icio.us links pointed me to an amusing Salon article detailing a creative proposal the Bush administration came up with to ease the reconstruction of Iraq: make Denver Baghdad’s “sister city!” Of course, no one seems to have actually asked Denver before the announcement, and reaction from the mayor’s office, which is struggling to deal with a large budget deficit, seems to be a bit non-committal. Pity—just think about the South Park plot possibilities a Denver-Baghdad relationship would create!

Unescaping XML Entities in NSStrings

Thursday, June 10th, 2004

Ever find yourself wishing that NSString or NSXMLParser in Panther provided a quick and dirty way to unescape XML entities (e.g. &gt; to > or &lt; to <) in Cocoa strings? I recently worked on a personal Cocoa project that parses simple XML documents, and I often needed to convert the standard five XML entities to their literal values. Unfortunately, unless I’m really missing something (and it’s possible I am, since NSXMLParser isn’t exactly the most documented of Cocoa classes) this isn’t something you get without the use of a DTD in NSXMLParser—at least the attribute values I was dealing with exclusively were being returned by the parser with entities intact, and the various entity-related delegate methods were not being called.

Fortunately, I found a relatively easy solution to the problem: CFXMLCreateStringByUnescapingEntities(). This handy function will unescape the entities in a string using a provided mapping dictionary, or, if no mapping is provided, simply handle the standard five. For ease of use, I wrapped the function in a friendly Objective-C method and stuck it in a category on NSString, which I am posting here for the benefit of all mankind. Enjoy!

- NSString+XMLUtils.dmg (9k)

Point Reyes Desktop

Thursday, June 10th, 2004

I love having friends visit from out of town, so when my parents and youngest brother came to visit for the long weekend, I resolved to show them the best of what my adopted home has to offer. I’ve also been wanting to see what Point Reyes looks like without the thick fog cover that blanketed it last time I visited, so I made that the first stop on our tour.

Fortunately, this time the weather was gorgeous, and I was able to get some lovely photos. As is my custom, I’m providing one of them (of the southern part of Point Reyes Beach) as a desktop in standard 1280×1024, 15” PowerBook-style 1280×854, and 17” PowerBook-style 1440×900. A Creative Commons license applies.

(Update: At Lucien Dupont’s request, I’ve posted a 1680×1050 version for those with Apple 20” Cinema Displays.)

(Update: At Dan Wood’s request, I’ve posted a 1900×1200 version for those lucky devils with Apple 23” Cinema Displays.)

Point Reyes Beach

Gmail Humanitarianism

Tuesday, June 8th, 2004

That inveterate do-gooder Jonas Luster has figured out a way to harness the power of the Gmail Swap meme for the forces of good: he and some other people who have invitations to spare are giving them away to people who promise to do a good deed in exchange (or to people who are already doing good deeds). Never one to miss an opportunity to be a humanitarian without actually spending any money or expending any real effort of my own, I jumped on the bandwagon and contributed an invitation. If you can spare a golden ticket or two, you might think about doing the same.

Getting Back to OS X’s Roots

Wednesday, June 2nd, 2004

You may think you’ve got serious OS X geek cred if, for example, you’ve been using OS X since the developer previews, but chances are my good Colorado friend Chris Jones has you beat. Not content to simply experience OS X in its present form, Chris recently fulfilled a longtime ambition by purchasing a sleek black NeXT slab running OS X and Cocoa’s venerable predecessor, OpenStep. Oddly enough, Chris didn’t have to look far to get his slice of vintage early 90s computing, since the number one (remaining) reseller of NeXT equipment happens to be based about 15 minutes from where Chris and I used to work in the Denver Tech Center.

Never having used NeXTSTEP or OpenStep myself, I’ll be curious to hear about Chris’s impressions as a modern day OS X user (I had no idea, for example, that OS X’s anthropomorphic, head shaking login window had its roots with NeXT). Maybe if he can find it, he can even get Sir Tim Berners-Lee’s original WorldWideWeb browser (a NeXTSTEP app) running!

Fixing iPod Volume Icons

Wednesday, June 2nd, 2004

Another thing I was able to do this weekend was to hand deliver my Mom’s shiny new green iPod mini (I heard a rumor that they were in stock at Valley Fair, and I lucked into getting a few). I was really looking forward to showing her how the little iPod mini icon on the desktop actually matches the iPod’s color (she’s a big fan of little details like that), so you can imagine my dismay when, after attaching the iPod, its icon on the desktop was a boringly rendered, “generic” iPod icon.

I thought about wiping the iPod and reinstalling its software using the updater, but by the time I noticed the problem I had already loaded it with music and didn’t feel like doing it again. Fortunately, it occurred to me that the various iPod volume icons were probably contained within the iPod Software Updater package (under /Applications/Utilities). A quick look inside the package (right click on the file and select “Show Package Contents,” then navigate to Contents/Resources/Updates) reveals a group of icon files named DeviceIcon-1.icns (scroll wheel iPod), DeviceIcon-2.icns (dock connector iPod), DeviceIcon-3-QKJ.icns (green iPod mini), and so on. I simply opened the terminal, then typed something like the following:

cp /Applications/Utilities/iPod\ Software\ Updater/iPod\ Updater\ 2004-04-28/Contents/Resources/Updates/DeviceIcon-3-QKJ.icns /Volumes/Katie\ Andersen's\ Mini/.VolumeIcon.icns

After unmounting and remounting the iPod, it had the correct icon in the Finder.

Just thought I’d feed that to Google in case anyone else encounters the same annoyance.