Surfin’ Safari

WebKit Fixes in Safari 2.0.2 / Mac OS X 10.4.3

Posted by Maciej Stachowiak on Tuesday, November 1st, 2005 at 5:30 pm

Continuing our recent tradition of WebKit fix lists, here is the list of WebKit bug fixes in Safari 2.0.2, which is included in the Mac OS X 10.4.3 Software Update. This list is courtesy of Safari/WebKit Integration Engineer Tim Hatcher. As an added bonus, the versions on the release branch are tagged Safari-2~0~2.

Again the usual disclaimers: This list does not include any changes to Safari the app, only to the open source components (WebKit/WebCore/JavaScriptCore). We do not guarantee we will do this for future updates.

Fix List

  • Passed the Acid2 test. The detailed list of fixes was posted on hyatt’s blog.
    • Fixed parsing of the rel attribute on <link>s.
    • Disallowed <table> inside <p> in strict mode.
    • Added support for min/max-width/height for positioned elements.
    • Fixed the rendering glitch that caused the reference page to paint garbage.
    • Made sure that percentages that go to auto don’t mess up the self-collapsing block check.
    • Implement full SGML-style comment parsing for HTML in strict mode.
    • Make sure empty tables honor CSS-specified height in strict mode.
    • Fixed baseline alignment within table cells to use the bottom of empty blocks.
    • Fixed floats to not grow if child floats overhang but the height of the outer float is auto.
    • Made sure percentage min-height goes to 0 and not auto when the percentage does not apply.
    • Implemented fallback content for the <object> element and fixed intrinsic sizing to work properly when images are specified in the object element.
    • Disabled antialiasing for the drawing of polygons.
  • Eliminated many memory leaks and other sources of memory growth.
    • Fixed a bug where the WebKit page cache can grow without bound when there is a snapback item around.
    • Fixed several 32-byte leaks related to XMLHttpRequest.
    • Fixed a memory leak in KWQArrayImpl::resize().
    • Fixed many leaks of StyleBaseImpl called within computeAndStoreNodeDesiredStyle within -[WebView paste:].
    • Fixed many leaks of StyleBaseImpl called within fixupNodeStyles within -[WebView paste:].
    • Fixed many leaks of StyleBaseImpl within startMarkup within -[WebHTMLView _writeSelectionToPasteboard:].
    • Fixed many leaks of StyleBaseImpl within createMarkup within -[WebHTMLView _writeSelectionToPasteboard:].
    • Fixed many many leaks in JavaScript parsing.
    • Fixed additional parsing leaks on malformed JavaScript.
    • Fixed 14 leaks of WebFileButton and associated objects, seen after running WebKit layout tests.
  • Many RTL/bidi text fixes.
    • Several fixes in WebCore’s bidi algorithm.
    • Fixed a bug where Hebrew, Arabic, Farsi and other RTL languages were being rendered with incorrect weighting.
    • Fixed a bug where Hebrew, Arabic and other RTL languages would fail to render RTL in some cases.
    • Made visually ordered Hebrew render correctly.
    • Fixed incorrect bidi layout of ETs, ANs, and ENs in some contexts.
    • Fixed the final layout order of text runs with different bidi embedding levels.
    • Fixed bidi layout in many cases of explicit Unicode embedding.
    • Fixed layout when English numbers appear in the among the RTL characters.
    • Fixed a bug where Hebrew or Arabic text on long pages became garbled.
  • Added support for multipart/x-mixed-replace content (often used by web cams).
  • Fixed handling of JavaScript catch blocks where there is no try block, only a finally.
  • Added support for the JavaScript hasOwnProperty method.
  • Made JavaScript regular expressions stop crashing when using certain ranges of Unicode characters.
  • Improved date string parsing when making Date objects in JavaScript.
  • Fixed a bug where some applet LiveConnect calls threw privileged exceptions.
  • Made JavaScript’s Date.setUTC...() functions take Daylight Savings Time into account.
  • Added filename and line number information to more JavaScript exceptions.
  • Fixed a bug where XML parsing during an XMLHttpRequest spins up the hard drive, preventing idle sleep.
  • Fixes a crash when an XMLHttpRequest had a NULL document (seen commonly on Friendster and the Apple Widget download page).
  • The <canvas> backing store is now zero filled to prevent corrupted areas.
  • Made sure that is always an element, not a text node.
  • Fixed a bug where line breaks do not show in blocks styled with whitespace: pre; word-wrap: break-word.
  • Changed the HTML parser to no longer strip new-lines after tags in most cases - now it will only strip the newline immediately after a <pre> open tag.
  • The document() function is now implemented for XSLT.
  • Better tab support in editable areas (primarily in Mail when composing messages.)
  • Improved word selection with tabs characters on the same line.
  • Fixed an editing bug where deleting a line sometimes makes the insertion point jump to the top.
  • Fixed designMode to allow editing in an <iframe> when the src attribute is "" or about:blank.
  • Made selecting an item from a <select> menu with the mouse add a focus ring if keyboard access is on.
  • No longer ignore CSS font-family and font-size on <select> elements with size > 1.
  • Menu separator support: an <hr> inside a <select> with size 1 will now add a horizontal separator in the menu.
  • Made document.writeln() work with windows opened via"about:blank") in same function.
  • Fixed a bug where fails if name attribute is the name as a window just closed in same function.
  • Support for scrollIntoView method for DOM elements.
  • Made XMLSerializer.serializeToString handle any DOM element, not just documents.
  • Made the <canvas> element handle bezier curves correctly.
  • Added support to <canvas> for quadraticCurveTo().
  • Fixed a bug where insertRow() on a table containing whitespace with no <tr> and <td> elements would fail.
  • Scrollbars are now updated properly when laying out pages.
  • WebKit will now display in composited Carbon windows.
  • More Objective-C DOM classes are now exported to allow categories or do other things that require class name linking.
  • Fixed an Objective-C DOM bug where changing a style value in a style sheet rule didn’t reflect the change in the WebView.
  • Fixed a bug where Shockwave for Director renders 3D content vertically offset from embed space when using OpenGL.
  • Fixed a bug in some cases where named anchors don’t scroll to the right place.
  • Fixed a bug where JavaScript throw statements would fail inside eval.
  • Fixed a JavaScript infinite recursion when looking up properties on
  • Improved JavaScript date handling if the timezone isn’t specified: rather than returning invalidDate, substitute the local timezone.
  • Fixed a bug where tiled images tiled incorrectly when printing.
  • Changed JavaScript to use a custom allocator for a 9% speedup on JavaScript iBench.
  • Many miscellaneous JavaScript optimizations for a 12% speedup on JavaScript iBench.

50 Responses to “WebKit Fixes in Safari 2.0.2 / Mac OS X 10.4.3”

  1. simx Says:

    I just wanted to make a quick observation — does Safari actually pass the Acid2 test now? In my comparison of how Safari 2.0.2 renders the test page ( ) and the reference rendering ( ), the diamond nose in Safari’s rendering is one pixel shorter on the bottom two sides.

    While, of course, this seems to be the only problem with Safari’s rendering of the test and I may be being quite picky, it does suggest that there needs to be a minor change before Safari actually passes the Acid2 test.

  2. Trackback from

    Challenge-Response:Safari/Preview Whine Whine

    I was hanging out on the internets complaining about things as I always do. This time I was complaining…

  3. maciej Says:

    The specifics of the nose size depend on undefined behavior, as also noted by Opera. Both renderings are considered correct, according to the author of the test.

  4. justy Says:

    I’m still seeing a problem with misaligned Flash elements that I first saw with the nightlies. At, for instance, the Flash element is moved down approx. 20 pixels. Now, what’s odd is that the active areas for UI elements are where they would be if the Flash element were correctly rendered. This didn’t used to happen with Safari 2.0.

    I can’t tell if this is a problem with Flash (because Flash ads on, say, arstechnica look right), or if it’s a problem with the coding of GW’s web site.

  5. Brady J. Frey Says:

    Ironically, I have a similar problem in one of my flash sites now in the new safari… the funny thing is, it is rendering different on different comptures, all updated and running the same webkit. I’m at a loss then if there’s something wrong with builds (as I’m guessing) or if there’s an inconsistency that I don’t notice? Either way, some have a huge pixel shift, some do not.

    Small beans, though — beautiful job making safari so advanced!

  6. Pingback from SitePoint Blogs » Safari wins the Acid2 race:

    [...] luded in the Mac OS X 10.4.3 update from Apple, includes Acid2 compliance on its extensive list of fixes. The iCab and Konqueror browsers have also boasted Acid2 compliance, but they have yet to [...]

  7. Diggory Says:

    Thanks for all the hard work everyone.

  8. chem Says:

    It seems has not yet been updated, for example the min-height/max-height on positioned elementes is fixed now.

  9. Ton22 Says:

    Just a quick note on Safari 2.0.2. For some reason it still renders ’s in CSS text-transform: capitalize setting (like in The Baby’s Bottle) the wrong way. Safari 2.0.2 renders it The Baby’S Bottle. The nightly builds render it right. Hope this can be fixed ASAP as this render problem thingy goes a long long way back. I always hope for the best when a new Safari hits the Application folder, but alas. :(

  10. Robin Says:

    “Disabled antialiasing for the drawing of polygons.”

    Is this for elements? Or possibly border intersects?

  11. Robin Says:

    That should have been <canvas> elements - the blog ate my unescaped html.

  12. Luke Says:

    The inside a tag is an interesting addition, and I like the effect it produces. It is, however, non-standard and doesn’t validate. Does anyone know if other browsers will just ignore it?

  13. Luke Says:

    That last comment should say “The <hr> inside a <select> tag”. :)

  14. alastair Says:

    Am I missing something or does the XSLT document() function not work as intended for local files?

    document(’file:///full/path/to/doc.xml’) - works
    document(’doc.xml’) - doesn’t work, gives “unsupported URL” error
    document(’file:/doc.xml’) - doesn’t work, gives “file doesn’t exist” error (mistakes it for ‘file:///doc.xml’)
    document(’file://doc.xml’) - doesn’t work, gives “file is directory” error (mistakes it for ‘file://doc.xml/’)
    document(’file://./doc.xml’) - doesn’t work, gives “file doesn’t exist” error

    (where doc.xml is in the same directory as the source doc and stylesheet)

  15. Robin Says:

    Luke - personally I’d use <optgroup> elements inside a <select> over <hr>s.

  16. Phrogz Says:

    Thanks again for the detailed changelist. Well done! :)

  17. Pingback from Gustomela  Desperate Mac Users! › WebKit Fixes in Safari 2.0.2 / Mac OS X 10.4.3 › November › 2005:

    [...] .2 / Mac OS X 10.4.3

    filed under Apps + Mac OS X - posted @ 6:06 pm

    Su Surfin’ Safari la lista completa e dettagliata di tutta la monnezza che hanno dovuto scrostare da Safar [...]

  18. Pingback from note@Aerialarts » Acid2�?�格より�?�IE消滅�?��?�嬉�?��?�:

    [...] �IE消滅�?��?�嬉�?��?� Filed under: Web Design, Software — ar19 @ 3:21:06 WebKit�?�Acid2テ� [...]

  19. Pingback from » O Safari συμβατός με το Acid 2 test!:

    [...] 2.0.2 version του browser έχει διο�?θώσει πολλά από τα παλιά bugs και δίκαια λοιπόν η Apple ανακη�?�?σσετε νικήτ�?ια. Πίσω από [...]

  20. Trackback from Valid Blogging:

    Safari und Acid2

    Apple hat heute das dritte Update für Mac OS X Tiger veröffentlich. In der Änderungsliste für Mac OS X 10.4.3 ist unter anderem auch Safari aufgeführt. Und endlich ist in diesem Update die Webkit Version enthalten, die den Acid2-Test…

  21. Drew Says:

    This level of detail in the changes is very helpful. Thanks!

  22. Drew Says:

    And congratulations on a great release. :)

  23. ap_kelly Says:

    I too was excited when seeing the Acid 2 Test rendered correctly in the latest release of Safari, however, I noticed that if I put my 3 button mouse with scroll wheel over the smiling face and use the scroll wheel then the image falls apart, some bits scroll, other do not, and you end up with an image that isn’t compliant.

    I use a Mac Mini with 10.4.3 and a Logitec 3 button mouse with scroll wheel.

    Other than that, keep up the good work.


  24. goldfinger Says:

    I’ve been using safari 2.0.2 regularly since the 10.4.3 update. It looks like there still may be some memory issues. I’ve been doing “normal” surfing (not many open tabs, just bouncing around from one site to another) and the real memory allotment for safari (as reported by activity viewer) has steadily increased over time. It stood at about 273 meg when I decided to play it safe and close. (had it open almost constantly since the update).

    I’m using the standard array of plugins: quicktime 7.0.3, adobe reader 7.0.5, flash 7.0 r24, shockwave 10.1.0, wmp, Java 1.4.2_09 Plug-in (Cocoa), RealMedia Player (latest version). Prior to closing safari (when it reached 273 megs) I had made the rounds of sites that made use every plugin.

    I don’t have, nor have I ever installed, any haxies, modifications, or additions to safari. It’s an out-of-the-box installation on my eMac, with 1 gig of ram.

  25. Twist Says:

    Looks like the javascript bug dealing with modifying the contents of textarea’s is still in effect. Example of this would be the formatting buttons on many online forums, blogs, and at

  26. Pingback from » Safari Passes the Acid2 Test:

    [...] interested in the more technical aspects of this accomplishment, then you may want to see the list of changes that the Safari and WebKit developers made to pass the Acid2 test. (hat-tip: Tom) [...]

  27. Roberto Avanzi Says:

    I am willing to play the devil’s advocate: The latest safari renders the acid2 test perfectly, but NOT the data-url-free version available at

    Opera 9 pr 1 OTOH renders the standard version ok and the data-url-free version almost correctly.

    You made a great job and Safari ist just wonderful. I am sure more wonderful improvements are to come…

  28. Vince_Safarian Says:

    Hi too see the acid2test problem : when scrolling the face fall apart

    as reported in comments and here

  29. ghutchis Says:

    I understand the standard disclaimers, but this is very helpful as both a user and a developer.


  30. Pingback from MHC-in-the-box » More on the WebKit fixes in Safari 2.0.2:

    [...] l all the changes in Safari and WebKit the 10.4.3 update brought to Apple’s browser, WebKit Fixes in Safari 2.0.2 / Mac OS X 10.4.3. Once again, great work fellas!!!. While [...]

  31. sulka Says:

    Good work! I can see Safari’s memory usage is down and the browser feels slightly faster. However, I’ve seen more Safari crashes after the update than before it. After updating, I’m getting three-four crashes per day, before the update I got less than one crash per day on average. :(

  32. grahams Says:

    Great new release, but was disappointed that WebKit’s recently announced support for CSS3 Backgrounds and Borders has not been included. I’ve tried to preface “border-radius” with both “-moz-” and “-khtml-” but to no avail.

    Is there a particular reason for this being held back?

  33. Drew Says:

    Kelly and Vince, as I understand it, scrolling is not an aspect of the Acid2 test. Because the elements are positioned statically to appear the same place regardless of the scroll, it looks to me like this is in fact the proper behavior. Part of the reason the Acid2 page is so interestingly constructed is to not take scrolling into account. It would be unreasonable (and in fact, wrong) for Safari not to have these elements stay in their location when the page scrolled. I see nothing wrong with Safari’s implementation here.

  34. d.w. Says:

    This was probably a Syndication Framework change rather than Safari or Webkit, but it looks like Atom 1.0 feeds are now supported.

  35. lex Says:

    I just want to echo the Flash-related comments above. In my browsing experience, Flash ads and interactive SWFs all display approximately 20 pixels too low, but respond to clicks in the “original” space.

  36. justy Says:

    I’d like to add an update. The latest version of Flash (8,0,22,0) seems to fix this problem, at least on the site I posted earlier. Many of the Flash ads on arstechnica also appear correctly, whereas ads for Grand Theft Auto would drop several pixels, while other ads wouldn’t misbehave.

    Again, the 8,0,22,0 version of Flash seems to fix this behavior. The updated version of Flash dates from 9/12/2005.

  37. Pingback from » Blog Archive » WebKit Fixes in 10.4.3:

    [...] . If you’d like to get an overview of the changes and fixes which 10.4.3 implements, head over to Surfin’ Safari. [...]

  38. courtfkizer Says:

    How about a build that lets you click messages in Gmail. it’s been broken for several weeks in nightlies…..

  39. ccapeng Says:

    Please update Safari 1.3.

  40. d.w. Says:

    Here’s a Microsoft’s developer’s explanation for why their AJAXy portal thing doesn’t work in Safari. Is this valid? Google’s stuff (e.g. GMail and Google Maps and Reader, etc.) seem to be able to work around these Safari “limitations” pretty well…

  41. Roberto Avanzi Says:

    Why do the links in work in Camino but not in Safari? Otherwise, a great browser.

  42. maciej Says:

    A number of you have mentioned various possible bugs in Safari/WebKit here - I encourage you to file them in under the WebKit component.

  43. Trackback from

    Safari and Content-Type: multipart/x-mixed-replace

    Update: 2005-11-15 Yikes! The WebKit Team just added multipart/x-mixed-replace. Thank you very much! Surfin’ Safari asks and i respond: Random fun question. If you had to pick a W3C technology to implement next in WebCore, which one would you choose? …

  44. Trackback from MacHappy:

    Safari in OS X 10.4.3 passes Acid 2 test

    I upgraded to 10.4.3 today and noticed that the Safari that is bundled with it is now Acid 2 compliant.

    What does that mean in plain english? It means that Safari is fully web standards compliant, putting it ahead of Firefox and way ahead of IE6 and…

  45. Trackback from

    Safari offset redux…

    Oh dear… Seems there may be more to the Safari offset problem/fix. After playing Shockwave 3d content (any hardware accellerated content, not just SPi-V), Quicktime VR file display with an offset.To repro, first open this link on showing Times

  46. jan666 Says:

    with every new version of Safari it gets more and more bugs! - Dear Safari-Developers please learn programming before seeding Software!!!
    I´m Fed up being Apple permanent paying beta-tester

  47. peeder Says:

    following up on what Twist wrote about the absence of selectionStart and selectionEnd properties on textarea and input form fields, it looks as if they were working on this back in late June. Here’s a bug link:

    It’s quite exasperating for me and my (100K+) users that this fix is still not in Safari 2. But it looks as if it will arrive shortly. I know you can do it, Safari is an outstanding browser!

    I’m also interested in a resolution to bug 5122…some means of reliably firing JavaScript after the DOM has been parsed but before the images are done loading and window.onload is fired. This functionality is simply essential for “unobtrusive JavaScript” patterns where event handlers are added to the DOM from JavaScript as opposed to mucking up the markup (and paying the freight to do so). We have that functionality in IE6 and FF 1: see for more info.

  48. hardcoreUFO Says:

    It would be nice to have Webkit stop using the ugly missing_image.tiff icon when an image is missing, and instead use the alt text in the image tag. Camino does this very nicely.

  49. Pingback from My Top OS X Apps at andrew.hamann:

    [...] /”> Safari Safari is fast, nimble, efficient, and, most of all, compliant. What more could you want? Honorable Mention - OmniWeb 5 And because I am in an especially goo [...]

  50. Pingback from Web 2.0 » Blog Archives » OS Stats:

    [...] f you manage a web site, need to send a file to a friend Surfin Safari - Blog Archive WebKit Fixes in Safari 2.0.2 / Mac Added support for multipart/x-mixed-replace [...]