Nearly everything you do with CSS involves units for determining the look and formatting of your web page elements. With this concise guide, you’ll learn how to work with an array of units—including measurements and keywords—that help you define color, text, distance between elements, location of external files, and other values.
This book contains chapters from the upcoming fourth edition ofCSS: The Definitive Guide. When you purchase either the print or the ebook edition ofValues, Units, and Colors, you’ll receive a significant discount on the entire Definitive Guide when it’s released. Why wait when you can learn how to use units and other key CSS3 features right away?
- Use RGB or HSL values to mix your own colors, and designate the degree of opacity
- Learn how to apply global keywords introduced in CSS3
- Use string values to wrap a sequence of text characters in quotes
- Describe margins, letter spacing, and other properties, with either fixed or relative length units
- Understand how number, integer, and percentage values differ
- Explore CSS3 unit types for describing display resolution
- Use time values for transitions and animations
- Preface
- Chapter 1: Values, Units, and Colors
Preface;Conventions Used in This Book;Using Code Examples;Safari? Books Online;How to Contact Us;Chapter 1: Values, Units, and Colors;1.1 Keywords, Strings, and Other Text Values;1.2 Numbers and Percentages;1.3 Distances;1.4 Color;1.5 Angles;1.6 Time and Frequency;1.7 Position;1.8 Summary;1.9 Color Equivalence Table;
Eric A. Meyer is the author of the critically acclaimed online tutorialIntroduction to HTML, as well as some other semi-popular Web pages. He is a member of the CSS&FP Working Group and the author of Cascading Style Sheets: The Definitive Guide.