Scoped Styles, Deflated WebSockets and the Vibration API
Published on in Google Chrome, Last Week, tech, WebKit. Version: Chrome 19
Last week, 912 commits landed in Chromium and 754 at WebKit, totaling up to 1,666 changes. Highlights include scoped stylesheets, parsing of properties for the Grid Layout and a new interpreter for Apple’s JavaScript engine.
Two new extension APIs have been added to Chromium, namely a fontSettings API which will (so far) allow you to retrieve the font family for a given script, and a Key Bindings API which allows you to register shortcuts triggering events in your extension. An API has been added allowing the Chrome Web Store to install multiple extensions at once, and extensions now also support icons sized either 256×256 or 512×512 pixels.
A command line flag and an about:flags entry have been added to Chromium allowing you to enable support for scoped stylesheets. CSS rules declared in <style scoped> elements will only apply to the subtree rooted at the style element’s parent element, which will prove to be really useful for components and better encapsulation of styles.
Web Inspector’s Audit Panel gained the ability to warn developers about CSS properties which should be unprefixed. The Ctrl/Cmd {+,-,0} key combinations may now be used to control zooming of the inspector, attributes containing links can now be properly selected in the Elements Panel and, while it’s not enabled by default yet, managing IndexedDB is making visual progress now. Showing re-paint rectangles is now an Inspector option and three patches landed preparing changes in the Timeline Panel, such as the ability to align events by their start time.
Following inflator and deflator classes, WebKit’s WebSocket implementation now supports per-frame compression through the DEFLATE extension. Samsung’s Kihong Kwon landed initial support for the Vibration API. The zero-width joiner (0x200D) and non-joiner (0x200C) characters are now recognized by the JSC and v8 lexers, the PopStateEvent’s state property now equals history’s state property’s value and spin buttons now fire two events.
Initial parsing support for the grid-column and grid-row CSS properties has been added as part of support for the CSS Grid Layout module. <rt> elements won’t inherit the text-decoration property anymore, file upload controls can now stretch to make sure the text fits in the label and the click event for transformed SVG elements now is reliable.
Apple’s JavaScriptCore is now a triple-tier virtual machine, adding a new low level interpreter which is 2 to 2.5 times as fast as the old one. While performance of the triple-tiering engine is neutral on performance tests, reducing the amount of JIT’ed code delivers strong performance improvements on actual websites.
Other changes which occurred last week:
- Style and link elements will now emit events based on whether the stylesheet was successfully loaded.
- Ian Vollick has been busy on implementing support for animations in Chromium’s compositor.
- An empty skeleton of KURL based on WTFURL, a new URL parsing library, has been added.
- Both IndexedDB as deferred canvas rendering can now be traced through Chromium’s about:tracing.
- The requestAnimationFrame mechanism has been enabled for the BlackBerry port.
- The drop-shadow() CSS filter can now be applied to composited layers on Chromium.
- An IDL attribute checker has been added to the generator, and is now enabled for all ports.
- The Page Information button will be replaced with a Website Settings UI, first part landed last week.
- The bundled version of Flash will now be enabled by default for 64-bit Linux installations of Chrome.
- The HTTP Referrer header will now be set when requesting media downloads.
- The FractionalLayoutRect type has been added in preparation for sub-pixel layout support.
- Chrome on Android sheriffs now appear on the Chromium Console page.
- After allowing a 100 column limit for Java files, Marcus Bulach landed the first Java file!
Last week also happened to be Evan Martin’s last week as a member of the Google Chrome team. Besides having made more than 1,400 commits, Evan has had tremendous impact on the project ever since he started working on it. Thanks, and good luck on your next endeavours!