We know he have a lot of readers out there interested in the Open Web and its capabilities, and part of that is to see the latest additions and implemented features in Firefox. Therefore, we’re introducing Firefox Development Highlights here at Mozilla Hacks.
Introduction
The purpose of this post is to highlight some of the latest (couple of weeks) developments in Firefox and Gecko. Bear in mind that these changes might be backed out at any time and they are part of our Bleeding Edge posts.
You can test them out in Firefox Nightly.
If you are interested in a steady flow of the latest highlights, you can also follow @FirefoxNightly on Twitter.
Graphic
Firefox’ graphic stack received some great improvements lately: better scaling algorithm for images and support for retina display. Gecko now downscales images using a high-quality scaling algorithm. You can see the improvements in this screenshot (click on it for a larger version):
This is disabled on mobile, where we worry about speed/multicore abilities. It’s also disabled on OS X, which has high-quality downscaling built in.
Gecko now supports HiDPI displays, for web pages, plugins and for Firefox’ UI.
Standards
CSS3 flexbox model is now available in Gecko, behind a preference: layout.css.flexbox.enable
. Go to about:config in Firefox and add that as a preference, set to true
.
Quote from W3C:
In the flex layout model, the children of a flex container can be laid out in any direction, and can “flex” their sizes, either growing to fill unused space or shrinking to avoid overflowing the parent. Both horizontal and vertical alignment of the children can be easily manipulated. Nesting of these boxes (horizontal inside vertical, or vertical inside horizontal) can be used to build layouts in two dimensions.
Web Workers
Support for transferable objects from HTML5 spec.
If you want to send data to/from a Web Worker, you have to use postMessage() method. Internally what happens is that the data is duplicated using the structured cloned algorithm and then the copy is sent. To make this sharing faster, HTML5 specs add a new concept: transferable objects, data is transferred from one context to another without copy. Note: data is no longer available once transferred to the new context. Right now we can transfer just ArrayBuffers, but maybe in the future we will support other data types.
About Paul Rouget
Paul is a Firefox developer.
About Robert Nyman [Editor emeritus]
Technical Evangelist & Editor of Mozilla Hacks. Gives talks & blogs about HTML5, JavaScript & the Open Web. Robert is a strong believer in HTML5 and the Open Web and has been working since 1999 with Front End development for the web - in Sweden and in New York City. He regularly also blogs at http://robertnyman.com and loves to travel and meet people.
7 comments