Moving towards CSS 3

This paper was writen in the Spring of 2009. The assignment was to carve out one area of current W3C standardization activity and develop an assessment of the state of the standardization effort.

<tootmyownhorn>
  The professor who assigned it said, "This is the finest effort I have seen to date on this assignment."
</tootmyownhorn>.

The CSS Standard

The CSS(Cascading Style Sheets) Recommendation defines a language of presentational rules for documents that are tagged with markup. This includes HTML, XHTML, and XML files.

The first version (or level) of the CSS standard was released by the W3 Consortium in 1996 and was one of the first Recommendations issued by the Consortium. It developed from a paper released on October 10, 1994 called Cascading HTML Style Sheets written by Hakon Wium Lie, who worked Tim Berners-Lee at CERN.1.  Lie and Bert Bos developed CSS through six drafts into the final recommendation.

However, Lie’s proposal was not the only style sheet proposal. The idea for an HTML styling syntax started showing up on the WWW-Talk mailing list in 1993. Other proposals were released by Robert Raisch of O’Reilly & Associates (June 10, 1993), Pei-Yuan Wie (October 22, 1993), and Joe English (November 18, 1994). And in the fall of 1996, as CSS1 was well on its way to becoming a recommendation, Netscape proposed its own JavaScript-based syntax for styling.2

One of the most important differences between Lie’s proposal and others was the idea of the cascade. The cascade creates a hierarchy of styles, with the most important being the author defined styles, followed by user defined styles (although precedence is reversed for "!important" rules), followed by browser defined styles.

This allows room for both user control and designer’s intent.

CSS level 3 is currently under development. Some of the goals for CSS3 are “paged media, internationalization issues, and harmonization with other W3C standards for vector graphics, mathematical markup, and multimedia.”3

With level 3, the CSS specification has been greatly expanded to the point where it would be cumbersomely slow to bring the entire spec to recommendation level at the same time.4  To speed development, the spec has been broken down into about 42 of these modules. Features covered by the modules include the following5:

  • Media queries for more precisely controlled device presentation rules
  • Effects over time, such as animations and transitions
  • Expanded hyperlink pseudo-classes to reflect new ways of displaying linked information on the web
  • Replaced content, which allows for better image replacement

…and much more.

Motivation

The general mission of the W3C is to “lead the World Wide Web to its full potential by developing common protocols that promote its evolution and ensure its interoperability,”6  and the CSS standard supports this mission.

The creators of CSS detailed more specific motivations in the goals section of their first draft:

The most important goal is to come up with a style sheet language that authors (including the home page writer) feels comfortable writing. If we don't achive[sic] this, style sheets will not be widely deplayed[sic] on the web.

The appearance of the web can be improved by a style sheet mechanism that:

  • is simple, yet flexible (easy & fast to implement)
  • is human readable/writable (just like HTML)
  • provides a mapping between HTML elements and presentation properties (i.e. not SGML-complete)
  • supports presentation hints, not commands (make no guarantees)
  • can be contained (leave the HTML source to itself, apply to existing documents)
  • allow both readers and authors to influence the presentation
  • support non-visual media, e.g. speech synthesizers
  • can be applied to incompletely loaded documents
  • works efficiently in editing environments
  • is platform-independant 7

However, as the authors recognized, in order for CSS to be successful, others had to be motivated to use it.

Because CSS was practical and the benefits were easy to grasp, Web professionals and academics were motivated to use it. The CSS standard, in conjunction with the (X)HTML standard, decreased the amount of resource wasted in web development and increased interoperability. These motivated individuals and organizations lobbied the major browser makers to increase their standards compliance so they could take advantage of the following benefits:

Separating style from content   

Using CSS, all presentational elements reside in a separate file, making it easier for machines to understand and manipulate the information (for instance, making it easier for search engine bots to find the relevant words on a page). Having the presentational rules in a separate file also makes site-wide changes much less labor intensive.

Affording multiple presentations

Because style is separated from content with CSS, sites can be presented differently depending on the device that is accessing the site. For instance, a site that has white text on a background image on a computer screen can be styled as black text with no background for print, with a different background image for a handheld device, and (with CSS2.1) even auditory styles can be put in for screen readers. It also allows the user to override the author’s styles based on his or her requirements.

Cross-browser compatibility

In the years before browsers conformed to the HTML and CSS standards, sites had to be coded multiple ways for the different browsers. For instance, Connected Earth spent approximately $1.8 million on a site that, by the time it was released in 2002, did not work with most modern browsers.8 Even more money was required to make the site work in the other browsers. As browsers become more and more conformant with the CSS standard, this duplicate development is not necessary.

Forward compatibility

As new browsers and devices are developed in accordance with the standard, sites that were developed for previous browsers and devices continue to work, so the site does not need to be redeveloped. The standard also builds on itself, so code that was compliant with CSS2 will also be compliant with CSS3.

Process

All Recommendations published by the W3C must pass through a set process:
•    W3C receives a Submission
•    W3C publishes a Note
•    W3C creates a Working Group
•    W3C publishes a Working Draft
•    W3C publishes a Candidate Recommendation
•    W3C publishes a Proposed Recommendation
•    W3C publishes a Recommendation9
In the case of CSS level 3, that process is taking considerably longer than it did for CSS level 1 or 2. The initial idea for CSS came in 1994, and the specification was released just two years later, with CSS2 released just two years after that. Comparatively, the CSS3 specification has been in process since 1998, going much more slowly through each stage of the process.

Note

The final note for CSS3 was published in December of 1998 by Bert Bos, who worked with Lie on the original specification 4 years earlier. The note included 67 potential features for CSS3 and a voting utility to gather feedback on what the community thought was important.

Working Group

The Working Group had already been established for CSS when work began on CSS3 (it was at the time known as the CSS & FP Working Group). The group charter is public from 2002 to date, but charter versions before that date are member access only.

The working group is composed of W3C members and other “interested parties”. The current Working Group includes representatives from:

  • Adobe Systems Inc.
  • Antenna House, Inc.
  • Apple, Inc.
  • Disruptive Innovations
  • Google, Inc.
  • HP
  • International Webmasters Association / HTML Writers Guild (IWA-HWG)
  • Microsoft Corporation
  • Mozilla Foundation
  • Opera Software
  • Rochester Institute of Technology
  • Sun Microsystems, Inc.
  • The Boeing Company
  • Universidad de Oviedo
  • W3C Invited Experts
  • W3C/ERCIM

Many well-known individuals are working on the details of the specification, with a particular bias towards developers of major browsers. Lie and Bos are still involved in the project, and both are editors on a number of CSS3 modules. Other editors include:

  • CSS expert and author Eric Meyer
  • former IE developer Tantek Çelik, current IE developer Markus Mielke
  • Mozilla contributor Elika Etemad, Mozilla developers Daniel Glazman and David Baron
  • Opera developers Anne van Kesteren, Claudio Santambrogio, and Ian Hickson

Members of the Working Group are expected to put 1 day’s worth of work into participation (meetings, reviewing and writing drafts) every week, with Bert Bos, chairman of the CSS Working Group, expected to put in 2 days per week. Meetings include weekly teleconferences and face-to-face meetings two times a year (down from 3 times a year in the 2006-2008 charter).10

The group works by consensus, but if they cannot reach consensus, they resort to a vote.

Working Draft

Working drafts will be posted for public input. The W3C invites the public to join the Working Group mailing list to be a part of the discussion.

The general working draft for CSS3 was released by Eric Meyer in April of 2000, although drafts for particular modules had been released as early as June of 1999. The third and final working draft was released by Eric Meyer and Bert Bos in May of 2001.

Candidate Recommendation

Currently, six modules are at the Candidate Recommendation stage. They must remain in the CR stage for at least 6 months before becoming official Recommendations.

As the standard has been developed, browser makers have implemented the new features that have been tentatively set forth. While the standard is in the CR phase, the browsers will set their own syntax for the rule with a prefix. Otherwise, “the CSS WG could change the specification, other browsers could adopt the new version, and people would get different rendering results from the exact same feature. So effectively, a prefix says: the behavior of this element might change at any point in time, and it’s not per se a correct representation of the latest specification.”11

Proposed Recommendation

A Proposed Recommendation remains a work in progress, but indicates that the Working Group is getting close to a final Recommendation.

Recommendation

The final recommendation is reviewed by W3C members and approved by the W3C’s director, Tim Berners Lee. At this time, it is stable and can be used as a reference for browser makers and Web developers.

The W3C expects to have the final Recommendation for CSS3 in 2011, more than a decade after work began.

Conclusion

The development of the CSS standard was one of the key factors in the rapid acceleration of Web development. Its simplicity and clearly recognizable benefits resulted in its quick and nearly universal adoption. The separation of style from content moved the Web back towards its roots and potential to be a semantic-rich tool, opening the doors to much more robust machine processing of information.

The phased development of the standard(levels 1, 2, and now 3) ensured that enough functionality would be introduced to move things forward without overwhelming the intended users or the standards process—CSS 1 and 2 gave developers enough control to move the Web forward greatly as they wait for CSS3 to be developed.

While the general standards process used to develop the standard could be criticized—an overwhelming number of the editors of the standard are employees of the dominant players in the market place—the process used to develop CSS itself has been very open and responsive to the needs of users. Overall, while it’s not perfect, the process has developed a practical standard that’s ready adoption has shaped the world and greatly accelerated the development of the Web in an invisible way.


  1. Erik T. Ray, Learning XML (Sebastopol, CA; O’Reilly and Associates, 2003) Ch 5.
  2. virtuelvis.com/archives/2005/01/css-history
  3. www.oreillynet.com/pub/a/oreilly/web/news/css_interview_0500.html
  4. www.css3.info/modules/
  5. www.w3.org/Style/CSS/current-work#CSS3
  6. www.w3.org/2005/10/Process-20051014/
  7. www.w3.org/Style/CSS/draft1.html#goals
  8. Jeffrey Zeldman, Designing With Web Standards (Berkeley, CA: New Riders, 2007) 12.
  9. www.w3schools.com/w3c/w3c_process.asp
  10. www.w3.org/Style/2004/css-charter-long
  11. www.css3.info/why-and-when-browsers-prefix-css3-features/