Hanblog

Aller au contenu | Aller au menu | Aller à la recherche

dimanche, novembre 15 2009

WebKit's week - #10

Week from May 25 to June 7 (before r44490). To test those changes, you'll need a WebKit nightly.

Smarter border-radius (44235)

You all know border-radius. And you enjoy using it. Before this change, if the radius was longer than some metrics (eg. half the width of the element), then it's set to zero and there are no rounded corners. Since then, WebKit follow the latest rules of the spec and will reduce the radius to the max possible value.

Multiple corrections according to specs (44293, 44298, 44301, 44302, 44360, 44475, 44481)

A lot of events weren't dispatched to the window object, unlike what the spec says. Zou, fixed. In addition, some storage events needed a storageArea event giving access to the modified storage area. Those are small but necessary fixes.

Locking the anchor in view while loading

Between the moment when a page starts to render and when it's fully loaded, a lot of resources can modify the layout of a page. Therefore, the position of an anchor can change. Before this change, the browser stayed at the initial position of the anchor. Now, if the user doesn't scroll, the anchor will stay in the view.

Web Inspector's panel activation

The Resources, Network and Profiles panels all have an activation page. This activation page are here to not affect the performances of the pages when they are not needed.


This is everything for this week. Of course, this is just a selection I've made. If you've noticed any other interesting changes, please let me know. Same thing if I got something wrong.

vendredi, octobre 30 2009

Mozilla Europe Camp 2009

Paul Rouget and Mozilla Europe were kind enough to invite me to the EU Moz Camp 09 in Prague on the first week end of October. It was two amazing days and I learned a lot.

The Community

As I am not really involved in Mozilla, I don't really know how it is to be part of this big community. It actually feels pretty good. During two days, I met a lot of people, had a lot of interesting talks every time (and some beers). I've met a lot of French contributors, shared my room with Nadir Kadem from Dailymotion, met Robert Nyman (really nice person), Vladimir Vukićević lead developer of Firefox, Honza Bambas who has implemented localStorage and many others.

No one looked at me strangely when I said I was contributing to WebKit (except Tristan Nitot but I'm used to it).

And strangely enough, I might have found there why I was contributing to WebKit. gerv said that "When the community feels smaller, it grows bigger". That's what I've found cool with WebKit : you don't need to know the project for a long time to rapidly be aware of everything going on in this community.

Mike Beltzner and the future of Firefox

I really enjoyed his talk and talking with him later. He seems very smart, reactive and open to many suggestions, how to fix problems. Be careful, he does speak French!

I'm both happy and sceptical about the pace acceleration of the releases. For web developers, it's really great cause you get new stuff and bug fixes faster. But at the same time, it can be painful if Mozilla can't migrate its user base at a fast pace too. Web developers don't want three or four versions of Firefox out there. By the way, I wonder if they will change their policy concerning older version support. Right now, I believe they support the current and the previous versions only.

They were discussions on the way to ship Firefox 3.6. If it's not yet set in stone, here is my proposal: ship Firefox 3.6 as a major update to 3.5.x and 3.6.1 as a minor update to 3.5.x. Why? We need a lot of users to move to the latest version and the more effective way to do this is use a minor update. But you don't want to hurt your users so you only use minor updates once you got the feedback of the first release (and fixed bugs). I know it's not a perfect solution (user is not completely in control) but it's the best I could think of.

HTML round table

I'm not gonna talk about the whole round table here but only a specific point around education. In order to keep the web moving and catching up with the proprietary alternatives, you not only need to implement new specs, you also need good information about them.

  • Good documentation : I think DevMo is doing pretty well in this area.
  • Good cross browser data : There's a lot of compatibility tables but none of them are up-to-date, complete and accurate. I think it should be the standards bodies work (W3C or ECMA). They edit the specs, the specs requires tests so they only need a good presentation of the results with a bit of high level explanation.
  • Good examples : Showcasing the novelties is important and hacks.mozilla.org is young but effective in this area.
  • Good tutorials : Showcasing for Firefox is cool but it often forgets the real world where web developers create for multiple browsers. You need tutorials. I think Mozilla should create a place to gather such tutorials. Opera has Dev Opera for that. I really like articles like Cross-Browser Inline-Block.

But I don't think it's Mozilla's role to create compatibility libraries (such as excanvas or SVG web. It helps obsolete browsers to stay in the market and that's not really what we want.

Firebug and Jan Odvarko (Honza)

They got a lot of cool stuff coming in Firebug 1.5. I especially like the capacity to break on many events (HTML change, CSS change, JS property change). Makes it very easy to understand how a piece of software works just by saying "hey, this part of the page changed, show me the code that did it". Very smart. The HTTP Archive format is also exciting and I hope it will be integrated in the Web Inspector (even better if I find time to do it). Don't miss the slides (and detailed follow ups on his blog)

Mozilla Labs

The labs projects are very interesting. I'm still not convinced by the migration of apps to the browser (I prefer native apps using the network) but if it has to be, Prism is a good move.

The synchronization part of Weave already looks good and I like the open way Mozilla is using for all his server side efforts: develop a server, provide the protocol but also host a version. I also have big expectations on the sharing part of Weave. Something like Opera Unite (share data with friends without uploading a thing) but that can also work when you're offline (cause it's served by the Weave server which has synchronized in the background).

Jetpack is a good reaction from Mozilla but it has to happen fast. Chrome extensions will be really easy to create and ship so it will be a competitor. Not for the end user but for web developers that will try Chrome to develop extensions, maybe use it and then recommend it. I'd say don't listen to add-on developers scared by the lack of functionality, disparition of XPCOM, etc. Add a lot of APIs, get it in Firefox as soon as possible and market it as the easiest way to create extensions. You'll figure out later how to deal with existing extensions.

Irina Sandu, William Quivigier and Paul Rouget

Thank you for the organization, everything was perfect even when I missed my plane. I understand how hard it might be and being so nice while having so many stuff to take care of is amazing (I'm sure FuzzyFox will agree)

mardi, juillet 21 2009

WebKit's week - #9

Week from May 11 to May 24 (before r44117). To test those changes, you'll need a WebKit nightly.

New input types (43267)

4 new input fields are now supported : url, mail, number et tel (see the HTML5 spec). No additional functionality (like completion with the address book, the bookmarks, etc), just a basic support. But we can guess those functionalities will be available later.

ARIA role : grid(43669)

Even if Safari 4 has a basic support of WAI-ARIA, the work is not over. New roles are still coming in.

Orientation and ratio available in CSS (43739)

Media queries in CSS give a better control through knowledge of the properties of the device. WebKit already supports some of those queries. This change adds support for orientation (portrait or landscape) and ration (exact, minimal or maximal) of the view.

displayName support in the debugger (43774)

Anonymous functions are often used in JavaScript. They are really handy for development but not so much when you have to find where a problem lies. Therefore, Francisco Tolmasky of 280North got the idea of the function.displayName property. You can now choose what name the debugger will use. Before that, he has also done a similar change for the profiler. I can only recommend the lengthy article he wrote about it.


This is everything for this week. Of course, this is just a selection I've made. If you've noticed any other interesting changes, please let me know. Same thing if I got something wrong.

jeudi, avril 23 2009

WebKit's week - #8

French version

After four months without news, I'll try to be more regular. Let's hope my new organisation will help.

Changes of the week

Everything mentioned below should work with the latest nightly available at the moment (42662).

6 parallel connections (42457, 42559)

With this commit, WebKit can now use 6 parallel connections per domain, previously 4. The number of parallel connections is important to download as fast as possible the resources of a web page. WebKit is now behaving like latest versions of IE, Firefox or Chrome. Opera uses 8 connections per domain. To test this, you'll have to wait for a future version of the CFNetwork library.

function.displayName (42478)

You can create anonymous function in JavaScript. They are very useful but the drawback is they also appear anonymous in the profiler. This make the interpretation of the results pretty hard. Now, you can give a name to those functions and it will be used in the profiler.

Yarr! (42481)

Yarr! (Yet Another Regex Runtime) is, as it suggests, a new Regex Runtime. It is disabled by default for some reasons like being incomplete at the moment but said to be faster than the old one. Hoperfully, we'll have more news when he'll be live.

XMLHttpRequest withCredentials (42483)

This is a new feature from the XMLHttpRequest Level 2 spec. With the withCredentials attribute, you can define whether or not you wanna send the cookies and HTTP authentication data when using a cross domain XHR. Like the number of parallel connections, we need a new version of CFNetwork to test this.

Array.reduce and Array.reduceRight (42563, 42570)

These are two new methods define by ECMAScript 5. You are invited to read the documentation on the Mozilla developer center.

SQL is read only with private browsing (42616)

When using the private browsing mode (aka porn mode), the web database is no longer writeable. Inserts, updates, deletes are no longer available. This way, the website can't record stuff while in a private session.

Implementation of the played attribute (42619)

The new video element has a played attribute which give info about what part of the video has been played. You got access to a TimeRanges object.


This is everything for this week. Of course, this is just a selection I've made. If you've noticed any other interesting changes, please let me know. Same thing if I got something wrong.

samedi, décembre 27 2008

WebKit's week - #7

French version

Christmas edition !

Changes of the week

Everything mentioned below should work with the latest nightly available at the moment (38826).

Web Workers (38150, 38567)

Once again, let's talk about a new specificaiton. With Web workers, you can realise complex tasks in JavaScript in another thread and so in the background. Therefore, the browser is not unresponsive and we can better use the multiple cores of the recent processors. The spec is a work in progress and changes often. You'll find more detailed explanations on the Web Tech blog of Mozilla (which implements this spec, available in Firefox 3.1β2). Some APIs are available in a Worker, but the DOM API isn't part of them. Oliver Hunt prepared a demo to show the performance gain.

WML support (38541, Bug 20393)

WML is the language intended for devices that implement the WAP protocol. WebKit doesn't support this language but it is currently being implemented. This support is not available by default in the nightlies. You'll have to compile your own copy if you want to test it.

HttpOnly Cookie (38566)

An Internet Explorer extension (added in Firefox and Opera since) will soon be supported by WebKit based browsers. This restricts the access to certain cookies. They are only available for an HTTP request and so not from JavaScript. This is an important functionality to restrict the damages of an XSS vulnerability. This is not available in the nightlies because you need some updated Apple proprietary libraries (CFNetwork). UPDATE (29 december) : CFNetwork has been updated since this commit so it is now testable in the nightlies, my bad.

Updated propositions (38717, 38737, 38760)

Propositions for CSS Transforms, CSS Transitions and CSS Animations have been updated. CSS Transforms have been splitted into a 2D and 3D proposition. Also, a proposition of extension to the CSS Media Queries for the previous propositions. And an extension of pointer-events to HTML elements. All these propositions are consultable on a unique location.

Underground work

In addition to all this, a lot of what I call "underground" work has been done. A lot of renamings, cleanings, fixes for recently introduced features, a smaller memory footprint, tests for conformity. There's too much commits for me to point. All this work, which is not really visible but very useful, is an occasion for me to remind you the goals of the WebKit project.


This is everything for this week. Of course, this is just a selection I've made. If you've noticed any other interesting changes, please let me know. Same thing if I got something wrong.

mardi, décembre 2 2008

WebKit's week - #6

French version

Apologizes for the chaotic rhythm of publication. So here is a raw version.

Changes of the week

Everything mentioned below should work with the latest nightly available at the moment (38100).

Multiline Inputs (35739)

Before this commit, WebKit was only sending the first line of an input field. Now, a multiline text (entered with copy and paste) will keep all the text. The carriage return will be replaced by spaces. This matches other browsers behavior.

Computed styles tab collapsed (37523)

After the post on the redesigned Web Inspector, many people were asking why styles can't be edited. In fact, they were trying to edit the computed styles. As the name explains, it represents the final styles after being calculated by the browser and therefore, they are not editable. To avoid this confusion and keep an easy access to this data, this tab is now collapsed by default.

Debug without reloading the page (37622)

Wanna debug some Javascript ? You just have to enable the debugger and there you go. No reloading involved.

Time and size per resource

In order to ease the interpretation of the waterfall in the Resources panel, the time and size for each resources were added. You just have to hover the resource to get the different times (waiting and loading times) or the size of the resource. Time details

On demand profiler (37730, 37933)

Before these commits, the profiler was always enable when the Safari's Developer menu was enabled. This affects performance, even when you weren't running a profile. Now, the profiler is disabled by default. A new activation screen is therefore necessary. A similar screen was added for the profiler too. Profiler activation screen

Geolocation API (37854)

A lot of applications could benefit from knowing the user position and offer local services. So an API is under development at the W3C : Geolocation API. There is a clear usecase with the iPhone for example. This functionality can't be tested in the nightlies at the moment.

Multi-file upload (37863)

HTML5 introduces the multiple attribute on file inputs. This allows uploading multiple files at a time. Combined with XMLHttpRequest version 2, this allows uploading files with a progression bar without external plugins.

Mozilla cursors (37902)

Two new values were added to customise cursors : -webkit-grab and -webkit-grabbing. They were already used in Mozilla. Demo of all supported cursors

Changing the accesskey shortcut (38211)

Originally, the accesskey shortcut was Ctrl. This caused collisions with the Emacs style shortcuts in Mac OS. The shorcut was changed to Ctrl+Opt. But this caused new problems with VoiceOver. So the intermediate solution is now : Ctrl+Opt without VoiceOver and Ctrl with VoiceOver.


Julien Chaffraix and I were at Paris Web 2008. Among many good moments, they were a nice browser panel with a represent of the four big engines.


This is everything for this week. Of course, this is just a selection I've made. If you've noticed any other interesting changes, please let me know. Same thing if I got something wrong.

lundi, octobre 20 2008

Paris Web, a really nice conference

The third edition of Paris Web will be held from November 13 to 15. I should have mentioned it earlier since the early bird is over. But guess what : it's still really affordable.

The program is remarkable. Chris Wilson, Daniel Glazman, François Yergeau, Nicole Sullivan, Christian Heilmann, Charles MacCathieNeville, Aaron Leventhal will all be there. And I'm just talking about the famous names. There's a lot more interesting persons speaking there.

On Saturday, I will present a workshop on Firebug and the Web Inspector :

Our web pages are less and less static. After writing the code, we have to understand how they are interpreted by the browsers.

Which CSS rules apply to this element

What is this bug in my JavaScript code ?

Why is this action taking so much time ?

We will discover and use these two tools to answer those questions and much more. We will talk about the Console API and the command line.

I would also like to talk about the new features in WebKit, we still need to figure out how. Julien Chaffraix (another WebKit contributor) will be there too. He'll be part of the browser discussion on Friday.

In addition to the lectures and workshops, there will be a free party on friday night.

This is an awesome organisation. They are all volunteers but it's a professional class event. If you're gonna be there, leave a message here if you want.

lundi, octobre 13 2008

WebKit's week - #5

French version

One month without news is bad. So we resume with only two weeks.

Changes of the week

Everything mentioned below should work with the latest nightly available at the moment (37469).

Styling placeholder (37123, 37217)

WebKit supports a placeholder attribute on input elements. This attribute allows you to display a tooltip in the field when the user hasn't enter any content. By default, this tooltip is printed in light gray. Now, we can play with his style using the -webkit-input-placeholder pseudo-element. See the example.

Debugging before onload fires (37313)

Before this fix, it was impossible to debug a part of code running before the resource finished its loading. It wasn't really handy for a tool like the Web Inspector. Fixed !

Origin header for POST requests (37317)

Beginning of implementation for the Access Control for Cross-Site Requests specification. An Origin header, which only contains the domain of the originating page, is added. This allows application to check if the request comes from an authorized domain. Unlike the Referer header, this one doesn't reveal the complete path of the originating page.

Exact line search (37389)

Like Firebug, it's now possible to search for a particular line in the Resources panel. We can use two syntaxes : #123 or line:123. We can add a keyword to only match lines with this keyword.

Fixing SunSpider (37389)

As David Mandelin mentioned on his blog, the regexp-dna test on SunSpider was incorrect. An option only supported in Gecko was in the test and so, this engine was disadvantaged. Eveyrthing is fine now, all the engines do the same test.

News of the week

While I wasn't giving news, three new posts were added to the Surfin' Safari blog:


This is everything for this week. Of course, this is just a selection I've made. If you've noticed any other interesting changes, please let me know. Same thing if I got something wrong.

lundi, septembre 8 2008

WebKit's week - #4

French version

After a few weeks off, let's get back with webkit news. By the way, the english versions are now aggregated on Planet Webkit.

Changes of the week

Everything mentioned below should work with the latest nightly available at the moment (36135).

DOM properties and local variables editing (35835)

Double clicking a property in the sidabar of Elements or Scripts panels now allows you to change the value of this property. You can even enter JavaScript as shown in this screenshot. DOM editing

console.count support (35842)

Still a Firebug compatibilty stuff. This method allows you to count how many times a specific code has been called.

Editable Metrics tab (35876)

Like Firebug, it is now possible to edit dimensions, padding, borders, margins and position of a box. Metrics editing

Canvas Text support (36060)

Canvas, the element allowing you to draw in 2D now has an API to draw text. You can use the two tests to learn it.

Chrome consequences

Obviously, you haven't missed Google's announcement this week. A new browser using WebKit. And the two projects are working together as you can see with the following commits.

  • 36074 New constants for Skia, V8 and Chromium.
  • 36095 V8 benchmarks are integrated into WebKit.
  • 36097 Little anecdote, some Google developers gave patches under fake names to stay under the radar before the announcement.


This is everything for this week. Of course, this is just a selection I've made. If you've noticed any other interesting changes, please let me know. Same thing if I got something wrong.

lundi, août 18 2008

WebKit's week - #3

French version

Changes of the week

Everything mentioned below should work with the latest nightly available at the moment (35806).

CSS Animations implementation (35666)

I announced this implementation too early last week. Comparing to the two specs, associated events were missing.

Compatibility with Firebug's API (35676, 35786, 35787)

New commands are available in the console. $, $$, $x, keys, values, profile/profileEnd, clear. You can find these functions descriptions in Firebug's documentation And don't forget the addition of console.dir to list all properties of an object. console.dir

SVG tests (35675, 35679, 35680, 35682, 35683, 35695, 35700)

I'm not familiar with SVG but something like 80 tests were added to ensure the right behaviour of the engine. Especially, the elements line, radialGradient, image, marker, mask, cursor, pattern and rect are concerned. Some fixes were made in consequence.

Resizable and closable inspector in docked mode (35719, 35720, 35722)

When the inspector is inside a page, it is now possible to resize and close it. I waited a long time for this. This docked mode is now the default. And to finish with this, the inspector will remember in which mode you've let it.

Loader enhancements (35799, 35801)

In order to always get better performances, some tweaks were made :

  • Stylesheets get highest priority since the engine won't render before having downloaded every stylesheets.
  • For each new host, the connection is established as soon as possible in order to reduce the effect of the latency due to it.
  • When the document and all stylesheets are parsed, there's no need to maintain a queue, we can download all documents, whatever priority they have.
  • To avoid delaying the initial rendering, resources in <body> are not downloaded if there's no render. This improves by 25%, or 5 seconds, the initial rendering for CNN with a bandwith limited to 300kb/s, interesting for mobile devices.


This is everything for this week. Of course, this is just a selection I've made. If you've noticed any other interesting changes, please let me know. Same thing if I got something wrong.

lundi, août 11 2008

WebKit's week - #2

French version

Changes of the week

Everything mentioned below should work with the latest nightly available at the moment (35657).

CSS Animations implementation (35545, 35568, 35580, 35646)

CSS Animation is a work in progress spec written by Apple. Like its mate, CSS Transition, it allows animated effects in CSS. When transitions are just effects computed when a property is changed, animations are called explicitly to trigger a value change. There's a keyframe system to have a precise control of the animation flow. See how it works with the different examples.

Quick edition for numeric values (35561)

For CSS properties accepting numeric values, it is now possible to increase or decrease them with the keyboard. Remember the handy shortcuts changing the amount : with Alt, we jump by 0.1, with Shift or Page Up by 10, with Shift and Page Up by 100.

Profiler's Heavy view (35625)

OK, it's not an amazing novelty but it's a reason to talk about the new profiler. It allows you to get detailed information about the execution time of your JavaScript. Comparing to Firebug, results are displayed as a tree so you can look closer. Two views are available, Tree or Heavy, each one is interesting for different purposes. It's also possible to reduce noise by filtering the results to focus on some code. It reacts to console.profile and console.profileEnd, like Firebug.

Squirrelfish engine improvements (35593, 35639)

This engine was announced two months ago and since, it's always improved. I can't explain what they are doing but the figures speak for themselves : 2.6% and 2.5% progression for the SunSpider test


This is everything for this week. Of course, this is just a selection I've made. If you've noticed any other interesting changes, please let me know. Same thing if I got something wrong.

dimanche, août 3 2008

WebKit's week - #1

French version

I've been following the WebKit project for 4 months now and I thought it would be interesting to extract cool news of the week here. This is the first post in this series and I hope it will be interesting and live long.

I'm French so my tailor is rich but my English is poor. Please correct me if you find mistakes.

Changes of the week

Everything mentioned below should work with the latest nightly available at the moment (35531).

CSS parser enhancements (35403)

It's always good to improve standards compliance. The menu:

  • don't fail when closing braces are not found for a declaration at the end of the file;
  • don't accept "!important fail" as valid;
  • keep accepting @import when it comes after invalid @ rules;
  • don't drop the whole @media block when there's an error before the closing brace;
  • some other minor css parsing revisions.

Support for CSS variable declaration blocks (35414)

The CSS WG is working (among other stuff) on CSS variables. To support this effort and try to find the best syntax, there are some tries in WebKit.

So this week, we have support for CSS variable declaration blocks. See the example in a test to see how it works.

Of course, these are experiments and do not represent the final syntax. There are other experimentations going on, like the use of the var keyword.

Support for console.group (35421)

Let's start by saying the Web Inspector (WebKit's equivalent to Firebug basically) is being refreshed. It has almost nothing to do with the one in Safari 3.1. Try it!

One of the novelty is to support the same Console API as Firebug to help web developers work.

This week, WebKit now supports console.group and console.groupEnd. I must point out this work was done by Keishi Hattori, one of the students participating in the Webkit GSoC .

Support for XMLHttpRequestUpload (35435)

Again, a work in progress specification and a testing implementation. The implementation has even more details than the latest spec I could find.

The idea ? Add events to allow better knowledge about the status of the XHR request. This could allow upload forms with progress bars.

The example shows the new available events and properties.

Ability to disable individual CSS properties (35514)

Also in the refresh project of the inspector. A useful functionality to analyse a web page design, try new things, etc.

News of the week

Ariya Hidayat had some fun adding a live tab previews in Arora (a browser based on QtWebKit).


This is everything for this week. Of course, this is just a selection I've made. If you've noticed any other interesting changes, please let me know. Same thing if I got something wrong.