soeren says

Safari 5

June 12th, 2010

Monday saw the somewhat quiet release of Safari 5. One can speculate as to whether widely-discussed network issues during the keynote led to Steve dropping the subject, whether some features, in his eyes, lack the polish to be worth presenting, or whether it had never been intended to be featured at all.

In any case, it is a worthy upgrade, bringing us Chrome-like DNS prefetching and geolocation, greatly improved address bar autocomplete (though no merging of the address and search fields — personally, I’m undecided, but many consider this a flaw) and the ability to undo the accidental closing of a tab. Consistently with just about any other application, this is accomplished through Edit → Undo, but other browsers would likely place this feature in the History menu, where even Safari itself has the related Reopen Last Closed Window.

Though I’m in favor of them, the autocomplete changes will take some getting used to. In the screenshot on the side, how do you select the URL to change part of it?

And then there’s Bing support. Safari on Windows and iPhone (but, oddly, not Mac) had supported Yahoo! as an alternative engine for a while; now, the Mac and Windows versions both support all three big search engines. This sadly does not mean OpenSearch support; unlike IE 7, Firefox 2 and others browsers, Safari still doesn’t support this Amazon-created standard for search engine information. It does, however, apparently mean that search engine configurations are no longer hardcoded in the binary itself; rather, there’s a ~/Library/Safari/Configurations.plist.signed enumerating the engines by name, home page URL, URL formats for queries and the respective suggestions API, etc. Past the end of the markup, there’s an RSA signature, suggesting that Safari won’t accept user modifications for whatever reason. Instead, cursory checks suggest it ignores the file’s contents entirely.


The two big features, however, are clearly Extensions and Reader.

Extensions

Credit to extensions as we know them today largely belongs to Firefox, which started off with a very simple, lean feature set (much like Safari 1.0, and in stark contrast with Opera at the time), but allowed virtually unlimited customization and enhancements. This was facilitated by Firefox’s cross-platform chrome1 being developed in XUL, CSS and JS, much like a web page, except with an XML dialect for user interfaces rather than for the Web. This means relatively easy adjustments to just about any part of Firefox’s chrome.

Google Chrome, using native UI instead, followed the different approach of allowing little “web pages” to be written that hook into predefined APIs, such as to add another button to the toolbar. This yields less flexibility, but accounts for most common cases.

Finally, Greasemonkey, itself an extension for Firefox, allows JS-based customization of the content of web pages — e.g. removing ads, tweaking the layout or adding features. Chrome allows most Greasemonkey to run and treats them seamlessly as extensions.

Safari’s model is much closer to Chrome’s, though it has no built-in support for Greasemonkey.2 Apple provides a Conversion Guide which explicitly mentions all three previous types of extensions. As much as I wish they had made Greasemonkey extensions just work, the feasibility of which is demonstrated by Chrome, but the conversion is rather easy, and the cool Extension Builder helps, too.

One oddity is the requirement to sign up with Apple’s Safari Developer Program. While free, it requires an account, and as of five days later, they still have yet to approve mine3. After that, you get to sign your extensions, and only then can you actually use the Extension Builder in a meaningful way. Perhaps Apple plans to use this facility for a kill switch, i.e. to weed out malware. Who knows — perhaps they even intend to run an opt-in Extensions Store.

Extensions, once ready to install, are .safariextz-suffixed xar archives. Unpacked, they’re .safariextension folders, with an Info.plist and various other files. The archive itself appears to contain a special tag (perhaps a digital signature assigned to the program member) that makes Safari accept it; simply recompressing the folder using xar -cf will not work.

Overall, the feature doesn’t seem finished. Enabling extensions is supposed to be possible through Preferences, but it takes a trip through the Develop menu (which is normally hidden). Only then (and, in my case, after another relaunch) does the entirely Extensions pane in Preferences appear, and even after that, I’ve had a previously-installed extension suddenly vanish entirely. Rather than directly offering an installation, Safari will download an extension, then require you to open the resulting, otherwise useless file.

Even the built-in update mechanism has its weaknesses: leaving the Install Updates Automatically checkbox unticked, I would still have expected to be notified of available updates. And once they were installed, they were also re-enabled if previously disabled, and toolbar items re-added if previously removed.

An Extensions Gallery is promised for later this summer. Until then, this Tumblr account does the job just fine.

Reader

If Extensions are finicky but useful, Safari Reader is even messier, and often useless.

Going by the revised Acknowledgments, the feature is largely based on Arc90’s Readability project, which I’ve been increasingly using in the recent months, as website layouts get less and less, well, readable. (My settings: Athelas, Large, with a Medium margin. Gorgeous.) When about to leave, but wanting to read something on the go, I instead use Instapaper, invoking its Read Later bookmarklet using cmd-7, then using Instapaper Pro on the iPhone to get a nicely formatted, distraction-free, no-fingers-necessary reading environment. Both Readability and Instapaper remove most of a website’s layout, focusing largely on text. For the desktop, I find Readability’s output slightly better.

Safari’s is… different. Some pages that work just fine in Readablity and Instapaper just don’t at all in Safari Reader, not offering the little Reader button in the first place. Others only offer a portion of the article, stopping at a seemingly random location of the page, without any indication to the user that there’s more to read.

Yet others, however, work great. Consider this four-page Computerworld article, which it excellently lays out all in one scrollable pane, with little separators signifying page breaks. It’s awesome for that, and neither of the two others offer this capability.

But alas, the results are really hit-and-miss. Of this two-page eWeek article, it only shows the first page, and then the comments — with a heading in dark blue on darker blue, no less. Clicking the Next link does get you to page two, but leaves Reader; you have to re-enter it.

Readability and Instapaper are both continuously improved. It’s unclear to me if Safari Reader updates itself over time, or if newer versions will only be supplied as part of general Safari updates, which would suck — because right now, it just isn’t that good.

Post scriptum

The unpolished feeling of the two big additions makes me wonder why Safari 5 was released at all. As a technology preview, sure. As a final product worthy of a marketing page, though, it almost feels as if Apple was trying to steal the thunder of the first final release of Chrome for Mac.

  1. A.k.a. all portions of the user interface that aren’t the content itself.
  2. There’s always GreaseKit, a port of Greasemonkey itself.
  3. It also comes with weird “Once you’ve completed your purchase”-type screens and mentions of “iPhone”, even though it is free and unrelated to their recently-rebranded iOS platform. It’s clearly a quick and dirty derivative of their other two programs.

Posted in Elaborated

Share | No Comments

June 4 Chuckellania

June 5th, 2010

Posted in Chuckellania

Share | 2 Comments

June 3 Chuckellania

June 3rd, 2010

  1. Why can I still not order a MacBook Pro without an optical drive?

Posted in Chuckellania

Share | No Comments

June 1 Chuckellania

June 1st, 2010

Posted in Chuckellania

Share | No Comments

May 31 Chuckellania

May 31st, 2010

Posted in Chuckellania

Share | No Comments