Graphics Programs Reference
In-Depth Information
body {
line-height : 1.4 ;
}
While you're there, you might also feel like adding your standard page background and text
colors along with your favorite body font:
body {
font : smaller/1.4 Helvetica, sans-serif ;
background : #ABACAB ;
color : #444 ;
}
You can pull the rule that strips of list bullets because you know you'll never want to change
those. (Which is not actually the case for me, but hey, we're all dif erent.) Add in rules that
dei ne exactly how and how far lists are indented, the separation between paragraphs and list
items, the way you prefer to style strong , and so on.
By this point, what you have is not a reset style sheet, it's a reboot style sheet. You're rebooting
the browser into your preferred baseline for styling a document, establishing a customized
starting point on which you can build any project. With that rebooter in hand, you can get a
jump-start on each new project, making it the kernel around which each i nal style sheet
grows.
36
Not only can you reboot browsers with CSS, you also can upgrade some of them with
JavaScript. Seriously.
IE9.JS
With Dean Edwards's IE9.js, you can make IE5 through IE8 act much more like (the still
unreleased, as of this writing) IE9 when it comes to handling CSS and HTML. You can i nd
this at code.google.com/p/ie7-js —yes, the ie7 part is correct (see Figure 1-35). (It's
because this project started as IE7.js, and when IE8 and IE9 came out, new versions were
needed.)
IE9.js is a set of JavaScript routines that, if the browser is a version of Internet Explorer before
IE9, will scan through the CSS and HTML of a page and i gure out which parts aren't sup-
ported by the version of IE being used to view the page. It then does a bunch of fancy back-
end juggling to make that support happen transparently.
As an example, IE5 and IE6 did not support attribute selectors. h us, if you have a rule like
this:
a[href] { text-decoration : none ; color : red ;}
 
Search WWH ::




Custom Search