<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:dc="http://purl.org/dc/elements/1.1/" version="2.0"><channel><atom:link rel="hub" href="http://tumblr.superfeedr.com/" xmlns:atom="http://www.w3.org/2005/Atom"/><description>Generated Content by David Storey: A blog about HTML5, CSS3, SVG, ES5/JavaScript and other open web technologies. Also throws in thoughts about design and general geekery.</description><title>Generated Content by David Storey</title><generator>Tumblr (3.0; @dstorey)</generator><link>http://generatedcontent.org/</link><item><title>IE11: what we know and what we can speculate </title><description>&lt;p&gt;
A build of Windows–codenamed Windows Blue–was leaked onto the internet recently. What does this tell us about what is coming in IE11?
&lt;/p&gt;

&lt;p&gt;&lt;!-- more --&gt;&lt;/p&gt;

&lt;p&gt;
&lt;strong&gt;First a disclaimer:&lt;/strong&gt; the information in this post all comes from public sources. I have not run the leaked build myself, and although I am helping Microsoft with the userAgents community, I have no inside knowledge of current or future plans for IE11. This post is a distillation of these various posts, and my personal opinion or speculation.
&lt;/p&gt;

&lt;h2&gt;A new identity&lt;/h2&gt;

&lt;p&gt;
The first news about IE11 was that it has a &lt;a href="http://www.neowin.net/news/ie11-to-appear-as-firefox-to-avoid-legacy-ie-css" target="_blank"&gt;new user agent string&lt;/a&gt;:
&lt;/p&gt;

&lt;p&gt;
&lt;var&gt;Mozilla/5.0 (IE 11.0; Windows NT 6.3; Trident/7.0; .NET4.0E; .NET4.0C; rv:11.0) like Gecko&lt;/var&gt;
&lt;/p&gt;

&lt;p&gt;
There  are two significant changes to this string:
&lt;/p&gt;

&lt;ol&gt;&lt;li&gt;&lt;var&gt;MSIE&lt;/var&gt; has been replaced by &lt;var&gt;IE&lt;/var&gt;&lt;/li&gt;
  &lt;li&gt;A &lt;var&gt;like Gecko&lt;/var&gt; token has been added&lt;/li&gt;
&lt;/ol&gt;&lt;p&gt;
The former is clearly to avoid getting the code branch designed for IE when sites use browser sniffing (a practice that causes untold damage). These are almost certainly designed for older versions of IE, such as those that don&amp;#8217;t support &lt;code&gt;addEventListener&lt;/code&gt; or other standards-based features. IE is saying it no longer wants legacy IE code. It wants standards-based code.
&lt;/p&gt;

&lt;p&gt;
The latter has caused some confusion. It was reported that IE is pretending to be Firefox. This is only partially true. It is correct that Gecko is the name of Firefox’s rendering engine, but &lt;var&gt;like gecko&lt;/var&gt; was the token added by WebKit. The reason why WebKit added it, and now also IE, is sites often didn&amp;#8217;t say “do you want the IE-specific code or the standards-based code?” They often instead said: “Are you IE or are you Gecko?” It is not a question of if you support the standard, but if you are called Gecko. Even though WebKit is widely popular (as is IE), these sites and practices still persist, so the token is still needed. IE is basically taking a page out of WebKit’s playbook, which is asking for the Gecko branch. What IE will not get with this string is the sites specifically sniffing out WebKit. I suspect it doesn’t want these, as these code paths probably often include WebKit specific code or prefixes. Especially on mobile sites. Pretending to be Gecko gives less risk of vendor specific code, as it is not a reliable way to detect just Gecko-based browsers due to WebKit making the same move.
&lt;/p&gt;

&lt;p&gt;
Changing the UA string is not the only way current builds of IE11 are cloaking their identity. The &lt;code&gt;appName&lt;/code&gt; property now returns &lt;code&gt; Netscape&lt;/code&gt; rather than &lt;code&gt;Microsoft Internet Explorer&lt;/code&gt;. WebKit and Gecko already do this. IE and Opera/Presto were there only ones that didn’t identify as Netscape, but as the latter is switching to Blink, everyone is now Netscape.
&lt;/p&gt;

&lt;p&gt;
Finally on the identity front, IE11 is now cloaking support for &lt;code&gt;document.all&lt;/code&gt;. If you use feature detection to detect support for this feature, IE, like Firefox, WebKit, and Opera, will say &lt;code&gt;false&lt;/code&gt;. Why? Isn’t object detection the holy grail? Yes, but, developers were &lt;i&gt;::drumroll::&lt;/i&gt; using object detection to browser sniff. What? While working on Opera compatibility, I’d often (more times than I can count) see code like this:
&lt;/p&gt;


&lt;pre&gt;&lt;code class="lang-javascript"&gt;var isIE = null;
if (document.all) {
 isIE = true;
}

if (isIE) {
  // do some crazy IE specific stuff with ActiveX, or filters or so on
} else {
  // use standards based code
}&lt;/code&gt;&lt;/pre&gt;

&lt;p&gt;
Now all of a sudden, if you support &lt;code&gt;document.all&lt;/code&gt;, you are obviously IE and want to use totally non-related code. Cloaking support for &lt;code&gt;document.all&lt;/code&gt; avoids this.
&lt;/p&gt;

&lt;p&gt;
The other possibility is to remove support entirely, but sites would often use it without testing for support, and not have an alternative path, leaving sites broken. Cloaking generally gives you the best of both worlds, and is now an ubiquitous practice amongst browser vendors.
&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Update: &lt;/strong&gt;  IE11 now cloaks support for the &lt;code&gt; ActiveXObject&lt;/code&gt; object, almost certainly for the same reasons as already outlined.&lt;/p&gt;

&lt;p&gt;
You have to bear in mind that all these changes happened in a leaked build of IE11. It could be that the developers are just experimenting to see if the identity changes break more than they fix. It should not be held as gospel that these changes will make it into the final version of IE11.
&lt;/p&gt;

&lt;p&gt;There is one key significance to all this. Microsoft is telling the world; &lt;q&gt;IE has grown up, it is standards compliant and is capable of supporting the standards branch on sites. We no longer want the IE code paths.&lt;/q&gt; I’m inclined to agree. IE10 is a huge step forward, and IE11 probably will be able to go toe to toe with the competition in terms of standards support.&lt;/p&gt;

&lt;h2&gt;ES6 support&lt;/h2&gt;

&lt;p&gt;
A few features from ECMAScript 6 (the next version of JavaScript) appear in the leaked builds:
&lt;/p&gt;


&lt;h3&gt;__proto__&lt;/h3&gt;

&lt;p&gt;
The __proto__ property was non-standard, and looks really ugly to my eyes. It references the prototype of the object. The spec represents this as &lt;var&gt;[[Prototype]]&lt;/var&gt;, but there was no standards-based way to access this. ES6 changes this by &lt;a href="http://people.mozilla.org/~jorendorff/es6-draft.html#sec-B.3.1" target="_blank"&gt;standardising &lt;code&gt;__proto__&lt;/code&gt;&lt;/a&gt;.
&lt;/p&gt;

&lt;p&gt;
IE11 now supports this feature, along with Firefox, WebKit and Opera.
&lt;/p&gt;

&lt;h3&gt;WeakMap&lt;/h3&gt;

&lt;p&gt;
A &lt;a href="http://people.mozilla.org/~jorendorff/es6-draft.html#sec-15.15" target="_blank"&gt;&lt;code&gt;WeakMap&lt;/code&gt;&lt;/a&gt; is a key/value pair map, where the key is an object, and if there is no longer a reference to the key object, it will be available to be garbage collected. Due to this behaviour,  &lt;code&gt;WeakMap&lt;/code&gt; keys are not enumerable. One specific use case for WeakMaps is to keep references to DOM nodes. When a DOM node is deleted from the document, it can be garbage collected and thus automatically removed from the map. This can reduce memory requirements. 
&lt;/p&gt;

&lt;p&gt;
Support for &lt;code&gt;WeakMap&lt;/code&gt; is included in IE11, Firefox, and behind a flag in Chrome.
&lt;/p&gt;

&lt;h3&gt;Update: Set&lt;/h3&gt;

&lt;p&gt;Support for &lt;a href="http://people.mozilla.org/~jorendorff/es6-draft.html#sec-15.16" target="_blank"&gt;&lt;code&gt;Set&lt;/code&gt; objects&lt;/a&gt; has appeared in the latest leak. A &lt;code&gt;Set&lt;/code&gt; holds a collection of values, but unlike data structures like an &lt;code&gt;Array&lt;/code&gt;, a &lt;code&gt;Set&lt;/code&gt; can not contain duplicates. For an excellent look into &lt;code&gt;Set objects&lt;/code&gt;, check out Nicholas Zakas’ blog post &lt;a href="http://www.nczonline.net/blog/2012/09/25/ecmascript-6-collections-part-1-sets/" target="_blank"&gt;ECMAScript 6 collections, Part 1: Sets&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;
Support for &lt;code&gt;Set&lt;/code&gt; includes IE11, Firefox, and Chrome (behind a flag).
&lt;/p&gt;

&lt;h2&gt;Update: Proprietary Mozilla APIs&lt;/h2&gt;

&lt;p&gt;Along with &lt;code&gt;__proto__&lt;/code&gt; which was until it was recently standardised, was a proprietary Mozilla invention, IE11 has added support for &lt;code&gt;__defineGetter__&lt;/code&gt; in the latest leaked build. This is a legacy feature, which has been standardised as &lt;a href="http://es5.github.io/#x15.2.3.6" target="_blank"&gt;&lt;code&gt;Object.defineProperty&lt;/code&gt;&lt;/a&gt; in ES5. Why add a legacy feature when there is a standard that replaces it? One reason: compatibility. There is a bunch of code out there that uses &lt;code&gt;__defineGetter__&lt;/code&gt; without a non-legacy IE fallback. One of the reasons Opera added &lt;code&gt;__defineGetter__&lt;/code&gt; is that some frameworks and sites (Atlas being one I remember) would use it to add functionality.&lt;/p&gt;

&lt;p&gt;In the case of Atlas it implemented everything using legacy IE API, and the “standards” based path was basically a polyfill for Firefox using &lt;code&gt;__defineGetter__&lt;/code&gt; to implement those APIs. If you didn’t support it, you just received a broken site. Now, that was a pretty backwards was to develop, but the feature was (and probably still is) used extensively. I suppose the IE team are seeing similar issues to the Opera team did, especially now they’re changing the UA string and cloaking support for legacy IE features.&lt;/p&gt;

&lt;h2&gt;WebGL&lt;/h2&gt;

&lt;p&gt;
If there was ever a poster child that trolls and haters would use to claim IE is still not a modern browser, it would be WebGL. I’m personally not convinced it is the most important feature for the average web developer, as it is a complex technology to learn and use, and the average web site generally doesn’t need 3D graphics. 
&lt;/p&gt;

&lt;p&gt;
On the other hand, where WebGL is useful, it is often critical. Games are an obvious example. With the recent announcement by Mozilla and Epic of &lt;a href="http://blog.mozilla.org/blog/2013/03/27/mozilla-is-unlocking-the-power-of-the-web-as-a-platform-for-gaming/" target="_blank"&gt;porting the Unreal 3 engine to JavaScript with asm.js&lt;/a&gt;, the Web’s credibility as a gaming platform is only going to increase. It is going to become more important that Microsoft has a solution in this space.
&lt;/p&gt;

&lt;p&gt;
The good news is that implementation of WebGL in IE11 is underway. It has to be &lt;a href="http://withinwindows.com/within-windows/2013/3/30/blues-clues-how-to-enable-webgl-in-internet-explorer-11" target="_blank"&gt;enabled with a registry tweak&lt;/a&gt;, which isn’t all that surprising considered its unfinished state. There was initial confusion that it only supports IESL shaders (from DirectX), rather than the GLSL format defined in the spec (which has its roots in OpenGL). Fortunately that is not the case, and it is &lt;a href="http://www.youtube.com/watch?v=McMVn8rP048&amp;amp;feature=player_embedded" target="_blank"&gt;possible to get WebGL demos running&lt;/a&gt;, even at this stage.&lt;/p&gt;

&lt;p&gt;
However, it is important not to get ahead of ourselves. Until it appears in an official build it does not mean it is certain to land in IE11. Anything from the feature not being complete on time to security concerns could mean it is not included or disabled by default. I remember at Opera that WebGL was initially turned off as it was possible to blue screen of death Windows by visiting a page with WebGL content (I think due to issues with shaders). Safari also currently has WebGL disabled by default. However, if Microsoft are implementing WebGL, I’d be very surprised if the plan isn’t to include it. 
&lt;/p&gt;

&lt;h2&gt;Networking&lt;/h2&gt;

&lt;p&gt;
The currently leaked build of IE11 has &lt;a href="http://withinwindows.com/within-windows/2013/4/1/blues-clues-internet-explorer-11-getting-spdy-support" target="_blank"&gt;evidence for SDPY support&lt;/a&gt;, although it is not currently functioning. As such you should be especially careful about assumptions it will appear in any final build of IE11. 
&lt;/p&gt;

&lt;p&gt;
SPDY is a networking protocol originally proposed by Google, built on top of HTTP. Its main goal is to speed up page loading by reducing latency, compressing headers, and reducing the number of connections  per client. While it is not a standard, it is being used as the starting point for a future &lt;a href="http://en.wikipedia.org/wiki/HTTP_2.0" target="_blank"&gt;HTTP 2.0 standard&lt;/a&gt; from the IETF. 
&lt;/p&gt;

&lt;p&gt;
SPDY is supported by Opera, Firefox, and Chrome, and looks like it will be coming to IE11.
&lt;/p&gt;

&lt;h2&gt;DOM and JavaScript APIs&lt;/h2&gt;

&lt;h3&gt;Mutation Observers&lt;/h3&gt;

&lt;p&gt;
Traditionally if you wanted to monitor DOM changes you would listen for &lt;a href="http://www.w3.org/TR/DOM-Level-2-Events/events.html#Events-eventgroupings-mutationevents" target="_blank"&gt;DOM Mutation Events&lt;/a&gt;. It is widely acknowledged that the design of Mutation Events is flawed,  due to &lt;a href="http://www.w3.org/2008/webapps/wiki/MutationReplacement#Background" target="_blank"&gt;inherent performance issues&lt;/a&gt;. Because of these problems, Mutation Events are now &lt;a href="http://dev.w3.org/2006/webapi/DOM-Level-3-Events/html/DOM3-Events.html?rev=1.100#events-mutationevents" target="_blank"&gt;deprecated&lt;/a&gt;. 
&lt;/p&gt;

&lt;p&gt;
As the functionality of Mutation Events is important, there is a glaring need for a replacement. Step up &lt;a href="http://www.w3.org/TR/domcore/#mutation-observers" target="_blank"&gt;DOM4 Mutation Observers&lt;/a&gt;! IE11 includes this feature, joining Chrome, Safari 6, and Firefox. Opera will inherit support once it switches to Blink.
&lt;/p&gt;

&lt;h3&gt;Full Screen API&lt;/h3&gt;

&lt;p&gt;
Sometimes it is desirable to make a web page cover the entire screen, hiding the browser chrome. Playing videos is probably the most common use case, but gaming would be a close second. The &lt;a href="http://www.w3.org/TR/fullscreen/" target="_blank"&gt;Full Screen API&lt;/a&gt; enables this functionality. 
&lt;/p&gt;

&lt;p&gt;
IE11 looks like it is implementing this spec, with the &lt;code&gt;requestFullscreen&lt;/code&gt; method currently supported in leaked builds. it is prefixed with the &lt;code&gt;ms&lt;/code&gt; prefix. Presumably the rest of the spec will be implemented in future builds. The spec is also supported unprefixed in Opera, and prefixed in Safari, Chrome, and Firefox. Firefox currently supports and older draft according to &lt;a href="http://caniuse.com/fullscreen" target="_blank"&gt;caniuse.com&lt;/a&gt;, as does Safari 5.1 and Chrome 15–19.
&lt;/p&gt;

&lt;h2&gt;Update: CSS&lt;/h2&gt;

&lt;h3&gt;Flexbox syntax update&lt;/h3&gt;

&lt;p&gt;
 The good news is that Flexbox in IE11 has been updated to the latest version (and most likely final) version of the spec. The Flexbox syntax changed just before IE10 was released, so it supports an outdated syntax. I was hit by the same issue when writing the flexbox section of SmashingBook 3. The new syntax is currently supported by Opera 12.1, Chrome (prefixed), and is coming to Firefox in version 21. Safari (and current Firefox) still supports a version of the spec older than the IE10 version.
&lt;/p&gt;

&lt;h3&gt;CSS Level 4 Selectors?&lt;/h3&gt;

&lt;p&gt;There is preliminary support for &lt;a href="http://dev.w3.org/csswg/selectors4/" target="_blank"&gt;CSS Level 4 Selectors&lt;/a&gt; in the latest leaked builds, but they are currently non-functional, and I don’t know which are included. I’m looking forward to seeing an update to &lt;a href="http://fremycompany.com/BG/2013/Internet-Explorer-11-9385-new-features-771/" target="_blank"&gt;François blog post&lt;/a&gt; to see what they are.&lt;/p&gt;

&lt;p&gt;No browser to my knowledge has extensive support of the new CSS Level 4 selectors, except those moved in from &lt;a href="http://www.w3.org/TR/css3-ui/#user-interface-selectors" target="_blank"&gt;CSS 3 Basic UI&lt;/a&gt;.  The spec itself is relatively immature. &lt;/p&gt;

&lt;h3&gt;transform-style: preserve-3d?&lt;/h3&gt;

&lt;p&gt;According to François Remy’s post referenced above, there is also preliminary support for &lt;a href="http://dev.w3.org/csswg/css-transforms/#transform-style" target="_blank"&gt;&lt;code&gt;transform-style&lt;/code&gt;&lt;/a&gt; in the latest IE11 build, but preserve-3d does not work yet. Presumably the plan is to have this supported (to the relief of authors of sexy demos everywhere) by the time IE11 ships.&lt;/p&gt;

&lt;h2&gt;What’s next?&lt;/h2&gt;

&lt;p&gt;
Your guess is as good as mine at this stage. I can say what I’d like to see however. Adding support for  &lt;code&gt;transform-style: preserve-3d&lt;/code&gt; makes sense to round out 3D capabilities (&lt;strong&gt;Update: &lt;/strong&gt; looks like this is underway). I’d love to see support for &lt;code&gt;@supports&lt;/code&gt; from &lt;a href="http://www.w3.org/TR/css3-conditional/" target="_blank"&gt;CSS Conditional Rules&lt;/a&gt;, as the sooner it is implemented cross-browser, the more useful it becomes. When I worked at Motorola, I pushed for this to be implemented by the WebKit team there, and it has now landed in WebKit. It is also supported in Firefox behind a flag, and in Opera 12.1. Support for &lt;code&gt;border-image&lt;/code&gt; would also be nice. Additional codecs such as WebM would be great, but I&amp;#8217;m not holding my breath.&lt;/p&gt;

&lt;p&gt;As &lt;code&gt;WeakMap&lt;/code&gt; has been implemented from ES6, I&amp;#8217;d not be totally shocked if more of that spec is implemented. Especially considering &lt;a href="http://www.typescriptlang.org" target="_blank"&gt;TypeScript&lt;/a&gt; prototypes some up and coming features (&lt;strong&gt;Update: &lt;/strong&gt; &lt;code&gt;Set&lt;/code&gt; is now also supported). Similarly, MS’ &lt;a href="http://html5labs.interoperabilitybridges.com/prototypes/cu-rtc-web-roaming/cu-rtc-web-roaming/info" target="_blank"&gt;CU-RTC-Web&lt;/a&gt; prototypes at least hints something could be implemented. As does the &lt;a href="http://html5labs.interoperabilitybridges.com/prototypes/device-orientation-events/device-orientation-events/info" target="_blank"&gt;Device Orientation&lt;/a&gt; prototype. This would be very nice for mobile and tablets. I guess we’ll find out more at &lt;a href="http://www.buildwindows.com" target="_blank"&gt;//Build/&lt;/a&gt; in San Francisco.
&lt;/p&gt;

&lt;h2&gt;When?&lt;/h2&gt;

&lt;p&gt;There is no definitive public release date, but we do know from executive interviews that Windows Blue will be &lt;a href="http://www.zdnet.com/what-microsoft-is-now-saying-and-not-about-windows-blue-7000014960/" target="_blank"&gt;released by the end of the year&lt;/a&gt;, and there will be a &lt;a href="http://www.theverge.com/2013/5/7/4308954/windows-8-1-blue-update-june" target="_blank"&gt;preview by the end of June&lt;/a&gt;. Presumably IE11 will be part of that release. &lt;/p&gt;

&lt;p&gt;
Thanks to &lt;a href="http://fremycompany.com/BG/2013/Internet-Explorer-11-rsquo-s-leaked-build-395/" target="_blank"&gt;François Remy&lt;/a&gt; and &lt;a href="http://withinwindows.com" target="_blank"&gt;Rafael Rivera&lt;/a&gt; for digging into the leaked build and releasing some of its secrets. And again to &lt;a&gt;François&lt;/a&gt; for further updates on later builds.
&lt;/p&gt;</description><link>http://generatedcontent.org/post/47216611856</link><guid>http://generatedcontent.org/post/47216611856</guid><pubDate>Fri, 05 Apr 2013 13:56:00 -0700</pubDate><category>IE11</category><category>webgl</category><category>spdy</category><category>es6</category><category>flexbox</category><category>browser sniffing</category></item><item><title>Vertical text with CSS 3 Writing Modes </title><description>&lt;p&gt;Languages with latin-based writing systems such as English are typically written left to right, and from top to bottom. However, there is a whole different world of writing modes out there. &lt;a href="http://www.w3.org/TR/css3-writing-modes/" target="_blank"&gt;CSS3 Writing Modes&lt;/a&gt; allows you to use these in your web sites. Read on to find out what you can, and can not use right now.&lt;/p&gt;

&lt;p&gt;&lt;!-- more --&gt;&lt;/p&gt;

&lt;h2&gt;Introduction to writing modes&lt;/h2&gt;

&lt;p&gt;If you’re from anywhere outside of East Asia or the Middle East, it is likely that the writing mode your are most intimately familiar with is those that go from the left edge of the page to the right (line direction), and from the top of the page to the bottom (block direction). Examples of scripts that use this writing system include Latin (e.g. English, French, Spanish, etc.), Greek, Cyrillic (Russian, Ukrainian, Bulgarian, etc.), and Brahmic scripts such as Devanagari, Thai, Tibetan, and so on.&lt;/p&gt;

&lt;p&gt;In the Middle-East (as well as North Africa, and Pakistan), the Arabic script is common, while in Israel the Hebrew script is used. Both of these scripts are written from right to left, rather than left to right as in Latin. What they do have in common with Latin scripts is that the lines progress down the page. If you look at a site set in Hebrew or Arabic, they tend to look like a mirror image of what one might expect if you come from a country that uses the Latin alphabet.&lt;/p&gt;

&lt;p&gt;Things get a bit more complex when you look at CJK (Chinese, Japanese, and Korean), traditional Mongolian and other languages that can be written in vertical orientation. The key word is &lt;em&gt;can&lt;/em&gt;. If you look at almost any Chinese or Japanese web site, you may notice that it is most likely written from left to right and top to bottom, just like Latin languages. While this is prevalent on the web, traditionally—and still in many printed publications—these languages were written with a line direction from top to the bottom of the page, and a block direction that goes from the right hand side of the page, to the left. Mongolian on the other hand uses the same top to bottom orientation, but the block direction goes from left to right.&lt;/p&gt;

&lt;p&gt;I suspect one of the reasons why vertical text isn’t so prevalent on the web is that there hasn’t been high quality support for it in web browsers, and operating systems and applications in general. I would also guess there could be usability issues with scrolling. Vertical scrolling has traditionally been easier than horizontal scrolling, and you don’t want to keep scrolling up and down the page for each line. Multi-column layout on the web has similar scrolling issues. I’m mainly guessing though, as I’m not much more than a rookie in terms of when and how to use vertical rather than horizontal text in East Asian languages.&lt;/p&gt;

&lt;h2&gt;How to apply writing modes on the Web&lt;/h2&gt;

&lt;p&gt;In actual fact, we’ve been able to use vertical text longer than you might think. &lt;a href="http://msdn.microsoft.com/en-us/library/bb250415(v=vs.85).aspx" target="_blank"&gt;IE 5.5 added support for this feature&lt;/a&gt;, and support was upgraded in &lt;a href="http://blogs.msdn.com/b/ie/archive/2009/05/29/the-css-corner-writing-mode.aspx" target="_blank"&gt;IE8&lt;/a&gt;. At the basic level, the support problem was that of other browsers. Things are a bit different now, as WebKit also has support. I suspect this is due to the demands of ePub for e-books, where WebKit is popular, and vertical text for the Japanese market is a key feature.&lt;/p&gt;

&lt;h3&gt;writing-mode&lt;/h3&gt;

&lt;p&gt;The property you need to use is &lt;a href="http://dev.w3.org/csswg/css3-writing-modes/#writing-mode" target="_blank"&gt;&lt;code&gt;writing-mode&lt;/code&gt;&lt;/a&gt;. The specification includes three values. While WebKit supports these values, IE support predates the latest version of the spec, and instead uses the values that were used in an older version and originate from SVG 1.1. While this isn’t ideal, they map well and work more or less in the same way.&lt;/p&gt;

&lt;p&gt;IE supports the writing-mode property with the -ms -prefix (IE 8+) and without (since IE 5.5 when prefixes were not common), while WebKit requires the usual -webkit- prefix.&lt;/p&gt;

&lt;h4&gt;horizontal-tb&lt;/h4&gt;

&lt;p&gt;The &lt;code&gt;horizontal-tb&lt;/code&gt; value is used for horizontal scripts with a block direction that goes from top to bottom. This is the default value, so you probably don’t need to specify it, unless you’re overriding a previously set value.&lt;/p&gt;

&lt;p&gt;You’ll notice that the horizontal part of the keyword doesn’t specify the direction of the line of text. This can be set (if it hasn’t been already) by the good old &lt;code&gt;direction&lt;/code&gt; property. Left to right uses the &lt;code&gt;ltr&lt;/code&gt; keyword, and right to left uses the &lt;code&gt;rtl&lt;/code&gt; keyword.&lt;/p&gt;

&lt;p&gt;For IE there are two different values. Instead of using the direction property to specify the line direction, it is specified in the &lt;code&gt;writing-mode&lt;/code&gt; value. left to right, top to bottom uses the value &lt;code&gt;lr-tb&lt;/code&gt;, while right to left, top to bottom uses &lt;code&gt;rl-tb&lt;/code&gt;.&lt;/p&gt;

&lt;p&gt;Here is an example setting left to right, top to bottom text. I’ve included all prefixes, so it will also work if IE updates it’s syntax or Firefox adds support:&lt;/p&gt;

&lt;pre class="language-css"&gt;&lt;code&gt;
-ms-writing-mode: lr-tb;
-webkit-writing-mode: horizontal-tb;
-moz-writing-mode: horizontal-tb;
-ms-writing-mode: horizontal-tb;				
writing-mode: horizontal-tb;
&lt;/code&gt;&lt;/pre&gt;

&lt;p&gt;While for right to left, top to bottom, the following code is needed:&lt;/p&gt;

&lt;pre class="language-css"&gt;&lt;code&gt;
-ms-writing-mode: rl-tb;
-webkit-writing-mode: horizontal-tb;
-moz-writing-mode: horizontal-tb;
-ms-writing-mode: horizontal-tb;
writing-mode: horizontal-tb;

direction: rtl; /* not specified as part of writing-mode property in standard syntax */
&lt;/code&gt;&lt;/pre&gt;

&lt;h4&gt;vertical-rl&lt;/h4&gt;

&lt;p&gt;This is where things get fun. The vertical-rl keyword is used to make the line direction switch in vertical mode, with a block progression from right to left. This is the value you will want to use for vertical layout in CJK languages. You do not need a direction property here as there are no known languages that uses bottom to top lines (unless you’re mixing scripts, such as embedding Arabic inside CJK text, but that is a whole different story).&lt;/p&gt;

&lt;p&gt;IE supports this using the older &lt;code&gt;tb-rl&lt;/code&gt; value:&lt;/p&gt;

&lt;pre class="language-css"&gt;&lt;code&gt;
-ms-writing-mode: tb-rl; 
-webkit-writing-mode: vertical-rl;
-moz-writing-mode: vertical-rl;
-ms-writing-mode: vertical-rl;
writing-mode: vertical-rl; 
&lt;/code&gt;&lt;/pre&gt;

&lt;h4&gt;vertical-lr&lt;/h4&gt;

&lt;p&gt;If you want to use vertical Mongolian text, you’ll want to use the &lt;code&gt;vertical-lr&lt;/code&gt; value, or &lt;code&gt;tb-lr&lt;/code&gt; for IE. Lines go from top to bottom like CJK languages, but they flow from the left to the right of the page.&lt;/p&gt;

&lt;pre class="language-css"&gt;&lt;code&gt;
-ms-writing-mode: tb-lr;
-webkit-writing-mode: vertical-lr;
-moz-writing-mode: vertical-lr;
-ms-writing-mode: vertical-lr;
writing-mode: vertical-lr;
&lt;/code&gt;&lt;/pre&gt;

&lt;h3&gt;Writing-mode demos&lt;/h3&gt;

&lt;a href="https://dl.dropbox.com/u/444684/OpenWebDemos/css3writingModes/writing-mode.html" target="_blank"&gt;&lt;img src="http://media.tumblr.com/af9e5e653a5823302d571a18322440ad/tumblr_inline_mjoessBmMo1qz4rgp.png" alt="Demo of writing modes in action"/&gt;&lt;/a&gt;

&lt;p&gt;You can see all four of these writing modes in action (if you&amp;#8217;re using a modern version of IE or WebKit-based browser) in my &lt;a href="https://dl.dropbox.com/u/444684/OpenWebDemos/css3writingModes/writing-mode.html" target="_blank"&gt;writing modes demo&lt;/a&gt;. I’ve used English text in each example, but you should get the basic idea. The right to left example may be confusing though, as the text (except final punctuation and list markers) looks left to right, but right aligned. The reason is that when using Latin characters inside right to left text, they keep their left to right orientation. This is known as bi-directional text, or Bidi, but that is a discussion for another day).&lt;/p&gt;

&lt;p&gt;Although vertical layout is primarily for languages that are naturally displayed in this orientation, Latin-based languages can also sometimes be used vertically. Usually due to lack of available space, or for stylistic reasons. Think of the spine of a book, labels on the 𝑦 axis of a graph, or those fancy vertical signs you see run down the side of theatres and other such establishments. In all but the latter case, each glyph is usually rotated 90° clockwise along with the line, so that it is displayed on its side, rather than its natural orientation. That is the default behaviour when using latin characters in vertical text using CSS.&lt;/p&gt;

&lt;a href="https://dl.dropbox.com/u/444684/OpenWebDemos/css3writingModes/writing-modes-table.html" target="_blank"&gt;
&lt;img src="http://media.tumblr.com/9a49cc81bd8d61b42a7be27dbcda68e3/tumblr_inline_mjoevyUMbd1qz4rgp.png" alt="Demo using vertical text to save space in a table heading"/&gt;&lt;/a&gt;

&lt;p&gt;I’ve made a demo taking advantage of this behaviour, where I’ve rotated text in a table header to save horizontal space. View the &lt;a href="https://dl.dropbox.com/u/444684/OpenWebDemos/css3writingModes/writing-modes-table.html" target="_blank"&gt;writing-mode property support demo&lt;/a&gt; in WebKit or IE to see this in action.&lt;/p&gt;

&lt;p&gt;One thing you should be aware of with the previous demo is that I had to add a &lt;code&gt;span&lt;/code&gt; (or another element) inside the &lt;code&gt;th&lt;/code&gt; for the vertical orientation to apply in WebKit. In IE this was not needed, but the header cell didn’t resize after rotation, leaving white space. I suspect it is a bug in both browsers, but with the way tables work, it is anyone’s guess (or at least, someone smarter than me about such things). The spec mentions that writing-mode does not apply to table rows, row groups, columns and column groups, but does not mention individual table cells. Adding an element inside the cell works in both browsers however, so this technique is viable if you don&amp;#8217;t mind an extra element.&lt;/p&gt;

&lt;a href="https://dl.dropbox.com/u/444684/OpenWebDemos/css3writingModes/japanese.html" target="_blank"&gt;
&lt;img src="http://media.tumblr.com/403bfc7f0016ec00612836963b680a4d/tumblr_inline_mjoexvhPj71qz4rgp.png" alt="Demo of Japanese text in vertical orientation"/&gt;&lt;/a&gt;

&lt;p&gt;Finally I’ve made a vertical text demo using Japanese text. Here you can see the vertical text writing mode used for it’s main intended purpose. Check out the &lt;a href="https://dl.dropbox.com/u/444684/OpenWebDemos/css3writingModes/japanese.html" target="_blank"&gt;Japanese vertical text demo&lt;/a&gt; in IE or Chrome.&lt;/p&gt;

&lt;p&gt;
The rules for vertical Japanese text are far more complex than I could ever hope to understand while working on this post, so there may be a number of issues that would look wrong to native eyes. After checking with &lt;a href="http://girliemac.com/blog/" target="_blank"&gt;Tomomi Imura&lt;/a&gt;, one such issue is with how the latin digits are rotated. In Japanese vertical layouts, these digits often keep their horizontal orientation, but with special rules, such as centring the glyph (central baseline in CSS terminology) rather than using the alphabetic baseline (the left edge of the line in top to bottom, right to left text). If two digits are found together, they are often combined side by side as if they were one glyph (know as &lt;a href="http://rishida.net/docs/unicode-tutorial/part4#tatechuyoko" target="_blank"&gt;tate-chu-yoko&lt;/a&gt;). While latin digits often keep their horizontal orientation, alphabetic glyphs can be rotated (as is the default) or keep their horizontal orientation. I’ve no idea what the rules are here, or if it is entirely stylistic. The main thing I have noticed is that runs of uppercase Latin characters are often set in the horizontal orientation, while lowercase characters are often in the sideways orientation. The next section will cover what we can and can’t do to correct these issues.&lt;/p&gt;

&lt;h2&gt;Changing the orientation of glyphs in vertical text&lt;/h2&gt;

&lt;p&gt;If you want to keep glyphs from scripts such as latin from rotating when in vertical mode, you can use the &lt;code&gt;text-orientation&lt;/code&gt; property, with a value of &lt;code&gt;upright&lt;/code&gt;:&lt;/p&gt;

&lt;pre class="language-css"&gt;&lt;code&gt;
-ms-writing-mode: tb-rl; /* old syntax. IE */
-webkit-writing-mode: vertical-rl;
-moz-writing-mode: vertical-rl;
-ms-writing-mode: vertical-rl;
writing-mode: vertical-rl; /* new syntax */
			
-webkit-text-orientation: upright;
-moz-text-orientation: upright;
-ms-text-orientation: upright;
text-orientation: upright;
&lt;/code&gt;&lt;/pre&gt;

&lt;p&gt;This is currently only supported in WebKit browsers. You can check it out by viewing an &lt;a href="https://dl.dropbox.com/u/444684/OpenWebDemos/css3writingModes/japanese-upright.html" target="_blank"&gt;updated version of the previous Japanese demo&lt;/a&gt;, using &lt;code&gt;text-orientation: upright&lt;/code&gt;.&lt;/p&gt;

&lt;a href="https://dl.dropbox.com/u/444684/OpenWebDemos/css3writingModes/japanese-upright.html" target="_blank"&gt;&lt;img src="http://media.tumblr.com/074c103082a5dd3fbdd3e5150548929a/tumblr_inline_mjoezzkAZU1qz4rgp.png" alt="image"/&gt;&lt;/a&gt;

&lt;p&gt;This property applies to all glyphs, but as Japanese characters are already in the horizontal orientation, you will only see a difference with the Latin characters.&lt;/p&gt;

&lt;p&gt;As you may want to keep some non-Japanese characters in the default sideways orientation, it may be best to add &lt;code&gt;span&lt;/code&gt;s around the glyphs you want to keep upright.&lt;/p&gt;

&lt;p&gt;The eagle-eyed among you might notice an issue in WebKit browsers. While the digits are kept horizontal, they are still aligned to the alphabetic baseline, rather than centred to the central baseline. Chrome is also slightly clipping the text. Every glyph is also rotated, which is incorrect. Glyphs such as hyphens (-), and brackets and braces ({}()&amp;lt;&amp;gt;) should be left sideways, otherwise they look very odd.&lt;/p&gt;

&lt;p&gt;While this is where support stops for this property in Safari, Chrome also supports the &lt;code&gt;sideways&lt;/code&gt; and &lt;code&gt;sideways-right&lt;/code&gt; keywords. The &lt;code&gt;sideways-right&lt;/code&gt; value rotates the glyphs 90° clockwise when using vertical layout. This is the same as what is applied by default to horizontal scripts such as Latin. It will however also rotate glyphs that are usually displayed horizontally in vertical layout, which will probably look odd to anyone that can read those languages.&lt;/p&gt;

&lt;p&gt;The currently unsupported &lt;code&gt;sideways-left&lt;/code&gt; keyword rotates the glyphs 90° anti-clockwise. The text line is also rotated 180° as if the text is read bottom to top, instead of top to bottom. Think of how labels on the left hand side of the 𝑦 axis of a graph are often displayed.&lt;/p&gt;

&lt;h3&gt;Combining glyphs side-by-side in vertical text&lt;/h3&gt;

&lt;p&gt;While in vertical text glyphs progress down the page, rather than side by side, sometimes you may want to have two (or maybe more?) glyphs side by side, such as the aforementioned case where two digits are combined. &lt;/p&gt;

&lt;p&gt;For that particular use case, we can use the following rule:&lt;/p&gt;

&lt;pre class="language-css"&gt;&lt;code&gt;
text-combine-horizontal: digits 2;
&lt;/code&gt;&lt;/pre&gt;

&lt;p&gt;The &lt;code&gt;digits 2&lt;/code&gt; value (actually the &lt;code&gt;2&lt;/code&gt; can be omitted, as it is the default), says that if two digits (U+0030–U+0039) or less are found in a row, combine them in the space used for 1 character (a width of &lt;code&gt;1em&lt;/code&gt;). Unfortunately, while this would solve our problem, it is not currently supported anywhere, to my knowledge.&lt;/p&gt;

&lt;p&gt;The all keyword works the same way, but tries to apply it to the entire textual contents of the element. You can imagine that if you apply this to an element with more than a few characters, it is likely to not be able to do that. The spec says that it must try to fit the contents into &lt;code&gt;1em&lt;/code&gt;, but can use any method to do so. So I’m not exactly sure what would happen if the contents don’t fit. Craziness is my best guess.&lt;/p&gt;

&lt;p&gt;The final value is &lt;code&gt;none&lt;/code&gt;, which is the default. It is easy to imagine what this does (nothing, except default back to nothing if the element was previously doing something).&lt;/p&gt;

&lt;h2&gt;Some unexpected things to take into account when using vertical text&lt;/h2&gt;

&lt;p&gt;If you expect everything to work as if you just rotated the element and its children 90° using CSS transform rotate, then there are a number of things you should be aware about.&lt;/p&gt;

&lt;h3&gt;Height, width, and the box model&lt;/h3&gt;

&lt;p&gt;If you rotate an element 90° clockwise with a transform, the width of the element looks as if it is the height (width now goes from top to the bottom of the screen). With vertical text however, the width and height remain the physical width and height. That is, if you specify the &lt;code&gt;width&lt;/code&gt; and &lt;code&gt;height&lt;/code&gt;, the text lines will rotate when specifying vertical text, but the width and height of the element will stay the same.&lt;/p&gt;

&lt;p&gt;Similarly, margin/border/padding-top will remain the physical top of the element, rather than the right side when an element is rotated 90° clockwise. A key difference here is margin collapsing. As text flows across the page, &lt;code&gt;margin-left&lt;/code&gt; collapses instead of &lt;code&gt;margin-bottom&lt;/code&gt; when using &lt;code&gt;vertical-rl&lt;/code&gt;, and the right margin collapses when using &lt;code&gt;vertical-lr&lt;/code&gt;.&lt;/p&gt;

&lt;p&gt;The positioning properties such as &lt;code&gt;top&lt;/code&gt;, &lt;code&gt;right&lt;/code&gt;, &lt;code&gt;bottom&lt;/code&gt;, and &lt;code&gt;left&lt;/code&gt; also still refer to the physical edge of the element’s margin box. The &lt;code&gt;top&lt;/code&gt; property still refers to the top edge, rather than switching to the physical right edge.&lt;/p&gt;

&lt;h3&gt;Text-align, vertical-align, text-decoration and floats&lt;/h3&gt;

&lt;p&gt;
While the box model doesn&amp;#8217;t rotate, &lt;code&gt;text-align&lt;/code&gt;, &lt;code&gt;vertical-align&lt;/code&gt;, &lt;code&gt;text-decoration&lt;/code&gt; and &lt;code&gt;float&lt;/code&gt;s do. Left aligned text will become top aligned, right aligned text will be bottom aligned. As you may have guessed by now, &lt;code&gt;float: left&lt;/code&gt; will float the element to the physical top, while &lt;code&gt;float: right&lt;code&gt; will float to the physical bottom.
&lt;/code&gt;&lt;/code&gt;&lt;/p&gt;

&lt;p&gt;&lt;code&gt;Vertical-align: top&lt;/code&gt; will align to the physical right of the cell when using &lt;code&gt;vertical-rl&lt;/code&gt; and the physical left of the cell when using &lt;code&gt;vertical-lr&lt;/code&gt;. Similarly, the &lt;code&gt;underline&lt;/code&gt; value of &lt;code&gt;text-decoration&lt;/code&gt; will be drawn along the physical left edge of the line box using &lt;code&gt;vertical-rl&lt;/code&gt; and the physical right side when using &lt;code&gt;vertical-lr&lt;/code&gt;.&lt;/p&gt;

&lt;p&gt;Due to the above, the &lt;code&gt;vertical-align&lt;/code&gt; property is unfortunately named, as are the &lt;code&gt;left&lt;/code&gt; and &lt;code&gt;right&lt;/code&gt; values of &lt;code&gt;text-align&lt;/code&gt; and &lt;code&gt;float&lt;/code&gt;. For &lt;code&gt;text-align&lt;/code&gt;, two new abstract keywords have been defined, named &lt;code&gt;start&lt;/code&gt; and &lt;code&gt;end&lt;/code&gt;. The &lt;code&gt;start&lt;/code&gt; value is the equivalent of &lt;code&gt;left&lt;/code&gt; and &lt;code&gt;end&lt;/code&gt; is the equivalent of &lt;code&gt;right&lt;/code&gt; (except when using the right to left line direction (e.g. Arabic or Hebrew), where &lt;code&gt;start&lt;/code&gt; is right, and &lt;code&gt;end&lt;/code&gt; is &lt;code&gt;left&lt;/code&gt;). This makes their use less confusing, as they always apply to the start and end of the line box, no matter what orientation is being used. These are currently only supported by WebKit and Gecko. Similarly the abstract values for &lt;code&gt;top&lt;/code&gt; and &lt;code&gt;bottom&lt;code&gt; are &lt;code&gt;over&lt;/code&gt; and &lt;code&gt;under&lt;/code&gt; respectively. &lt;/code&gt;&lt;/code&gt;&lt;/p&gt;

&lt;p&gt;All of this might be easier to understand with a diagram, so here you go:&lt;/p&gt;

&lt;h2&gt;Abstract and physical dimensions and directions&lt;/h2&gt;

&lt;h3&gt;Flow relative directions&lt;/h3&gt;

&lt;p&gt;The following diagrams show the mapping between the flow relative abstract (yellow) and physical (green) directions, as well as the dimensions of the element. The physical directions always stay the same, while the logical directions change depending on writing mode, direction and text orientation.&lt;/p&gt;

    &lt;img src="http://media.tumblr.com/d31edf5cc489d9bfe4a5102f77ea4d1a/tumblr_inline_mjoepksX881qz4rgp.png" alt=""/&gt;&lt;p&gt;horizontal-tb ltr (left to right, top to bottom)&lt;/p&gt;

    &lt;img src="http://media.tumblr.com/a2109bd9869f3f3116e5cd69f9ec6d29/tumblr_inline_mjoepyrbNn1qz4rgp.png" alt=""/&gt;&lt;p&gt;horizontal-tb rtl (right to left, top to bottom)&lt;/p&gt;

    &lt;img src="http://media.tumblr.com/6528ad2e08f3f128cafbae79cfcabfbd/tumblr_inline_mjoeqwePld1qz4rgp.png" alt=""/&gt;&lt;p&gt;vertical-rl (top to bottom, right to left)&lt;/p&gt;

    &lt;img src="http://media.tumblr.com/053a5a45de8dbc34ec5fbdeb9ad54c03/tumblr_inline_mjoermakoD1qz4rgp.png" alt=""/&gt;&lt;p&gt;vertical-lr (top to bottom, left to right)&lt;/p&gt;


&lt;h3&gt;Line relative directions&lt;/h3&gt;

&lt;p&gt;The following diagrams show the line relative physical (blue) and abstract (yellow) directions. You will notice that the physical line-relative directions do change when the text orientation is flipped from &lt;code&gt;sideways-right&lt;/code&gt; to &lt;code&gt;sideways-left&lt;/code&gt;.&lt;/p&gt;


    &lt;img src="http://media.tumblr.com/2cc02eabbd4eba64bc097ed0508c8767/tumblr_inline_mjoeonDU8j1qz4rgp.png" alt=""/&gt;&lt;p&gt;horizontal-tb (top: ltr, bottom: rtl)&lt;/p&gt;

    &lt;img src="http://media.tumblr.com/30b246f91c89bb888d62871150b2b9bf/tumblr_inline_mjoo5kieKn1qz4rgp.png" alt=""/&gt;&lt;p&gt;vertical-lr and vertical-rl&lt;/p&gt;
    &lt;ol&gt;&lt;li&gt;text-orientation: sideways-right, direction: ltr&lt;/li&gt;
       &lt;li&gt;text-orientation: sideways-right, direction: rtl&lt;/li&gt;
       &lt;li&gt;text-orientation: sideways-left, direction: ltr&lt;/li&gt;
       &lt;li&gt; text-orientation: sideways-left, direction: rtl&lt;/li&gt;
    &lt;/ol&gt;</description><link>http://generatedcontent.org/post/45384206019</link><guid>http://generatedcontent.org/post/45384206019</guid><pubDate>Thu, 14 Mar 2013 17:55:00 -0700</pubDate><category>writing modes</category><category>css3</category><category>vertical text</category><category>internationalisation</category></item><item><title>Finer grained control of hyphenation with CSS4 Text</title><description>&lt;p&gt;CSS3 Text provides the ability to apply hyphenation to text, via the &lt;a href="http://www.w3.org/TR/css3-text/#hyphens" target="_blank"&gt;&lt;code&gt;hyphens&lt;/code&gt;&lt;/a&gt; property. While this is all well and good, it doesn’t provide the fine grain control you may require to get professional results. For this, let me introduce to you &lt;a href="http://dev.w3.org/csswg/css4-text/" target="_blank"&gt;CSS4 Text&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;&lt;!-- more --&gt;&lt;/p&gt;

&lt;h2&gt;Applying bog standard hyphens&lt;/h2&gt;

&lt;p&gt;Many of you are probably aware of the &lt;a href="http://www.w3.org/TR/css3-text/#hyphens" target="_blank"&gt;&lt;code&gt;hyphens&lt;/code&gt;&lt;/a&gt; property, and what it is used for. It has long been considered a bad practice to justify text on the Web due to the &lt;a href="http://en.wikipedia.org/wiki/River_(typography)" target="_blank"&gt;rivers&lt;/a&gt; it tends to leave between words. Hyphenation largely solves or reduces this problem. It is also easy to apply:&lt;/p&gt;

&lt;pre class="language-css"&gt;&lt;code&gt;p {
    text-align: justify;
    			    			
    -webkit-hyphens: auto;
    -moz-hyphens: auto;
    -ms-hyphens: auto;
    hyphens: auto;
}&lt;/code&gt;&lt;/pre&gt;

&lt;p&gt;Also, remember to set the language (using the &lt;code&gt;lang&lt;/code&gt; or &lt;code&gt;xml:lang&lt;/code&gt; attribute, so that the browser knows which hyphenation rules to use.&lt;/p&gt;

&lt;p&gt;You can also use the &lt;code&gt;manual&lt;/code&gt; value, which will hyphenate words only when you specify it, using the soft hyphen (&lt;code&gt;&amp;amp;shy;&lt;/code&gt;), or regular hyphen.&lt;/p&gt;

&lt;p&gt;Browser support is mixed. Firefox, Internet Explorer 10, and Safari support hyphenation, while Chrome and Opera don’t. Chalk one up for the differences between WebKit browsers list.&lt;/p&gt;

&lt;h2&gt;Problems with hyphenation&lt;/h2&gt;

&lt;p&gt;While hyphenation reduces the rivers flowing through your text, they lead to a different issue. That of ladders. In typography, ladders are when more than two hyphens appear in a row at the end of a line. It becomes visually distracting, and makes the text harder to read. Especially when using short line lengths, such as with multi-column layout.&lt;/p&gt;

&lt;h2&gt;Applying more control with CSS4 Text&lt;/h2&gt;

&lt;p&gt;The &lt;a href="http://dev.w3.org/csswg/css4-text/" target="_blank"&gt;CSS4 Text specification&lt;/a&gt; (warning: work in progress) provides a number of ways you can optimise how hyphens are applied. While they are no substitute for manually typesetting and hyphenating your text, it does provide you with much more fine grained control, and can improve the readability of your justified and hyphenated text.&lt;/p&gt;

&lt;h3&gt;Limiting the number of hyphens in a row using hyphenate-limit-lines&lt;/h3&gt;

&lt;p&gt;The &lt;a href="http://dev.w3.org/csswg/css4-text/#hyphenate-line-limits" target="_blank"&gt;&lt;code&gt;hyphenate-limit-lines&lt;/code&gt;&lt;/a&gt; property allows you to specify the maximum number of lines in a row that a word will be hyphenated. The general rule of thumb is that two consecutive lines is the ideal maximum:&lt;/p&gt;

&lt;pre class="language-css"&gt;&lt;code&gt;hyphenate-limit-lines: 2;&lt;/code&gt;&lt;/pre&gt;

&lt;p&gt;This property is currently supported by IE10 and Safari, using the -ms- and -webkit- prefix respectively.&lt;/p&gt; 

&lt;p&gt;You can check out my &lt;a href="https://dl.dropbox.com/u/444684/css4text/hyphenate-limit-lines.html" target="_blank"&gt;hyphenate-limit-lines demo&lt;/a&gt; to see this in action. You will need to use one of the aforementioned browsers to see any difference between the two blocks of text. If you do not see three or more hyphens in a row for the first example, you can resize the width of the browser window. You should see that the second example never has more than two hyphens in a row.&lt;/p&gt;

&lt;a href="https://dl.dropbox.com/u/444684/css4text/hyphenate-limit-lines.html" target="_blank"&gt;&lt;img src="http://media.tumblr.com/52303444f7c44e62948b390794936416/tumblr_inline_mj9p1wuvyO1qz4rgp.jpg" alt="demo showing hyphenate-limit-lines in action"/&gt;&lt;/a&gt;

&lt;h3&gt;Limiting the word length, and number of characters before and after the hyphen.&lt;/h3&gt;

&lt;p&gt;You usually don’t want shorter words to be hyphenated as it makes them harder to read. Similarly, you often don’t want too few characters left on a line before the hyphen or pushed to the next line after the hyphen. I don’t think there is a hard and fast rule for the ideal limits, and it is more based on what looks best for your content. I’ve seen a six character word limit, with three character minimum before the break, and two after, &lt;a href="http://books.google.com/books?id=rs6gyb2hPF4C&amp;amp;pg=PT196&amp;amp;lpg=PT196&amp;amp;dq=recommended+word+length+hyphenation&amp;amp;source=bl&amp;amp;ots=SIGbE9tAtQ&amp;amp;sig=F0c8Tg16fAG0xtFUjKB4OWkbKE4&amp;amp;hl=en&amp;amp;sa=X&amp;amp;ei=IEo1UaOvJIOVqgHt1ICQDw&amp;amp;ved=0CHgQ6AEwCTgK" target="_blank"&gt;recommend&lt;/a&gt;. I’ve seen good results with this, but your milage may vary.&lt;/p&gt; 

&lt;p&gt;You can set these limits with the &lt;a href="http://dev.w3.org/csswg/css4-text/#hyphenate-char-limits" target="_blank"&gt;&lt;code&gt;hyphenate-limit-chars&lt;/code&gt;&lt;/a&gt; property. It takes three space separated values. If all are set, the first is the minimum character limit for the word before hyphenation, the second is the minimum characters before the hyphenation break, and the last is the minimum characters after the hyphenation break. If the last value is missing, it is set to the same as the second. If only one value is supplied, the last two are set to &lt;code&gt;auto&lt;/code&gt;. If the auto keyword is used (or implied), the user agent picks the best fit based on the current layout.&lt;/p&gt;

&lt;p&gt;The following example sets a six character word limit, with three characters before the hyphenation break and two after:&lt;/p&gt;

&lt;pre class="language-css"&gt;&lt;code&gt;hyphenate-limit-chars: 6 3 2;&lt;/code&gt;&lt;/pre&gt;

&lt;p&gt;Support is currently limited to IE10 only, using the &lt;code&gt;-ms-&lt;/code&gt; prefix.&lt;/p&gt;

&lt;p&gt;You can see this in action in IE10 in my &lt;a href="https://dl.dropbox.com/u/444684/css4text/hyphenate-limit-chars.html" target="_blank"&gt;hyphenate-limit-chars example&lt;/a&gt;. Again, resize the width of the window to see how each example behaves differently. I have manually underlined the words in the second example that have the potential to be hyphenated (six characters or more). They will not always hyphenate, as it may not be possible to apply the hyphenation break in a position that will leave enough characters before or after the break.&lt;/p&gt;

&lt;a href="https://dl.dropbox.com/u/444684/css4text/hyphenate-limit-chars.html" target="_blank"&gt;&lt;img src="http://media.tumblr.com/ea12c7eeff8ec882c9f761a919789792/tumblr_inline_mj9p06oYAS1qz4rgp.png" alt="demo showing hyphenate-limit-chars in action"/&gt;&lt;/a&gt;

&lt;h3&gt;Setting the hyphenation zone&lt;/h3&gt;

&lt;p&gt;When using hyphenation, there is a specific zone that a word needs to fall in at the end of a line before it is considered for hyphenation. With the &lt;a href="http://dev.w3.org/csswg/css4-text/#hyphenate-size-limits" target="_blank"&gt;&lt;code&gt;hyphenate-limit-zone&lt;/code&gt;&lt;/a&gt; property, you can manually specify the width of this zone.&lt;/p&gt;

&lt;p&gt;Whether or not a word falls into the boundary is calculated &lt;em&gt;before&lt;/em&gt; justification is applied (i.e. as if &lt;code&gt;text-align: left&lt;/code&gt; was applied when using left to right languages).  If a word falls into the hyphenation zone, no hyphenation will be applied on that line. If the last word on the line falls outside the zone, the word on the next line is brought up to the current line and hyphenated (unless any other hyphenation limits prevent it from doing so).&lt;/p&gt;

&lt;p&gt;The hyphenation zone is specified using a length value or a percentage. In the following example it is set to 40px:&lt;/p&gt;

&lt;pre class="language-css"&gt;&lt;code&gt;hyphenate-limit-zone: 40px;&lt;/code&gt;&lt;/pre&gt;

&lt;p&gt;Support is currently limited to IE10. Open the following &lt;a href="https://dl.dropbox.com/u/444684/css4text/hyphenate-limit-zone.html" target="_blank"&gt;hyphenate-limit-zone example&lt;/a&gt; in this browser to see it in action. I’ve hi-lighted where the zone would be in each example. In the first, third and fifth examples, no hyphenation zone is set, but it shows clearly which words would fall in or out of the zone before justification and hyphenation are applied. &lt;/p&gt;

&lt;a href="https://dl.dropbox.com/u/444684/css4text/hyphenate-limit-zone.html" target="_blank"&gt;&lt;img src="http://media.tumblr.com/006955548794b21e9b3bb46bfcf05afb/tumblr_inline_mj9owxpqh01qz4rgp.png" alt="demo showing hyphenate-limit-zone in action"/&gt;&lt;/a&gt;

&lt;h3&gt;Other, unsupported features&lt;/h3&gt;

&lt;p&gt;There are a couple of additional properties, that are not supported in any browsers currently.&lt;/p&gt; 

&lt;p&gt;The first is &lt;code&gt;hyphenate-character&lt;/code&gt;. This accepts a string that specifies the character used to hyphenate. For example, the regular hyphen character (which is the default so doesn’t need specifying) can be set using:&lt;/p&gt;

&lt;pre class="language-css"&gt;&lt;code&gt;hyphenate-character: "\2010";&lt;/code&gt;&lt;/pre&gt;

&lt;p&gt;I’m not sure why you would want to set a character other than the default one used by the language in question, but I guess there could be some use case if you’re getting creative.&lt;/p&gt;

&lt;p&gt;The other unsupported property is &lt;code&gt;hyphenate-limit-last&lt;/code&gt;. This specifies if hyphenation is applied on the last line of an element, column, page, or spread. The &lt;code&gt;none&lt;/code&gt; keyword applies no restriction, the &lt;code&gt;always&lt;/code&gt; keyword does not apply hyphenation on the last line of all the aforementioned cases. The &lt;code&gt;spread&lt;/code&gt; keyword doesn’t apply hyphenation to the last line before a spread break, &lt;code&gt;page&lt;/code&gt; restricts this to spread breaks and page breaks, while the &lt;code&gt;column&lt;/code&gt; keyword restricts it to spread, page and column breaks.&lt;/p&gt;

&lt;pre class="language-css"&gt;&lt;code&gt;hyphenate-limit-last: column;&lt;/code&gt;&lt;/pre&gt;

&lt;h2&gt;Tying it all together&lt;/h2&gt;

&lt;p&gt;While each of the examples shown only use one of the hyphenate-limit-* properties, they can be combined to apply greater control. Unless you’re an hyphenation expert (I’m not), you can often get the bed results by experimenting with the various properties to suit you specific content. Different styling such as line lengths, justification, columns, word spacing, letter spacing, text size, etc. can have a big difference on how the text is hyphenated, and how much massaging you need to apply. Just remember not to go overboard with restricting hyphenation, or you’ll end up with the original problem you were using hyphenation to avoid; the large rivers of white space between words.&lt;/p&gt;</description><link>http://generatedcontent.org/post/44751461516</link><guid>http://generatedcontent.org/post/44751461516</guid><pubDate>Wed, 06 Mar 2013 17:54:56 -0800</pubDate><category>hyphens</category><category>CSS3</category><category>CSS4</category><category>text</category></item><item><title>Get help faster, by reporting better issues</title><description>&lt;p&gt;I have been spending quite a bit of time recently helping out with compatibility issues on sites such as &lt;a href="http://stackoverflow.com" target="_blank"&gt;StackOverflow&lt;/a&gt; and the &lt;a href="http://social.msdn.microsoft.com/Forums/en-US/iewebdevelopment/" target="_blank"&gt;MSDN forums&lt;/a&gt;. It is often difficult to give helpful advice, as the reporter doesn’t give sufficient details to debug the problem. Instead of repeatedly typing the same message in each thread, I’ve distilled some points here, that may guide you when reporting your web development woes. Taking some time to stop and think, and put yourself in the shoes of the person that will read your report, will help you create better reports, and you’ll receive faster and better quality feedback.&lt;/p&gt;

&lt;p&gt;&lt;!-- more --&gt;&lt;/p&gt;

&lt;h2&gt;Avoid common issues&lt;/h2&gt;

&lt;p&gt;A few quick checks can spot the low hanging fruit that you may have overlooked:&lt;/p&gt;

&lt;ul&gt;&lt;li&gt;Check the error console of your browser’s developer tool. Especially if it is a JavaScript issue.&lt;/li&gt;
    &lt;li&gt;Validate your &lt;a href="http://validator.w3.org" target="_blank"&gt;HTML&lt;/a&gt; and &lt;a href="http://jigsaw.w3.org/css-validator/" target="_blank"&gt;CSS&lt;/a&gt;. &lt;a href="http://www.jshint.com" target="_blank"&gt;Lint your JavaScript&lt;/a&gt;. It just takes a mismatched end tag, or missing semi-colon to wreak all sorts of havoc.&lt;/li&gt;
    &lt;li&gt;Problem in IE? Check the &lt;a href="http://msdn.microsoft.com/en-us/library/ie/gg589507(v=vs.85).aspx" target="_blank"&gt;F12 tool&lt;/a&gt; to make sure your page is using the latest document mode. IE can default to using an earlier version of the engine.&lt;/li&gt;
&lt;/ul&gt;&lt;h2&gt;Sharing your problem&lt;/h2&gt;

&lt;p&gt;If you are still having issues, it is time to look for help. Follow the next few steps to improve your chances of getting helpful feedback.&lt;/p&gt;

&lt;h3&gt;Step 1: Give a way to run the code you are having problems with&lt;/h3&gt;

&lt;p&gt;If you don&amp;#8217;t give people a way to run your code, it can be very difficult to find the issue you are experiencing. An inline code snippet in the post often doesn&amp;#8217;t help, as the issue may not even relate to that code, and it is not possible to experiment with the code to try out different theories. 

&lt;/p&gt;&lt;p&gt;At worst case, link to the actual page you are developing. If you really want to be helpful, make a reduced test case, which only includes the minimum amount of code that still exhibits the problem. For example, if the issue is with your login form, you can probably remove all the HTML around it and the CSS that doesn&amp;#8217;t apply.

&lt;/p&gt;&lt;p&gt;There are a number of online tools such as JSFiddle that allow you to host small snippets of code. If possible use one of these. This allows us to edit the code and link back to the result. Popular tools include:

&lt;/p&gt;&lt;ul&gt;&lt;li&gt;&lt;a href="http://jsfiddle.net" target="_blank"&gt;JSFiddle&lt;/a&gt;&lt;/li&gt;
    &lt;li&gt;&lt;a href="http://jsbin.com" target="_blank"&gt;JS Bin&lt;/a&gt;&lt;/li&gt;
    &lt;li&gt;&lt;a href="http://dabblet.com" target="_blank"&gt;Dabblet&lt;/a&gt;&lt;/li&gt;
    &lt;li&gt;&lt;a href="http://codepen.io" target="_blank"&gt;CodePen&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;&lt;h3&gt;Step 2: Concisely explain the issue you are having&lt;/h3&gt;

&lt;p&gt;No need to tell a story about what you ate for breakfast. Include the following details:&lt;/p&gt;

&lt;ul&gt;&lt;li&gt;Short description of the issue. Keep it as short as a tweet if possible&lt;/li&gt;
    &lt;li&gt;Steps to reproduce the issue. Even if obvious to you&lt;/li&gt;
    &lt;li&gt;Result you are expecting&lt;/li&gt;
    &lt;li&gt;Actual result you are seeing&lt;/li&gt;
    &lt;li&gt;A screenshot if the issue is visual&lt;/li&gt;
    &lt;li&gt;The browser(s), version(s), and operating system (if applicable) where you’re seeing the issue&lt;/li&gt;
    &lt;li&gt;Any other essential supporting information&lt;/li&gt;
&lt;/ul&gt;&lt;h3&gt;Step 3: There is no step 3&lt;/h3&gt;

&lt;p&gt;Sit back, relax, and wait for a reply. If you work out the issue before anyone replies, report back your findings. It saves someone wasting their time dealing with your issue, and will help anyone else that runs into the same problem as you.&lt;/p&gt;

&lt;h2&gt;Stumbled across a browser bug?&lt;/h2&gt;

&lt;p&gt;Often it isn’t your fault. It’s the browser. If this is the case, remember to report the bug with the browser vendor(s) in question. If they don’t know about the bug, they can’t fix it. Luckily, if you followed the steps above, most of the work has already been done, and you can copy and paste your excellent report into the bug tracking system of the browser vendor in question. But, remember to search first to see if the same issue has been reported.&lt;/p&gt;

&lt;p&gt;Lea Verou has an excellent article on &lt;a href="http://coding.smashingmagazine.com/2011/09/07/help-the-community-report-browser-bugs/" target="_blank"&gt;how to report browser bugs&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;Here are the location of the bug trackers:&lt;/p&gt;

&lt;ul&gt;&lt;li&gt;&lt;a href="https://connect.microsoft.com/IE/Feedback" target="_blank"&gt;Internet Explorer&lt;/a&gt;&lt;/li&gt;
    &lt;li&gt;&lt;a href="https://bugs.opera.com/wizard/" target="_blank"&gt;Opera&lt;/a&gt; (Note: Opera will soon be switching to WebKit)&lt;/li&gt;
    &lt;li&gt;&lt;a href="https://bugzilla.mozilla.org" target="_blank"&gt;Firefox&lt;/a&gt;&lt;/li&gt;
    &lt;li&gt;&lt;a href="https://bugs.webkit.org" target="_blank"&gt;WebKit (Chrome and Safari)&lt;/a&gt;&lt;/li&gt;
    &lt;li&gt;&lt;a href="http://code.google.com/p/v8/issues/list" target="_blank"&gt;V8, for issues with JS support in Chrome&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;</description><link>http://generatedcontent.org/post/44173037944</link><guid>http://generatedcontent.org/post/44173037944</guid><pubDate>Wed, 27 Feb 2013 15:27:00 -0800</pubDate><category>bugs</category><category>compatibility</category></item><item><title>Hey -o-, let’s go!</title><description>&lt;p&gt;So the news we were all dreading came to pass. &lt;a href="http://my.opera.com/ODIN/blog/300-million-users-and-move-to-webkit" target="_blank"&gt;Opera will drop Presto, in favour of WebKit&lt;/a&gt;. Four becomes Three. Only one browser engine remains where the dominant contributions come from an independent vendor who don’t have a vested interest in a large native ecosystem. What does this mean for Opera, and the Web at large?&lt;/p&gt; 

&lt;p&gt;&lt;!-- more --&gt;&lt;/p&gt;

&lt;h2&gt;I Fought the Law, and the Law Won&lt;/h2&gt;

&lt;p&gt;This move is Opera throwing in the towel. It is saying “WebKit has become too dominant (specifically on mobile), and we can’t compete”. Think about that for a second. It isn’t viable to have an independently developed browser engine in 2013. No matter that you have some of the best developers in the industry, and great industry influence.&lt;/p&gt; 

&lt;p&gt;While many will say Opera’s influence is negligible, think back to the biggest changes in the history of the Web over the last few years. Moving from HTML to CSS based layouts? Opera was perhaps the first to have a useable CSS engine. Håkon (father of CSS, and Opera CTO) often says it was the reason he started to believe a browser could be made in Norway, not just the USA, and joined Opera. AJAX? Opera reverse engineered this from MS’ ActiveX based approach and were the spec editors through Anne van Kesteren. HTML5? Started at Opera with Ian Hickson and others. Responsive web design? Media Queries came from Opera, and were implemented for years before showing up in other browsers. What about native video on the Web? Opera again.&lt;/p&gt; 

&lt;h2&gt;Should I Stay or Should I Go?&lt;/h2&gt;

&lt;p&gt;But why did it come to this? What pushed Opera over the edge, and made it decide to become a bit part player in the increasingly crowded WebKit fraternity, rather than be in control of its own destiny with its own engine? I think it is clear from previous moves from Opera. It had to change its user agent string to hide the true version due to sites not working when moving to a two digit version number. Faulty browser sniffing. It had to add support for -webkit- properties. Browser engine mono-culture on mobile (and even desktop in some cutting edge sites). I could go on.&lt;/p&gt; 

&lt;p&gt;I have first hand knowledge of browser compatibility work inside Opera, and it was always like being a salmon swimming against the tide. That we have standards is a bit of a fallacy. Devs used to code for only IE, then Firefox came along, and you had a IE path and a standards path. Except the standards path was basically a Firefox path, bugs and all. So you had to emulate Firefox. Or if the standards path worked, you had to beg the developer to give it to Opera, as they browser sniffed anyway. Then WebKit became the apple of the developer’s eye, and there becomes a proliferation of -webkit- only prefixes without fallback or regard for other browsers. Opera just wasn’t big enough in the right markets to weigh on developers minds. Unless it did something that was perceived to be wrong, then it was suddenly important.&lt;/p&gt; 

&lt;p&gt;Faced with that situation you can continue to swim against the tide, or say screw it and join the path of least resistance. I’m sorry to say, but we’ve all failed the Web, as this is WebKit not Web Standards. That is just the market reality.&lt;/p&gt; 

&lt;p&gt;Opera had to do what was best for their users (and shareholders), and let’s face it, except for the power users–of which Opera has many–the user has no idea what engine the browser is using, and shouldn&amp;#8217;t need to care. Most will be none the wiser after the switch. Except less of their sites will block them from using it, and more of the shoddily built sites (of which most top sites are in one way or another) will just start working. Yey &lt;del&gt;standards&lt;/del&gt; &lt;ins&gt;WebKit&lt;/ins&gt;!&lt;/p&gt; 

&lt;h2&gt;Armageddon time&lt;/h2&gt;

&lt;p&gt;Opera failed, I failed in my dev rel and web compatibility role. Influential developers failed to fully comprehend or care about the situation. The W3C failed. Other non-WebKit vendors failed. There is no point in pointing fingers. We all failed in some capacity.  We all need to do better, starting today.&lt;/p&gt; 

&lt;h2&gt;Death or Glory?&lt;/h2&gt;

&lt;p&gt;So what does this mean for Opera? Is it bad for Opera? Not necessarily. I think it could be very good for them. Even though they have over 300 million users, there is a lot of user churn. I guess we’ll finally find out if those not sticking around was because of compatibility issues or because of the product itself. There are no longer any excuses to hide behind. And some argue Opera is becoming an ad company rather than a browser vendor anyway.&lt;/p&gt; 

&lt;p&gt;On the other hand, its influence may wane somewhat. People in Opera used to often not count a browser as a browser if it was only a shell around another engine. Opera on iOS will certainly be this. On other platforms it remains to be seen if Opera will more passively just use Chromium and focus its efforts on value added features, or if it will actively add standards features with as much gusto as it does with Presto. Will WebKit give Opera the respect it deserves, or will it be like other vendors that struggle to get its patches into trunk?&lt;/p&gt; 

&lt;p&gt;What happens if Opera wants to go in a different direction to Google and Apple? It can create its own fork, but then it starts to become less compatible over time. It doesn’t have the influence of a Google to get away with that, and it removes the reasons to move to WebKit in the first place.&lt;/p&gt; 

&lt;h2&gt;Four horsemen&lt;/h2&gt;

&lt;p&gt;What does it mean for the Web?  We used to have a multitude of engines on the web. Hands up who remembers the iCab engine? Assimilated into WebKit. UC Web? Ditto. NetFront. You guessed it. BlackBerry, OmniWeb, the list seems almost endless. We ended up with four major engines, and now we have three.&lt;/p&gt;  

&lt;p&gt;Competition breeds innovation. You can trace the performance race back to the early stated goals of WebKit to always improve performance. What wasn’t shown on the Keynote slides was that Opera used to be leagues ahead in terms of performance at the time. WebKit and Apple used it as the standard which to beat. I have fond memories of the ACID tests and the friendly rivalry between WebKit and Opera on who would pass it first. People thought of this as browser grandstanding. But it motivated browser developers to work that little bit harder to fix complex bugs, improve rendering, and speed up the browser. As quickly as possible. When developers smelt victory they’d spend extra hours in the office getting that extra 1%. It was kind of like the olympics for browser geeks. Competition driving standards compliance. If WebKit wins out in the end, where will be the competition? Who gets their patch landed before another one?&lt;/p&gt; 

&lt;p&gt;There can even be competition between alternative proposals for solving a particular issue. This can cause comptibility issues, but can also lead to better APIs overall. Will there be less incentives if everyone ends up working on the same engine? That is hard to tell.&lt;/p&gt; 

&lt;h2&gt;Three card trick&lt;/h2&gt;

&lt;p&gt;But, currently we’re down to three, not one. We have to hope that Mozilla and IE stick to their guns. Because right now the W3C requires two interoperable implementations for something to become a standard. That now becomes two thirds of implementations. If we lose another engine, one effectively has veto power. WebKit effectively has that now anyway on mobile, where once Opera switches over the Opera Mini backend to WebKit, it is rounding errors away from complete domination.&lt;/p&gt;  

&lt;h2&gt;Gates of the West&lt;/h2&gt;

&lt;p&gt;Developers often claimed WebKit was the only relevant engine on mobile already. But it never was. With Opera Mini holding the top spot for a long time, and still being hugely dominant in &lt;a href="http://gs.statcounter.com/#mobile_browser-ww-monthly-201301-201301-map" target="_blank"&gt;countries such as India and Russia&lt;/a&gt;, this was just a wealthy western web viewpoint rather than a global viewpoint. True, for their use case no other engine might have mattered (except the lock in they were creating to create friction against change in the future, just like the IE6 days…), but there were many developers in the world where this was not the case. Could any developer in Russia or India only develop for iPhone and Android? I doubt it.&lt;/p&gt; 

&lt;p&gt;But this western viewpoint caused a multitude of issues for Opera, that effectively blocked its influence in developing markets to spread westwards, and down under. And, thus the play you see unfold today.&lt;/p&gt; 

&lt;h2&gt;Last gang in town&lt;/h2&gt;

&lt;p&gt;So now, the torch is passed to Mozilla and Microsoft, as on the 13th day Opera become the Judas in the battle to avoid mobile monoculture. Microsoft becoming a saviour of the Web? It looked unlikely during the &lt;del&gt;dark ages&lt;/del&gt; &lt;ins&gt;IE6 years&lt;/ins&gt;, but they might just have become our best hope. They have the resources to put up a fight for feature parity with WebKit, and mobile OS marketshare with Windows Phone, plus Windows 8 puts the spanner in the works, as any desktop can become a touch platform. I know I’ll be cheering them on.&lt;/p&gt; 

&lt;p&gt;Mozilla were very late to the mobile party, and that is reflected in its tiny mobile market share. It may have needed Opera to stay strong more that it would care to admit. I was always disappointed Opera and Mozilla couldn&amp;#8217;t co-operate more, and the trolling that came from certain corners. They both have shared goals for the most part. I think Mozilla saw web compatibility as an Opera problem, until it entered the mobile world and got hit with it themselves. The same mistake can’t happen twice. Mozilla and Microsoft really need to get talking on how to combat the WebKit threat. Especially now it can move even faster forward if Opera developers also contribute to the engine codebase. We can’t afford only one superpower, with the W3C relegated to the role of the UN.&lt;/p&gt; 

&lt;p&gt;I really worry for what this move means for the W3C long term.&lt;/p&gt;  

&lt;h2&gt;I’m so bored with the USA&lt;/h2&gt;

&lt;p&gt;But, back to Opera again. Are there any hidden meanings in the announcement today? Could Opera be primed for a take over? A number of people lost their jobs (I&amp;#8217;ve no idea how many, but a big chunk of my old team, and there are a lot of new faces on the Opera Alumni Facebook group). A move like this was always going to have human tragedy. Could they be  “cutting the fat” before a takeover? There have been so many rumours over the years, but the former CEO never wanted to sell. Now the company is run by a sales guy.&lt;/p&gt;  

&lt;p&gt;WebKit developers are in major short supply. I remember the difficulty we had attracting and keeping WebKit talent at Motorola, and how hard Adobe are looking for developers. Opera (if they don’t eventually lay them off) have a large number of very talented browser engine developers, who know the specs inside out, and are in many cases on W3C working groups. These are transferable skills to the world of WebKit. If Opera gets any sort of influence in the WebKit community, they may just become a more valuable takeover target, and surely more bang for your buck than an Instagram.&lt;/p&gt;  

&lt;p&gt;Many people speculate about Facebook. Adobe could perhaps be an option. My dark horse prediction is Yandex.&lt;/p&gt; 

&lt;h2&gt;Rudi can’t fail&lt;/h2&gt;

&lt;p&gt;We need to learn from the mistakes of the past. The Web is too important to stagnate again or to be held ransom to the politics and design goals of one single code base and project. The &lt;a href="http://www.w3.org/2001/tag/" target="_blank"&gt;TAG at the W3C&lt;/a&gt; have just had a fresh injection of elected talent. Let’s not hand the keys to the WebKit project maintainers instead.  Nothing against them at all; they’re great people. Just, diversity of opinion is one of the things that make the web great. And it is not just for people like us, that can afford shiny new iPhones. It is for the farmer in Africa, the factory worker in Bangladesh, the growing middle-class in China. Everybody. Diversity in the standards process tends to help with keeping these goals in mind.&lt;/p&gt; 

&lt;h2&gt;Here Today, Gone Tomorrow&lt;/h2&gt;

&lt;p&gt;As well as a reduction in the gene pool of web rendering engines, there is a very human sadness with this move. I’ve no idea how many people lost their livelihoods with the move, but at least a bunch of my old team in Opera DevRel and people in the standards team. I hope people that wished Opera would go away and become bankrupt are happy with that news.&lt;/p&gt;  

&lt;p&gt;I’m not even sure the DevRel team I founded and helped to build still exists. In many ways it was like my baby, that I stepped away from to watch it grow up. It was, I believe, the first developer relations team focused on web technology. I fondly remember Andy Budd saying at @Media that he wished other vendors would take an active interest in the concerns of developers like Opera did (or words to that effect). The CEO of YouTube said something similar when working with them on Opera compatibility, before it became a Google concern.&lt;/p&gt; 

&lt;p&gt;We hired some amazing people, who were foremost web people, not marketeers or from other platforms. We understood the web, cared for the web, and fought for the web. We had a diversity in the team that would make a conference organiser green with envy. Not just male and female (although at one time we had more female dev rel in North America than male), but, a rainbow of races, creeds, social backgrounds, religions, what have you. It was like the United Nations, without the arguments, and much more inappropriate humour. It was a global second family (as was Opera at a whole), but I&amp;#8217;m glad to say, every single one was hired because they were the best person for the job, not because of what was between their legs, or any other physical characteristic. I hope those that left today find a job in the web, as they’ll be missed otherwise.&lt;/p&gt;  

&lt;p&gt;We might not have ultimately succeeded in keeping the web open, but there will be a lasting influence. Every browser vendor now has its own developer relations team. Something we perhaps can‘t claim credit for, but at least influenced in a meaningful way. Many of those in Opera and the other vendor‘s DevRel teams have become active in improving the health of the web community, and members of working groups defining the standards we use every day. If that is my lasting legacy on the web, then it is at least something.&lt;/p&gt; 

&lt;h2&gt;I Believe In Miracles&lt;/h2&gt;

&lt;p&gt;The best that can come of this? Maybe Opera will eventually open up the Presto codebase. Let it enjoy its twilight years in the sun. I don’t suspect it can survive without corporate backing, but there is a lot to learn from.&lt;/p&gt;.</description><link>http://generatedcontent.org/post/43036827576</link><guid>http://generatedcontent.org/post/43036827576</guid><pubDate>Wed, 13 Feb 2013 16:05:00 -0800</pubDate><category>Opera</category><category>webkit</category><category>soitcametothis</category></item><item><title>Predictions for the Web in 2013</title><description>&lt;p&gt;2012 was a bumper year for the Web. Lets get our crystal ball out and look what we could have in store for us in 2013, in terms of the browser and platform wars.&lt;/p&gt;

&lt;p&gt;&lt;!-- more --&gt;&lt;/p&gt;

&lt;h2&gt;The desktop browser market&lt;/h2&gt;

&lt;p&gt;Chrome spent much of 2012&amp;#160;&lt;a href="http://gs.statcounter.com/#browser-ww-monthly-201112-201212" target="_blank"&gt;eating marketshare&lt;/a&gt; from IE and Firefox. Indeed, the only browser to grow except for Chrome was the other WebKit browser, Safari. However its ~2% marketshare gain was mostly due to Safari on iPad’s growth rather than the desktop browser.&lt;/p&gt;

&lt;p&gt;Towards the end of the year, Microsoft released Windows 8 with &lt;a href="http://msdn.microsoft.com/library/ie/hh673549.aspx" target="_blank"&gt;IE10&lt;/a&gt;. As IE10 comes out on Windows 7, and Windows 8 starts to build marketshare, Microsoft will hope it reverse their losses to Chrome. Can they do it? It’s hard to say, but it’s clear that IE10 is Microsoft’s best browser in quite some time. It’s CSS, HTML and ECMAScript support is finally competitive with the competition. It has a WebGL sized hole in its standard support (but how many average web pages use 3D graphics?) and doesn’t support some of the more experimental APIs, but the gap that grew from IE putting its tools down for 5 years has almost closed.&lt;/p&gt;

&lt;p&gt;The gap between IE releases have been getting shorter since IE8 came out. If they can reduce that to around a year or less, and keep their current pace of development, could we have a mighty war on our hands between IE and Chrome for marketshare and standards compliance supremacy before the end of the year? It would certainly make things more interesting. Competition breeds innovation, but with Apple and Google using the same engine, not much competition has been happening between those great rivals. Microsoft could really put a cat amongst the pigeons, and break any potential WebKit dominance on the desktop. I strongly believe that engine diversity is good for the Web, so I’ll be hoping for a IE and Firefox comeback in 2013.&lt;/p&gt;

&lt;p&gt;One prediction that I hope doesn’t come true is the demise of Opera in the desktop market. In the last year, Opera dropped from 1.98% to only 1.26%. In the early days of January &lt;a href="http://gs.statcounter.com/#browser-ww-monthly-201112-201301" target="_blank"&gt;it is down further to 1.16%&lt;/a&gt;. Is it in danger of dropping out the top 5 browsers? I&amp;#8217;m not sure if Opera is actually losing users, or whether the market is just growing faster than it is.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Prediction:&lt;/strong&gt; IE11 and Chrome 1,234 (~approx.) going toe to toe by the end of 2013?&lt;/p&gt;

&lt;h2&gt;Mobile platform wars: the race for third&lt;/h2&gt;

&lt;p&gt;Forget about the titanic battle for first place in the mobile market. iOS and Android will go at it tooth and nail through 2013, but the latter already has the marketshare battle sewn up globally, as it extends its reach downwards into the more price sensitive markets that Apple chooses not to compete in. The main contest between those two will be who comes out on top in the premium markets, where there is more profit–rather than marketshare–on the line.&lt;/p&gt;

&lt;p&gt;The more interesting battle in my mind in 2013 is the looming battle for 3rd place, and thus relevancy, in the smartphone market. For some contestants their entire futures as an independent entity rest on not only wrestling 3rd place out of the hands of their rivals, but building on that platform to get closer to iOS and Android than the rest of the chasing pack. A weak 3rd place won&amp;#8217;t be good enough to get developer attention. I suspect these platforms will need to at least get into the double digit market share, or have something else to offer developers to remain in the race. Manoeuvring into third place by the end of 2013 will likely be a key springboard to building out the victor’s ecosystem however.&lt;/p&gt;

&lt;p&gt;Who are the likely contestants in this battle? Currently Nokia’s two operating systems; S40 and Symbian are the only two platforms under iOS and Android that are around &lt;a href="http://gs.statcounter.com/#mobile_os-ww-monthly-201212-201212-bar" target="_blank"&gt;the 10–15% mark&lt;/a&gt;. The latter is a legacy platform that will only drop in popularity as users upgrade their phones. S40 is a feature phone OS, which will presumably stick around a while longer on the low end, but is not part of the app-centric smartphone battle.&lt;/p&gt;

&lt;p&gt;The core battle will likely be between Windows Phone 8 and BlackBerry 10. It&amp;#8217;s an interesting contest, as BlackBerry still has an edge in terms of marketshare (mostly due to its strong position in the UK and Canada), but it&amp;#8217;s influence is fading fast. RIM will need to try to convert those loyal holdouts to BB10. In reality, Windows Phone has the head star,t as BlackBerry is moving to a whole new platform, which is still not on the market. Nokia have an even bigger legacy user base, that can be a key asset if they work out how to get Windows Phone at a price point to attract those users to upgrade and switch to Microsoft&amp;#8217;s newer platform. Both Nokia and RIM will need to move fast though, before Android eats up that potential source of new users.&lt;/p&gt;

&lt;p&gt;Windows Phone&amp;#8217;s market success has never really justified the column inches written about it, but there are signs that it will prove the naysayers wrong. In Europe it is currently the 3rd most popular platform in key markets such as France, Italy, Germany, Ireland, Switzerland, Austria, Belgium, and the entire Nordics region. Despite an overall marketshare lead over Windows Phone in Europe, BlackBerry is only more popular in the UK and Portugal. Furthermore Windows Phone has had a large uptick in the last few months, so it looks like momentum is on its side. Microsoft will hope that it can repeat the success it is having in Nokia’s home market of &lt;a href="http://gs.statcounter.com/#mobile_os-FI-daily-20111226-20130102" target="_blank"&gt;Finland&lt;/a&gt; in other markets.&lt;/p&gt;

&lt;p&gt;I do hope Windows Phone does well, as we desperately need a successful platform with a none-webKit browser as default. It is also a brave step from Microsoft to focus on design, and not just produce a carbon copy of Apple’s OS (and those before it such as UIQ and PalmOS). My biggest disappointment of 2012 was that Windows Phone 8 didn&amp;#8217;t ship with support for native HTML apps in much the same way as Windows 8 did. I think that was a mistake, especially when you consider the similarities between the platforms and the cross pollination it would have allowed.  I think it will be coming in 2013 though. Microsoft would be crazy not to. Imagine if the first popular web based mobile operating system ends up being Trident based rather than WebKit? No one would have predicted that a few years ago, but it is well within the realms of possibility.&lt;/p&gt;

&lt;p&gt;Windows Phone and BlackBerry 10 are not the only contestants though. &lt;a href="http://www.mozilla.org/en-US/firefoxos/" target="_blank"&gt;Firefox OS&lt;/a&gt; will likely make its bow in 2013, and also &lt;a href="http://www.ubuntu.com/devices/phone" target="_blank"&gt;Ubuntu phone&lt;/a&gt;. I believe the latter also ships with a Gecko based browser and HTML app platform. I consider these platforms to be the black horses of the race. Both are from strong and well respected open source friendly companies, but neither have a great deal of experience or history of success in the mobile space. Mozilla have little experience writing operating systems or dealing with OEMs and Operators (the latter of which is one of Opera&amp;#8217;s strong suites, and partially why they do so well in the mobile browser wars), while Canonical have a ton of OS experience, but are not exactly known as a web powerhouse (although they do have some people such as &lt;a href="http://yaili.com" target="_blank"&gt;Yaili&lt;/a&gt; and &lt;a href="http://www.kryogenix.org/" target="_blank"&gt;Stuart&lt;/a&gt; who are very much involved in the community). 

&lt;/p&gt;&lt;p&gt;I do worry that both may be spreading themselves a little thin, and their solutions may be a little late, considering the huge resources available to Apple, Google and Microsoft, and the fact they won&amp;#8217;t be standing still waiting for the competition to catch up. Especially considering they are both Gecko based, I would have liked to have seen what a combined effort from Mozilla and Canonical could have looked like. Mozilla would have been able to lend their world class experience in producing a browser, Web APIs, web developer tools, and their influence in the developer and standards communities to Canonical experience writing operating systems and services. They are probably the two biggest names in consumer focused open source software, so people in the developer community at least would sit up and notice. Instead, I fear that both will eat into each other&amp;#8217;s potential marketshare, as they go after the same audience and the same developers. They will also potentially fragment the Gecko ecosystem, unless they manage to ship comparable versions.&lt;/p&gt;

&lt;p&gt;The final realistic competitor is &lt;a href="https://www.tizen.org" target="_blank"&gt;Tizen&lt;/a&gt; from Intel and Samsung. It remains to be seen if Samsung will go all in, or if it will mainly be used as a bargaining chip against Google. Tizen sits atop a pile of caucuses of now abandoned mobile operating systems, such as Bada from Samsung (which was getting some traction in emerging markets), and Meego, Maemo, Moblin, Harmattan and probably half a dozen others I&amp;#8217;m forgetting. Whether it is successful where Nokia, Intel and Samsung failed before is anyone&amp;#8217;s guess. Its one true advantage is that if Samsung is truly committed to the project, it has the reach and marketing budget to make a fist of it. What it doesn&amp;#8217;t have is a strong history making great software, and a strong developer community. If they want “HTML5” developers to develop for the platform, it better start reaching out to them and be involved in the community, starting yesterday.&lt;/p&gt;

&lt;p&gt;One of the threads that run through most of these platforms is the support for HTML apps. This is potentially great news for developers, as it allows a way to get apps onto each platform with less work than porting to various different native toolkits. Unfortunately, I expect that rather than work together for the common good, they&amp;#8217;ll all have their own system and device APIs and manifest formats. The W3C DAP and Widgets specs have not taken off so far with the larger players, and I don&amp;#8217;t really expect this to change in 2013, unless there is a change of attitudes. WebRTC looks like it will be adopted in some form or other (Microsoft have a rival proposal), but that was specced outside of DAP. I&amp;#8217;ve not seen the same interest in the various DAP specs such as calendar and contacts APIs. With the two leading WebKit vendors having their own non-Web-based OS&amp;#8217;, this is a space where Microsoft, Mozilla and Opera working together could strengthen each other&amp;#8217;s hand against the market leaders. In an ideal world, we could just write code once for the non-UI part of the app, but this isn&amp;#8217;t the case right now.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Prediction:&lt;/strong&gt; Windows Phone is slowly starting to gain momentum. With its head start over the other platforms, and Microsoft’s resources, 2013 will be the year it breaks into 3rd place, and starts to put some air between it and the chasing pack. I also predict they’ll come out with JavaScript apps at some point, either in 2013 or early 2014.&lt;/p&gt;

&lt;h2&gt;Web on TV?&lt;/h2&gt;

&lt;p&gt;Web on TV has been the next frontier of the web since, well, before web on tablets became the next frontier. I don’t expect things to shake up too much this year. Apple TV could throw a spanner in the works and reinvent the field if it finally comes out with apps, a browser, and a new control method.&lt;/p&gt;

&lt;p&gt;The main battle that is brewing is between the console makers and the companion box platforms such as Google TV and Apple TV. In many ways they are converging. Consoles are getting more media centre functionality, and the mobile platforms that the TV boxes evolved from are getting stronger gaming platforms. I suspect the consoles will get better at streaming media and apps faster than the companion boxes get at having top games available, considering many seem to be platform exclusives.&lt;/p&gt;

&lt;p&gt;I own a Samsung Smart TV, and rarely use the browser. The main problem is the control method. It takes longer to type in a URL than it does to go to the other room and find my laptop. It has voice and hand gesture support, but I can’t get either to work. Whoever can solve the input dilemma has a good crack at making a browser that people actually use to surf the web. Microsoft may hold some aces up their sleeve with both &lt;a href="http://en.wikipedia.org/wiki/Xbox_SmartGlass" target="_blank"&gt;SmartGlass&lt;/a&gt; and Kinect. Using a smartphone or tablet as an input device just makes sense. It will be interesting to see what the next XBox and Playstation come out with. If they are not released until the Christmas season, it won&amp;#8217;t be until 2014 that any effects are seen.&lt;/p&gt;

&lt;p&gt;It’s not just the control scheme that is the issue though. The other is the content itself. There is certain content that is more suited to accessing on the TV than others. The obvious one is games, where you benefit from having a large display and space for multiple players. Anything which is social in nature can benefit from using the TV, such as streaming music and videos, video conferencing, photo slideshows and so on. My TV doesn&amp;#8217;t have an HBO app, so I thought I could access their TV shows via the browser. It seemed like the ideal use case. Unfortunately their site blocks the browser. I had a similar issue with Comcast’s Xfinity site. Some shows do not allow you to beam them to the TV, so I thought I could stream them via the browser. There was no blocking this time, but the stream requires Silverlight, which the TV doesn&amp;#8217;t support. These kind of compatibility issues, plus lack of optimisation for the 10 foot viewing experience, puts barriers in front of what would be a fantastic use of a TV browser.&lt;/p&gt;

&lt;p&gt;There is also the case of trying to get to the content as quickly as possible. In the days of Teletext, you just pressed one button to access the service, and the content was tied to the channel you were on. Launching the browser would also benefit from this one button access.&lt;/p&gt; 

&lt;p&gt;The one key advantage a TV browser could have over using a tablet or laptop however, is if it is contextually aware. That is that it could access the video stream you are accessing, and feed related content to the browser or app. This could be anything from having a portal for the channel you are on, to allowing you to access the web site of the product that is being advertised (now, that is the advertiser’s holy grail), get information about the TV show being broadcast, allow you to vote or interact with game shows, and so on. If this was done right, you’d have access with one click, rather than having to search for the content if you were using a desktop or mobile browser. You wouldn’t necessarily access this content on the TV itself. The TV could pass it to a companion device, much like SmartGlass or the Wii U. There is already an industry standard called &lt;a href="http://www.hbbtv.org" target="_blank"&gt;HbbTV&lt;/a&gt; to allow you to access the broadcast stream, but this has only seen any kind of adoption in Europe, and I doubt it will get any kind of mass market adoption this year. It is one to look out for though.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Prediction:&lt;/strong&gt; Still looking for the web on TV holy grail in 2013, but watch out for what the consoles do going into 2014.&lt;/p&gt;</description><link>http://generatedcontent.org/post/39603019294</link><guid>http://generatedcontent.org/post/39603019294</guid><pubDate>Thu, 03 Jan 2013 15:23:00 -0800</pubDate><category>2013</category><category>browser</category><category>mobile</category><category>predictions</category><category>tv</category></item><item><title>Public service announcement: time to update your CSS3 </title><description>&lt;p&gt;If you use experimental CSS on your sites, demos, articles or tools, there is a certain amount of maintenance required to keep on top of changes. With a number of recent changes in the browser world, now is the time to revisit and update your code. Read on to find out what may need updating.&lt;/p&gt;

&lt;p&gt;&lt;!-- more --&gt;&lt;/p&gt;


&lt;h2&gt;Reorder your prefixes&lt;/h2&gt;

&lt;p&gt;There is no specific order that you should place your prefixed properties. However, a commonly recommended method is to place them in alphabetical order, with the prefixless version last. This would make the order: moz, ms, o, webkit, then prefixless.&lt;/p&gt;

&lt;p&gt;Opera recently added support for -webkit- prefixes for a limited number of CSS properties. This is needed as a number of developers choose to only include the webkit prefix, or don’t include the opera prefix. As both the &lt;code&gt;-o-&lt;/code&gt; prefix and &lt;code&gt;-webkit-&lt;/code&gt; prefixes are counted as the same specificity, order wins out and the webkit prefix will be used if both are specified. You probably want the o prefix to be used for Opera,  especially if you have to override something, so a useful suggestion is to order them in oder of the length of the prefix, like so:&lt;/p&gt;

&lt;pre&gt;&lt;code class="language-css"&gt;-webkit-property
-moz-property
-ms-property
-o-property
property&lt;/code&gt;
&lt;/pre&gt;

&lt;p&gt;This also has the benefit that it looks relatively neat, and its easy to spot if you have missed one once you are used to using this scheme. Each property gets one character shorter, except the initial webkit prefix.&lt;/p&gt;

&lt;p&gt;This is one of the least critical updates to make in this post, but can prove to be useful.&lt;/p&gt;

&lt;h2&gt;Remove redundant prefixes&lt;/h2&gt;

&lt;p&gt;A number of commonly used CSS3 properties have been available without prefix for quite a while now, such as &lt;code&gt;border-radius&lt;/code&gt;. In the recent past quite a few CSS specs have reached the stage where it is now considered ok for browser vendors to remove the prefixes. This includes Transforms, Transitions, Animations, Multi-Column Layout, Flexbox, and Image Values (primarily gradients). Different browsers are at a different state in the march towards removing prefixes, but some are ready to be removed, depending on how far back you have to support older browsers.&lt;/p&gt;

&lt;h3&gt;box-sizing&lt;/h3&gt;

&lt;p&gt;Internet Explorer and Opera have supported &lt;a href="http://www.w3.org/TR/css3-ui/#box-sizing" target="_blank"&gt;&lt;code&gt;box-sizing&lt;/code&gt;&lt;/a&gt; without prefix since they were implemented, so the only prefixes you need to consider are for Gecko and WebKit based browsers. Firefox still needs to use the &lt;code&gt;-moz-&lt;/code&gt; prefix to this day, but you can drop the WebKit prefix if you don’t need to support:&lt;/p&gt;

&lt;ul&gt;&lt;li&gt;Chrome 9 and below (~0.30% marketshare)&lt;/li&gt;
    &lt;li&gt;Safari 5 and below (~0.74% marketshare)&lt;/li&gt;
    &lt;li&gt;Android 3 browser and below (&amp;gt; 60% active Android devices)&lt;/li&gt;
    &lt;li&gt;Safari on iOS 4.3 and below&lt;/li&gt;
    &lt;li&gt;BlackBerry 7 browser and below&lt;/li&gt;
&lt;/ul&gt;&lt;p&gt;Recommended usage:

&lt;/p&gt;&lt;pre&gt;&lt;code class="language-css"&gt;-webkit-box-sizing: &lt;var&gt;value&lt;/var&gt;;  /*evaluate removing as Android users upgrade */
-moz-box-sizing: &lt;var&gt;value&lt;/var&gt;;
box-sizing: &lt;var&gt;value&lt;/var&gt;;&lt;/code&gt;&lt;/pre&gt;

&lt;h3&gt;box-shadow&lt;/h3&gt;

&lt;p&gt;The situation with &lt;a href="http://www.w3.org/TR/css3-background/#the-box-shadow" target="_blank"&gt;&lt;code&gt;box-shadow&lt;/code&gt;&lt;/a&gt; is almost exactly as for &lt;code&gt;box-sizing&lt;/code&gt; in the previous section, except Firefox only needed its prefix in versions 3.5 and 3.6. Together, these current account for 0.77% marketshare.&lt;/p&gt;

&lt;p&gt;Recommended usage:&lt;/p&gt;

&lt;pre&gt;&lt;code class="language-css"&gt;-webkit-box-shadow: &lt;var&gt;value&lt;/var&gt;;  /*evaluate removing as Android users upgrade or box-shadow usage is not critical */
box-shadow: &lt;var&gt;value&lt;/var&gt;;&lt;/code&gt;&lt;/pre&gt;

&lt;p&gt;I would personally remove -webkit-box-shadow as it is not usually a critical piece of styling, unlike box-sizing, which could break layout.&lt;/p&gt;

&lt;h3&gt;border-radius&lt;/h3&gt;

&lt;p&gt;As with the previous two properties, Opera and Internet Explorer have supported &lt;a href="http://www.w3.org/TR/css3-background/#border-radius" target="_blank"&gt;&lt;code&gt;border-radius&lt;/code&gt;&lt;/a&gt; without prefix since implementation. You can drop the -webkit- and -moz- prefixes if you do not need to support the following:&lt;/p&gt;

&lt;ul&gt;&lt;li&gt;Firefox 3.6 and below (~0.95% marketshare)&lt;/li&gt;
    &lt;li&gt;Chrome 4 and below (~0.05% marketshare)&lt;/li&gt;
    &lt;li&gt;Safari 4 and below (~0.12% marketshare)&lt;/li&gt;
    &lt;li&gt;Android 2.1 and below  (~3% active Android devices)&lt;/li&gt;
    &lt;li&gt;Safari on iOS 3.2 and below&lt;/li&gt;
&lt;/ul&gt;&lt;p&gt;Recommended usage:&lt;/p&gt;

&lt;pre&gt;&lt;code class="language-css"&gt;border-radius: &lt;var&gt;value&lt;/var&gt;;&lt;/code&gt;&lt;/pre&gt;

&lt;h3&gt;The newer specs&lt;/h3&gt;

&lt;p&gt;The bad news is that you still need to use -webkit- in modern versions of WebKit for all of the specs in this section. The good news is that you do not need prefixes for &lt;a href="http://www.w3.org/TR/2011/WD-css3-images-20110217/#gradients" target="_blank"&gt;gradients&lt;/a&gt;, &lt;a href="http://www.w3.org/TR/css3-transitions/" target="_blank"&gt;transitions&lt;/a&gt;, &lt;a href="http://www.w3.org/TR/css3-3d-transforms/" target="_blank"&gt;transforms&lt;/a&gt; and &lt;a href="http://www.w3.org/TR/css3-animations/" target="_blank"&gt;animations&lt;/a&gt; starting from:&lt;/p&gt;

&lt;ul&gt;&lt;li&gt;Internet Explorer 10&lt;/li&gt;
    &lt;li&gt;Opera 12.1&lt;/li&gt; 
    &lt;li&gt;Firefox 16&lt;/li&gt;
&lt;/ul&gt;&lt;p&gt;In addition, prefixes have never been needed for all the specs above (except 2D transforms) in IE. 3D transforms are not implemented in Opera, but it is safe to assume it will be directly implemented without prefix.&lt;/p&gt;

&lt;p&gt;I’d recommend to use the &lt;code&gt;-webkit-&lt;/code&gt;, &lt;code&gt;-moz-&lt;/code&gt;, &lt;code&gt;-o-&lt;/code&gt; and the unprefixed version (taking into account the notes below for gradients), with the exception of keeping the &lt;code&gt;-ms-&lt;/code&gt; prefix for 2d transforms and dropping the &lt;code&gt;-o-&lt;/code&gt; prefix for 3d transforms. You may be able to consider removing the Firefox and Opera prefixes in the relatively near future, as users are upgrading at a fast clip, and these browsers don’t have the problem of the near glacial speed that Android devices update their OS.&lt;/p&gt;

&lt;p&gt;&lt;a href="http://www.w3.org/TR/css3-multicol/" target="_blank"&gt;Multi-column layout&lt;/a&gt; was implemented without prefixes in IE and Opera. Prefixes are still needed in Firefox and all versions of WebKit.&lt;/p&gt;

&lt;p&gt;&lt;a href="http://www.w3.org/TR/css3-flexbox/" target="_blank"&gt;Flexbox&lt;/a&gt; has a storied history (see later in this post) and thus needs multiple different syntaxes and prefixes, but is supported by modern versions of all browsers. It is implemented without prefix in Opera 12.1.&lt;/p&gt;

&lt;h2&gt;Add Prefixless properties&lt;/h2&gt;

&lt;p&gt;As the specs mentioned are now ready to be implemented without prefix, it is also time for web developers to add the prefixless version to their code. In theory, these properties should not change now they have reached this strange, and there is general consensus in the CSS working group.&lt;/p&gt; 

&lt;p&gt;There are two schools of thought between developers. The first is to include the prefixless version when writing the original CSS. If you are in this school, you will just need to remove any redundant prefixes, but make sure you check the next section, as there have been breaking changes. The other school of thought is to not include the prefixless version. If you’re in this school, you’ll have to add all of these now. You’ll also need to check the next section to see how to do this.&lt;/p&gt;

&lt;h2&gt;Update to the new syntax&lt;/h2&gt;

&lt;p&gt;This is perhaps the most critical part of your spring clean. Especially if you are a tools developer, or have tutorials with a lot of foot traffic.&lt;/p&gt;

&lt;p&gt;It is probably well known by web developers that border-radius changed to an alternative syntax  from the original found in Firefox 2. It is probably also known that a similar thing happened with gradients, replacing the original Safari proposal. What is less known, and is certainly less updated in the wild, is that the syntax for gradients has changed again. Unless you changed your gradient code relatively recently, you’ll likely have a bunch of outdated code that needs to be updated.&lt;/p&gt;

&lt;h3&gt;New gradient syntax&lt;/h3&gt;

&lt;p&gt;Fortunately the new gradient syntax is easy to update to, and you only really need to make the update to the unprefixed version. You can keep all the prefixed properties with the old syntax. All of the latest browsers support this new syntax, with the exception of WebKit. Its true, WebKit is lagging IE!&lt;/p&gt;

&lt;p&gt;The general rule is that if you use a direction keyword it needs to be reversed and be preceded by the &lt;code&gt;to&lt;/code&gt; keyword. Thus:&lt;/p&gt;

&lt;pre&gt;&lt;code class="language-css"&gt;background:  -prefix-linear-gradient(left, white, black);&lt;/code&gt;&lt;/pre&gt;

&lt;p&gt;Becomes:&lt;/p&gt;

&lt;pre&gt;&lt;code class="language-css"&gt;background:  linear-gradient(to right, white, black);&lt;/code&gt;&lt;/pre&gt;

&lt;p&gt;If you use an angle, the starting point of the gradient line has shifted. Previously 0deg started at the East position. Angles increased in an anticlockwise direction, such that 90deg started at the North position. With the unprefixed syntax the gradient line for 0deg starts at the North position and the angle increases clockwise. The formula for switching from the old the new degree value is abs(oldDegValue − 450) mod 360.&lt;/p&gt;

&lt;p&gt;For radial gradients the position keyword or length now needs to be preceded by the &lt;code&gt;at&lt;/code&gt; keyword:&lt;/p&gt;

&lt;pre&gt;&lt;code class="language-css"&gt;background: -prefix-radial-gradient(center, white, black);&lt;/code&gt;&lt;/pre&gt;

&lt;p&gt;Becomes:&lt;/p&gt;

&lt;pre&gt;&lt;code class="language-css"&gt;background: radial-gradient(at center, white, black);&lt;/code&gt;&lt;/pre&gt;

&lt;p&gt;The &lt;code&gt;cover&lt;/code&gt; and &lt;code&gt;contain&lt;/code&gt; gradient size keywords are no longer supported. The &lt;code&gt;cover&lt;/code&gt; keyword should be switched to &lt;code&gt;farthest-corner&lt;/code&gt; and &lt;code&gt;contain&lt;code&gt; to &lt;code&gt;closest-side&lt;/code&gt;. &lt;/code&gt;&lt;/code&gt;&lt;/p&gt;

&lt;p&gt;Finally, if you specify a gradient position and a shape or size, the position should be specified last, thus:&lt;/p&gt;

&lt;pre&gt;&lt;code class="language-css"&gt;-prefix-radial-gradient(center, 50px 25px, white, black);&lt;code&gt;&lt;/code&gt;&lt;/code&gt;&lt;/pre&gt;

&lt;p&gt;Becomes:&lt;/p&gt;

&lt;pre&gt;&lt;code class="language-css"&gt;-radial-gradient(50px 25px at center, white, black);&lt;/code&gt;&lt;/pre&gt;

&lt;h3&gt;New flexbox syntax&lt;/h3&gt;

&lt;p&gt;The Flexbox syntax has changed more times than I can count. Fortunately, there is likely to be less content out there using the old syntax as there is with gradients, due to the fact the site will likely break if flexbox isn&amp;#8217;t supported.&lt;/p&gt;

&lt;p&gt;Currently, only Opera supports the new syntax without prefix. Chrome supports the new syntax with prefix since Chrome 21, Firefox is due to support the new syntax unprefixed in Firefox 20, but currently only supports the old syntax. IE supports a slightly older syntax, but not the same one as the older WebKit and Firefox implementations. Safari currently only supports the old syntax. To get the best cross platform compatibility you will need to include:&lt;/p&gt;

&lt;ul&gt;&lt;li&gt;The latest syntax unprefixed: &lt;code&gt;display: flex&lt;/code&gt; and friends. (Opera, Firefox 20, and probably Chrome in the near future)&lt;/li&gt;
   &lt;li&gt;The latest syntax with -webkit- prefix:  &lt;code&gt;display: -webkit-flex&lt;/code&gt; and friends (Chrome 21). You may want to drop this and rely on old syntax until WebKit goes prefixless&lt;/li&gt;
   &lt;li&gt;The old new syntax with -ms- prefix: &lt;code&gt;display: -ms-flexbox&lt;/code&gt; and friends (IE10)&lt;/li&gt;
   &lt;li&gt;The old syntax with -moz- and -webkit- prefixes: &lt;code&gt;display: -webkit-box&lt;/code&gt; (WebKit),  &lt;code&gt;display: -moz-box&lt;/code&gt;  (Firefox 
&lt;/li&gt;
&lt;/ul&gt;&lt;p&gt;The spec is too involved to include a comparison tacked onto the end of this post, but you can read about how to spot the difference and see some demos of the old old and new new syntax on &lt;a href="http://css-tricks.com/old-flexbox-and-new-flexbox/" target="_blank"&gt;CSS Tricks&lt;/a&gt;. Chris does not include a demo of the old new (or is it new old) syntax, so you can look at &lt;a href="http://msdn.microsoft.com/en-us/library/ie/hh673531(v=vs.85).aspx" target="_blank"&gt;Microsoft’s Flexbox documentation&lt;/a&gt; to find out more. I may do a full blog post on this in the near future if I find time.&lt;/p&gt;

&lt;small&gt;Marketshare stats are taken from StatCounter for the month of December 2012. Active Android version stats are from &lt;a href="http://developer.android.com/about/dashboards/index.html" target="_blank"&gt;Google’s official platform versions dashboard&lt;/a&gt;.&lt;/small&gt;</description><link>http://generatedcontent.org/post/37949105556</link><guid>http://generatedcontent.org/post/37949105556</guid><pubDate>Fri, 14 Dec 2012 17:56:00 -0800</pubDate><category>CSS3</category><category>gradients</category><category>transforms</category><category>transitions</category><category>flexbox</category><category>animations</category><category>prefixes</category></item><item><title>Mobile first: the revolution is well under way</title><description>&lt;p&gt;A little over a year ago, I wrote a post about how &lt;a href="http://generatedcontent.org/post/10045571079/mobiledominance" target="_blank"&gt;countries in Africa were at the foothills of a mobile web revolution&lt;/a&gt;. Nigeria had just started seeing more web traffic on mobile devices than traditional desktop, and more countries were on course to follow that lead. This post looks at what progress has been made since then, and what the trends look like going forward.&lt;/p&gt;

&lt;p&gt;&lt;!-- more --&gt;&lt;/p&gt;

&lt;h2&gt;Africa, millions of mobiles blossom&lt;/h2&gt;

&lt;p&gt;Nowhere more so than Africa, a real mobile revolution is underway. Since that post in September, the mobile market share vs desktop share in Nigeria has grown to over 70%. As then, the mobile share in many countries rises on weekends and drops during the week. Checking the stats today (11th November, a Sunday), each of the African countries mentioned in the previous post have a larger mobile share than desktop, except Tanzania (which has over 40% mobile share). A number of other African countries have also surpassed the 50% mark for mobile market share. It would be possible to travel from the Niger Delta on the west coast of Africa, to the horn of Africa on the east coast, without passing through a country where people surf more on desktop than a mobile phone.&lt;/p&gt;


&lt;p&gt;The following map highlights those countries that are over one third and one half mobile traffic:&lt;/p&gt;

&lt;figure&gt;&lt;img src="https://dl.dropbox.com/u/444684/blogimages/africa-mobileshare.svg" alt="Map of mobile share in Africa" width="560"/&gt;&lt;figcaption&gt;Mobile vs Desktop marketshare in Africa (Source: StatCounter)&lt;/figcaption&gt;&lt;/figure&gt;&lt;p&gt;Today was a particularly good day for mobile traffic, and many countries do drop below 50% mobile share on week days, but it shows the general trend, and progress since last September. The following table highlights this progression:&lt;/p&gt;
 
&lt;table&gt;&lt;thead&gt;&lt;tr&gt;&lt;th&gt;Country
        &lt;/th&gt;&lt;th&gt;Population&lt;/th&gt;
        &lt;th&gt;Mobile share: 11th November, 2012&lt;/th&gt;
        &lt;th&gt;Mobile share: 11th September, 2011&lt;/th&gt;
    &lt;/tr&gt;&lt;/thead&gt;&lt;tbody&gt;&lt;tr&gt;&lt;td&gt;Nigeria&lt;/td&gt;
        &lt;td&gt;166,629,000&lt;/td&gt;
        &lt;td&gt;72%&lt;/td&gt;
        &lt;td&gt;54%&lt;/td&gt;
    &lt;/tr&gt;&lt;tr&gt;&lt;td&gt;Ethiopia&lt;/td&gt;
        &lt;td&gt;84,320,987&amp;#160;&lt;/td&gt;
        &lt;td&gt;59%&lt;/td&gt;
        &lt;td&gt;39%&lt;/td&gt;
     &lt;/tr&gt;&lt;tr&gt;&lt;td&gt;Congo, DRC&lt;/td&gt;
        &lt;td&gt;69,575,000&lt;/td&gt;
        &lt;td&gt;45%&lt;/td&gt;
        &lt;td&gt;17%&lt;/td&gt;
     &lt;/tr&gt;&lt;tr&gt;&lt;td&gt;Tanzania&lt;/td&gt;
        &lt;td&gt;43,188,000&lt;/td&gt;
        &lt;td&gt;43%&lt;/td&gt;
        &lt;td&gt;24%&lt;/td&gt;
     &lt;/tr&gt;&lt;tr&gt;&lt;td&gt;Kenya&lt;/td&gt;
        &lt;td&gt;38,610,097&lt;/td&gt;
        &lt;td&gt;51%&lt;/td&gt;
        &lt;td&gt;34%&lt;/td&gt;
     &lt;/tr&gt;&lt;tr&gt;&lt;td&gt;Uganda&lt;/td&gt;
        &lt;td&gt;32,939,800&lt;/td&gt;
        &lt;td&gt;43%&lt;/td&gt;
        &lt;td&gt;13%&lt;/td&gt;
     &lt;/tr&gt;&lt;tr&gt;&lt;td&gt;Sudan&lt;/td&gt;
        &lt;td&gt;30,894,000&amp;#160;&lt;/td&gt;
        &lt;td&gt;51%&lt;/td&gt;
        &lt;td&gt;30%&lt;/td&gt;
     &lt;/tr&gt;&lt;tr&gt;&lt;td&gt;Ghana&lt;/td&gt;
        &lt;td&gt;24,658,823&lt;/td&gt;
        &lt;td&gt;38%&lt;/td&gt;
        &lt;td&gt;21%&lt;/td&gt;
     &lt;/tr&gt;&lt;tr&gt;&lt;td&gt;Mozambique&lt;/td&gt;
        &lt;td&gt;23,700,715&lt;/td&gt;
        &lt;td&gt;38%&lt;/td&gt;
        &lt;td&gt;15%&lt;/td&gt;
     &lt;/tr&gt;&lt;tr&gt;&lt;td&gt;Niger&lt;/td&gt;
        &lt;td&gt;16,274,738&lt;/td&gt;
        &lt;td&gt;55%&lt;/td&gt;
        &lt;td&gt;25%&lt;/td&gt;
     &lt;/tr&gt;&lt;tr&gt;&lt;td&gt;Malawi&lt;/td&gt;
        &lt;td&gt;15,883,000&lt;/td&gt;
        &lt;td&gt;67%&lt;/td&gt;
        &lt;td&gt;35%&lt;/td&gt;
     &lt;/tr&gt;&lt;tr&gt;&lt;td&gt;Mali&lt;/td&gt;
        &lt;td&gt;14,528,662&amp;#160;&lt;/td&gt;
        &lt;td&gt;76%&lt;/td&gt;
        &lt;td&gt;5%&lt;/td&gt;
     &lt;/tr&gt;&lt;tr&gt;&lt;td&gt;Zambia&lt;/td&gt;
        &lt;td&gt;13,092,666&lt;/td&gt;
        &lt;td&gt;60%&lt;/td&gt;
        &lt;td&gt;30%&lt;/td&gt;
     &lt;/tr&gt;&lt;tr&gt;&lt;td&gt;Zimbabwe&lt;/td&gt;
        &lt;td&gt;13,014,000&lt;/td&gt;
        &lt;td&gt;76%&lt;/td&gt;
        &lt;td&gt;45%&lt;/td&gt;
     &lt;/tr&gt;&lt;tr&gt;&lt;td&gt;Chad&lt;/td&gt;
        &lt;td&gt;11,274,106&amp;#160;&lt;/td&gt;
        &lt;td&gt;93%&lt;/td&gt;
        &lt;td&gt;61%&lt;/td&gt;
     &lt;/tr&gt;&lt;tr&gt;&lt;td&gt;Somalia&lt;/td&gt;
        &lt;td&gt;9,797,000&amp;#160;&lt;/td&gt;
        &lt;td&gt;61%&lt;/td&gt;
        &lt;td&gt;13%&lt;/td&gt;
     &lt;/tr&gt;&lt;tr&gt;&lt;td&gt;Sierra Leone&lt;/td&gt;
        &lt;td&gt;6,126,000&amp;#160;&lt;/td&gt;
        &lt;td&gt;87%&lt;/td&gt;
        &lt;td&gt;20%&lt;/td&gt;
     &lt;/tr&gt;&lt;tr&gt;&lt;td&gt;Liberia&lt;/td&gt;
        &lt;td&gt;4,245,000&lt;/td&gt;
        &lt;td&gt;40%&lt;/td&gt;
        &lt;td&gt;3%&lt;/td&gt;
     &lt;/tr&gt;&lt;tr&gt;&lt;td&gt;Lesotho&lt;/td&gt;
        &lt;td&gt;2,217,000&lt;/td&gt;
        &lt;td&gt;51%&lt;/td&gt;
        &lt;td&gt;17%&lt;/td&gt;
     &lt;/tr&gt;&lt;tr&gt;&lt;td&gt;Swaziland&lt;/td&gt;
        &lt;td&gt;1,220,000&lt;/td&gt;
        &lt;td&gt;43%&lt;/td&gt;
        &lt;td&gt;36%&lt;/td&gt;
     &lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;h2&gt;Asia Pacific: a mobile giant has awoken&lt;/h2&gt;

&lt;p&gt;Back when I wrote the original post, no countries in Asia had more mobile traffic than desktop traffic. It was however clear that countries in South Asian were going along the same path as Africa. Fast forward over a year, and India has perhaps became one of the most important mobile web markets in the world. It is now consistently has more than 50% mobile traffic, and has became &lt;a href="http://www.opera.com/smw/2012/04/" target="_blank"&gt;the country with the most Opera Mini users&lt;/a&gt;. With its vast population, it has a lot of room for growth.&lt;/p&gt;

&lt;figure&gt;&lt;img src="https://dl.dropbox.com/u/444684/blogimages/asiapacificmobile.svg" alt="Map of mobile market share, Asia Pacific" width="560" height="380"/&gt;&lt;figcaption&gt;Mobile vs desktop in Asia Pacific&lt;/figcaption&gt;&lt;/figure&gt;&lt;p&gt;The rest of Asia/Pacific hasn’t advanced as far as Africa, with only Turkmenistan, East Timor, and Papua New Guinea having more mobile traffic than desktop. However, it should’t be too long before Bangladesh (32%) and a number of the central asian countries progress to a mobile first future.&lt;/p&gt;

&lt;h2&gt;The rest of the world&lt;/h2&gt;

&lt;p&gt;In comparison, only Cost Rica in the Americas (16%), and the United Kingdom in Europe (19%) have over 15% mobile marketshare.&lt;/p&gt;

&lt;h2&gt;Smartphones or dumb?&lt;/h2&gt;

&lt;p&gt;Almost without exception, the &lt;a href="http://gs.statcounter.com/#mobile_os-ww-daily-20121111-20121111-map" target="_blank"&gt;top two mobile operating systems&lt;/a&gt; in those countries with higher mobile traffic were Nokia Series 40 and Nokia Symbian/S60. The exceptions are Mali and Papua New Guinea where the top OS is unknown (this usually means a proxy browser, which is likely running on a feature phone), and Turkmenistan, where Android has its sole victory.&lt;/p&gt;

&lt;p&gt;Nokia Series 40 is firmly a feature phone OS, while Symbian is strictly a smartphone operating system, but the capabilities of phones running it are far from what many of us in the west would consider a smartphone. Many S60 phones don’t even use touch screens, unless they are of relatively recent vintage.&lt;/p&gt;

&lt;h2&gt;Full browsers or proxy?&lt;/h2&gt;

Considering the operating systems in use, it is probably no surprise that &lt;a href="http://gs.statcounter.com/#mobile_browser-ww-daily-20121111-20121111-map" target="_blank"&gt;proxy browsers dominate&lt;/a&gt; this landscape. Opera Mini is the most popular browser in all of these countries except Turkmenistan (Android) and Mali, where Nokia is the largest browser. It is not clear if it is Nokia’s Gecko based proxy browser or the full WebKit browser that rules the roost however. Considering the break down of OS, I expect a combination of both. 

&lt;h2&gt;Looking ahead&lt;/h2&gt;

It seems a long way off before the west posts the same sort of mobile to desktop ratio that Africa is exhibiting. If it ever does at all. Expect to see further mobile gains in Africa, especially in non-French speaking Sub-Saharan countries. Over in Asia, it seems like much of South, South East and Central Asia are poised to become mobile first countries by the end of next year. South Korea could be the exception in the industrialised world. It is currently sitting on 27%, well above that of neighbouring countries in East Asia, the US and the EU. Whichever way things pan out, it should be an interesting year for mobile web developers.</description><link>http://generatedcontent.org/post/35546774583</link><guid>http://generatedcontent.org/post/35546774583</guid><pubDate>Sun, 11 Nov 2012 21:34:00 -0800</pubDate><category>Mobile web</category><category>Market share</category><category>nigeria</category><category>india</category><category>mobile first</category></item><item><title>Flip Ahead and Fast Forward. Providing hints to detect the next page</title><description>&lt;p&gt;Internet Explorer 10 introduced a new featured called &lt;a href="http://blogs.msdn.com/b/b8/archive/2012/06/01/web-browsing-in-windows-8-release-preview-with-ie10.aspx" target="_blank"&gt;Flip Ahead&lt;/a&gt;. This makes a best guess at detecting the next page, article, post, thread, product or so on. When the user performs a forward swipe gesture (or presses the forward button on a mouse) it loads the detected page. If this sounds familiar to you, you’ve probably heard about or used Opera’s Fast Forward feature. This is roughly the same concept (although Opera bundles in other things, such as logging in), and can be activated using a mouse gesture, or pressing the space bar when reaching the end of the page.&lt;/p&gt;
&lt;p&gt;Both implementations use heuristics to detect the next page. For Opera they are defined in the fastforward.ini file. The location of this file can be found by enteringopera:config#UserPrefs|FastForwardConfigurationinto the Opera url field. I’m unsure of the exact heuristics employed by IE. Browsing history data is reported back to Microsoft to improve Flip Ahead, so I expect the heuristics will evolve time goes on. As the feature “phones home’ it is opt-in and thus disabled by default.&lt;/p&gt;
&lt;p&gt;&lt;!-- more --&gt;&lt;/p&gt;
&lt;h2&gt;Provide hints to Flip Ahead and Fast Forward with rel-next&lt;/h2&gt;
&lt;p&gt;While both implementations can apply some advanced heuristics to detect the next page, the browser is basically guessing what is the most appropriate page. As a page author, you can directly give hints to the browser on what page you’d like to load when the Flip Ahead or Fast Forward action is performed. Make sure to specify a page that makes sense, otherwise you will confuse the user. Examples include the second page of an article if you use pagination, the next article on your blog, next page of search results, or the next image in a slideshow.&lt;/p&gt;
&lt;p&gt;The best way to specify the next page is to use a link element in the head with &lt;code&gt;rel="next"&lt;/code&gt;:&lt;/p&gt;
&lt;pre&gt;&lt;code class="language-markup"&gt;&amp;lt;head&amp;gt;
    …
    &amp;lt;link rel="next" href="/page/2" /&amp;gt;
&amp;lt;/head&amp;gt;&lt;/code&gt;&lt;/pre&gt;
&lt;p&gt;This is the only approach I could find that works in IE (with limited testing in the Microsoft store) and has a number of advantages in Opera: it is the heuristic with the highest weighting, it uses standard markup that can lead to other benefits, and it is language independent. Other heuristics in Opera include looking for link text such as “more” or “next”. As each language uses different link text, the browser will only detect words for the languages it knows about.&lt;/p&gt;
&lt;p&gt;In Opera, if you rely on link text within the page, the last occurrence of the term with the highest ranking wins. Due to this, you have to be careful not to introduce a new link with similar link text later in the document. This can be a major problem as the next page can be hijacked if you accept user generated content (such as comments on this blog). Links with &lt;code&gt;rel="nofollow"&lt;/code&gt; are not ignored, so these links are considered when calculating which link should be the next page. Using a link element with &lt;code&gt;rel="next"&lt;/code&gt; mitigates this risk.&lt;/p&gt;
&lt;p&gt;I will update this post if I find out other ways to trigger Flip Ahead in IE. When spoofing as IE10 touch, the new MSN provides a rel-next link, but Bing does not, so I assume there are more heuristics. Their next page link uses “next” as the link text, but this doesn’t seem to be detected when I tried in a test file.&lt;/p&gt;
&lt;h2&gt;Other benefits of using rel-next&lt;/h2&gt;
&lt;p&gt;HTML4, and later HTML5 define rel=”next” as a valid &lt;a href="http://dev.w3.org/html5/spec-preview/links.html#sequential-link-types" target="_blank"&gt;sequential link type&lt;/a&gt;. This indicates the next logical document in sequence. As such, browser and search engine providers have adopted it to bring additional benefits.&lt;/p&gt;
&lt;h3&gt;SEO benefits&lt;/h3&gt;
&lt;p&gt;Google and other search engines support &lt;a href="http://googlewebmastercentral.blogspot.com/2011/09/pagination-with-relnext-and-relprev.html" target="_blank"&gt;rel=”next” and rel=”prev” links&lt;/a&gt;. Adding these hints will allow the search engine to return more appropriate results, such as the first page of a multi-page article or the first image in a slideshow.&lt;/p&gt;
&lt;h3&gt;Prefetching in Firefox&lt;/h3&gt;
&lt;p&gt;If you have chosen the next page link wisely, it is likely that the user will want to visit that page. Possibly even more likely when the browser supports a method such as Flip Ahead to automatically detect it.&lt;/p&gt;
&lt;p&gt;Firefox (and other Gecko based browsers) support a feature known as &lt;a href="https://developer.mozilla.org/en-US/docs/Link_prefetching_FAQ" target="_blank"&gt;prefetching&lt;/a&gt;, which uses rel=”next” as a hint to load that resource in the background. The advantage of this is that if the correct page is prefetched, the loading time for that page will be reduced. As well as rel=”next”, you can also use rel=”prefetch” to prefetch a resource. The main difference is that rel=”prefetch” can be used on any type of resource, while rel=”next” should only be used for the next page, as it contains other semantics beyond being a prefetching hint.&lt;/p&gt;
&lt;p&gt;Chrome supports something called &lt;a href="https://developers.google.com/chrome/whitepapers/prerender" target="_blank"&gt;prerendering&lt;/a&gt; which goes a step further and actually renders the page in the background after fetching it. This can be triggered using rel=”prerender” on the link element, and doesn’t support rel=”next” as far as I’m aware.&lt;/p&gt;
&lt;h2&gt;Wrap up&lt;/h2&gt;
&lt;p&gt;So there you have it. One little link element with rel=”next” and you get a whole host of benefits across three different browsers and the leading search engines. Just remember to choose the next link wisely, as it can degrade the experience if your site does something unpredictable.&lt;/p&gt;</description><link>http://generatedcontent.org/post/34540801993</link><guid>http://generatedcontent.org/post/34540801993</guid><pubDate>Sun, 28 Oct 2012 20:09:00 -0700</pubDate><category>fast forward</category><category>flip ahead</category><category>next page</category><category>rel-next</category><category>IE 10</category><category>Opera</category></item><item><title>Device screen resolutions ordered by OS</title><description>&lt;p&gt;Its often a chore to track down what screen resolutions are supported by the various operating systems and devices that are commonly used on the Web. Vendor sites and developer guidelines are often helpful, but it means hunting down information across many sites and documents. Sites like &lt;a&gt;GSM Arena&lt;/a&gt; are great, but it often means checking devices one at a time, and useful information for web developers are lost amongst the densely packed information that is of limited concern to us. As I was researching this information anyway, and I’m a bit of a data nerd, I thought I may as well catalogue the information on my blog for easy access at a later date. If the information is of use to anyone else, then all the better.&lt;/p&gt;

&lt;p&gt;I’ve grouped the data by operating system, version, and device type, as I wanted to see what resolutions needed to be supported to broadly cover a particular OS. Not surprisingly, some of the more closed operating systems have tighter control and consistency potentially making them easier to support, while more open operating systems have a plethora of different resolutions and aspect ratios.&lt;/p&gt;

&lt;p&gt;&lt;!-- more --&gt;&lt;/p&gt;

&lt;p&gt;As Android is particularly varied, and impossible to predict which devices get updated to a subsequent version of the OS, I’ve kept all versions grouped together. The exception is Cupcake and below, as Android only supported one resolution at that time, making classification easy.&lt;/p&gt;

&lt;p&gt;I only included operating systems (and versions) that are currently popular on the Web, or I suspect will be in the future. For feature phones, I used the information I gathered from Opera Mini stats to figure out what devices are still popular. I ignored desktop operating systems, as they are too varied to cover without spending longer than I wanted to on this study.&lt;/p&gt;

&lt;p&gt;Other information I’m considering adding includes pixel density (but this varies widely as many devices have the same resolution but different physical sized displays), and the device pixel ratio (although this can vary depending on the browser used).&lt;/p&gt;

&lt;p&gt;Without further ado, here is the data:&lt;/p&gt;

&lt;h2&gt;Smartphones&lt;/h2&gt;

&lt;h3&gt;iOS: iPhone and iPod Touch&lt;/h3&gt;

&lt;table&gt;&lt;thead&gt;&lt;tr&gt;&lt;th&gt;Name&lt;/th&gt;&lt;th&gt;Resolution (px)&lt;/th&gt;&lt;th&gt;Aspect Ratio&lt;/th&gt;&lt;/tr&gt;&lt;/thead&gt;&lt;tbody&gt;&lt;tr&gt;&lt;td&gt;
        HVGA
      &lt;/td&gt;
      &lt;td&gt;
        480×320
      &lt;/td&gt;
      &lt;td&gt;
        3:2
      &lt;/td&gt;
    &lt;/tr&gt;&lt;tr&gt;&lt;td&gt;
        DVGA
      &lt;/td&gt;
      &lt;td&gt;
        960×640
      &lt;/td&gt;
      &lt;td&gt;
        3:2
      &lt;/td&gt;
    &lt;/tr&gt;&lt;tr&gt;&lt;td&gt;
          Unknown       
      &lt;/td&gt;
      &lt;td&gt;
        1136×640
      &lt;/td&gt;
      &lt;td&gt;
        16:9
      &lt;/td&gt;
    &lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;h3&gt;Android&lt;/h3&gt;

&lt;h4&gt;Cupcake and below&lt;/h4&gt;

&lt;table&gt;&lt;thead&gt;&lt;tr&gt;&lt;th&gt;Name&lt;/th&gt;&lt;th&gt;Resolution (px)&lt;/th&gt;&lt;th&gt;Aspect Ratio&lt;/th&gt;&lt;/tr&gt;&lt;/thead&gt;&lt;tbody&gt;&lt;tr&gt;&lt;td&gt;
        HVGA
      &lt;/td&gt;
      &lt;td&gt;
        480×320
      &lt;/td&gt;
      &lt;td&gt;
        3:2
      &lt;/td&gt;
    &lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;h4&gt;Donut and above&lt;/h4&gt;

&lt;table&gt;&lt;thead&gt;&lt;tr&gt;&lt;th&gt;Name&lt;/th&gt;&lt;th&gt;Resolution (px)&lt;/th&gt;&lt;th&gt;Aspect Ratio&lt;/th&gt;&lt;/tr&gt;&lt;/thead&gt;&lt;tbody&gt;&lt;tr&gt;&lt;td&gt;
        QVGA
      &lt;/td&gt;
      &lt;td&gt;
        320×240
      &lt;/td&gt;
      &lt;td&gt;
        4:3
      &lt;/td&gt;
    &lt;/tr&gt;&lt;tr&gt;&lt;td&gt;
        WQVGA
      &lt;/td&gt;
      &lt;td&gt;
        400×240
      &lt;/td&gt;
      &lt;td&gt;
        15:9
      &lt;/td&gt;
    &lt;/tr&gt;&lt;tr&gt;&lt;td&gt;
        HVGA
      &lt;/td&gt;
      &lt;td&gt;
        480×320
      &lt;/td&gt;
      &lt;td&gt;
        3:2
      &lt;/td&gt;
    &lt;/tr&gt;&lt;tr&gt;&lt;td&gt;
        nHD
      &lt;/td&gt;
      &lt;td&gt;
        640×360
      &lt;/td&gt;
      &lt;td&gt;
        16:9
      &lt;/td&gt;
    &lt;/tr&gt;&lt;tr&gt;&lt;td&gt;
        VGA
      &lt;/td&gt;
      &lt;td&gt;
        640×480
      &lt;/td&gt;
      &lt;td&gt;
        4:3
      &lt;/td&gt;
    &lt;/tr&gt;&lt;tr&gt;&lt;td&gt;
        WVGA
      &lt;/td&gt;
      &lt;td&gt;
        800×480
      &lt;/td&gt;
      &lt;td&gt;
        15:9
      &lt;/td&gt;
    &lt;/tr&gt;&lt;tr&gt;&lt;td&gt;
        FWVGA
      &lt;/td&gt;
      &lt;td&gt;
        854×480
      &lt;/td&gt;
      &lt;td&gt;
        16:9
      &lt;/td&gt;
    &lt;/tr&gt;&lt;tr&gt;&lt;td&gt;
        qHD
      &lt;/td&gt;
      &lt;td&gt;
        960×540
      &lt;/td&gt;
      &lt;td&gt;
        16:9
      &lt;/td&gt;
    &lt;/tr&gt;&lt;tr&gt;&lt;td&gt;
        DVGA
      &lt;/td&gt;
      &lt;td&gt;
        960×640
      &lt;/td&gt;
      &lt;td&gt;
        3:2
      &lt;/td&gt;
    &lt;/tr&gt;&lt;tr&gt;&lt;td&gt;
        HD 720p
      &lt;/td&gt;
      &lt;td&gt;
        1280×720
      &lt;/td&gt;
      &lt;td&gt;
        16:9
      &lt;/td&gt;
    &lt;/tr&gt;&lt;tr&gt;&lt;td&gt;
        XGA
      &lt;/td&gt;
      &lt;td&gt;
        1024×768
      &lt;/td&gt;
      &lt;td&gt;
        4:3
      &lt;/td&gt;
    &lt;/tr&gt;&lt;tr&gt;&lt;td&gt;
        WXGA
      &lt;/td&gt;
      &lt;td&gt;
        1280×768
      &lt;/td&gt;
      &lt;td&gt;
        15:9
      &lt;/td&gt;
    &lt;/tr&gt;&lt;tr&gt;&lt;td&gt;
        WXGA
      &lt;/td&gt;
      &lt;td&gt;
        1280×800
      &lt;/td&gt;
      &lt;td&gt;
        16:10
      &lt;/td&gt;
    &lt;/tr&gt;&lt;tr&gt;&lt;td&gt;
        HD 1080p
      &lt;/td&gt;
      &lt;td&gt;
        1920×1080
      &lt;/td&gt;
      &lt;td&gt;
        16:9
      &lt;/td&gt;
    &lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;h3&gt;Windows Phone&lt;/h3&gt;

&lt;p&gt;Microsoft specifies the resolutions that are support for each version of Windows Phone. This ensures consistency between devices.&lt;/p&gt;

&lt;h4&gt;Windows Phone 7&lt;/h4&gt;

&lt;table&gt;&lt;thead&gt;&lt;tr&gt;&lt;th&gt;Name&lt;/th&gt;&lt;th&gt;Resolution (px)&lt;/th&gt;&lt;th&gt;Aspect Ratio&lt;/th&gt;&lt;/tr&gt;&lt;/thead&gt;&lt;tbody&gt;&lt;tr&gt;&lt;td&gt;
        WVGA
      &lt;/td&gt;
      &lt;td&gt;
        800×480
      &lt;/td&gt;
      &lt;td&gt;
        15:9
      &lt;/td&gt;
    &lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;h4&gt;Windows Phone 8&lt;/h4&gt;

&lt;table&gt;&lt;thead&gt;&lt;tr&gt;&lt;th&gt;Name&lt;/th&gt;&lt;th&gt;Resolution (px)&lt;/th&gt;&lt;th&gt;Aspect Ratio&lt;/th&gt;&lt;/tr&gt;&lt;/thead&gt;&lt;tbody&gt;&lt;tr&gt;&lt;td&gt;
        WVGA
      &lt;/td&gt;
      &lt;td&gt;
        800×480
      &lt;/td&gt;
      &lt;td&gt;
        15:9
      &lt;/td&gt;
    &lt;/tr&gt;&lt;tr&gt;&lt;td&gt;
        HD 720p 
      &lt;/td&gt;
      &lt;td&gt;
        1280×720
      &lt;/td&gt;
      &lt;td&gt;
        16:9
      &lt;/td&gt;
    &lt;/tr&gt;&lt;tr&gt;&lt;td&gt;
        WXGA
      &lt;/td&gt;
      &lt;td&gt;
        1280×768
      &lt;/td&gt;
      &lt;td&gt;
        15:9
      &lt;/td&gt;
    &lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;h3&gt;Symbian&lt;/h3&gt;

&lt;h4&gt;S60, 2nd Edition&lt;/h4&gt;

&lt;table&gt;&lt;thead&gt;&lt;tr&gt;&lt;th&gt;Name&lt;/th&gt;&lt;th&gt;Resolution (px)&lt;/th&gt;&lt;th&gt;Aspect Ratio&lt;/th&gt;&lt;/tr&gt;&lt;/thead&gt;&lt;tbody&gt;&lt;tr&gt;&lt;td&gt;
            Unknown
      &lt;/td&gt;
      &lt;td&gt;
        208×176
      &lt;/td&gt;
      &lt;td&gt;
        13:11
      &lt;/td&gt;
    &lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;h4&gt;S60, 3rd Edition&lt;/h4&gt;

&lt;table&gt;&lt;thead&gt;&lt;tr&gt;&lt;th&gt;Name&lt;/th&gt;&lt;th&gt;Resolution (px)&lt;/th&gt;&lt;th&gt;Aspect Ratio&lt;/th&gt;&lt;/tr&gt;&lt;/thead&gt;&lt;tbody&gt;&lt;tr&gt;&lt;td&gt;
        QVGA
      &lt;/td&gt;
      &lt;td&gt;
        320×240
      &lt;/td&gt;
      &lt;td&gt;
        4:3
      &lt;/td&gt;
    &lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;h4&gt;S60, 5th edition to Nokia Belle (neé Symbian Belle)&lt;/h4&gt;

&lt;table&gt;&lt;thead&gt;&lt;tr&gt;&lt;th&gt;Name&lt;/th&gt;&lt;th&gt;Resolution (px)&lt;/th&gt;&lt;th&gt;Aspect Ratio&lt;/th&gt;&lt;/tr&gt;&lt;/thead&gt;&lt;tbody&gt;&lt;tr&gt;&lt;td&gt;
        nHD
      &lt;/td&gt;
      &lt;td&gt;
        640×360
      &lt;/td&gt;
      &lt;td&gt;
        16:9
      &lt;/td&gt;
    &lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;h3&gt;BlackBerry OS&lt;/h3&gt;

&lt;h4&gt;BlackBerry 5&lt;/h4&gt;

&lt;table&gt;&lt;thead&gt;&lt;tr&gt;&lt;th&gt;Name&lt;/th&gt;&lt;th&gt;Resolution (px)&lt;/th&gt;&lt;th&gt;Aspect Ratio&lt;/th&gt;&lt;/tr&gt;&lt;/thead&gt;&lt;tbody&gt;&lt;tr&gt;&lt;td&gt;
        QVGA
      &lt;/td&gt;
      &lt;td&gt;
        320×240
      &lt;/td&gt;
      &lt;td&gt;
        4:3
      &lt;/td&gt;
    &lt;/tr&gt;&lt;tr&gt;&lt;td&gt;
        HVGA
      &lt;/td&gt;
      &lt;td&gt;
        480×320
      &lt;/td&gt;
      &lt;td&gt;
        3:2
      &lt;/td&gt;
    &lt;/tr&gt;&lt;tr&gt;&lt;td&gt;
        Unknown
      &lt;/td&gt;
      &lt;td&gt;
        480×360
      &lt;/td&gt;
      &lt;td&gt;
        4:3
      &lt;/td&gt;
    &lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;h4&gt;BlackBerry 6&lt;/h4&gt;

&lt;table&gt;&lt;thead&gt;&lt;tr&gt;&lt;th&gt;Name&lt;/th&gt;&lt;th&gt;Resolution (px)&lt;/th&gt;&lt;th&gt;Aspect Ratio&lt;/th&gt;&lt;/tr&gt;&lt;/thead&gt;&lt;tbody&gt;&lt;tr&gt;&lt;td&gt;
        QVGA
      &lt;/td&gt;
      &lt;td&gt;
        320×240
      &lt;/td&gt;
      &lt;td&gt;
        4:3
      &lt;/td&gt;
    &lt;/tr&gt;&lt;tr&gt;&lt;td&gt;
          Unknown
      &lt;/td&gt;
      &lt;td&gt;
        400×360
      &lt;/td&gt;
      &lt;td&gt;
        10:9
      &lt;/td&gt;
    &lt;/tr&gt;&lt;tr&gt;&lt;td&gt;
           Unknown
      &lt;/td&gt;
      &lt;td&gt;
        480×360
      &lt;/td&gt;
      &lt;td&gt;
        4:3
      &lt;/td&gt;
    &lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;h4&gt;BlackBerry 7&lt;/h4&gt;

&lt;table&gt;&lt;thead&gt;&lt;tr&gt;&lt;th&gt;Name&lt;/th&gt;&lt;th&gt;Resolution (px)&lt;/th&gt;&lt;th&gt;Aspect Ratio&lt;/th&gt;&lt;/tr&gt;&lt;/thead&gt;&lt;tbody&gt;&lt;tr&gt;&lt;td&gt;
        QVGA
      &lt;/td&gt;
      &lt;td&gt;
        320×240
      &lt;/td&gt;
      &lt;td&gt;
        4:3
      &lt;/td&gt;
    &lt;/tr&gt;&lt;tr&gt;&lt;td&gt;
        Unknown
      &lt;/td&gt;
      &lt;td&gt;
        480×360
      &lt;/td&gt;
      &lt;td&gt;
        4:3
      &lt;/td&gt;
    &lt;/tr&gt;&lt;tr&gt;&lt;td&gt;
        VGA
      &lt;/td&gt;
      &lt;td&gt;
        640×480
      &lt;/td&gt;
      &lt;td&gt;
        4:3
      &lt;/td&gt;
    &lt;/tr&gt;&lt;tr&gt;&lt;td&gt;
        WVGA
      &lt;/td&gt;
      &lt;td&gt;
        800×480
      &lt;/td&gt;
      &lt;td&gt;
        15:9
      &lt;/td&gt;
    &lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;h4&gt;BlackBerry 10&lt;/h4&gt;

&lt;table&gt;&lt;thead&gt;&lt;tr&gt;&lt;th&gt;Name&lt;/th&gt;&lt;th&gt;Resolution (px)&lt;/th&gt;&lt;th&gt;Aspect Ratio&lt;/th&gt;&lt;/tr&gt;&lt;/thead&gt;&lt;tbody&gt;&lt;tr&gt;&lt;td&gt;
          Unknown
      &lt;/td&gt;
      &lt;td&gt;
        720×720
      &lt;/td&gt;
      &lt;td&gt;
        1:1
      &lt;/td&gt;
    &lt;/tr&gt;&lt;tr&gt;&lt;td&gt;
        720p
      &lt;/td&gt;
      &lt;td&gt;
        1280x720
      &lt;/td&gt;
      &lt;td&gt;
        16:9 
      &lt;/td&gt;
 &lt;/tr&gt;&lt;tr&gt;&lt;td&gt;
        WXGA
      &lt;/td&gt;
      &lt;td&gt;
        1280x768
      &lt;/td&gt;
      &lt;td&gt;
        15:9
      &lt;/td&gt;
    &lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;p&gt;&lt;strong&gt;Note:&lt;/strong&gt; The 1:1 display is the standard size for all keyboard BlackBerry 10 devices. 720p is the standard size for all BlackBerry 10 touch devices. WXGA is a one off resolution for the BlackBerry Z10 and the developer device.&lt;/p&gt;

&lt;h3&gt;MeeGo: Harmattan&lt;/h3&gt;

&lt;p&gt;The only smartphone released commercially with MeeGo was the Nokia N9 with the Harmattan variant.&lt;/p&gt;

&lt;table&gt;&lt;thead&gt;&lt;tr&gt;&lt;th&gt;Name&lt;/th&gt;&lt;th&gt;Resolution (px)&lt;/th&gt;&lt;th&gt;Aspect Ratio&lt;/th&gt;&lt;/tr&gt;&lt;/thead&gt;&lt;tbody&gt;&lt;tr&gt;&lt;td&gt;
        FWVGA
      &lt;/td&gt;
      &lt;td&gt;
         854×480
      &lt;/td&gt;
      &lt;td&gt;
        16:9
      &lt;/td&gt;
    &lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;h3&gt;Maemo&lt;/h3&gt;

&lt;h4&gt;All versions&lt;/h4&gt;

&lt;table&gt;&lt;thead&gt;&lt;tr&gt;&lt;th&gt;Name&lt;/th&gt;&lt;th&gt;Resolution (px)&lt;/th&gt;&lt;th&gt;Aspect Ratio&lt;/th&gt;&lt;/tr&gt;&lt;/thead&gt;&lt;tbody&gt;&lt;tr&gt;&lt;td&gt;
        WVGA
      &lt;/td&gt;
      &lt;td&gt;
        800×480
      &lt;/td&gt;
      &lt;td&gt;
        15:9
      &lt;/td&gt;
    &lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;p&gt;&lt;strong&gt;Note:&lt;/strong&gt; Not all Maemo devices are phones, and they’re not particularly popular (outside of &lt;a href="http://gs.statcounter.com/#mobile_os-FI-monthly-201109-201210" target="_blank"&gt;a blip in Finland&lt;/a&gt;), but the Nokia site made it easy to find the information, so why not?&lt;/p&gt;

&lt;h3&gt;Firefox OS&lt;/h3&gt;

&lt;table&gt;&lt;thead&gt;&lt;tr&gt;&lt;th&gt;Name&lt;/th&gt;&lt;th&gt;Resolution (px)&lt;/th&gt;&lt;th&gt;Aspect Ratio&lt;/th&gt;&lt;/tr&gt;&lt;/thead&gt;&lt;tbody&gt;&lt;tr&gt;&lt;td&gt;
        HVGA
      &lt;/td&gt;
      &lt;td&gt;
         480×320
      &lt;/td&gt;
      &lt;td&gt;
         3:2
      &lt;/td&gt;
    &lt;/tr&gt;&lt;tr&gt;&lt;td&gt;qHD&lt;/td&gt;&lt;td&gt;960×540&lt;/td&gt;&lt;td&gt;16:9&lt;/td&gt;
     &lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;p&gt;&lt;strong&gt;Note:&lt;/strong&gt; The higher end Geeksphone Peak developer preview phone supports a qHD display, while the lower end, and currently announced consumer devices from ZTE and Alcatel support HVGA. Specs from OEMs such as Sony and LG have yet to be announced. This section will be updated when the information is available.&lt;/p&gt;

&lt;h2&gt;Feature phones&lt;/h2&gt;

&lt;p&gt;I’ve only included feature phones that have names and are relatively well known, as it is much easier to research data that way. Bada and later versions of Series 40 could be considered low end smartphone operating systems, and are sometimes marketed as such. I’ve kept them separate from smartphones as they are usually aimed at a very different market segment.&lt;/p&gt;

&lt;h3&gt;Nokia OS/Asha Platform&lt;/h3&gt;

&lt;h4&gt;Series 40, 3rd Edition to Developer Platform 1.x&lt;/h4&gt;

&lt;table&gt;&lt;thead&gt;&lt;tr&gt;&lt;th&gt;Name&lt;/th&gt;&lt;th&gt;Resolution (px)&lt;/th&gt;&lt;th&gt;Aspect Ratio&lt;/th&gt;&lt;/tr&gt;&lt;/thead&gt;&lt;tbody&gt;&lt;tr&gt;&lt;td&gt;
         Unknown
      &lt;/td&gt;
      &lt;td&gt;
        160×128
      &lt;/td&gt;
      &lt;td&gt;
        5:4
      &lt;/td&gt;
    &lt;/tr&gt;&lt;tr&gt;&lt;td&gt;
        QVGA
      &lt;/td&gt;
      &lt;td&gt;
        320×240
      &lt;/td&gt;
      &lt;td&gt;
        4:3
      &lt;/td&gt;
    &lt;/tr&gt;&lt;tr&gt;&lt;td&gt;
        HVGA
      &lt;/td&gt;
      &lt;td&gt;
        480×320
      &lt;/td&gt;
      &lt;td&gt;
        3:2 
      &lt;/td&gt;
    &lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;p&gt;&lt;strong&gt;Note:&lt;/strong&gt; the HVGA resolution was only found on one device; the Nokia 6260. This has a higher resolution than any subsequent Series 40 devices.&lt;/p&gt;

&lt;h4&gt;Series 40, Developer Platform 2&lt;/h4&gt;

&lt;table&gt;&lt;thead&gt;&lt;tr&gt;&lt;th&gt;Name&lt;/th&gt;&lt;th&gt;Resolution (px)&lt;/th&gt;&lt;th&gt;Aspect Ratio&lt;/th&gt;&lt;/tr&gt;&lt;/thead&gt;&lt;tbody&gt;&lt;tr&gt;&lt;td&gt;
        WQVGA
      &lt;/td&gt;
      &lt;td&gt;
        400×240
      &lt;/td&gt;
      &lt;td&gt;
        15:9
      &lt;/td&gt;
    &lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;h4&gt;Asha Software Platform 1.0&lt;/h4&gt;

&lt;table&gt;&lt;thead&gt;&lt;tr&gt;&lt;th&gt;Name&lt;/th&gt;&lt;th&gt;Resolution (px)&lt;/th&gt;&lt;th&gt;Aspect Ratio&lt;/th&gt;&lt;/tr&gt;&lt;/thead&gt;&lt;tbody&gt;&lt;tr&gt;&lt;td&gt;
        QVGA
      &lt;/td&gt;
      &lt;td&gt;
        320×240
      &lt;/td&gt;
      &lt;td&gt;
        4:3
      &lt;/td&gt;
    &lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;p&gt;&lt;strong&gt;Note:&lt;/strong&gt; the Asha software platform is yet another rebranding of the S40/Nokia OS platform. It has the same APIs as Developer Platform 2, with additional localisation (JSR-238) and platform APIs. Web Apps use the Gecko engine.&lt;/p&gt;


&lt;h3&gt;Bada&lt;/h3&gt;

&lt;h4&gt;Bada 1.x&lt;/h4&gt;

&lt;table&gt;&lt;thead&gt;&lt;tr&gt;&lt;th&gt;Name&lt;/th&gt;&lt;th&gt;Resolution (px)&lt;/th&gt;&lt;th&gt;Aspect Ratio&lt;/th&gt;&lt;/tr&gt;&lt;/thead&gt;&lt;tbody&gt;&lt;tr&gt;&lt;td&gt;
        WQVGA
      &lt;/td&gt;
      &lt;td&gt;
        400×240
      &lt;/td&gt;
      &lt;td&gt;
        15:9
      &lt;/td&gt;
    &lt;/tr&gt;&lt;tr&gt;&lt;td&gt;
        WVGA
      &lt;/td&gt;
      &lt;td&gt;
        800×480
      &lt;/td&gt;
      &lt;td&gt;
        15:9
      &lt;/td&gt;
    &lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;h4&gt;Bada 2&lt;/h4&gt;

&lt;table&gt;&lt;thead&gt;&lt;tr&gt;&lt;th&gt;Name&lt;/th&gt;&lt;th&gt;Resolution (px)&lt;/th&gt;&lt;th&gt;Aspect Ratio&lt;/th&gt;&lt;/tr&gt;&lt;/thead&gt;&lt;tbody&gt;&lt;tr&gt;&lt;td&gt;
        HVGA
      &lt;/td&gt;
      &lt;td&gt;
        480×320
      &lt;/td&gt;
      &lt;td&gt;
        3:2
      &lt;/td&gt;
    &lt;/tr&gt;&lt;tr&gt;&lt;td&gt;
        WVGA
      &lt;/td&gt;
      &lt;td&gt;
        800×480
      &lt;/td&gt;
      &lt;td&gt;
        15:9
      &lt;/td&gt;
    &lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;h2&gt;Tablets&lt;/h2&gt;

&lt;h3&gt;iOS: iPad&lt;/h3&gt;

&lt;table&gt;&lt;thead&gt;&lt;tr&gt;&lt;th&gt;Name&lt;/th&gt;&lt;th&gt;Resolution (px)&lt;/th&gt;&lt;th&gt;Aspect Ratio&lt;/th&gt;&lt;/tr&gt;&lt;/thead&gt;&lt;tbody&gt;&lt;tr&gt;&lt;td&gt;
        XGA
      &lt;/td&gt;
      &lt;td&gt;
        1024×768
      &lt;/td&gt;
      &lt;td&gt;
        4:3
      &lt;/td&gt;
    &lt;/tr&gt;&lt;tr&gt;&lt;td&gt;
        QXGA
      &lt;/td&gt;
      &lt;td&gt;
        2048×1536
      &lt;/td&gt;
      &lt;td&gt;
        4:3
      &lt;/td&gt;
    &lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;h3&gt;Android and derivatives&lt;/h3&gt;

&lt;p&gt;The NOOK and Kindle tablets are also included in this list. Each model shares a common resolution with an already included standard Android tablet.&lt;/p&gt;

&lt;table&gt;&lt;thead&gt;&lt;tr&gt;&lt;th&gt;Name&lt;/th&gt;&lt;th&gt;Resolution (px)&lt;/th&gt;&lt;th&gt;Aspect Ratio&lt;/th&gt;&lt;/tr&gt;&lt;/thead&gt;&lt;tbody&gt;&lt;tr&gt;&lt;td&gt;
        WSVGA
      &lt;/td&gt;
      &lt;td&gt;
        1024×600
      &lt;/td&gt;
      &lt;td&gt;
        17:10
      &lt;/td&gt;
    &lt;/tr&gt;&lt;tr&gt;&lt;td&gt;
        XGA
      &lt;/td&gt;
      &lt;td&gt;
        1024×768
      &lt;/td&gt;
      &lt;td&gt;
        4:3
      &lt;/td&gt;
    &lt;/tr&gt;&lt;tr&gt;&lt;td&gt;
        WXGA
      &lt;/td&gt;
      &lt;td&gt;
        1280×800
      &lt;/td&gt;
      &lt;td&gt;
        16:10
      &lt;/td&gt;
    &lt;/tr&gt;&lt;tr&gt;&lt;td&gt;
        WXGA+
      &lt;/td&gt;
      &lt;td&gt;
        1440×900
      &lt;/td&gt;
      &lt;td&gt;
        16:10
      &lt;/td&gt;
    &lt;/tr&gt;&lt;tr&gt;&lt;td&gt;
        WUXGA
      &lt;/td&gt;
      &lt;td&gt;
        1920×1200
      &lt;/td&gt;
      &lt;td&gt;
        16:10
      &lt;/td&gt;
    &lt;/tr&gt;&lt;tr&gt;&lt;td&gt;WQXGA&lt;/td&gt;
        &lt;td&gt;2560×1600&lt;/td&gt;
        &lt;td&gt;16:10&lt;/td&gt;
    &lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;h3&gt;Windows RT&lt;/h3&gt;

&lt;p&gt;All Windows RT tablets currently have a WXGA display. This is the minimum specified by Microsoft. Future tablets may have higher resolution displays.&lt;/p&gt;

&lt;table&gt;&lt;thead&gt;&lt;tr&gt;&lt;th&gt;Name&lt;/th&gt;&lt;th&gt;Resolution (px)&lt;/th&gt;&lt;th&gt;Aspect Ratio&lt;/th&gt;&lt;/tr&gt;&lt;/thead&gt;&lt;tbody&gt;&lt;tr&gt;&lt;td&gt;
        WXGA
      &lt;/td&gt;
      &lt;td&gt;
        1366×768
      &lt;/td&gt;
      &lt;td&gt;
        16:9
      &lt;/td&gt;
    &lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;p&gt;&lt;strong&gt;Note:&lt;/strong&gt; Windows RT includes a “Snap Mode” feature. This displays an app or web page in a sidebar, pinned to one side of the screen.  The snapped view takes up 320px, the splitter control takes up 22px, and the remainder for the fill view (the regular web page). On current Windows RT machines, this leaves 1,046×768 for the main web page.&lt;/p&gt;

&lt;p&gt;To &lt;a href="http://timkadlec.com/2012/10/ie10-snap-mode-and-responsive-design/" target="_blank"&gt;optimise your site/app to work in the snapped view&lt;/a&gt;, you must use the &lt;a href="http://dev.w3.org/csswg/css-device-adapt/" target="_blank"&gt;@viewport&lt;/a&gt; CSS AtRule.&lt;/p&gt;

&lt;h3&gt;BlackBerry Tablet OS&lt;/h3&gt;

&lt;table&gt;&lt;thead&gt;&lt;tr&gt;&lt;th&gt;Name&lt;/th&gt;&lt;th&gt;Resolution (px)&lt;/th&gt;&lt;th&gt;Aspect Ratio&lt;/th&gt;&lt;/tr&gt;&lt;/thead&gt;&lt;tbody&gt;&lt;tr&gt;&lt;td&gt;
        WSVGA
      &lt;/td&gt;
      &lt;td&gt;
        1024×600
      &lt;/td&gt;
      &lt;td&gt;
        16:9
      &lt;/td&gt;
    &lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;h2&gt;E ink eBook readers&lt;/h2&gt;

&lt;p&gt;eBook readers are not particularly popular for surfing the Web, but I thought it would be fun to include them. They all share common resolutions, so are grouped together.&lt;/p&gt;

&lt;table&gt;&lt;thead&gt;&lt;tr&gt;&lt;th&gt;Name&lt;/th&gt;&lt;th&gt;Resolution (px)&lt;/th&gt;&lt;th&gt;Aspect Ratio&lt;/th&gt;&lt;/tr&gt;&lt;/thead&gt;&lt;tbody&gt;&lt;tr&gt;&lt;td&gt;
        SVGA
      &lt;/td&gt;
      &lt;td&gt;
        800×600
      &lt;/td&gt;
      &lt;td&gt;
        4:3
      &lt;/td&gt;
    &lt;/tr&gt;&lt;tr&gt;&lt;td&gt;
        XGA
      &lt;/td&gt;
      &lt;td&gt;
        1024×768
      &lt;/td&gt;
      &lt;td&gt;
        4:3
      &lt;/td&gt;
    &lt;/tr&gt;&lt;tr&gt;&lt;td&gt;
           Unknown
      &lt;/td&gt;
      &lt;td&gt;
        1200×824
      &lt;/td&gt;
      &lt;td&gt;
        150:103
      &lt;/td&gt;
    &lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;h2&gt;TV&lt;/h2&gt;

&lt;p&gt;TVs share a set of standardised resolutions, so all platforms are grouped together. I should include SD resolutions at a later date, as the Wii does not support HD.&lt;/p&gt;

&lt;table&gt;&lt;thead&gt;&lt;tr&gt;&lt;th&gt;Name&lt;/th&gt;&lt;th&gt;Resolution (px)&lt;/th&gt;&lt;th&gt;Aspect Ratio&lt;/th&gt;&lt;/tr&gt;&lt;/thead&gt;&lt;tbody&gt;&lt;tr&gt;&lt;td&gt;
        HD 720p
      &lt;/td&gt;
      &lt;td&gt;
        1280×720
      &lt;/td&gt;
      &lt;td&gt;
        16:9
      &lt;/td&gt;
    &lt;/tr&gt;&lt;tr&gt;&lt;td&gt;
        HD 1080p
      &lt;/td&gt;
      &lt;td&gt;
        1920×1080
      &lt;/td&gt;
      &lt;td&gt;
        16:9
      &lt;/td&gt;
    &lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;</description><link>http://generatedcontent.org/post/34217358607</link><guid>http://generatedcontent.org/post/34217358607</guid><pubDate>Tue, 23 Oct 2012 22:43:00 -0700</pubDate><category>aspect ratio</category><category>ebook</category><category>mobile</category><category>resolution</category><category>tv</category><category>tablet</category></item><item><title>Public service announcement: You (probably) don’t need to escape quotes in strings</title><description>&lt;p&gt;&lt;figure&gt;&lt;img src="http://media.tumblr.com/tumblr_mc4oem4NMA1qmllqg.png" width="560" alt=""/&gt;&lt;/figure&gt;
When reading a programming book or online reference, you will invariably see something like the following when describing how to include quotes within strings:&lt;/p&gt;

&lt;pre&gt;&lt;code class="lang-javascript"&gt;
// use single quote (or apostrophe) character for JS strings, double quotes for quotes
var quotedString = 'This is a string "with a quote" inside it';

// otherwise use the backslash character (\) to escape quotes and apostrophes
var anotherString = "This is a string with an escaped \"quote\" inside it";&lt;/code&gt;&lt;/pre&gt;

&lt;p&gt;While this is useful advice for teaching escape sequences–which you will probably need when including HTML, CSS or other languages inside strings–you don’t need to do it when including English text.&lt;/p&gt;

&lt;p&gt;Its ok if you don’t know this, as we’re getting into the realms of typographic geekery that the average developer or programming book author doesn’t delve into, but let me explain.&lt;/p&gt;

&lt;p&gt;&lt;!-- more --&gt;&lt;/p&gt;

&lt;h2&gt;A little history&lt;/h2&gt;

&lt;p&gt;The quotation marks we often see inside strings and all over the web today are commonly called straight (or ambidextrous) quotes. They are &amp;#8221; (U+0022 - quotation mark) and &amp;#8217; (U+0027 apostrophe) respectfully. Their unicode name doesn’t help the confusion one bit.&lt;/p&gt;

&lt;p&gt;Back in ye olde days when we had beautiful typography, and all was well in the world, quotes were nice and curvy. We opened quotes with a single ( ‘ ) or  double ( “ ) left quotation mark and closed it with a single ( ’ ) or double ( ” ) right quotation mark.&lt;/p&gt;

&lt;p&gt;When the typewriter was invented, space for all the mechanics needed for the keys was limited. Instead of taking up four keys, plus addition ones for prime ( ′ , used for feet, arc-minutes and minutes), double prime ( ″ , used for inches, arc-seconds and seconds), ditto (〃) and so on, generic straight quotes were added instead.&lt;/p&gt;

&lt;p&gt;Typewriters are long gone, but then came the problem of the ASCII character set. It had limited space for characters due to the primitive storage and memory requirements at the time, so it too only included the straight quote marks.&lt;/p&gt;

&lt;p&gt;We have since outgrown typewriters and ASCII, with Unicode prevalent on most computers (and devices) today. So lets set our quotes free of this legacy restriction and allow them to flaunt their curves.&lt;/p&gt;

&lt;h2&gt;Unescaped quotes in strings&lt;/h2&gt;

&lt;p&gt;Now armed with the knowledge of the correct quotes to use, we can include them in our strings without fear of escapes. It even saves two characters per quote:&lt;/p&gt;

&lt;pre&gt;&lt;code class="lang-javascript"&gt;
var curvyQ = "This is a string with “correct unescaped quotes”.";
var apostToo = 'Don’t use straight quotes, and avoid needing to escape.';
&lt;/code&gt;&lt;/pre&gt;

&lt;p&gt;As can be seen above, apostrophes have the same issue and solution, with the right single quote mark used instead of the straight quote. Actually there are multiple apostrophes such as ( ʼ ) Letter apostrophe, U+02BC, but you most likely don’t need to know about those.&lt;/p&gt;

&lt;h2&gt;Typing these fancy quotes&lt;/h2&gt;

&lt;p&gt;Word processors with smart quotes turned on will swap out straight quotes for curvy quotes, but they sometimes get it wrong, can be plain annoying when you want straight quotes (such as when typing code), and few developers likely code in MS Word or OpenOffice.&lt;/p&gt;

&lt;p&gt;Fortunately, on the Mac at least, they are easy to type by hand. On a US keyboard they are &lt;kbd&gt;alt-[&lt;/kbd&gt; (left double quote), &lt;kbd&gt;shift-alt-[&lt;/kbd&gt; (right double quote), &lt;kbd&gt;alt-]&lt;/kbd&gt; (left single quote) and &lt;kbd&gt;shift-alt-]&lt;/kbd&gt; (right double quote). For other keyboard layouts your milage may very, but the keyboard viewer menu item will help you to find them.&lt;/p&gt;

&lt;p&gt;It looks like it is a &lt;a href="http://desktoppub.about.com/cs/finetypography/ht/curly_quotes.htm" target="_blank"&gt;whole lot more difficult&lt;/a&gt; to type them on Windows, unless things have changed since that article, and my last experience on that OS. But, you can always set up your own shortcuts.&lt;/p&gt;

&lt;p&gt;If you don’t want to type them by hand, you can &lt;a href="http://en.wikipedia.org/wiki/Quotation_mark_glyphs#Quotation_marks_in_Unicode" target="_blank"&gt;use the unicode escapes or HTML entities&lt;/a&gt;, but I find this makes the source code less elegant and harder to read.&lt;/p&gt;

&lt;h2&gt;What about the &lt;code&gt;q&lt;/code&gt; element&lt;/h2&gt;

&lt;p&gt;All kinds of developers get this quote thing wrong, including browser developers. If you include the &lt;code&gt;q&lt;/code&gt; element in your HTML, Firefox and Chrome will use the correct quote marks, but Safari and Opera use straight quotes.&lt;/p&gt;

&lt;p&gt;Fortunately you can use CSS to correct this:&lt;/p&gt;

&lt;pre&gt;&lt;code class="lang-css"&gt;q, q:lang(en) { quotes:"“" "”" "‘" "’"; }&lt;/code&gt;&lt;/pre&gt;

&lt;p&gt;Bear in mind that different language use different quote marks (Including British English, but it just reverses the nesting order between single and double quotes), so if you have a multi-lingual site you may want to look up the other quote marks and make use of the &lt;code&gt;lang&lt;/code&gt; pseudo-class.&lt;/p&gt;

&lt;h2&gt;When you do need to escape quotes?&lt;/h2&gt;

&lt;p&gt;As far as I’m aware, the only time you actually need to use straight quotes is when programming, such as for surrounding attribute values in HTML (and then only when the value has a space), strings in JavaScript, and so on, but not in written language.&lt;/p&gt;</description><link>http://generatedcontent.org/post/33863680090</link><guid>http://generatedcontent.org/post/33863680090</guid><pubDate>Thu, 18 Oct 2012 16:36:00 -0700</pubDate><category>Typography</category><category>quotes</category><category>strings</category></item><item><title>Realigned.</title><description>&lt;p&gt;It has been just over a year since I moved from my &lt;a href="http://my.opera.com/dstorey/" target="_blank"&gt;old blog at My.Opera.com&lt;/a&gt; to the Tumblr blog you’re reading now. In that time I persevered with a slightly modified built-in theme, that wasn’t really designed for long form blogging. As things broke, I fixed them, but the code was getting messy, and the &lt;a href="http://disqus.com" target="_blank"&gt;Disqus&lt;/a&gt; integration was acting all kinds of weird.&lt;/p&gt;

&lt;p&gt;I knew that with my kind of experience with web technology, I should really have a theme of my own, that fit my particular needs. As I was laid off recently, there is no time like the present to give the blog a complete overhaul. What you see now is the result of that labour.&lt;/p&gt;

&lt;p&gt;&lt;!-- more --&gt;&lt;/p&gt;

&lt;h2&gt;The redesign&lt;/h2&gt;

&lt;p&gt;The initial seeds of the idea for the blog theme came around a month ago. I designed the website for the &lt;a href="http://tetsubo.org" target="_blank"&gt;Montage and Ninja projects&lt;/a&gt; at Motorola, while the project was in stealth mode, and so I was limited in the amount of developer outreach I could do. For that project I used a lot of noise textures. As time went on I got more and more jaded with seeing these kind of effects all over the Web. I knew when I got around to redesigning my own blog, I wanted to go as much towards the minimalist stripped down aesthetic as possible. I wanted to keep just the amount of detail that was needed to get the design across. Above all else, I wanted something original.&lt;/p&gt;

&lt;p&gt;In many ways it is ironic. I‘ve been talking about CSS3 for years, all the way back to the early years of CSS3.info and my work with Opera even before that. In those days we longed to be able to move away from square corners, and be able to lift the design with shadows and graphical flourishes. Now that we are finally at the stage where many of the CSS properties that allow us to achieve those effects have got prefixless in the major browsers, here I am designing a theme that almost requires none of that. Indeed, this blog design could easily have been done ten years ago with almost the same lack of images.&lt;/p&gt;

&lt;h3&gt;Colour palette&lt;/h3&gt;

&lt;p&gt;After deciding on the stripped back look, the next thing I wanted to do was play with colour. Its my weakest point as a (pretend) designer. I know next to nothing about colour theory.  Well, actually, my weakest point is that I’ve no idea how to use Photoshop (or any tools of its ilk), and actually prefer to code up in CSS. So choosing colours was going to be a challenge to get me out of my comfort zone. I made it a no-no that I could just fall back to the neutral tones and strong photographic imagery I usually rely on in my designs.&lt;/p&gt;

&lt;p&gt;Orange was a colour that kept coming into my head. Its a colour that cropped up in a photo I used in a demo recently, and I’ve seen it used with striking effect in print design. I knew I wanted to try moving in this direction when looking at images of the classic &lt;a href="http://www.autoblog.com/2012/08/18/1968-ford-gt40-gulf-mirage-sets-auction-record-at-11-million/" target="_blank"&gt;Gulf Ford GT40&lt;/a&gt;. As a sucker for retro styling, I thought “This is it!”. And so the foundations were in place for the other other accent colour was also in place. The blue and orange just worked so well together, without being too trendy. In the end I rejected that blue after trying over and over to get something legible in place, and I put the design on hold. I ended up with a different blue by chance when playing around while bored on a flight back from London after a trip to the Netherlands.&lt;/p&gt;

&lt;p&gt;The blue was most likely unconsciously inspired by KLM even though I was flying United at the time. In any case, the whole colour scheme looks fairly dutch, and I was remising at the time how bad United’s design is now it has &lt;a href="http://www.underconsideration.com/brandnew/archives/the_united_and_continental_airline_mashup.php" target="_blank"&gt;merged with Continental&lt;/a&gt; and dropped the &lt;a href="http://new.pentagram.com/2011/03/fifteen-years-of-flying-united-1/" target="_blank"&gt;Saul Bass Tulip&lt;/a&gt; (Dutch again!) logo. It was partly this disappointment of the state of design around me compared to European airlines that inspired me to start working on my design again.&lt;/p&gt;

&lt;h3&gt;Typography&lt;/h3&gt;

&lt;p&gt;The typography in this design actually came last, which is unusual for me. It is often the first thing I do. I still consider this design a prototype, and have a lot of work to get the ratio between different headings and sections correct, and the whole vertical rhythm sorted out. I went for the safe option here, after the daring colours, and plucked for Helvetica Neue. I may revisit this in the future when I’ve lived in the design some more.&lt;/p&gt;

&lt;p&gt;For the main headings, menu, and logo, I wanted to try something else, and went with the free (and bizarrely named) &lt;a href="http://www.theleagueofmoveabletype.com/ostrich-sans" target="_blank"&gt;Ostrich Sans&lt;/a&gt; font from League of Moveable Type. The logo uses the light font, an the headings use the black variant.&lt;/p&gt;

&lt;h3&gt;Layout&lt;/h3&gt;

&lt;p&gt;The layout is where I did follow a trend, and went for a mobile first, responsive design. Well, not exactly mobile first, as I designed around how the design looks at specific widths rather than to common mobile sizes.&lt;/p&gt;

&lt;p&gt;I wanted to keep the side bar I had in the current design to keep a link to the past, but increased the size to give the design some balance at larger widths. I actually looked at work from print designers such as &lt;a href="http://en.wikipedia.org/wiki/Jan_Tschichold" target="_blank"&gt;Jan Tschichold&lt;/a&gt; to get inspiration here, although didn’t stick to the golden section any more than as an initial inspiration for the margin sizes. You can see s crop of the initial design on my &lt;a href="http://dribbble.com/shots/766217-Generated-Content-redesign?list=following" target="_blank"&gt;Dribbble account&lt;/a&gt;. The main change in the final design is the logo placement, and the tags.&lt;/p&gt;

&lt;p&gt;I knew the sidebar would become problematic at smaller sizes, so I first did a narrow design with the logo and menu across the top of the page. This more or less stayed unchanged in the final design.&lt;/p&gt;

&lt;h3&gt;Design process&lt;/h3&gt;

&lt;p&gt;While I’d love to say I designed in the browser, I actually built the design sketches in Keynote. Although I’m happier working in code than tools like Photoshop, I love using Keynote to quickly experiment placing and deleting elements on the page. I find it is incredibly easy to use and just powerful enough to be able to implement a lot of ideas, without being too complex to get in the way. The restrictions it has also places some boundaries that allow me to focus rather than play around too long with all kinds of crazy ideas.&lt;/p&gt;

&lt;p&gt;While Keynote is great for initial experiments and layout (except the restricted canvas size), I find text styling and layout much harder than in CSS and the effects such as shadows render differently. So, after the initial exploration phase, I usually move over to a text editor to code up and finish off the design.&lt;/p&gt;

&lt;h2&gt;The recode&lt;/h2&gt;

&lt;p&gt;The coding aspect of this design is perhaps less interesting. It took about as long as the design (approximately 1 day, with another half day for nips, tucks, bug fixes, adjustments for mobile, and procrastination. Old content also has to be updated to fit the new heading structure, and add hooks for &lt;a href="http://prismjs.com" target="_blank"&gt;Prism integration&lt;/a&gt; for the code snippets, but that is a job for another day.&lt;/p&gt;

&lt;h3&gt;CSS&lt;/h3&gt;

&lt;p&gt;As mentioned, there is very little visual effects, so there are not too many techniques to learn or be inspired by. I actually did use some CSS3 for the text and layout, as I used the rem unit and box-sizing (my only prefix) to make measurements easier to calculate, and hyphens for the text. Other than that, I used Media Queries to make the design responsive.&lt;/p&gt;

&lt;p&gt;I’ve mainly tested the layout on desktop browsers, and still have some work to do to ensure that mobile and tablet browsers get the right layout, and don’t break when zooming. I have some bugs to iron out here. I also need to add a fallback to the rem unit so that it works better in Opera Mini.&lt;/p&gt;

&lt;p&gt;I also need to fix the web fonts in Firefox, which suffers from cross origin restrictions.&lt;/p&gt;

&lt;h3&gt;HTML template&lt;/h3&gt;

&lt;p&gt;The HTML is perhaps more modern, using HTML5 structural elements, rather than just using the doctype and pulling out the buzzword. I based the template off the original theme as a starting point, but more or less ripped it all out, except for the parts around Tumblr integration and the non-text post types that I’ve not looked into yet.&lt;/p&gt;

&lt;h3&gt;The logo&lt;/h3&gt;

&lt;p&gt;The logo is done in SVG. Most of the time was spent wrestling with Inkscape so that I could change the font glyphs to paths rather than use another web font. Design tools insert a lot of non-optimal markup, so I cleaned it up somewhat by hand. I’ll leave cleaning the paths to another day. Probably by running it through &lt;a href="http://www.codedread.com/scour/" target="_blank"&gt;Scour&lt;/a&gt;.&lt;/p&gt;

&lt;h2&gt;The complete picture&lt;/h2&gt;

&lt;p&gt;I think I’m happy with how it turned out in the end. Using orange as the background colour for the text was something I worried about doing, and I still am to some extent. How much will the colour distract the reader from the actual content? I need to live with it some more to really know, but the issue is less than I initially feared when floating the idea. I also worried about black text on orange giving a dirty feel (as the orange couldn’t be too vibrant), but the freshness of the blue on white in the sidebar adds a freshness that overcomes that issue.&lt;/p&gt;

&lt;p&gt;Will I stick with it? Who knows, but I’ll give it a try, iterating as I go, and see what people think.&lt;/p&gt;</description><link>http://generatedcontent.org/post/33467917171</link><guid>http://generatedcontent.org/post/33467917171</guid><pubDate>Fri, 12 Oct 2012 19:06:00 -0700</pubDate><category>redesign</category><category>realign</category><category>orange</category></item><item><title>See your site like the rest of the world does. On the Nokia X2-01 </title><description>&lt;p&gt;In our world of ever increasing high resolution displays, multi-core, multi gigahertz processors, 4G networks and touch enabled experiences, it is often easy to forget how the rest of the world lives.&lt;/p&gt;

&lt;p&gt;Beyond the latest iPhones, and Android devices, there are a multitude of devices out there, enabling the next billion to experience the &lt;strong&gt;World&lt;/strong&gt; Wide Web for the first time. Move away from the wealthy few of the industrialised world, and a whole different picture emerges. One that might be familiar to those of you who were pioneers on the mobile web; before the iPhone came out and changed our mobile experience forever.&lt;/p&gt;

&lt;p&gt;&lt;!-- more --&gt;&lt;/p&gt;

&lt;p&gt;Entering long URLs and form data on a keypad designed for entering phone number and typing txt messages, not for writing novels, navigating with arrow keys instead directly touching the object on the screen. Running out of memory on large pages, or simply getting lost as the page layout was too complex for the tiny screen you were using.&lt;/p&gt;

&lt;p&gt;The browsers have gotten better since then, but surprisingly many of the devices used in the developing world haven’t significantly. Sure, the raw horsepower may have gone up, and more memory means less of those dreaded out of memory errors. But, key attributes that web developers care about, such as screen size and resolution, and input method are still stuck in the previous era.&lt;/p&gt;

&lt;p&gt;These restrictions are an everyday reality for those that are not as lucky as we are, with our super computers in our pockets. If you care about keeping the World in WWW, and ensuring the content you create is accessible to all, then it will be a reality for you as well.&lt;/p&gt;

&lt;p&gt;Lack of access to online information is only increasing the digital divide. However rudimentary their devices may be, being able to access information on their mobile phone is as empowering for them as it has been for us, if not more so. As Bruce Lawson wrote in his great post on the Opera DevRel team blog &lt;q&gt;&lt;a href="http://my.opera.com/ODIN/blog/2012/09/06/educating-bangladeshi-schoolkids-about-the-web" target="_blank"&gt;Comparison between Indian states shows that a 10% increase in mobile phone penetration rate leads to a 1.2% increase in GDP&lt;/a&gt;&lt;/q&gt;. Having access to information helps people help themselves. The video in Bruce’s post helps put a face to some of those people, and a window into the joy they experience when being able to access the Web.&lt;/p&gt;

&lt;p&gt;If you publish information on the Web, I can’t encourage you enough to try design your site with these devices in mind. No, they don’t need to look the same; you don’t need every wizz bang transition, or rounded corner, but having clear navigable access to the content of your site at small screen sizes and via keypad input is invaluable.&lt;/p&gt;

&lt;p&gt;If you use Media Queries, add tests to make sure the layout doesn’t break down at small sizes. If you have a separate site, make sure it still works when the screen size is even smaller that you may have tested already.&lt;/p&gt;

&lt;p&gt;To make it clear I’m talking here about sites with informational content. Its a whole different challenge for JavaScript heavy apps meant to compete with native apps. Although there is demand for these kind of sites in the developing world, with Facebook the number 1 site across much of the globe, it will require much more than a bit of extra testing and attention to details to get these sites working on basic phones.&lt;/p&gt;

&lt;h2&gt;What is the average phone used by the rest of the world?&lt;/h2&gt;

&lt;p&gt;Great you should ask, as I’ve just spent the last few days poring over the facts, and collating all the details I could find. Details are quite hard to get a hold of, with even &lt;a href="http://gs.statcounter.com/" target="_blank"&gt;StatCounter&lt;/a&gt; (which is good about breaking down its data per country) only breaking down per screen resolution. Fortunately, as Opera Mini is a proxy browser–and is the most popular browser in much of the developing world–it has reams of data on what devices access the Web through its servers. Opera publishes this data through its &lt;a href="http://www.opera.com/smw/" target="_blank"&gt;State of the Mobile Web&lt;/a&gt; series. Sadly, Opera are much less forthcoming with the data that is useful to us than it used to be, but there is still a lot of useful info that we can dig out.&lt;/p&gt;

&lt;p&gt;I couldn’t focus on every country in the world, as that would have simply taken too much time, so I narrowed down the study to the BRIC and Next 11 nations. These are 15 countries that Goldman Sachs identified as having a high potential for becoming the world’s largest economies in the 21st century. They also happen to all be countries where Opera Mini has a strong market share or user base, meaning that the Mini data will be highly relevant to the countries as a whole. 
I made one exception to this list, replacing South Korea with South Africa. The reason for this is that I feel like South Korea is much more like a developed nation these days, especially when considering mobile and internet access, and Opera Mini doesn‘t have such a relevant market share there. South Africa seemed like a good replacement, as it is one of the strongest African economies, and has always been a leading Opera Mini country.&lt;/p&gt;

&lt;p&gt;The full list of countries (with population in parenthesis) includes:&lt;/p&gt;

&lt;ul&gt;&lt;li&gt;China (1,347,350,000)&lt;/li&gt;
    &lt;li&gt;India (1,210,193,422)&lt;/li&gt;
    &lt;li&gt;Indonesia (237,641,326)&lt;/li&gt;
    &lt;li&gt;Brazil (193,946,886)&lt;/li&gt;
    &lt;li&gt;Pakistan (180,646,000)&lt;/li&gt;
    &lt;li&gt;Nigeria (166,629,000)&lt;/li&gt;
    &lt;li&gt;Bangladesh (152,518,015)&lt;/li&gt;
    &lt;li&gt;Russia (143,142,000)&lt;/li&gt;
    &lt;li&gt;Mexico (112,336,538)&lt;/li&gt;
    &lt;li&gt;Philippines (92,337,852)&lt;/li&gt;
    &lt;li&gt;Vietnam (87,840,000)&lt;/li&gt;
    &lt;li&gt;Egypt (82,540,000)&lt;/li&gt;
    &lt;li&gt;Iran (75,149,669)&lt;/li&gt;
    &lt;li&gt;Turkey (74,724,269)&lt;/li&gt;
    &lt;li&gt;South Africa (50,586,757)&lt;/li&gt;
&lt;/ul&gt;&lt;p&gt;The list includes 8 of the 10 most populous countries in the world, the most populous countries in Asia (China), Europe (Russia), and South America (Brazil), and the second most populous in North America (Mexico).&lt;/p&gt;

&lt;p&gt;For each country, I looked at the top 10 devices used by Opera Mini users, and categorised them by attributes that are of interest for web developers. Sadly, Opera doesn’t have information on the top devices outside of Africa, Asia and Latin America for 2012, but I collected previous year’s information where available.&lt;/p&gt;

&lt;p&gt;To check that the data from the leading developing nations was a valid representation of the region as a whole, I cross-referenced the data with the top 10 devices in each of the other countries in Africa, Latin America, and the Asia/Pacific region.&lt;/p&gt;

&lt;p&gt;There are a huge number of different devices, but in general many fall into similar categories based on screen resolution and input method.&lt;/p&gt;

&lt;h3&gt;Screen size and resolution&lt;/h3&gt;

&lt;p&gt;There were 8 resolutions over the top ten phones in each of the studied countries.  Two of these were the same resolution, just flipped between portrait and landscape orientation. Three were only found in Latin America, two of which cover the range between top end feature phones and bottom end smart phones.&lt;/p&gt;

&lt;h4&gt;QVGA Landscape (320×240)&lt;/h4&gt;

&lt;p&gt;All of the phones using landscape QVGA had 2.4 inch displays, giving around 167 ppi pixel density. This resolution has a 4:3 aspect ratio.&lt;/p&gt;

&lt;p&gt;Phones with the resolution included the Nokia X2 01, Nokia C3, Nokia Asha 200, Nokia E63, Alcatel OT-808, Alcatel OT-800, Alcatel OT-802, Samsung Ch@t 335 (S3350), and the BlackBerry Curve 8520.&lt;/p&gt;

&lt;p&gt;&lt;img src="http://media.tumblr.com/tumblr_ma9mnfEKBF1qmllqg.png" alt="QVGA landscape screen"/&gt;&lt;/p&gt;

&lt;h4&gt;QVGA Portrait (240×320)&lt;/h4&gt;

&lt;p&gt;The phones in this category ranged from 2.0 inches (200 ppi) to 2.6 inches (154 ppi). The exception was the Samsung S3850, which has a 3.2 inch screen (125 ppi), and the Samsung Galaxy Y S5360 with a 3 inch screen (133 ppi).&lt;/p&gt;

&lt;p&gt;Phones with this resolution include the Nokia Asha 303, Nokia 2700C, Nokia 2730C, Nokia 5130, Nokia X2 00, Nokia 6300, Nokia C2 01, Nokia N73, Nokia 3208c, Nokia 5000, Nokia 7020, Sony Ericsson K800, Samsung Galaxy Y S5360, and Samsung S3850.&lt;/p&gt;

&lt;p&gt;&lt;img src="http://media.tumblr.com/tumblr_ma9mu7BHAZ1qmllqg.png" alt="QVGA portrait screen"/&gt;&lt;/p&gt;

&lt;h4&gt;Approximately QQVGA (128 x 160)&lt;/h4&gt;

&lt;p&gt;These phone are 8 pixels wider than the standard 120x160 resolution, but this is a common size with older feature phones. All Nokia phones with this resolution have a 1.8 inch display, giving them a pixel density of 114ppi. The one Samsung device has a larger display, coming in at 2 inches and a pixel density of only 102 ppi. Luckily this was the smallest resolution in the study.&lt;/p&gt;

&lt;p&gt;The phones using this resolution included the Nokia C1, Nokia 2690, Nokia C2 00, Nokia 2330c, Nokia 2220 slide, and Samsung E250.&lt;/p&gt;

&lt;p&gt;&lt;img src="http://media.tumblr.com/tumblr_ma9mxlgBWb1qmllqg.png" alt="128x160 display"/&gt;&lt;/p&gt;

&lt;h4&gt;nHD (640×360)&lt;/h4&gt;

&lt;p&gt;nHD seems to be a resolution unique to Nokia, used in its touch based S60 phones. These phones have an aspect ratio of 16:9, and 3.2 inch displays. This brings the pixel density in at around 229 ppi.&lt;/p&gt;

&lt;p&gt;These were the closest we got to smartphones in the study. Two devices used this resolution; the Nokia 5233 and Nokia 5230. In the screenshot below the screen looks a lot bigger than it would in real life.&lt;/p&gt;

&lt;p&gt;&lt;img src="http://media.tumblr.com/tumblr_ma9n67Cp8Q1qmllqg.png" alt="nHD display"/&gt;&lt;/p&gt;

&lt;h4&gt;176×208&lt;/h4&gt;

&lt;p&gt;I couldn’t find the name for this resolution, but it is the common resolution for old non-touch S60 devices. These would have been considered smart phones back in the day. All phones with this resolution used 2.1 inch displays, with a pixel density of around 130 ppi.&lt;/p&gt;

&lt;p&gt;The resolution was used on the N70 and N72. These phones seem to be dying out as time goes by.&lt;/p&gt;

&lt;p&gt;&lt;img src="http://media.tumblr.com/tumblr_ma9nclxcyG1qmllqg.png" alt="176x208 display"/&gt;&lt;/p&gt;

&lt;h4&gt;220×176&lt;/h4&gt;

&lt;p&gt;This doesn’t seem to be a named resolution, but is common in lower end feature phones from various manufacturers. It is usually found in landscape oriented 2 inch displays, with a pixel density of around 141 ppi. This was the resolution used in the iPod Color.&lt;/p&gt;

&lt;p&gt;This resolution can be found in the Motorola MOTOKEY Mini EX108 and EX109. Both of which are variations of the same phone and are only found in the top 10 in Brazil.&lt;/p&gt;

&lt;h4&gt;WQVGA (400×240)&lt;/h4&gt;

&lt;p&gt;WQVGA screens are usually 3 inch portrait touch screens found in higher end feature phones. They have an aspect ratio of 4:3, and a pixel density of around 155 ppi.&lt;/p&gt;

&lt;p&gt;Phones with this resolution include the LG GM360 Viewty Snap and Samsung Star TV (S5233T), which have only made the top 10 in Mexico.&lt;/p&gt;

&lt;p&gt;It is also found in top of the range feature phones that have not made the top 10 lists yet, such as the latest Nokia Asha Touch devices, and a number of Samsung Bada devices (usually with a slightly bigger 3.2 inch display).&lt;/p&gt;

&lt;h4&gt;HVGA (480×320)&lt;/h4&gt;

&lt;p&gt;This is the resolution made famous by the first 3 generations of the iPhone, so most web developers have an intimate knowledge of how to design for it. These days it has trickled down to lower end smart phones. It is often found in a 3.5 inch capacitive touch configuration.&lt;/p&gt;

&lt;p&gt;Only one device was found with this resolution in the top 10 of the 15 countries studied, and it was not the iPhone. It was the Samsung Galaxy Ace S5830, which was 4th most popular in Mexico, and also popular throughout Latin America.&lt;/p&gt;

&lt;h3&gt;Input method&lt;/h3&gt;

&lt;p&gt;If the most common resolution of 320×240 or 240×320 wasn’t music to your ears, the news is worse on the input front. The good news was that the input method largely corresponded to the resolution and orientation, so we can group large amounts of devices in classes.&lt;/p&gt;

&lt;h4&gt;Numeric keypads&lt;/h4&gt;

&lt;p&gt;Phones with numeric keypads included:&lt;/p&gt;

&lt;ul&gt;&lt;li&gt;All Portrait QVGA (except Samsung S3850 and Nokia Asha 303)&lt;/li&gt;
    &lt;li&gt;All 128x160&lt;/li&gt;
    &lt;li&gt;All 176x208&lt;/li&gt;
&lt;/ul&gt;&lt;h4&gt;QWERTY keypads&lt;/h4&gt;

&lt;p&gt;All landscape QVGA devices had QWERTY keypads. These were the type located under the display, as commonly seen on a BlackBerry device. The Nokia Asha 303 has a QWERTY keypad under a portrait QVGA display.&lt;/p&gt;

&lt;h4&gt;Resistive touch screens&lt;/h4&gt;

&lt;p&gt;All the nHD devices have resistive touch screens, as do both the WQVGA devices in this study. The Nokia 3208C (QVGA portrait display) also has a resistive touch screen in addition to a numeric keypad. This is a China only model.&lt;/p&gt;

&lt;h4&gt;Capacitive touch screens&lt;/h4&gt;

&lt;p&gt;This is the type of display we now come to expect, and usually design our mobile experiences around. Unfortunately this was only found in three devices; the Samsung Galaxy Ace S5830, the portrait QVGA Samsung S3850 and Nokia Asha 303. The latter also has a QWERTY keypad under the display. Newer WQVGA devices–which have yet to make the top 10 list–may include capacitive displays.&lt;/p&gt;

&lt;h3&gt;Operating Systems&lt;/h3&gt;

&lt;p&gt;This information is not hugely useful for web developers, but can be interesting to classify the devices.&lt;/p&gt;

&lt;h4&gt;Nokia OS (S40)&lt;/h4&gt;

&lt;p&gt;This was the most common OS by far. This is considered a feature phone OS, and apps are quite often developed using Java. Opera Mini for example is a Java app on S40.&lt;/p&gt;

&lt;p&gt;All QVGA (of either orientation) phones from Nokia were S40 devices except the E63 and N73. I also believe that the 128x160 phones are S40, but they could be S30.&lt;/p&gt;

&lt;h4&gt;Symbian (S60)&lt;/h4&gt;

&lt;p&gt;The 176x208 devices use Symbian 8.1, the N73 and E73 use Symbian 9.1 and 9.2 respectively, and the nHD touch screen devices use Symbian 9.4.&lt;/p&gt;

&lt;h4&gt;Other&lt;/h4&gt;

&lt;p&gt;The Sony Ericsson, Alcatel, LG and Samsung phones used their own feature phone OS rather than any named smart phone operating systems.&lt;/p&gt;

&lt;p&gt;Outside of Symbian, only two of the devices used what are now commonly considered smart phone OS; one Android device (Samsung Galaxy Ace), and one Blackberry (BlackBerry Curve 8520). Both are lower-end devices.&lt;/p&gt;

&lt;h3&gt;Data&lt;/h3&gt;

&lt;p&gt;The area where most phones diverged was their data capabilities, although Class 32 GPRS and EDGE is the most common. All except two of the portrait QVGA and one of the Landscape QVGA phones from Nokia supported this. Ironically the &lt;a href="http://www.nokia.com/global/products/phone/asha200/" target="_blank"&gt;Nokia Asha 200&lt;/a&gt; is the newest phone and has slower data capabilities.&lt;/p&gt;

&lt;p&gt;The other phones supported everything from class 12 GPRS and EDGE to class 10 GPRS and no EDGE.&lt;/p&gt;

&lt;p&gt;Only one phone (the &lt;a href="http://www.nokia.com/us-en/products/phone/c3-00/" target="_blank"&gt;Nokia C3&lt;/a&gt;) supported WiFi (b/g), so don’t expect this if you’re targeting developing countries. All the data coming down the pipe the users are paying for, unless they’re on some sort of unlimited plan or have free minutes (or find a hack for Opera Mini, such as has happened in Nigeria and Mexico in the past).&lt;/p&gt;

&lt;h3&gt;In conclusion&lt;/h3&gt;

&lt;p&gt;Popular phones in the developing world can currently be largely grouped into the following categories (ignoring the older symbian devices):&lt;/p&gt;

&lt;h4&gt;Portrait keypad&lt;/h4&gt;

&lt;p&gt;Numeric keypad with QVGA portrait display, Class 32 GPRS/EDGE, no Wifi, and Nokia S40 OS. Data access potentially slower.&lt;/p&gt;

&lt;p&gt;Numeric keypad with 128x160 display. Widely varying data access speeds, at most 2G. No WiFi. Nokia S40 OS.&lt;/p&gt;

&lt;h4&gt;Portrait QWERTY&lt;/h4&gt;

&lt;p&gt;QWERTY keypad in a portrait phone. QVGA landscape display, Class 32 GPRS/EDGE, no Wifi, and Nokia S40 OS. Data access potentially slower. Newer devices and Blackberries may have WiFi.&lt;/p&gt;

&lt;h4&gt;Portrait full screen&lt;/h4&gt;

&lt;p&gt;nHD display with resistive touch screen. Class 32 GPRS/EDGE, no WiFi and Symbian 9.4 OS&lt;/p&gt;

&lt;h3&gt;The most popular devices&lt;/h3&gt;

&lt;p&gt;It is difficult to tell which device is the most popular, as there has been no global figure since &lt;a href="http://www.opera.com/smw/2011/11/" target="_blank"&gt;November 2011&lt;/a&gt;. At that time, the most popular phone was the Nokia 5130 XpressMusic. This is a Portrait QVGA (240×320) device. Six of the top ten were in this configuration, one was a landscape QVGA device, and three were 128x160 devices.&lt;/p&gt;

&lt;p&gt;Things change slowly in the feature phone world, but I suspect things have moved a bit, with slightly newer phones starting to become popular.&lt;/p&gt;

&lt;p&gt;We can only use countries in Asia, Africa, and Latin America to judge which phones are the most popular this year, but the &lt;a href="http://www.nokia.com/us-en/products/phone/nokia-x2-01/" target="_blank"&gt;Nokia X2 01&lt;/a&gt; (a landscape QVGA device) tied with the venerable &lt;a href="http://www.nokia.com/us-en/support/product/nokia-5130-xpressmusic/" target="_blank"&gt;Nokia 5130 XpressMusic&lt;/a&gt; with two countries where it was the most popular. These were India and Indonesia (1st and 3rd largest Opera Mini countries respectively) for the X2 01, and China and South Africa for the Nokia 5130. Other major countries where the X2 01 is the most popular phone include Kenya, Ghana and Zimbabwe, while the 5130 is most popular in Egypt and Tanzania. As a newer phone, the X2 01 is certainly on the rise, but how popular it is in countries such as Russia will go a long way deciding which ends up on the top of the pile.&lt;/p&gt;

&lt;p&gt;The C3 beat both of them out with three countries where it is the most popular; Mexico, Brazil, and the Philippines, but these countries are lower ranked in terms of Opera Mini users than those where the 5130 and X2 01 are the most popular. It is certainly a strong contender for the title of top device.&lt;/p&gt;

&lt;h4&gt;Nokia X2 01 - Landscape QVGA&lt;/h4&gt;

&lt;p&gt;&lt;img src="http://media.tumblr.com/tumblr_ma9nkvSU7r1qmllqg.png" style="float: right; margin: 1em 0 0 1.5em"/&gt;&lt;/p&gt;

&lt;p&gt;The &lt;a href="http://www.nokia.com/us-en/products/phone/nokia-x2-01/" target="_blank"&gt;Nokia X2 01&lt;/a&gt; can be considered one of the more modern replacements for the XpressMusic (the X series stands for Xpress). This particular device was released in January 2011 and is moving up the rankings.&lt;/p&gt;

&lt;p&gt;Asian, Latin American and African countries where it is the most popular:&lt;/p&gt;

&lt;ul&gt;&lt;li&gt;Angola&lt;/li&gt;
    &lt;li&gt;Botswana&lt;/li&gt;
    &lt;li&gt;Gabon&lt;/li&gt;
    &lt;li&gt;Ghana&lt;/li&gt;
    &lt;li&gt;Kenya&lt;/li&gt;
    &lt;li&gt;Mauritania&lt;/li&gt;
    &lt;li&gt;Zimbabwe&lt;/li&gt;
    &lt;li&gt;&lt;strong&gt;India&lt;/strong&gt;&lt;/li&gt;
    &lt;li&gt;Laos&lt;/li&gt;
    &lt;li&gt;Cambodia&lt;/li&gt;
    &lt;li&gt;&lt;strong&gt;Indonesia&lt;/strong&gt;&lt;/li&gt;
&lt;/ul&gt;&lt;p&gt;Other rankings (in 15 countries studied):&lt;/p&gt;

&lt;ol start="2"&gt;&lt;li&gt;Brazil, Nigeria, South Africa&lt;/li&gt;
&lt;li value="4"&gt;Vietnam&lt;/li&gt;
&lt;li value="6"&gt;Bangladesh&lt;/li&gt;
&lt;li&gt;Philippines &lt;/li&gt;
&lt;/ol&gt;&lt;p&gt;As a relatively new phone, it didn’t feature in any of the top ten last year.&lt;/p&gt;

&lt;h4&gt;Nokia 3150 XpressMusic&lt;/h4&gt;

&lt;p&gt;&lt;img src="http://media.tumblr.com/tumblr_ma9nxqf6V01qmllqg.png" style="float: right; margin: 1em 0 0 1em"/&gt;&lt;/p&gt;

&lt;p&gt;The &lt;a href="http://www.nokia.com/us-en/support/product/nokia-5130-xpressmusic/" target="_blank"&gt;Nokia 3150 XpressMusic&lt;/a&gt; has been the number one phone for at least the last two years. It was released back in February 2009. It is starting to drop in the rankings in a number of top countries.&lt;/p&gt;

&lt;p&gt;Asian, Latin American and African countries where it is the most popular:&lt;/p&gt;

&lt;ul&gt;&lt;li&gt;Benin&lt;/li&gt;
    &lt;li&gt;Burundi&lt;/li&gt;
    &lt;li&gt;&lt;strong&gt;Egypt&lt;/strong&gt;&lt;/li&gt;
    &lt;li&gt;Lesotho&lt;/li&gt;
    &lt;li&gt;Libya&lt;/li&gt;
    &lt;li&gt;Malawi&lt;/li&gt;
    &lt;li&gt;Mozambique&lt;/li&gt;
    &lt;li&gt;Namibia&lt;/li&gt;
    &lt;li&gt;Seychelles&lt;/li&gt;
    &lt;li&gt;&lt;strong&gt;South Africa&lt;/strong&gt;&lt;/li&gt;
    &lt;li&gt;Swaziland&lt;/li&gt;
    &lt;li&gt;Tanzania&lt;/li&gt;
    &lt;li&gt;&lt;strong&gt;China&lt;/strong&gt;
    &lt;/li&gt;&lt;li&gt;Nepal&lt;/li&gt;
    &lt;li&gt;Myanmar (Burma)&lt;/li&gt;
    &lt;li&gt;Thailand&lt;/li&gt;
&lt;/ul&gt;&lt;p&gt;Other rankings (in 15 countries studied):&lt;/p&gt;

&lt;ol start="2"&gt;&lt;li&gt;Bangladesh, Vietnam&lt;/li&gt;
   &lt;li&gt;Indonesia, Phillipines &lt;/li&gt;
   &lt;li&gt;India&lt;/li&gt;
   &lt;li&gt;Nigeria&lt;/li&gt;
&lt;/ol&gt;&lt;p&gt;In the countries where there is currently no data for this year, the 3150 XpressMusic
was the leading device in Pakistan, 2nd in Iran and Turkey, and 3rd in Russia.&lt;/p&gt;

&lt;h4&gt;Nokia C3 00&lt;/h4&gt;

&lt;p&gt;&lt;img src="http://media.tumblr.com/tumblr_ma9o2afkOs1qmllqg.png" style="float: right; margin: 1em 0 0 1em"/&gt;&lt;/p&gt;

&lt;p&gt;The &lt;a href="http://www.nokia.com/us-en/products/phone/c3-00/" target="_blank"&gt;Nokia C3 00&lt;/a&gt; is a landscape QVGA device, in much the same vein as the X2 01, except it does include WiFi. It was released in June 2010. It has the largest number of countries where it is the most popular in Asia/Pacific, Latin America and Africa, including three of the fifteen countries studied. It is the dominant phone by far in Latin America.&lt;/p&gt;

&lt;p&gt;Asian, Latin American and African countries where it is the most popular:&lt;/p&gt;

&lt;ul&gt;&lt;li&gt;&lt;strong&gt;Mexico&lt;/strong&gt;&lt;/li&gt;
    &lt;li&gt;Guatemala&lt;/li&gt;
    &lt;li&gt;Honduras&lt;/li&gt;
    &lt;li&gt;Nicaragua&lt;/li&gt;
    &lt;li&gt;Panama&lt;/li&gt;
    &lt;li&gt;Dominican Republic&lt;/li&gt;
    &lt;li&gt;Colombia&lt;/li&gt;
    &lt;li&gt;&lt;strong&gt;Brazil&lt;/strong&gt;&lt;/li&gt;
    &lt;li&gt;Ecuador&lt;/li&gt;
    &lt;li&gt;Bolivia&lt;/li&gt;
    &lt;li&gt;Paraguay&lt;/li&gt;
    &lt;li&gt;Chile&lt;/li&gt;
    &lt;li&gt;Argentina&lt;/li&gt;
    &lt;li&gt;Malaysia&lt;/li&gt;
    &lt;li&gt;Singapore&lt;/li&gt;
    &lt;li&gt;Brunei&lt;/li&gt;
    &lt;li&gt;&lt;strong&gt;Philippines&lt;/strong&gt;&lt;/li&gt;
    &lt;li&gt;Timor-Leste&lt;/li&gt;
    &lt;li&gt;American Samoa&lt;/li&gt;
    &lt;li&gt;Australia&lt;/li&gt;
    &lt;li&gt;New Zealand&lt;/li&gt;
    &lt;li&gt;Algeria&lt;/li&gt;
    &lt;li&gt;Morocco&lt;/li&gt;
    &lt;li&gt;Senegal&lt;/li&gt;
    &lt;li&gt;Gambia&lt;/li&gt;
    &lt;li&gt;Guinea-Bissau&lt;/li&gt;
    &lt;li&gt;Eritrea&lt;/li&gt;
    &lt;li&gt;Djibouti&lt;/li&gt;
    &lt;li&gt;DRC&lt;/li&gt;
    &lt;li&gt;Comoros&lt;/li&gt;
    &lt;li&gt;São Tomé and Príncipe&lt;/li&gt;
&lt;/ul&gt;&lt;p&gt;Other rankings (in 15 countries studied):&lt;/p&gt;

&lt;ol start="2"&gt;&lt;li&gt;Indonesia&lt;/li&gt;
&lt;li&gt;Egypt&lt;/li&gt;
&lt;li value="4"&gt;Nigeria, South Africa&lt;/li&gt;
&lt;li value-&gt;Vietnam, Bangladesh&lt;/li&gt;
&lt;/ol&gt;&lt;p&gt;In the countries where there is no data for this year, the Nokia C3 was 1st in Turkey, and 4th in Pakistan.&lt;/p&gt;

&lt;h4&gt;Nokia 2700 classic&lt;/h4&gt;

&lt;p&gt;&lt;img src="http://media.tumblr.com/tumblr_ma9o423KdY1qmllqg.png" style="float: right; margin: 1em 0 0 1em"/&gt;&lt;/p&gt;

&lt;p&gt;The &lt;a href="http://www.nokia.com/in-en/products/phone/2700-classic/specifications/" target="_blank"&gt;Nokia 2700 classic&lt;/a&gt; is a portrait QVGA device is similar to the 5130 XpressMusic in characteristics. It has been the second most popular phone for two years, originally being released back in July 2009. It is most popular in two of the countries studied; Bangladesh and Vietnam, and also most popular in two of the top 10 african countries; Ethiopia and Sudan. It also has a strong showing in 2nd and 3rd in a number of major countries.&lt;/p&gt;

&lt;p&gt;Asian, Latin American and African countries where it is the most popular:&lt;/p&gt;

&lt;ul&gt;&lt;li&gt;Chad&lt;/li&gt;
    &lt;li&gt;Ethiopia&lt;/li&gt;
    &lt;li&gt;Liberia&lt;/li&gt;
    &lt;li&gt;Sudan&lt;/li&gt;
    &lt;li&gt;Tunisia&lt;/li&gt;
    &lt;li&gt;Mongolia&lt;/li&gt;
    &lt;li&gt;&lt;strong&gt;Bangladesh&lt;/strong&gt;&lt;/li&gt;
    &lt;li&gt;&lt;strong&gt;Vietnam&lt;/strong&gt;&lt;/li&gt;
&lt;/ul&gt;&lt;p&gt;Other rankings (in 15 countries studied):&lt;/p&gt;

&lt;ol start="2"&gt;&lt;li&gt;China, Egypt&lt;/li&gt;
&lt;li&gt;India, Nigeria, South Africa&lt;/li&gt;
&lt;li&gt;Indonesia&lt;/li&gt;
&lt;li&gt;Phillipines&lt;/li&gt;
&lt;/ol&gt;&lt;p&gt;In the countries with no data for this year, the Nokia 2700 classic was the leading device in Russia, 2nd in Pakistan, 3rd in Turkey, and 6th in Iran last year.&lt;/p&gt;

&lt;h4&gt;Nokia C1&lt;/h4&gt;

&lt;p&gt;&lt;img src="http://media.tumblr.com/tumblr_ma9o7zIJvO1qmllqg.jpg" style="float: right; margin: 1em 0 0 1em"/&gt;&lt;/p&gt;

&lt;p&gt;This is where the groans might come in. The &lt;a href="http://press.nokia.com/products/280/nokia-c1-00/" target="_blank"&gt;Nokia C1&lt;/a&gt; is a 128 x 160 device, which importantly is the most popular phone in Nigeria. Although this is the only country it is the most popular, Nigeria has the most users of any African country.&lt;/p&gt;

&lt;p&gt;Curiously the C1 was only 4th last year, with the three phones above it all being QVGA portrait phones. I’m not sure why this is, unless the proliferation of the mobile web in Nigeria means that more users are getting online that can only afford even more basic phones.&lt;/p&gt;

&lt;p&gt;Other rankings (in 15 countries studied):&lt;/p&gt;

&lt;ol start="5"&gt;&lt;li&gt;India, Egypt&lt;/li&gt;
&lt;li value="7"&gt;Bangladesh&lt;/li&gt;
&lt;li&gt;Philippines, South Africa&lt;/li&gt;
&lt;li&gt;Vietnam&lt;/li&gt;
&lt;li&gt;Indonesia&lt;/li&gt;
&lt;/ol&gt;&lt;p&gt;In the countries where there was no data for this year, the C1 was 5th in Pakistan, and 10th in Turkey.&lt;/p&gt;

&lt;h3&gt;Alcatel: An honourable mention&lt;/h3&gt;

&lt;p&gt;While this list is hugely dominated by Nokia, Alcatel’s influence is slowly starting to grow under the radar. Less well know than Samsung or Sony, or even Chinese brands like Huawei, a number of its phones (still feature phones, not Android) were the top phones in Africa and Latin America, and broke the top ten in some Asia/Pacific markets, and Mexico. It was particularly popular in Western Africa:&lt;/p&gt;

&lt;p&gt;African and Latin American countries with Alcatel as the most popular phone:&lt;/p&gt;

&lt;h4&gt;Alcatel OT-606 Chat (portrait QVGA keypad phone, with slide out landscape QWERTY keyboard.)&lt;/h4&gt;

&lt;ul&gt;&lt;li&gt;Cameroon&lt;/li&gt;
    &lt;li&gt;Côte d’Ivoire&lt;/li&gt;
    &lt;li&gt;Equatorial Guinea&lt;/li&gt;
    &lt;li&gt;Madagascar&lt;/li&gt;
    &lt;li&gt;Republic of the Congo&lt;/li&gt;
    &lt;li&gt;Togo&lt;/li&gt;
    &lt;li&gt;Peru&lt;/li&gt;
    &lt;li&gt;Uruguay&lt;/li&gt;
    &lt;li&gt;Venezuela&lt;/li&gt;
&lt;/ul&gt;&lt;h4&gt;Alcatel OT-800 (landscape QVGA screen with QWERTY keypad)&lt;/h4&gt;

&lt;ul&gt;&lt;li&gt;Central African Rep.&lt;/li&gt;
    &lt;li&gt;Niger&lt;/li&gt;
    &lt;li&gt;Belize&lt;/li&gt;
&lt;/ul&gt;&lt;h4&gt;Alcatel OT-808 (landscape QVGA screen with QWERTY keypad)&lt;/h4&gt;

&lt;ul&gt;&lt;li&gt;Guinea&lt;/li&gt;
&lt;/ul&gt;&lt;h4&gt;Alcatel OT-710 (portrait QVGA with resistive touchscreen)&lt;/h4&gt;

&lt;ul&gt;&lt;li&gt;Papua New Guinea&lt;/li&gt;
&lt;/ul&gt;&lt;p&gt;Alcatel seems to be beating the inevitable onslaught of the Android army in Africa at least, and is perhaps the first credible challenger to Nokia’s feature phone crown in the developing world. Its OT-710 is the only phone in the study with a touch screen that is the most popular phone in a country.&lt;/p&gt;

&lt;h3&gt;Most popular type of phone&lt;/h3&gt;

&lt;p&gt;There are three types of phones you have to support if you want to cover most of your bases in the developing world, and they’re all keypad based-non-touch devices.&lt;/p&gt;

&lt;h4&gt;3rd group: 128x160 keypad devices&lt;/h4&gt;

&lt;p&gt;The 128x160 phones are perhaps slowly on the way out, but the recent popularity of the C1 in Nigeria, and the fact that the number 2 phone in India is another 128x160 device in the Nokia 2690, means that they will be around for a while.&lt;/p&gt;

&lt;p&gt;Models in top 10 of 15 countries studied: &lt;strong&gt;Nokia C1&lt;/strong&gt;, Nokia 2690, Nokia C2 00, Nokia 2330c, Nokia 2220 slide, Samsung E250&lt;/p&gt;

&lt;p&gt;Leading phone in: Nigeria (C1).&lt;/p&gt;

&lt;h4&gt;2nd group: QVGA portrait keypad devices&lt;/h4&gt;

&lt;p&gt;These are likely the largest by number, with 15 phones in this category, 5 countries where they are number 1, 4 at number 2, and 6 at number 3. The two most popular phones for the last two years have been in this category.&lt;/p&gt;

&lt;p&gt;Models in top 10 of 15 countries studied: &lt;strong&gt;Nokia 2700C&lt;/strong&gt;, Nokia 2730C, &lt;strong&gt;Nokia 5130 XpressMusic&lt;/strong&gt;, Nokia Asha 303, Nokia X2 00, Nokia 6300, Nokia C2 01, Nokia N73, Nokia 3208c, Nokia 5000, Nokia 7020, Sony Ericsson K800, Samsung Galaxy Y S5360, and Samsung S3850.&lt;/p&gt;

&lt;p&gt;Leading phone in: China (5130 XpressMusic), Bangladesh (2700c), Egypt (5130 XpressMusic), South Africa (5130 XpressMusic), and Vietnam (2700c),&lt;/p&gt;

&lt;h4&gt;1st group: landscape QVGA QWERTY devices&lt;/h4&gt;

&lt;p&gt;Portrait devices with a landscape oriented screen and a QWERTY keypad seem to be the new en vouge devices in a number of the countries studied. Perhaps not the most popular type of device yet, but they are becoming increasingly important, and are dominant in Latin America. The landscape screen gives slightly more width to play with when laying out pages. A very precious commodity at these screen sizes. The keyboards will also make data entry easier than the traditional number pads. These phones were number 1 in 3 countries, 3 at number 2, and 1 at number 3.&lt;/p&gt;

&lt;p&gt;Models in top 10 of 15 countries studied: &lt;strong&gt;Nokia X2 01&lt;/strong&gt;, &lt;strong&gt;Nokia C3&lt;/strong&gt;, Nokia Asha 200, Nokia E63, Alcatel OT-808, Alcatel OT-800, Alcatel OT-802, Samsung Ch@t 335 (S3350), and the BlackBerry Curve 8520.&lt;/p&gt;

&lt;p&gt;Leading phone in: India (X2 01), Indonesia (X2 01), Philippines (C3), Mexico (C3), and Brazil (C3)&lt;/p&gt;

&lt;h2&gt;Conclusions&lt;/h2&gt;

&lt;p&gt;The good news is there is only two different resolutions (plus one different orientation) to cover most of the bases in the developing countries studied. Plus another two resolutions if you want to cover all the bases including the more exotic devices. The bad news is that none of the most popular device types support touch, nor do they support WiFi (except the C3), so data is as much at a premium as pixels.&lt;/p&gt;

&lt;p&gt;My advice would be to try to get hold of both a Nokia X2-01 (or C3 00, which has WiFi) and a 5130 XpressMusic, plus perhaps a Nokia C1. That will cover all three main bases. They’re more or less cheap as chips compared to the devices we usually target.&lt;/p&gt;

&lt;p&gt;If you can’t get hold of a device, one trick is to download the &lt;a href="http://www.opera.com/developer/tools/mobile/" target="_blank"&gt;Opera Mobile emulator&lt;/a&gt; and set profiles up for these screen sizes and pixel densities. It will give you a good idea of the layout of your site on these small displays, but is far from perfect, as these devices usually support Opera Mini rather than Opera Mobile. THe former is much less capible, but unfortunately doesn’t have a downloadable, resizable emulator on the site. If you have Java, you can try the online &lt;a href="http://www.opera.com/developer/tools/mini/" target="_blank"&gt;Opera Mini simulator&lt;/a&gt;, but the resolution is fixed and uses the touch UI by default.&lt;/p&gt;

&lt;p&gt;If you are practicing responsive web design and already use media queries, you likely have the infrastructure in place to support these screen sizes. You might just need to add an extra breakpoint or two for smaller sizes. if your site is already keyboard accessible, then it is likely you won’t have too many issues with keypad navigation. The size of your assets could be a major concern, but the proxies used by Opera Mini, UC Web and the Nokia browser will go some ways to mitigate this.&lt;/p&gt;

&lt;h2&gt;The future&lt;/h2&gt;

&lt;p&gt;Phones that didn’t feature heavily here were Nokia’s new Asha line of feature phones. Only two Asha phones featured in the top 10: The Asha 303 (ninth in Mexico) and the Asha 200 featured (back in tenth in Nigeria). The latter of which had even worse specs than the other devices in its class. One reason for them not featuring is their relative newness. Another is that Nokia is pushing its own proxy browser with these new devices, so the users might stick with the default browser. It will be interesting to see if this browser eats away at Opera’s dominant position in the developing countries, or if users that buy these phones still use Opera.&lt;/p&gt;

&lt;p&gt;&lt;img src="http://media.tumblr.com/tumblr_ma9obibFMS1qmllqg.png" style="float: left; margin: 0 1em 0 0;"/&gt;&lt;/p&gt;

&lt;p&gt;The main exciting thing about these devices is that the three top of the line devices are full touch S40 devices, in the &lt;a href="https://www.nokia.com/global/products/phone/asha311/" target="_blank"&gt;Asha 311&lt;/a&gt;, &lt;a href="https://www.nokia.com/global/products/phone/asha306/" target="_blank"&gt;Asha 306&lt;/a&gt;, and &lt;a href="https://www.nokia.com/global/products/phone/asha305/" target="_blank"&gt;Asha 305&lt;/a&gt;. If the pricing is right, these could potentially be the game changers that give the developing world the revolution in user experience on the web that touch has already brought to ourselves in the west.&lt;/p&gt;

&lt;p&gt;They’ll not hold a candle to the iPhone, but they won’t have to. It is a totally different market and they‘ll be a fraction of the price. They have the potential to democratise touch for the rest of the world. It may take another generation however, before touch devices reach the mid-range of feature phones rather than the top end, before they really take off enmass.&lt;/p&gt;

&lt;p&gt;The interesting billion dollar question is, will it be touch dropping down to feature phones such as the Nokia S40 devices, or Android devices dropping in price enough to be viable market leaders in the the developing world. That will be an interesting battle.&lt;/p&gt;

&lt;p&gt;The other variable is if Nokia and Microsoft can get Windows Phone at a price point where they replace their fleet of feature phones. That could be a major win for their platform in a market Nokia knows all about. Whichever platform wins, it should be a win for web developers and users over the current situation of limited devices.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Stop press&lt;/strong&gt;. I wrote the bulk of this post last night, and since then the iPhone 5 has been announced. I couldn’t help but notice that the &lt;a href="http://www.apple.com/ipod-nano/specs.html" target="_blank"&gt;iPod Nano’s&lt;/a&gt; screen resolution is 240x432; the same width and a fraction taller than many of the devices in this study. Its a shame that device doesn’t have WiFi and a web browser, as the clamour for developers to get their sites working on that display would have been a great help in improving the experiences of users of these phones.&lt;/p&gt;

&lt;p&gt;&lt;strong&gt;Update:&lt;/strong&gt; Opera has released &lt;a href="http://www.opera.com/smw/2012/08/#map" target="_blank"&gt;data for Latin America covering August 2012&lt;/a&gt;. I’ve updated this post to reflect that. On the whole Latin America is similar but more advanced than Asia/Pacific and Africa. The most popular device is the C3 00 QVGA portrait device, which is similar  in capabilities to the X2 01 but also includes WiFi. Latin America has less reliance on Nokia than Asia and Africa–with Alcatel particularly strong–but it is still the most popular brand with Opera Mini users.&lt;/p&gt;

&lt;p&gt;We have started to see higher end WGVGA feature phones and lower end HVGA smart phones break the top ten in Latin America. I would expect this trend to proliferate in the text year and spread to the other regions. It will be interesting to see if this happens with Samsung and LG (or Alcatel) as seen in Latin America so far, or if the Nokia Asha Touch line becomes more popular instead. It will also be interesting to see if this happens with smart phone OS like Android or Windows Phone, or with souped up feature phones like S40, Bada, or other platforms. Indeed, Samsung’s higher end feature phone to make this list was its own un-named feature phone, rather than its more open, closer to a smart phone Bada OS.&lt;/p&gt;

&lt;p&gt;&lt;small&gt;The data I used to compile this post will be included in the following &lt;a href="https://docs.google.com/spreadsheet/ccc?key=0AgEv3x5hd8S3dGR4MmJQWmE4cV8tREhxaWFLUzNWb1E" target="_blank"&gt;Google spreadsheet&lt;/a&gt;.&lt;/small&gt;&lt;/p&gt;</description><link>http://generatedcontent.org/post/31441135779</link><guid>http://generatedcontent.org/post/31441135779</guid><pubDate>Wed, 12 Sep 2012 19:41:00 -0700</pubDate><category>mobile web</category><category>mobile</category><category>web</category></item><item><title>Montage and Ninja are here</title><description>&lt;p&gt;After leaving Opera last year, I hopped over the Atlantic to join Motorola Mobility in the Bay Area, to work on a top secret project. Many people asked &lt;q&gt;Why Motorola? and &lt;q&gt;What are you working on at a mobile company?&lt;/q&gt;. Well, finally, we &lt;a href="http://www.tetsubo.org" target="_blank"&gt;revealed our project to the world&lt;/a&gt; last week.&lt;/q&gt;&lt;/p&gt;

&lt;p&gt;&lt;!-- more --&gt;&lt;/p&gt;

&lt;p&gt;Motorola had put together a team of top engineers from companies such as Apple, Adobe, Nokia, Opera, and others. The team is also scattered with people you might recognise for their contributions to the Web community, such as &lt;a href="http://simurai.com" target="_blank"&gt;Simurai&lt;/a&gt;, &lt;a href="http://blog.tojicode.com" target="_blank"&gt;Brandon Jones&lt;/a&gt;, &lt;a href="http://askawizard.blogspot.com" target="_blank"&gt;Kris Kowal&lt;/a&gt;, &lt;a href="http://www.romancortes.com" target="_blank"&gt;Román Cortés&lt;/a&gt;, &lt;a href="http://www.oreillynet.com/pub/au/4542" target="_blank"&gt;Jon Reid&lt;/a&gt;, and more. If you’re a member of the Flex, Flash or WebObjects communities, you’ll also recognise a number of familiar faces.&lt;/p&gt;

&lt;p&gt;After a lot of hard work and much drinking of coffee, last week we released a MVC JavaScript framework called &lt;a href="http://tetsubo.org/home/montage/" target="_blank"&gt;Montage&lt;/a&gt;, and a visual authoring tool called &lt;a href="http://tetsubo.org/home/ninja/" target="_blank"&gt;Ninja&lt;/a&gt;. Both have been released for free under a BSD licence on &lt;a href="https://github.com/Motorola-Mobility" target="_blank"&gt;Github&lt;/a&gt;. we also released a number of smaller tools such as Screening, which is an automated testing tool (supporting WebDriver) for Montage apps. As a strong believer in eating our own dog food, both Ninja and Screening were built using Montage.&lt;/p&gt;

&lt;h2&gt;Montage framework&lt;/h2&gt;

&lt;p&gt;The Montage framework is designed with modern web technologies, such as ES5, HTML5, and CSS3.  As such we made the trade-off of jettisoning support for legacy browsers that do not support features such as object.create. The advantage is that we can remove the cruft and use a modern architecture. We will however support any browser that does support the standards we rely on. Montage is still work in progress, and as such browser support is improving as the framework matures.&lt;/p&gt;

&lt;p&gt;As well as the modern technologies built into the browser, we use various parts of &lt;a href="http://www.commonjs.org" target="_blank"&gt;CommonJS&lt;/a&gt; including Promises, Modules, and package.json.  We also take advantage of &lt;a href="http://nodejs.org" target="_blank"&gt;Node.JS&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;The main aim of Montage is to help developers be able to develop native quality applications using web technologies, as quickly and easily as possible. As such we support  components using HTML5 templates, &lt;a href="http://tetsubo.org/docs/montage/data-binding/" target="_blank"&gt;Two way data binding&lt;/a&gt; (to both objects and components) , &lt;a href="http://tetsubo.org/2012/03/recent-and-upcoming-changes-to-the-montage-serialization-format/" target="_blank"&gt;serialization&lt;/a&gt;, extended &lt;a href="http://tetsubo.org/docs/montage/event-handling/" target="_blank"&gt;event handling&lt;/a&gt;, an optimised &lt;a href="http://tetsubo.org/docs/montage/component-draw-cycle/" target="_blank"&gt;component draw cycle&lt;/a&gt; (for efficiently repainting when updating the DOM), &lt;a href="http://tetsubo.org/2012/05/keyboard-shortcuts-in-montage/" target="_blank"&gt;keyboard shortcut handling&lt;/a&gt;, &lt;a href="http://tetsubo.org/2012/04/gestures-in-montage/" target="_blank"&gt;gestures and composers&lt;/a&gt;, &lt;a href="http://tetsubo.org/2012/03/montage-converters/" target="_blank"&gt;data converters&lt;/a&gt;, and much more.&lt;/p&gt;

&lt;p&gt;I personally love how montage components use regular HTML, CSS, and JavaScript, so a designer can build the UI for an app or component using the technologies they likely already know, which the developer can then hook up to the controller and model layers. We use each technology for what it was designed for, rather than shoehorning everything into JavaScript. I also really love data bindings, as I can hook up a component to update the data in the model (or vice versa) or another component, without having to write any JavaScript in many cases. It just requires some configuration in the JSON serialisation file. Of course you can also use the JS API if you should so wish.&lt;/p&gt;

&lt;p&gt;While Montage is far from done, we have had the advantage of building a number of real world apps using Montage, such as Ninja, so we’ve been able to see what works and what needed improved or optimised. This has allowed us to rapidly improve the framework as we go. We’re really looking forward to having designers and developers in the community use Montage, and &lt;a href="http://tetsubo.org/forum/" target="_blank"&gt;collecting your feedback&lt;/a&gt;. As we’re &lt;a href="http://github.com/motorola-Mobility/montage" target="_blank"&gt;open source&lt;/a&gt;, we’d also love to see your bug reports, and maybe even a pull request or two. If you build anything using Montage, be sure to let us know!&lt;/p&gt;

&lt;h2&gt;Ninja authoring&lt;/h2&gt;

&lt;p&gt;The &lt;a href="http://tetsubo.org/home/ninja/" target="_blank"&gt;Ninja authoring tool&lt;/a&gt; is currently in alpha. It is packaged as a &lt;a href="https://chrome.google.com/webstore/detail/jjdndclgmfdgpiccmlamlicfjmkognne" target="_blank"&gt;Chrome extension&lt;/a&gt;. As I mentioned previously, it was written using the Montage framework.&lt;/p&gt;

&lt;p&gt;What really excites me about Ninja is that as a member of the SVG community, we were always hoping that a tool such as Flash would come out for SVG. There were plenty of great apps for creating static SVG, but not much for dynamic SVG. Now with Ninja we have a tool that is potentially as powerful as tools like Flash but for developing apps and pages using web standards rather than swf. If we do this right, we could have a revolutionary tool on our hands. And the team building Ninja is second to none in their experience building such tools.&lt;/p&gt;

&lt;p&gt;Ninja has a number of visual tools such as a pen, brush, canvas and WebGL drawing, 3D rotate and translate, colour panel, materials panel, animation, and so on, as well a code view, visual data binding, component panels, and a lot more.&lt;/p&gt;

&lt;p&gt;For a good overview of what Ninja is capable of, check out these &lt;a href="http://tetsubo.org/docs/ninja/videos/" target="_blank"&gt;Ninja videos&lt;/a&gt;, or see the &lt;a href="http://tetsubo.org/2012/07/ninja-v0-7-0-release-notes/" target="_blank"&gt;release notes&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;I expect that Ninja will be a great tool for designers moving to HTML from the Flash world, as well as those that want to be able to visually design their app or site, while still working in the browser and having access to the source. I look forward to seeing how you put the tool to use.&lt;/p&gt;

&lt;h2&gt;How you can get involved&lt;/h2&gt;

&lt;p&gt;Montage and Ninja are new and still under active development. We’d love to get your feedback on what’s hot and what’s not, and what can be improved. If you develop anything with their project then be sure to let us know. We have a &lt;a href="http://forums.tetsubo.org" target="_blank"&gt;forum&lt;/a&gt; on the Tetsubo site, and you can find the Montage team on IRC at &lt;a href="irc://chat.freenode.net/#montage" target="_blank"&gt;#montage&lt;/a&gt; on freenode.net. Feel free to &lt;a href="https://github.com/Motorola-Mobility/montage/issues?direction=desc&amp;amp;labels=&amp;amp;milestone=&amp;amp;sort=created&amp;amp;state=open" target="_blank"&gt;file bugs on GitHub&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;If you’d like to meet up in person, we’re having our first &lt;a href="http://www.meetup.com/Montage-Developers-of-Silicon-Valley/" target="_blank"&gt;Montage meetup&lt;/a&gt; in the Bay Area on 2nd August, organised by &lt;a href="http://lordbron.wordpress.com" target="_blank"&gt;Tom Ortega&lt;/a&gt;.&lt;/p&gt;</description><link>http://generatedcontent.org/post/27398344690</link><guid>http://generatedcontent.org/post/27398344690</guid><pubDate>Tue, 17 Jul 2012 01:56:00 -0700</pubDate><category>Ninja</category><category>Montage</category><category>HTML5</category><category>ES5</category><category>Framework</category><category>JavaScript</category><category>tool</category></item><item><title>Creating an angled split feature area with CSS transforms</title><description>&lt;p&gt;For an upcoming project I’m working on, I needed to have a feature area that showcased two things equally. The easy option would have been to show them in boxes, either side by side or one on top of the other. I decided instead to try my hand at a comic book look, where the cells are split diagonally. I also wanted to have a hover effect, so that each cell grew bigger or smaller depending on which cell was hovered.&lt;/p&gt;

&lt;p&gt;CSS has traditionally not been good at things that are not square (or rounded with &lt;code&gt;border-radius&lt;/code&gt;), but it is possible with minimal extra markup. I was speaking to &lt;a href="http://simurai.com" target="_blank"&gt;Simurai&lt;/a&gt; and he suggested using skew to skew the box, then skew the contents back again. That idea worked and formed the basis of the technique, along with a bunch of other fiddling.&lt;/p&gt;

&lt;p&gt;&lt;!-- more --&gt;&lt;/p&gt;

&lt;h2&gt;The final result&lt;/h2&gt;

&lt;p&gt;The &lt;a href="https://dl.dropbox.com/u/444684/splitfeature/index.html" target="_blank"&gt;final result&lt;/a&gt; looks like so:&lt;/p&gt;

&lt;p&gt;&lt;a href="https://dl.dropbox.com/u/444684/splitfeature/index.html" target="_blank"&gt;&lt;img src="http://media.tumblr.com/tumblr_m6kkveYECF1qmllqg.png" alt=""/&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;And when hovering the first box this happens:&lt;/p&gt;

&lt;p&gt;&lt;img src="http://media.tumblr.com/tumblr_m6kkwt6Xjl1qmllqg.png" alt=""/&gt;&lt;/p&gt;

&lt;p&gt;Conversely, hovering on the second box makes the first one smaller.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://dl.dropbox.com/u/444684/splitfeature/index.html" target="_blank"&gt;Try out the split feature demo&lt;/a&gt; to see it in action.&lt;/p&gt;

&lt;h2&gt;How it works&lt;/h2&gt;

&lt;p&gt;The main tricks are to place two divs (or elements of your choice) on top of each other. The first div requires a wrapper element, but the second does not. The wrapper is skewed at the angle you desire, and the child div is skewed back so that the content isn’t slanted. The child is then set to a width smaller that the first div and the overflow is hidden.&lt;/p&gt;

&lt;h3&gt;The HTML&lt;/h3&gt;

&lt;pre class="language-markup"&gt;&lt;code&gt;&amp;lt;div class="box sunrise"&amp;gt;&amp;lt;!-- contents --&amp;gt;&amp;lt;/div&amp;gt;
&amp;lt;div class="slider"&amp;gt;
    &amp;lt;div class="box sunset"&amp;gt;&amp;lt;!-- contents --&amp;gt;&amp;lt;/div&amp;gt;
&amp;lt;/div&amp;gt;&lt;/code&gt;&lt;/pre&gt;

&lt;h3&gt;The CSS&lt;/h3&gt;

&lt;p&gt;The two boxes are sized the same and decorated:&lt;/p&gt;

&lt;pre class="language-css"&gt;&lt;code&gt;.box { 
    width: 880px;
    height: 330px;
    border-radius: .5em;&lt;/code&gt;
}&lt;/pre&gt;

&lt;p&gt;The box with the sunrise image is set to use &lt;code&gt;position: absolute&lt;/code&gt; to remove it from the flow, so that the sunset box is placed on top of it. It is also styled with a &lt;code&gt;box-shadow&lt;/code&gt; and a background image.&lt;/p&gt;

&lt;pre class="language-css"&gt;&lt;code&gt;.sunrise {
    position: absolute;  /* remove from flow so sunset is placed on top */

    background:  url(sunrise.jpg) no-repeat;
    box-shadow: 0 0 10px rgba(0, 0, 0, .7);&lt;/code&gt;
}&lt;/pre&gt;

&lt;p&gt;The wrapper element around the sunset box is skewed by the required amount, and a transition is set up. An initial width is set and the overflow is hidden, so that only half the contents of the sunset div is shown.&lt;/p&gt;

&lt;pre class="language-css"&gt;&lt;code&gt;.slider {
    /* set initial width */
    width: 520px;
           
    /* hide the content that overflows (to allow second box to show through) */
   overflow: hidden;
   display: inline-block;
           
    /* skew container so that it has angled edge, and set up transition */
   transform: skewX(-20deg);
   transition: width 1.2s ease-in-out;&lt;/code&gt;
}&lt;/pre&gt;

&lt;p&gt;The sunset div is skewed back by the negation of the angle the parent was skewed, so the contents are straight rather than skewed at an angle. A background image is also set like the sunrise box. As the parent has a skew applied, we need to set a left margin to move the contents and the background image away from the left edge. Otherwise it will be clipped out by the hidden overflow.&lt;/p&gt;

&lt;pre class="language-css"&gt;&lt;code&gt;.sunset {
    /* skew back by negative of parent’s skew so contents is upright */
    transform: skewX(20deg);
    margin-left: 76px; /* give margin to push content away from left slanted edge */
   background: url(sunset-elephant.jpg) no-repeat;
   pointer-events: auto;    /* allow pointer events for the box */&lt;/code&gt;
}&lt;/pre&gt;

&lt;p&gt;Due to applying a left margin above, there will be a space on the left side. This can be removed by setting a negative left margin of the same value on the wrapper. We can also set &lt;code&gt;pointer-events&lt;/code&gt; to &lt;code&gt;none&lt;/code&gt; so that the hidden part  doesn’t cause the hover to fire. We also need to remember to set the pointer-events back on the sunset div, so the visible part can still be hovered (see above).&lt;/p&gt;

&lt;pre class="language-css"&gt;&lt;code&gt;.slider {
    …
    /* give negative margin to remove gap caused by left hand skew */
    margin-left: -76px;
           
   /* hide pointer events for unseen content */
   pointer-events: none;&lt;/code&gt;
}&lt;/pre&gt;

&lt;p&gt;Now all this is set up, the only thing left is to apply the hover. As the transitions have already been set up, we just need to change the width when hovering. As the second box (sunrise) is actually first in source order, we can use am adjacent sibling combinator to make the sunset div smaller when the sunrise div is hovered.&lt;/p&gt;

&lt;pre class="language-css"&gt;&lt;code&gt;/* make first box bigger on hover, and smaller when hover second box */
.slider:hover {
    width: 760px;
}
        
.sunrise:hover + .slider { 
    width: 250px;&lt;/code&gt;
}&lt;/pre&gt;

&lt;p&gt;That is more or less all there is to it. I’m sure there are probably ways with less markup or CSS, but this way works for what I need it for. The main drawbacks is the need for a wrapper div (can probably get away without it, depending on what content you have in the boxes) and the edge is not anti-aliased in the browsers I‘ve tested (Opera is particularly funky, but the strips make a unique effect).&lt;/p&gt;

&lt;p&gt;If you didn’t try it out before, &lt;a href="https://dl.dropbox.com/u/444684/splitfeature/index.html" target="_blank"&gt;check out the demo&lt;/a&gt;. Alternatively, &lt;a href="http://dabblet.com/gist/3038149" target="_blank"&gt;try out the demo and view the source on Dabblet&lt;/a&gt;.&lt;/p&gt;</description><link>http://generatedcontent.org/post/26407228072</link><guid>http://generatedcontent.org/post/26407228072</guid><pubDate>Tue, 03 Jul 2012 00:02:00 -0700</pubDate><category>css</category><category>transitions</category><category>transforms</category><category>skew</category><category>comic</category></item><item><title>box-sizing: border-box; the results are in</title><description>&lt;p&gt;A week has passed since I created &lt;a href="http://generatedcontent.org/post/25832131984/box-sizing" target="_blank"&gt;a poll on the use of &lt;code&gt;box-sizing: border-box&lt;/code&gt;&lt;/a&gt;. In that time 256 people filled out the &lt;a href="https://docs.google.com/spreadsheet/viewform?formkey=dE83R3I0Z29PaldPYm5nalEyU3dsNmc6MQ#gid=0" target="_blank"&gt;survey&lt;/a&gt;. The results so far are as follows:&lt;/p&gt;

&lt;p&gt;&lt;!-- more --&gt;&lt;/p&gt;

&lt;table&gt;&lt;thead&gt;&lt;tr&gt;&lt;th&gt;Use &lt;code&gt;box-sizing: border-box&lt;/code&gt;?&lt;/th&gt;
            &lt;th&gt;Yes&lt;/th&gt;
            &lt;th&gt;No&lt;/th&gt;
        &lt;/tr&gt;&lt;/thead&gt;&lt;tbody&gt;&lt;tr&gt;&lt;td&gt;Currently personal project&lt;/td&gt;
              &lt;td&gt;71%&lt;/td&gt;
              &lt;td&gt;29%&lt;/td&gt;
         &lt;/tr&gt;&lt;tr&gt;&lt;td&gt;Future personal project&lt;/td&gt;
              &lt;td&gt;88%&lt;/td&gt;
              &lt;td&gt;12%&lt;/td&gt;
         &lt;/tr&gt;&lt;tr&gt;&lt;td&gt;Future team project&lt;/td&gt;
              &lt;td&gt;85%&lt;/td&gt;
              &lt;td&gt;15%&lt;/td&gt;
         &lt;/tr&gt;&lt;tr&gt;&lt;td&gt;Future public project&lt;/td&gt;
              &lt;td&gt;60%&lt;/td&gt;
              &lt;td&gt;40%&lt;/td&gt;
         &lt;/tr&gt;&lt;/tbody&gt;&lt;/table&gt;&lt;p&gt;In the table above, a team project is one which the developers are known to the person making the decision, such as developers in the same company or a group of friends with which you can work closely. A public project is one which developers could be anyone that you may not be able to personally communicate the usage, such as an open source project or a public API.&lt;/p&gt;

&lt;p&gt;Although not a conclusive sample size, the signs are that developers are comfortable with and use (or are planning to use) the border box model, and are happy to use it in team projects. It surprises me a little how many developers actually already use it. The number of developers in favour of using the border box model in pubic project with potentially unknown developers drops, but is still 20% higher than those that wouldn’t. If these results signify anything, don’t be surprised if you see more projects spring up using the box model formally known as broken.&lt;/p&gt;

&lt;p&gt;Although developers are largely in favour of using &lt;code&gt;box-sizing: border-box&lt;/code&gt;, a sizeable number have mentioned that they’d only use it where needed, rather than blanket applying it across the whole document with the universal selector. A few mentioned it can break jQuery plug-ins, so that may limit adoption on jQuery-based sites. While a few others mentioned they would use it if its use was documented, such as with &lt;a href="http://warpspire.com/kss/" target="_blank"&gt;KSS comments&lt;/a&gt; (always a good practice when working with teams, or even solo projects if you’re going to have to maintain your code).&lt;/p&gt;

&lt;p&gt;I will leave the &lt;a href="https://docs.google.com/spreadsheet/viewform?formkey=dE83R3I0Z29PaldPYm5nalEyU3dsNmc6MQ#gid=0" target="_blank"&gt;poll open&lt;/a&gt; for now, in the hope of collecting a larger sample. As the results have largely stayed 60–40 in favour of the old IE box model throughout the life of the poll, I don’t expect the result to change significantly however.&lt;/p&gt;</description><link>http://generatedcontent.org/post/26334712021</link><guid>http://generatedcontent.org/post/26334712021</guid><pubDate>Mon, 02 Jul 2012 00:29:00 -0700</pubDate><category>box-sizing</category><category>poll</category><category>css</category></item><item><title>Sizing Boxes (Back to the Future)</title><description>&lt;p&gt;The way we are building web sites is fundamentally changing. The XHTML (&lt;code&gt;Strict&lt;/code&gt; if we took pride in our work) has given way to the more loose HTML5. Image slicing and dicing, and wrapper divs are starting to be replaced with lean (perhaps semantic if we’re lucky) HTML and CSS3 effects such as &lt;code&gt;border-radius&lt;/code&gt;, &lt;code&gt;box-shadow&lt;/code&gt; and gradients. Elastic layouts have metamorphosed into responsive design with Media Queries. JavaScript–no longer considered a toy–has earned its place at the table, forming a triumvirate with HTML and CSS. We may be at the cusp of a real tool for layout with flexbox. Perhaps even the venerable &lt;code&gt;em&lt;/code&gt; unit will fall out of favour, replaced with the more predictable &lt;a href="http://generatedcontent.org/post/11933972962/css3values" target="_blank"&gt;&lt;code&gt;rem&lt;/code&gt;&lt;/a&gt;, and &lt;a href="http://generatedcontent.org/post/21279324555/viewportunits" target="_blank"&gt;flexible &lt;code&gt;vh&lt;/code&gt; and &lt;code&gt;vw&lt;/code&gt; units&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;&lt;!-- more --&gt;&lt;/p&gt;

&lt;p&gt;As we stand in the foothills of the third major era of the open web (the age of tables and spacer gifs now all but a distant memory), our tools and processes are even growing up to start to resemble those of traditional programmers, with &lt;a href="http://rmurphey.com/blog/2012/04/12/a-baseline-for-front-end-developers/" target="_blank"&gt;build scripts, preprocessors, linters (squint and it could resemble a compiler), automated testing, and version control&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;But, it is something a bit more humble that I want to talk about today, which may also change how we write sites in its own little way. That is the &lt;a href="http://www.w3.org/TR/css3-ui/#box-sizing0" target="_blank"&gt;CSS &lt;code&gt;box-sizing&lt;/code&gt; property&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;Those of you who were around in the bad old days with remember the broken box model that IE used, rather than the standard W3C model. In this model the &lt;code&gt;border&lt;/code&gt; and &lt;code&gt;padding&lt;/code&gt; were counted as part of the &lt;code&gt;width&lt;/code&gt; and &lt;code&gt;height&lt;/code&gt; of the box. While in the W3C model the &lt;code&gt;padding&lt;/code&gt; and &lt;code&gt;border&lt;/code&gt; were added to the &lt;code&gt;width&lt;/code&gt; and &lt;code&gt;height&lt;/code&gt; to get the final dimensions of the box. In the IE model the &lt;code&gt;width&lt;/code&gt; represented the total width of the box, while in the W3C model it represented the width of the content box (that is the box that contains the content of the element). To get IE to play nice, we had to use &lt;a href="http://tantek.com/CSS/Examples/boxmodelhack.html" target="_blank"&gt;Tantek’s box model hack&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;The CSS &lt;code&gt;box-sizing&lt;/code&gt; property has existed for quite some time, and gives us a way to switch between the standard model (with box-sizing: content-box) and the old IE model (box-sizing: border-box). There has been a spark of interest recently in using this oft forgotten property, caused by Paul Irish’s &lt;a href="http://paulirish.com/2012/box-sizing-border-box-ftw/" target="_blank"&gt;* { box-sizing: border-box } FTW&lt;/a&gt;.&lt;/p&gt;

&lt;h2&gt;Time to switch to border-box?&lt;/h2&gt;

&lt;p&gt;If you want to get right to the action then please spend a few moments to take my &lt;a href="https://docs.google.com/spreadsheet/viewform?formkey=dE83R3I0Z29PaldPYm5nalEyU3dsNmc6MQ#gid=0" target="_blank"&gt;poll on box-sizing&lt;/a&gt;, otherwise read on.&lt;/p&gt;

&lt;p&gt;The standard will never switch to using &lt;code&gt;border-box&lt;/code&gt; by default, as too much content would break, but is it time to switch to using this for all elements in our own projects using the universal selector, as Paul advocates? Its something I’ve been giving a bit of thought to recently.&lt;/p&gt;

&lt;p&gt;If it was just for my own personal projects, or on projects with a small team where I know the developers and can communicate it clearly, I think I would plump for it. But for use in a style guide meant to be used by many developers, and open source project, or demos that might be seen by many people I’ve never even interacted with, I’m still on the fence.&lt;/p&gt;

&lt;h2&gt;The pros and cons&lt;/h2&gt;

&lt;p&gt;There are certainly a number of well known developers in the pro camp. Paul Irish is certainly a fan. He sums up the frustration with the current model: &lt;q&gt;Ugh. If I say the width is 200px, gosh darn it, it’s gonna be a 200px wide box even if I have 20px of padding.&lt;/q&gt; &lt;a href="http://blog.joelambert.co.uk" target="_blank"&gt;Joe Lambert&lt;/a&gt; says &lt;a href="http://paulirish.com/2012/box-sizing-border-box-ftw/#comment-111776%0A" target="_blank"&gt;&lt;q&gt;I’m a big fan of this technique and have been using it in a number of mobile web apps (and increasingly) website projects&lt;/q&gt;&lt;/a&gt;. &lt;a href="http://adactio.com" target="_blank"&gt;Jeremy Keith&lt;/a&gt; simply calls it &lt;a href="http://paulirish.com/2012/box-sizing-border-box-ftw/#comment-111784" target="_blank"&gt;&lt;q&gt;the bee’s knees&lt;/q&gt;&lt;/a&gt;. While &lt;a href="https://twitter.com/#!/stefsull" target="_blank"&gt;Stephanie Rewis&lt;/a&gt; wonders if &lt;a href="http://paulirish.com/2012/box-sizing-border-box-ftw/#comment-111772" target="_blank"&gt;&lt;q&gt;we should have lobbied the W3C to change their box model instead. I hear this frustration from devs all the time.&lt;/q&gt;&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;&lt;a href="http://tjkdesign.com" target="_blank"&gt;Thierry Koblentz&lt;/a&gt; however has a word of caution:&lt;/p&gt;

&lt;blockquote&gt;&lt;q&gt;Regarding what we used to call the “broken box model”, I think the issue is that you do not own the content box and any change in border or padding impacts that content area. I understand that it can be easier for people to style boxes that way, but it’s not a magic wand, you end up dealing with different issues.&lt;/q&gt;&lt;/blockquote&gt;

&lt;p&gt;&lt;a href="http://weblogs.mozillazine.org/bz/" target="_blank"&gt;Boris Zbarsky&lt;/a&gt; of Mozilla claims &lt;a href="https://bugzilla.mozilla.org/show_bug.cgi?id=243412#c21" target="_blank"&gt;&lt;q&gt;it [the spec] doesn’t define how it should work in enough detail that it can be implemented, leaving that to CSS3 Box, as far as I can tell…&lt;/q&gt;&lt;/a&gt;, while &lt;a href="http://dbaron.org" target="_blank"&gt;David Baron&lt;/a&gt; (also of Mozilla, and the CSS WG) states &lt;a href="https://bugzilla.mozilla.org/show_bug.cgi?id=308801#c31" target="_blank"&gt;&lt;q&gt;box-sizing is a poorly-designed feature that’s frankly intended only for backwards-compatibility with quirks mode.&lt;/q&gt;&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;The pros and cons as I see it are the following:&lt;/p&gt;

&lt;h3&gt;Pros&lt;/h3&gt;

&lt;ul&gt;&lt;li&gt;The size of an element is far easier to calculate. It is the size I tell it to be, no matter what I set the border or margin to be.&lt;/li&gt;
    &lt;li&gt;We can use percentage based widths in a fluid design while still using &lt;code&gt;em&lt;/code&gt;s or px for padding. With the traditional model we would need &lt;code&gt;calc&lt;/code&gt; to solve this problem. See Chris Coyier’s excellent &lt;a href="http://css-tricks.com/box-sizing/" target="_blank"&gt;box-sizing post&lt;/a&gt; for an explanation of the issue.&lt;/li&gt;
    &lt;li&gt;If you have grey hair from all those days developing for IE, you already know how to use it.&lt;/li&gt;
&lt;/ul&gt;&lt;h3&gt;Cons&lt;/h3&gt;

&lt;ul&gt;&lt;li&gt;If you need to support IE7 and below it is a no go, unless you want to use a polyfill, or put IE into quirks mode (not a good idea). Firefox also still needs a prefix, and you’ll need the -webkit- prefix if you care about relatively modern versions of WebKit. See &lt;a href="http://caniuse.com/#search=box-sizing" target="_blank"&gt;browser support&lt;/a&gt;.&lt;/li&gt;
    &lt;li&gt;Firefox’s behaviour is still buggy, especially around &lt;a href="https://bugzilla.mozilla.org/show_bug.cgi?id=308801" target="_blank"&gt;interactions with min- and max-width/height&lt;/a&gt;.&lt;/li&gt;
    &lt;li&gt;You lose control over the dimensions of the content box, which can lead to unpredictabilities you didn’t have to deal with before. For example, what happens if the padding is the same size or greater than the width or hight (cue frantic visits to the spec to check for the correct answer)?&lt;/li&gt;
     &lt;li&gt;Perhaps the biggest issue for me is author expectation. If I use &lt;code&gt;* { box-sizing: border-box; }&lt;/code&gt; on code that has to be used and extended by other developers, they will more often than not expect the W3C box model, and their own styles will not behave as desired. Furthermore, if they are a new developer, they might not be familiar with the IE box model at all, requiring further reading to get started even after figuring out the cause.&lt;/li&gt;
&lt;/ul&gt;&lt;h2&gt;What do you think?&lt;/h2&gt;

&lt;p&gt;With all that being said, and plenty of other reasons in either camp that I’m sure you can come up with, what are your thoughts? If you were working on a project where other developers would need to work with your code, would you use &lt;code&gt;box-sizing: border-box&lt;/code&gt;? I’ve created a poll so that you can let me know, and when the results are in, I’ll report back with what the crowd voted.&lt;/p&gt;

&lt;p&gt;&lt;a href="https://docs.google.com/spreadsheet/viewform?formkey=dE83R3I0Z29PaldPYm5nalEyU3dsNmc6MQ#gid=0" target="_blank"&gt;Take the box-sizing poll now!&lt;/a&gt;&lt;/p&gt;</description><link>http://generatedcontent.org/post/25832131984</link><guid>http://generatedcontent.org/post/25832131984</guid><pubDate>Sun, 24 Jun 2012 21:16:00 -0700</pubDate><category>box-sizing</category><category>css</category><category>box model</category></item><item><title>Responsive viewport units (vw, vh, and vmin)</title><description>&lt;p&gt;With all this new fangled talk of &lt;a href="http://en.wikipedia.org/wiki/Responsive_Web_Design" target="_blank"&gt;responsive web design&lt;/a&gt;, its about time that we had a poster child CSS unit to go with it. So move over &lt;code&gt;em&lt;/code&gt;, CSS3 Values and Units introduces a bunch of new &lt;a href="http://www.w3.org/TR/css3-values/#viewport-relative-lengths" target="_blank"&gt;viewport units&lt;/a&gt; that are getting ready for their time in the limelight.&lt;/p&gt;

&lt;p&gt;&lt;!-- more --&gt;&lt;/p&gt;

&lt;p&gt;Motorola recently implemented support for these viewport length units and they’ve now found their way into Chrome Canary, so we can now start to experiment with them. They are also supported in IE9, although the &lt;code&gt;vm&lt;/code&gt; unit has been updated to &lt;code&gt;vmin&lt;/code&gt; since then.&lt;/p&gt;

&lt;h2&gt;Introducing vh, vw, and vmin&lt;/h2&gt;

&lt;p&gt;The &lt;a href="http://www.w3.org/TR/css3-values/#vh-unit" target="_blank"&gt;&lt;code&gt;vh&lt;/code&gt; unit&lt;/a&gt; stands for viewport height, &lt;a href="http://www.w3.org/TR/css3-values/#vw-unit" target="_blank"&gt;&lt;code&gt;vw&lt;/code&gt;&lt;/a&gt; for &lt;del&gt;Volkswagen&lt;/del&gt; viewport width, and &lt;a href="http://www.w3.org/TR/css3-values/#vmin-unit" target="_blank"&gt;&lt;code&gt;vmin&lt;/code&gt;&lt;/a&gt; represents whichever of &lt;code&gt;vh&lt;/code&gt; or &lt;code&gt;vw&lt;/code&gt; is the shortest length.&lt;/p&gt;

&lt;p&gt;The values used can be somewhat confusing if you’ve not used these units before, as &lt;code&gt;1vh&lt;/code&gt; represents 1% of the current viewport (the content area of the browser window) height, rather than 100% as you may expect. Therefore if you want an element to be the full height of your viewport you should set it to &lt;code&gt;100vh&lt;/code&gt;. As you would expect, &lt;code&gt;vw&lt;/code&gt; works exactly the same way as &lt;code&gt;vh&lt;/code&gt; units.&lt;/p&gt;

&lt;p&gt;If you have a widescreen monitor and your browser window is set to full screen, the width would be wider than the height. In this case the &lt;code&gt;vmin&lt;/code&gt; unit would be the same as the &lt;code&gt;vh&lt;/code&gt; unit.&lt;/p&gt;

&lt;p&gt;The viewport units are dynamic rather than static, so if you resize the browser window, the computed value of the units will also change. If for example your browser window is 1000px wide, and element with a width of &lt;code&gt;10vw&lt;/code&gt; would be 100px wide. If you shrink the browser window to only 100px wide, the width of the element would resize with it to 10px wide.&lt;/p&gt;

&lt;h2&gt;A responsive example&lt;/h2&gt;

&lt;p&gt;One of the big issues with using multi-column layout is that you need to endlessly scroll up and down the page to read each column if the height is taller than the viewport. The viewport units mitigate this somewhat, as you can set the hight of the element with multi-column applied to it to be smaller than the viewport height (but remember to take the margins into account). You still have the issue of horizontal scrolling if you restrict the height, but this may be an ok solution if you’re designing for something like a tablet device.&lt;/p&gt;

&lt;p&gt;I’ve created a quick example that uses this technique. Go and check out my &lt;a href="http://dl.dropbox.com/u/444684/text/multi-column-viewport.html" target="_blank"&gt;multi-column responsive viewport example&lt;/a&gt; in Chrome Canary to see it in action. It should look something like the following screenshot:&lt;/p&gt;

&lt;p&gt;&lt;img src="http://media.tumblr.com/tumblr_m2n1gaECpj1qmllqg.png" alt=""/&gt;&lt;/p&gt;

&lt;p&gt;As the scrollbar is hidden by default in Mac OS X Lion, its a bit difficult in this example to see that the text is scrollable horizontally.&lt;/p&gt;

&lt;p&gt;Setting the width and height to respond to the viewport size is trivial with the &lt;code&gt;vh&lt;/code&gt; and &lt;code&gt;vw&lt;/code&gt; units:&lt;/p&gt;

&lt;pre&gt;&lt;code class="language-css"&gt;article &amp;gt; section {
    column-width: 22rem;
    column-gap: 2.6rem;
                
    height: 80vh;
    width: 80vw;
        
    overflow: scroll;
}&lt;/code&gt;
&lt;/pre&gt;

&lt;p&gt;This sets the height to be 80% of the viewport height, and the width to be 80% of the viewport width.  The width of each column is set to be ideally 22rem (220px in this case) wide, but the browser can adjust this as needed. Finally &lt;code&gt;overflow&lt;/code&gt; is set to &lt;code&gt;scroll&lt;/code&gt; so that additional columns are hidden and can be scrolled into view, rather than overflowing to the right, and potentially overlapping any element that we place there.&lt;/p&gt;

&lt;p&gt;I also set some margins on the body element to give some breathing space. This also scale with the viewport size, to be 2% of the viewport height top and bottom, and 10% of the width left and right:&lt;/p&gt;

&lt;pre&gt;&lt;code class="language-css"&gt;body {
    margin: 2vh 10vw;
}&lt;/code&gt;
&lt;/pre&gt;

&lt;p&gt;With this, you have a truly responsive design (at least with a simple example such as this), without even touching media queries. Imagine what untold powers they will bestow on you when you combine them? Add Flexbox to the mix, and we’ll really be cooking on gas.&lt;/p&gt;</description><link>http://generatedcontent.org/post/21279324555</link><guid>http://generatedcontent.org/post/21279324555</guid><pubDate>Tue, 17 Apr 2012 12:36:00 -0700</pubDate><category>responsive</category><category>viewport</category><category>multi-column</category></item><item><title>What’s new in CSS3 Values and Units?</title><description>&lt;p&gt;In CSS3 the values and units we can use in CSS properties are defined in the appropriately named &lt;a href="http://dev.w3.org/csswg/css3-values/" target="_blank"&gt;CSS Values and Units&lt;/a&gt; specification, with the exception those relating to colour and images, and the pre-defined keywords specific to individual properties.&lt;/p&gt;

&lt;p&gt;This spec gives us one new CSS wide keyword to play with (the &lt;code&gt;initial&lt;/code&gt; keyword), five new relative units for lengths, five new functional notations, and various new types and units to support new CSS3 modules such as Grid and Flexbox layout, Transitions, and Transforms.&lt;/p&gt;

&lt;p&gt;&lt;!-- more --&gt;&lt;/p&gt;

&lt;h2&gt;CSS-wide initial keyword&lt;/h2&gt;

&lt;p&gt;CSS2.1 added the first CSS-wide keyword to every property with the &lt;code&gt;inherit&lt;/code&gt; keyword. CSS3 adds to this with the &lt;code&gt;initial&lt;/code&gt; keyword. When you set a property’s value to &lt;code&gt;initial&lt;/code&gt; it will set the value to what is defined as the initial value in the CSS specification for that property. Note that this is sometimes, but not always the same as the default value set in the user-agent style sheet. For example the initial value for various margin and padding properties is 0, but the default value given by the user-agent depends on the element to which it applies.&lt;/p&gt;

&lt;p&gt;The &lt;code&gt;initial&lt;/code&gt; keyword can be useful if an element is inheriting unwanted styles and the original styling is desired. It is probably not something you will need to use often, but it is a useful tool to have on occasions. This is currently only supported by WebKit and Firefox (with moz prefix: &lt;code&gt;-moz-intitial&lt;/code&gt;).&lt;/p&gt;

&lt;p&gt;Take a look at the &lt;a href="http://dl.dropbox.com/u/444684/initial.html" target="_blank"&gt;&lt;code&gt;initial&lt;/code&gt; keyword demo&lt;/a&gt; I prepared to see this in action. This currently requires a Gecko or WebKit browser at the time of writing.&lt;/p&gt;

&lt;h2&gt;Font relative length units&lt;/h2&gt;

&lt;h3&gt;The rem unit&lt;/h3&gt;

&lt;p&gt;The &lt;code&gt;rem&lt;/code&gt; unit is perhaps my favourite new part of CSS3 Values. It stands for root em, and if you already understand how &lt;code&gt;em&lt;/code&gt;s work (I assume that is most of you?) then you’ll be right at home. They are only subtly different, but it makes them easier to work with.&lt;/p&gt;

&lt;p&gt;The root part of the name refers to the root element, or the &lt;code&gt;html&lt;/code&gt; element in HTML and the initial &lt;code&gt;svg&lt;/code&gt; element in SVG. With regular &lt;code&gt;em&lt;/code&gt;s the size of &lt;code&gt;1em&lt;/code&gt; is set to value of the &lt;code&gt;font-size&lt;/code&gt; property of the current element, or the size of the parent element’s text size when used with the &lt;code&gt;font-size&lt;/code&gt; property itself. The font size varies from element to element, so the size of an &lt;code&gt;em&lt;/code&gt; is not consistent across the document. This requires a lot of calculation when you are tying to line elements up or are tying to &lt;a href="http://24ways.org/2006/compose-to-a-vertical-rhythm" target="_blank"&gt;compose text to a vertical rhythm&lt;/a&gt;.&lt;/p&gt;

&lt;p&gt;The &lt;code&gt;rem&lt;/code&gt; value however stays consistent across the document, as &lt;code&gt;1rem&lt;/code&gt; is always the same size as the &lt;code&gt;font-size&lt;/code&gt; of the &lt;code&gt;html&lt;/code&gt; element (or root of which ever language you are using). If you want a margin to be a certain length, you just need to calculate it once for any element. If you want to make the maths as easy as possible you can set the html element to have a &lt;code&gt;font-size&lt;/code&gt; of &lt;code&gt;10px&lt;/code&gt; (or another multiple of 10), then set the desired body copy size on the &lt;code&gt;body&lt;/code&gt; element, such as &lt;code&gt;font-size: 1.2rem&lt;/code&gt; for 12px. Now you get the scalability benefits of &lt;code&gt;em&lt;/code&gt;s along with the ease of use and predictability of &lt;code&gt;px&lt;/code&gt;s.&lt;/p&gt;

&lt;p&gt;The only downside is the browser support.  Its supported in IE9, Firefox 3.6+, Safari 5+ and Chrome. It is also coming to Opera 12, which should hopefully be released soon. As Opera users generally upgrade fast, and Firefox &amp;lt;3.6 is only around 1% market share, your only real issue in the near feature will be those users stuck on IE6–8. Using a fallback is easy if you set the root font size to 10px, as you can set every size you set in rems to the equivalent px size. For example 2rem is 20px, 1.7rem is 17px, and so on. It adds a lot more page weight however.&lt;/p&gt;

&lt;p&gt;I’ve prepared a &lt;a href="http://dl.dropbox.com/u/444684/rem-example.html" target="_blank"&gt;rem unit demo&lt;/a&gt; which shows how you can follow a vertical rhythm using this unit.&lt;/p&gt;

&lt;h3&gt;The ch unit&lt;/h3&gt;

&lt;p&gt;The &lt;code&gt;ch&lt;/code&gt; unit is equal to the width of the &lt;q&gt;0&lt;/q&gt; (zero) glyph in the font used by the current element. This is mostly useful when using monospace fonts, where all glyphs are the same width. For example, if you have a &lt;code&gt;pre&lt;/code&gt; element where you want it to wrap after a 55 of characters, you can use &lt;code&gt;width: 55ch;&lt;/code&gt; unit.&lt;/p&gt;

&lt;p&gt;This unit is currently only supported by Internet Explorer 9 and Firefox.&lt;/p&gt;

&lt;h2&gt;Viewport relative lengths&lt;/h2&gt;

&lt;p&gt;There are three viewport relative lengths: &lt;code&gt;vh&lt;/code&gt;, &lt;code&gt;vw&lt;/code&gt;, and &lt;code&gt;vm&lt;/code&gt;. These are relative to the size of the initial containing block, or in other words the viewport. If you resize the viewport, such as changing the size of the browser window, then the size of elements specified in these units will change.&lt;/p&gt;

&lt;h3&gt;The vw unit&lt;/h3&gt;

&lt;p&gt;This is relative to the width of the viewport. One &lt;code&gt;vw&lt;/code&gt; unit is 100&lt;sup&gt;th&lt;/sup&gt; of the width of the viewport. If the viewport is 1000 pixels wide then &lt;code&gt;10vw&lt;/code&gt; would map to 100px.&lt;/p&gt;

&lt;h3&gt;The vh unit&lt;/h3&gt;

&lt;p&gt;The &lt;code&gt;vh&lt;/code&gt; unit works the same way as &lt;code&gt;vw&lt;/code&gt;, but is relative to the height of the viewport instead.&lt;/p&gt;

&lt;h3&gt;The vm unit&lt;/h3&gt;

&lt;p&gt;The &lt;code&gt; vm&lt;/code&gt; unit maps to whichever of the viewport width or hight is the smallest. There is some talk of dropping this as the same can be achieved using the &lt;code&gt;min()&lt;/code&gt; functional notation.&lt;/p&gt;

&lt;p&gt;These new units can be very useful if you don’t want something to end up larger than the viewport. One use case I’ve had for these is while using multi-column layout. You often don’t want text using multi-column to be taller than the screen size as the user will have to scroll up and down for each column. With &lt;code&gt;vh&lt;/code&gt; you could use for example &lt;code&gt;height: 95vh&lt;/code&gt; which would make it 95% of the height of the viewport, no matter how tall the viewport is. You could also imagine them being useful for things like slide shows, video players, and mobile.&lt;/p&gt;

&lt;p&gt;You might think these units sound great, but unfortunately they currently only work in IE9 and above, so it will be some time before we can used them.&lt;/p&gt;

&lt;h2&gt;The rest&lt;/h2&gt;

&lt;p&gt;There are new units for angles (&lt;code&gt;deg&lt;/code&gt;, &lt;code&gt;grad&lt;/code&gt;, &lt;code&gt;rad&lt;/code&gt;, and &lt;code&gt;turn&lt;/code&gt; units) and times (&lt;code&gt;s&lt;/code&gt;, &lt;code&gt;ms&lt;/code&gt; units. These are used in CSS3 2D/3D Transforms, and CSS Transitions respectively. There are also new units for frequencies (&lt;code&gt;Hz&lt;/code&gt;, &lt;code&gt;kHz&lt;/code&gt; units). These are used in the CSS3 Speech module.&lt;/p&gt;

&lt;p&gt;There are new layout specific units: fractions using the &lt;code&gt;fr&lt;/code&gt; unit, and grid units using the &lt;code&gt;gr&lt;/code&gt; unit.&lt;/p&gt;

&lt;p&gt;It doesn’t make too much sense covering these, without coving the full spec for which they are used, so I will leave them for a later date. There are also five functional notations, which require in-depth explanation, so they deserve their own post. I will cover these in the near future. These are mathematical expressions (&lt;code&gt;calc()&lt;/code&gt;, &lt;code&gt;min()&lt;/code&gt; and &lt;code&gt;max()&lt;/code&gt;), cycling values (&lt;code&gt;cycle()&lt;/code&gt;), and attribute references (&lt;code&gt;attr()&lt;/code&gt;).&lt;/p&gt;

&lt;p&gt;I hope you find some useful ways to use these new values and units that we now have to play with.&lt;/p&gt;</description><link>http://generatedcontent.org/post/11933972962</link><guid>http://generatedcontent.org/post/11933972962</guid><pubDate>Tue, 25 Oct 2011 19:09:00 -0700</pubDate><category>css3</category><category>values and units</category><category>typography</category><category>calc</category></item><item><title>What’s new in Android 4.0 for Web Developers?</title><description>&lt;p&gt;&lt;img src="http://www.google.com/nexus/img/content/introduction.png"/&gt;&lt;/p&gt;

&lt;p&gt;Google recently announced the &lt;a href="http://developer.android.com/sdk/android-4.0.html" target="_blank"&gt;Ice Cream Sandwich&lt;/a&gt; version of Android, along with a new version of the WebKit-based browser. Lets have a look at what is in there that’s of interest for web developers.&lt;/p&gt;

&lt;p&gt;&lt;!-- more --&gt;&lt;/p&gt;

&lt;h2&gt;User agent switching, or a knock to the mobile specific site?&lt;/h2&gt;

&lt;p&gt;When I was working with web site compatibility at Opera, one of the biggest complaints we got time and time again was when a popular site switched to giving the mobile version of the site rather than the desktop version. Despite perceived wisdom from developers that users are in the mobile context and want mobile optimised sites, the reality is users screamed blue murder. Especially when the site gave no option to switch back. The reasons were usually two fold. One: many users knew their way around the site and where they had to go (even when they only accessed the web on a mobile device) and two: often they wanted to use a feature that the developers had decided the mobile version didn’t need. Many of these users couldn’t just wait until they were on a desktop PC to use those features as their only way to access the web was through a mobile (think rural China, India or the Philippines for example).&lt;/p&gt;

&lt;p&gt;One perfect example was GMail. If you tried to sign up for an account (no one does that on mobile right?) it would say something like &lt;q&gt;sign up for an account on a PC&lt;/q&gt;. These users were completely locked out of the site with no way to get an account.&lt;/p&gt;

&lt;p&gt;I suspect Google has been getting the same complaints Opera was getting, especially as Android is starting to become popular in developing countries. For the Android 4 browser, they have added a way to switch to the desktop site on a per tab basis:&lt;/p&gt;

&lt;blockquote&gt;
To get the most out of web content, users can now request full desktop versions of web sites, rather than their mobile versions. Users can set their preference for web sites separately for each browser tab.
&lt;/blockquote&gt;

&lt;p&gt;If I’d hazard a guess about how they do this, then it would be that they switch the user agent string to that of a desktop browser such as Chrome. That way the site developer will think it is a desktop browser and will give the desktop site. If they cloak well enough, there will be no way for the developer to force users into using the mobile site. I think this is a good thing, as it will open up choice to the user, and force developers to think about making their regular sites as friendly as possible. This is exactly what &lt;a href="http://www.netmagazine.com/features/mobile-first" target="_blank"&gt;the mobile first&lt;/a&gt; brigade have been preaching. I suspect things like Media Queries will still work as expected in desktop mode. It will certainly put a dent in the firearms of those that want to browser sniff to give (or try to give. It always goes wrong. I’ve lost count of the amount of issues I had to deal with related to sever side browser sniffing for mobile browsers going wrong, across almost every major site) a tailored experience to mobile devices.&lt;/p&gt;

&lt;p&gt;So to recap, to guarantee a good experience on Android, you will need to make sure both your mobile site and your desktop site is mobile friendly. Or use one site and adapt via things like media queries.&lt;/p&gt;

&lt;h2&gt;Roboto, a new high DPI optimised font&lt;/h2&gt;

&lt;p&gt;Times change fast on mobile. Back when Android was first released, Google worked with Ascender Corp to produce the &lt;a href="http://www.droidfonts.com/" target="_blank"&gt;Droid family of fonts&lt;/a&gt;. One of the main design goals was to produce a font that worked well at small sizes on the restricted resolutions of mobile devices at the time. Thus, the letterforms were condensed to fit as maximise how much text could fit on screen.&lt;/p&gt;

&lt;p&gt;Fast forward to today and mobiles are ever increasing in both DPI and screen real estate (Galaxy Nexus has a 4.65 inch display at 330ppi!), and mobile platforms have expanded to tablets. With these new circumstances, Google has developed a new font in house by  &lt;a href="http://betatype.com/" target="_blank"&gt;Christian Robertson&lt;/a&gt; called Roboto.&lt;/p&gt;

&lt;p&gt;&lt;img src="http://media.tumblr.com/tumblr_lte188C0vP1qmllqg.png" alt=""/&gt;&lt;/p&gt;

&lt;p&gt;The font has been created from scratch for high DPI screens. It is a geometric font, somewhat reminiscent of Helvetica. As it is the default font, this is the font your site will be using unless you specify otherwise. You should be able to use it where you use arial or helvetica today without any problems. As it is included in an open source product, it will assumably be available to download freely, just like Google allowed with the &lt;a href="http://www.google.com/webfonts/specimen/Droid+Serif" target="_blank"&gt;Droid family&lt;/a&gt;. Be careful if you were planning to use it on desktop platforms however. In a comment &lt;a href="http://typographica.org/2011/on-typography/roboto-typeface-is-a-four-headed-frankenstein/" target="_blank"&gt;in defence of the font&lt;/a&gt;, Robertson stated:&lt;/p&gt;

&lt;blockquote&gt;
since Android doesn’t use much of the nastiness that is TrueType hinting, Roboto is not hinted to support older Windows browsers, for example.
&lt;/blockquote&gt;

&lt;p&gt;He mentions a few of the design choices in that post, and it is will worth a read. It remains to be seen whether the font gets accepted in the design community, and we will have to see it in its native environment, but I personally feel the UI looks much more fresher with it. I’m unsure of the Droid family, or any other fonts are also available for developers. I expect there should be at least one serif font, but you never know.&lt;/p&gt;

&lt;h2&gt;WebKit enhancements&lt;/h2&gt;

&lt;p&gt;One of the key things for web developers is the capabilities of the web browser. The Android browser has always lagged its desktop cousin, and was stating to get a bit of a bad reputation with web developers. Although they haven’t switched to Chrome (yet) in Android, we do get a new version of WebKit. The official docs report that this is &lt;a href="http://developer.android.com/sdk/android-4.0.html" target="_blank"&gt;WebKit 534.30&lt;/a&gt;. By comparing UA strings, it looks like this is the same version used by Chrome 12. However, just because the desktop version supports a feature, it doesn’t mean the code path was enabled on the Android branch of WebKit, or any porting work was done to expose a feature to the browsers.&lt;/p&gt;

&lt;h3&gt;Performance improvements&lt;/h3&gt;

&lt;p&gt;The Android team has upgraded to a newer version of V8 with crankshaft support. According to the &lt;a href="http://googlesystem.blogspot.com/2011/10/android-ice-cream-sandwich.html" target="_blank"&gt;Unofficial Google system blog&lt;/a&gt; &lt;q&gt;in benchmarks run on a Nexus S device, the Android 4.0 browser showed an improvement of nearly 220% over the Android 2.3 browser in the V8 Benchmark Suite and more than 35% in the SunSpider 9.1 JavaScript Benchmark. That’s not too shabby.&lt;/q&gt;&lt;/p&gt;

&lt;h3&gt;New on phones&lt;/h3&gt;

&lt;p&gt;While tablets have been running Honeycomb, phones have been stuck on Gingerbread. If you’re developing towards phones, then all the features added to Honeycomb will be available to you for the first time. Highlights include:&lt;/p&gt;

&lt;ul&gt;&lt;li&gt;&lt;a href="http://www.w3.org/Graphics/SVG/" target="_blank"&gt;SVG&lt;/a&gt; (Finally!)&lt;/li&gt;
&lt;li&gt;&lt;a href="http://www.w3.org/TR/css3-3d-transforms/" target="_blank"&gt;CSS3 3D Transforms&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="http://www.w3.org/TR/orientation-event/" target="_blank"&gt;Device Orientation Events&lt;/a&gt; (access to compass/direction)&lt;/li&gt;
&lt;li&gt;&lt;a href="http://www.w3.org/TR/FileAPI/" target="_blank"&gt;File API&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="http://www.w3.org/TR/html5/scripting-1.html#attr-script-async" target="_blank"&gt;HTML5 async and defer attributes for scripts&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="http://www.w3.org/TR/XMLHttpRequest2/" target="_blank"&gt;XHR2&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="http://www.whatwg.org/specs/web-apps/current-work/multipage/urls.html#dfnReturnLink-3" target="_blank"&gt;classList&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;&lt;h3&gt;New since Honeycomb&lt;/h3&gt;

&lt;p&gt;There are not a huge number of toys to play with, but there are a few including:&lt;/p&gt;

&lt;ul&gt;&lt;li&gt;&lt;a href="http://www.w3.org/TR/html5/interactive-elements.html#the-details-element" target="_blank"&gt;HTML5 Details and summary elements&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="http://www.w3.org/TR/FileAPI/#url" target="_blank"&gt;Blob URIs from File API&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="http://www.khronos.org/registry/typedarray/specs/latest/" target="_blank"&gt;TypedArrays&lt;/a&gt; (Originally from WebGL)&lt;/li&gt;
&lt;li&gt;&lt;a href="http://www.w3.org/TR/navigation-timing/" target="_blank"&gt;Navigation Timing&lt;/a&gt; (performance spec)&lt;/li&gt;
&lt;li&gt;&lt;a href="http://dev.w3.org/csswg/css3-images/" target="_blank"&gt;Updated CSS3 gradients to specced version&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;&lt;p&gt;Thanks to &lt;a href="http://caniuse.com/#compare=y&amp;amp;b1=android+3&amp;amp;b2=android+4" target="_blank"&gt;caniuse.com&lt;/a&gt; for the comparison data.&lt;/p&gt;

&lt;h3&gt;What’s missing?&lt;/h3&gt;

&lt;p&gt;So that WebKit version that corresponds to Chrome 12? How does it really stack up? Well a pretty huge difference actually. Some of the key things still still missing include:&lt;/p&gt;

&lt;ul&gt;&lt;li&gt;WebGL&lt;/li&gt;
&lt;li&gt;WebWorkers&lt;/li&gt;
&lt;li&gt;WebSockets&lt;/li&gt;
&lt;li&gt;Server Sent Events&lt;/li&gt;
&lt;li&gt;IndexedDB&lt;/li&gt;
&lt;li&gt;Drag and Drop&lt;/li&gt;
&lt;li&gt;History API&lt;/li&gt;
&lt;li&gt;HTML5 Forms (would be very useful on mobile)&lt;/li&gt;
&lt;li&gt;Progress and Meter&lt;/li&gt;
&lt;li&gt;File Writer &lt;/li&gt;
&lt;li&gt;SVG Filters&lt;/li&gt;
&lt;li&gt;Web Notifications (these are almost like they were designed for mobile)&lt;/li&gt;
&lt;li&gt;WOFF (although does anyone use WOFF now TTF is well supported?)&lt;/li&gt;
&lt;/ul&gt;&lt;p&gt;This is not to mention the features that have been added since Chrome 12. Our new Chrome overlords &lt;a href="http://news.cnet.com/8301-30685_3-20095696-264/google-move-hints-at-chrome-for-android/" target="_blank"&gt;can’t come soon enough&lt;/a&gt;.&lt;/p&gt;

&lt;h2&gt;So where are we at?&lt;/h2&gt;

&lt;p&gt;We have some thinking to do regarding desktop sites on mobile being within easier reach, no matter if we like it or not. We have a new font similar to Helvetica as a new font, and a faster more standards web browser to play with. On the whole it is a competent update, but hardly earth shattering for web developers. The Safari browser on iOS is still ahead in &lt;a href="http://caniuse.com/#compare=y&amp;amp;b1=ios_saf+5&amp;amp;b2=android+4" target="_blank"&gt;a number of key areas&lt;/a&gt; in terms of standards support.  With Opera Mobile 11.50 reaching 285 on the &lt;a href="http://html5test.com/results-tablets.html" target="_blank"&gt;HTML5test&lt;/a&gt; (not featured on the site yet, nor is Android 4), I expect that still has the best standards support on Android currently.&lt;/p&gt;</description><link>http://generatedcontent.org/post/11715026741</link><guid>http://generatedcontent.org/post/11715026741</guid><pubDate>Thu, 20 Oct 2011 17:59:00 -0700</pubDate><category>android</category><category>webkit</category><category>Ice Cream Sandwich</category><category>mobile</category></item></channel></rss>
