Surfin' Safari

Recent WebKit Features

Posted by Maciej Stachowiak on Saturday, August 12th, 2006 at 11:18 pm

There have been a lot of exciting new engine-level features that have been added to WebKit over the last few months, and not all of them have received their own blog entries. Since we featured some of these in Safari/WebKit WWDC presentations, now seems like a good time to mention some of the highlights of the cool new things you can find in WebKit nightlies:

  • JavaScript getters and setters – pretty much the same as getters and setters in Mozilla.
  • DOM class prototypes – now you can get direct access to the prototype objects for DOM classes, e.g. HTMLElement.prototype, to do the same kind of prototype hacking you can do in Mozilla.
  • Undetectable document.all, for compatibility with web pages that use it without checking.
  • Much improved support for HTML editing, including execCommand support for InsertOrderedList, InsertUnorderedList, Indent, Outdent, HiliteColor, RemoveFormat, FormatBlock, FindString, InsertHorizontalRule, InsertImage, InsertHTML, Unlink and CreateLink.
  • Significant JavaScript speed improvements, adding up to 20-30% improvements on benchmarks such as the JavaScript iBench and the 24fun BenchJS.
  • Significant DOM XPath support including some of the Mozilla and IE extensions.
  • Mozilla’s XSLTProcessor extension.
  • CSS3 Media Queries
  • New CSS3 properties including resize, background-size, border-radius (now complete), overflow-x and overflow-y.
  • Continued progress on styleable form controls – textarea and pop-up menu select (but not the list box kind) are now styleable.

This is just a sampling of some of the great new web content features that WebKit supports. If you would like to see these and more in action, try a nightly build or check out the code.

18 Responses to “Recent WebKit Features”

  1. Jeff Says:

    Hurray! border-radius works for elements that have a border now. Unfortunately if the element’s dimensions are less than the border diameter it is completely ignored. I recommend proportionally decreasing the radius if the width and height match and unproportionally decreasing the size if they do not.

    The new styleable controls are nice, please make the password boxes styleable too!

    The javascript speed-up is awesome, on some tests more than a 20x improvement over Safari, which makes browsing javascript-intensive sites like digg much more bearable (try viewing the comments on a digg story with > 150 comments, it hangs for 15 seconds at times in Safari).

    I look forward to these improvements in Safari 3.0, thanks for all the hard work!

  2. pauld Says:

    Is anything wrong with the nightly builds? Border-radius doesn’t work at all; it’s completely ignored.

  3. The_Decryptor Says:

    border-radius isn’t working for me as well (Just compiled from SVN)

    So far, digg does see a bit faster, getters and setters rock, and i haven’t had a chance to try out the other stuff.

    And the new style-able form controls, well now DeviantART has a odd login textbox (dark green text on a lighter green background), no idea if that was what they were aiming for though.

  4. Pingback from Safari kehittyy | Satunnainen Björklund:

    [...]

    Satunnainen Björklund 13.8.2006 Safari kehittyy Surfin’ Safari: Recent WebKit Features. Ennen ja jälkeen « Battlestar Galactica Xbox Livessä [...]

  5. rampartmanning Says:

    I really like what I see. How long does it usually take for Safari to pick up these improvements?

  6. xfinite Says:

    about border-radius not working, try using -webkit-border-radius

  7. Pingback from Recent WebKit Features:

    [...] edit Recent WebKit Features Posted by Jon Baer Mon, 14 Aug 2006 02:49:00 GMT Recent WebKit Features: ”There have been a lot of exciting new engine-level features that have been [...]

  8. ccapeng Says:

    InsertHTML for exeCommand — that’s interesting. Anything update about Range object? Are all new updates for OSX10.5?
    Please release them to current OS.

  9. michiel Says:

    “significant” DOM Xpath support. What does it support?
    If I use SafariGuide, an xpath query like “//dl/dt/following-sibling::dd” works fine, but in Safari nightly it does not.

    Where can we find out what Safari will/does support in the nightlies? For a testcase, see http://bugzilla.opendarwin.org/show_bug.cgi?id=5576

  10. christopherbalz Says:

    Does anyone have a guess or an idea of when these wysiwyg features will ship in Safari? Are we really going to have to wait for the Leopard version of OS X to come out?

  11. Pingback from Painfully Obvious » Blog Archive » Link: WebKit:

    [...] Aug15 Holy crap! The WebKit JS engine has matured by leaps and bounds since the last Safari release. I knew about XPath s [...]

  12. Pingback from ansemond.com » Blog Archive » Leopard videos and takedown notices:

    [...] erge windows into tabs, and bookmark all your tabs Other anticipated Safari improvements are faster javascript (essential for reading digg), better DOM support and CSS3 support. Other than that, [...]

  13. bbock Says:

    Is there a way that non-developers can contribute bug reports? There’s been a problem with Safari since day one that I hope can be fixed. If you take tablized data and copy it from Safari and past it, you get the contents of each sell in a row down the page with line breaks. This is bad. If you copy the same info from Opera, Firefox, or God forbid IE, you get the desired result: tab delimited data. This is important for those of us who copy data from a web application and paste it into a spreadsheet or text file. Try it yourself here: http://www.x-rates.com/

  14. hyatt Says:

    bbock, check out the reporting bugs link in the sidebar on the left.

  15. Phrogz Says:

    Hot diggity for the getters and setters! Thanks so much for this, Webkit team!

  16. bbock Says:

    D’oh! Thanks for pointing out what should have been obvious. Sorry! Thanks for not biting.

  17. Pingback from Brauche DRINGEND Iexplorer 5.5 fr Mac - Seite 2 - Apfeltalk:

    [...] Vielleicht erklrt dir das da warum das alles NOCH nicht mit dem normalen Safari geht!
    __________________ Frher ko [...]

  18. Pingback from shepherdweb.com » Safari Bugs (Bring on OS 10.5 Leopard) » Shane Shepherd: web design and development; music:

    [...] 0.5 Leopard. Other enhancements to be included in the release with the coming OS include: JavaScript getters and setters, DOM class prototypes, New CSS3 properties including resize, background-size, border-radi [...]