Typography - Getting The Hang Of Typography

(lu) #1

New Typographic Possibilities with CSS 3


Inayaili de León


There has been an increasing and sincere interest in typography on the web
over the last few years. Most Web sites rely on text to convey their
messages, so it՚s not a surprise that text is treated with utmost care. In this
article, we՚ll look at some useful techniques and clever effects that use the
power of style sheets and some features of the upcoming CSS Text Level 3
specification, which should give Web designers finer control over text.


Keep in mind that these new properties and techniques are either new
or still in the works, and some of the most popular browsers do not yet
support them. But we feel it՚s important that you, as an informed and
curious Web designer, know what՚s around the corner and are able to
experiment in your projects.


A Glance At The Basics


One of the most common CSS-related mistakes made by budding Web
designers is creating inflexible style sheets that have too many classes and
IDs and that are difficult to maintain.


Let՚s say you want to change the color of the headings in your posts,
keeping the other headings on your Web site in the default color.


Rather than add the class big-red to each heading, the sensible approach
would be to take advantage of the DIV class that wraps your posts
(probably post) and create a selector that targets the heading you wish to
modify, like so:

Free download pdf