WebKit is so insanely easy to use that I'm amazed every OS X application doesn't do it somewhere, just for the fun of it. Maybe they do.
A new major feature of Colloquy 2 are the extensible conversation styles. Styles are simple OS X bundles wraped around a CSS file (at minimum) or a CSS file and a XSL file. Knowing this, the fact that Colloquy uses XML to store chat messages that come in over the network is no surprise to some. Pairing these three technologies gives us great flexibility when processing and displaying a message on screen.

The process of formatting a message follows these steps, start to finish. First, wrap the message in a simple XML envelope, encoding any special characters and representing IRC styling as XHTML. This XML envelope gets transformed with the curent style's XSL file (or a built-in default XSL file). The resulting transformation from the XSL on the XML should be XHTML that can then be rendered with help from the style's CSS file. Rendering is done via Apple's Safari (WebKit) engine -- so the possibilities are endless (evidenced by the built-in iChat like Bubbles style).

Colloquy is an IRC client for OS X that I just discovered this week, via an article posted on MacSlash. I've been looking for a decent Cocoa-based app as an alternative to my use of X-Chat Aqua, Conversation, and irssi. Having never heard of Colloquy before, I figured I'd check it out.

Colloquy is a Cocoa app, and the source is available. It's the first OS X IRC client I've played with yet that most resembles what I expect out of a modern Cocoa app. Conversation is right there, too, but I don't see any source (no offence to the author) and it doesn't yet support multiple servers or AppleScript (although those are on the planned features list).

Beyond all that, though, what has sucked me into Colloquy is the way IRC messages are presented and styled. In case the introductory quotes haven't given you the idea, this thing pipelines XML, XSL, CSS, HTML, Javascript, and WebKit to provide an immensely flexible user-customizable, modular display style system. There aren't that many styles yet, but conceivably anything one could do with the pile of technologies above can be employed in presenting IRC messages.

Yes, you could make the case that this is an insane example of overkill. If so, Conversation or a shell-based program is likely more your speed. Admittedly, Colloquy is not a featherweight IRC client. But I've been thinking about this sort of inversion of web tech for awhile. Instead of the browser hosting the app, the app hosts the browser. I've been doing a ton of tinkery UI work with HTML and JavaScript in my news aggregator and have come to appreciate the DOM and various things JavaScript makes possible in modern browsers.

This has lately lead me to consider how a browser canvas could be used as a sort of universal widget inside a native app... not at all unlike the way Colloquy uses it. Apple's WebKit encapsulation makes it just about dead simple to drop it into an app and integrate it. In fact, from a shallow glance at the docs for WebKit, it seems even simpler to use than some other GUI widgets in the Cocoa arsenal.

So... is this the start of more Cocoa apps embedding WebKit views, "just for the fun of it"? Who knows, but it really appeals to my propensity for mixing and matching different tech within the same project. I suppose it's a sort of sick addiction I've picked up from the Tower of Babel web development I've been doing for years, but it looks like fun to me!

shortname=colloquy_irc

Archived Comments

  • I picked up Colloquy several weeks ago after hearing about it via email. It is a nice IRC program that makes good use of WebKit to provide easily customisable display. Its ability to automatically identify yourself with a password to NickServ on the Freenode IRC network saves a lot of time. It has one or two frustrating bugs that have prevented it from being my main IRC client. When version 2.0 moves past beta status, I will definitely reconsider.
  • Source is right there in the SourceForge CVS repository...
  • I enjoy reading nice things about colloquy because I think its a great client also, but contrary to the above post, it emphatically does support multiple servers. Thats one of my favorite features.
  • Oh, yeah source is available and multiple servers are supported for Colloquy... I was referring to Conversation, which doesn't support multiple servers or offer source.
  • Careful with recent versions of Colloquy. After a recent upgrade (announced and downloaded via the application) corrupted its own data store of rooms in the connections window. Has this happened to anyone else?