Book Review: The Book of CSS3 by Peter Gasston

Several months ago, I attended a fascinating talk on CSS3 by Peter Gasston at London Web. As one of the first people to ask a question during the Q&A session at the end of Peter’s talk, I received a free copy of his The Book of CSS3: A Developer’s Guide to the Future of Web Design. Unfortunately, my own manic schedule meant I had to put the book to the side for a while. But now I’ve managed to read it from cover to cover, I’d like to share my thoughts about it.

Let me say it right out: Peter has done a splendid job. The book is extremely well researched, and he obviously knows what he’s talking about. Having said that, the book’s subtitle (A Developer’s Guide to the Future of Web Design) very much sets the tone. If you’re looking for a quick guide on how to create CSS3 eye candy with rounded corners and drop shadows, this is not the book for you. Although Peter covers the relevant properties (border-radius and box-shadow), he takes a much more serious approach through an in-depth exploration of each new property, together with warnings about anomalies in different browsers. Because CSS3 is still evolving and browser makers are bringing out new versions at a breathtaking pace, you might think that Peter’s book will rapidly go out of date. Undoubtedly, some parts of it will; but many of the CSS3 modules that Peter covers are unlikely to change. Color is already a W3C recommendation. Selectors is a proposed recommendation; and Media Queries, Backgrounds and Borders, and Multi-column Layout are all candidate recommendations.  As a result, The Book of CSS3 is a reference book that I’ll be keeping by my side for a considerable time to come.

Even the more experimental areas covered by the book are not really a problem, thanks to the decision by all mainstream browsers to adopt browser-specific prefixes (such as -moz for Firefox and -webkit for Safari and Chrome) until the specifications settle down. Unlike CSS2.1, you won’t need hacks to deal with quirky implementations in older browsers. Just use the browser-specific prefixes in combination with the standard properties. Older versions use the prefixed properties, and when the specification stabilizes, the most up-to-date version will use the standard ones (as long as you put the standard ones lower down in the cascade). Perhaps one exception is the Flexible Box (flexbox) Layout module. Just as the book was going to press, the W3C decided to completely rename the properties. Peter mentions this at the end of the chapter on flexbox layout, but the changes haven’t yet made it through to the browsers that support it (Firefox, Safari, and Chrome). However, they will presumably continue to support the old properties with the browser-specific prefixes. But until Internet Explorer supports flexbox (planned for IE 10), using this type of layout is of limited value anyway.

Although flexbox and other proposed layout systems don’t have much practical value at the moment, I found the chapters devoted to them among the most interesting in the book—mainly because they give me hope for the future. CSS layout has always been a minefield, but if browsers (and the W3C) continue the current rapid pace of development, the job of the web developer should become a lot easier. Or will it? One of the comments in the Q&A session after Peter’s talk was that CSS was becoming more like a programming language. And it was obvious from the questioner’s tone that the thought of handling more code was unwelcome. But if you’re involved in designing websites and want to understand the direction in which CSS is moving, Peter Gasston’s book is an excellent place to start.

This entry was posted in Books, CSS. Bookmark the permalink.

9 Responses to Book Review: The Book of CSS3 by Peter Gasston

  1. Chris Kurose says:

    Hi David,

    I hate to post off-topic, but it seems the comment section on embedding Bridge web galleries is closed… It was asked by another user in that comment section but never answered – is there a way to edit any of the files that bridge creates in the resources folder (index.html, style.xml, AC_RunActiveContent.js, or AC_OEtags.js) to make the gallery autoplay upon loading the page? I have a sinking feeling that the way to do this is within the flash files themselves, which I don’t know how to edit.

    I did run into an area in the style.xml file that reads:

    …but when I changed this to ‘play’ or ‘autoplay’ it didn’t have any effect. I think this section just styles the appearance of the gallery when it’s in ‘pause’ mode?

    Any help would be hugely appreciated – I can’t find an answer to this question anywhere on the web, and your tutorial on customizing and embedding bridge galleries was the only thing that allowed me to get as far as I have . Thanks!

  2. David Powers says:

    Sorry, I don’t know the answer. I wrote that tutorial a couple of years ago, which is why comments are closed. The gallery uses flashvars to load most parameters, but changing play to autoplay on line 194 of index.html doesn’t have any effect. I suspect that autoplay simply loads the gallery as normal and then pauses on the first image. The buttons below the image will be controlled internally by ActionScript, but without an .FLA file to edit, I’m not aware of any way to trigger the slideshow automatically.

    As far as I know, there’s a Bridge forum on the Adobe website. You might be able to get some help if you post a question there.

  3. Pingback: An odd turn-up for the book | Musings of a code slave

  4. David Gustavsson says:

    Seems lika a god book.

    Are you planing books on HTML 5 and CSS3 whitout Dreamweaver like “Getting startED whit CSS”?

  5. David Powers says:

    Yes, I’m planning to write a book provisionally titled “Beginning CSS”, which will cover both CSS2.1 and CSS3. Writing books takes a long time, so it won’t be out until the second half of 2012.

  6. David Gustavsson says:

    Ok, thanks for the info. I think I will buy your DW, HTML5, CSS3… video/book. The video is the main attraction there?, the book is only 48 pages? So there are no “normal, thick” books fore this this aside from the mobile version? Do I need to buy additional HTML5/CSS3 books? How much do this cover?

  7. David Powers says:

    The “book” that accompanies the video is really just a brief introduction to the content of the video lessons, plus a little supplementary explanation. The video contains a lot of information about both HTML5 and CSS3, so you might find it covers most of what you need to know. If you’re interested in learning more, you might want to consider “Introducing HTML5, 2nd Edition” by Bruce Lawson and Remy Sharp, and “Stunning CSS3″ by Zoe Mickley Gillenwater.

  8. David Gustavsson says:

    Thanks for the info and tips!