• Complain

Eric A. Meyer - Values, Units, and Colors

Here you can read online Eric A. Meyer - Values, Units, and Colors full text of the book (entire story) in english for free. Download pdf and epub, get meaning, cover and reviews about this ebook. year: 2012, publisher: OReilly Media, genre: Computer. Description of the work, (preface) as well as reviews are available. Best literature library LitArk.com created for fans of good reading and offers a wide selection of genres:

Romance novel Science fiction Adventure Detective Science History Home and family Prose Art Politics Computer Non-fiction Religion Business Children Humor

Choose a favorite category and find really read worthwhile books. Enjoy immersion in the world of imagination, feel the emotions of the characters or learn something new for yourself, make an fascinating discovery.

Eric A. Meyer Values, Units, and Colors
  • Book:
    Values, Units, and Colors
  • Author:
  • Publisher:
    OReilly Media
  • Genre:
  • Year:
    2012
  • Rating:
    4 / 5
  • Favourites:
    Add to favourites
  • Your mark:
    • 80
    • 1
    • 2
    • 3
    • 4
    • 5

Values, Units, and Colors: summary, description and annotation

We offer to read an annotation, description, summary or preface (depends on what the author of the book "Values, Units, and Colors" wrote himself). If you haven't found the necessary information about the book — write in the comments, we will try to find it.

Nearly everything you do with CSS involves units for determining the look and formatting of your web page elements. With this concise guide, youll learn how to work with an array of unitsincluding measurements and keywordsthat help you define color, text, distance between elements, location of external files, and other values.

This book contains chapters from the upcoming fourth edition of CSS: The Definitive Guide. When you purchase either the print or the ebook edition of Values, Units, and Colors, youll receive a significant discount on the entire Definitive Guide when its 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

Eric A. Meyer: author's other books


Who wrote Values, Units, and Colors? Find out the surname, the name of the author of the book and a list of all author's works by series.

Values, Units, and Colors — read online for free the complete book (whole text) full work

Below is the text of the book, divided by pages. System saving the place of the last page read, allows you to conveniently read the book "Values, Units, and Colors" online for free, without having to search again every time where you left off. Put a bookmark, and you can go to the page where you finished reading at any time.

Light

Font size:

Reset

Interval:

Bookmark:

Make
Values, Units, and Colors
Eric A. Meyer
Published by OReilly Media

Beijing Cambridge Farnham Kln Sebastopol Tokyo Preface Conventions Used in - photo 1

Beijing Cambridge Farnham Kln Sebastopol Tokyo

Preface
Conventions Used in This Book

The following typographical conventions are used in this book:

Italic

Indicates new terms, URLs, email addresses, filenames, and file extensions.

Constant width

Used for program listings, as well as within paragraphs to refer to program elements such as variable or function names, databases, data types, environment variables, statements, and keywords.

Constant width bold

Shows commands or other text that should be typed literally by the user.

Constant width italic

Shows text that should be replaced with user-supplied values or by values determined by context.

Tip

This icon signifies a tip, suggestion, or general note.

Caution

This icon indicates a warning or caution.

Using Code Examples

This book is here to help you get your job done. In general, you may use the code in this book in your programs and documentation. You do not need to contact us for permission unless youre reproducing a significant portion of the code. For example, writing a program that uses several chunks of code from this book does not require permission. Selling or distributing a CD-ROM of examples from OReilly books does require permission. Answering a question by citing this book and quoting example code does not require permission. Incorporating a significant amount of example code from this book into your products documentation does require permission.

We appreciate, but do not require, attribution. An attribution usually includes the title, author, publisher, and ISBN. For example: Values, Units, and Colors by Eric A. Meyer (OReilly). Copyright 2012 OReilly Media, Inc., 978-1-449-34251-7.

If you feel your use of code examples falls outside fair use or the permission given above, feel free to contact us at .

Safari Books Online
Note

Safari Books Online (www.safaribooksonline.com) is an on-demand digital library that delivers expert content in both book and video form from the worlds leading authors in technology and business.

Technology professionals, software developers, web designers, and business and creative professionals use Safari Books Online as their primary resource for research, problem solving, learning, and certification training.

Safari Books Online offers a range of product mixes and pricing programs for organizations, government agencies, and individuals. Subscribers have access to thousands of books, training videos, and prepublication manuscripts in one fully searchable database from publishers like OReilly Media, Prentice Hall Professional, Addison-Wesley Professional, Microsoft Press, Sams, Que, Peachpit Press, Focal Press, Cisco Press, John Wiley & Sons, Syngress, Morgan Kaufmann, IBM Redbooks, Packt, Adobe Press, FT Press, Apress, Manning, New Riders, McGraw-Hill, Jones & Bartlett, Course Technology, and dozens more. For more information about Safari Books Online, please visit us online.

How to Contact Us

Please address comments and questions concerning this book to the publisher:

OReilly Media, Inc.
1005 Gravenstein Highway North
Sebastopol, CA 95472
800-998-9938 (in the United States or Canada)
707-829-0515 (international or local)
707-829-0104 (fax)

We have a web page for this book, where we list errata, examples, and any additional information. You can access this page at http://oreil.ly/values-units-colors.

To comment or ask technical questions about this book, send email to .

For more information about our books, courses, conferences, and news, see our website at http://www.oreilly.com.

Find us on Facebook: http://facebook.com/oreilly

Follow us on Twitter: http://twitter.com/oreillymedia

Watch us on YouTube: http://www.youtube.com/oreillymedia

Chapter 1. Values, Units, and Colors

In this book, well tackle features that are the basis for almost everything you can do with CSS: the units that affect the colors, distances, and sizes of a whole host of properties, as well as the units that help to define those values. Without units, you couldnt declare that an image should have 10 pixels of blank space around it, or that a headings text should be a certain size. By understanding the concepts put forth here, youll be able to learn and use the rest of CSS much more quickly.

Keywords, Strings, and Other Text Values

Of course, everything in a style sheet is text, but there are certain value types that directly represent strings of text as opposed to, say, numbers or colors. Included in this category are URLs and, interestingly enough, images.

Keywords

For those times when a value needs to be described with a word of some kind, there are keywords . A very common example is the keyword none, which is distinct from 0 (zero). Thus, to remove the underline from links in an HTML document, you would write:

a:link, a:visited {text-decoration: none;}

Similarly, if you want to force underlines on the links, then you would use the keyword underline.

If a property accepts keywords, then its keywords will be defined only for the scope of that property. If two properties use the same word as a keyword, the behavior of the keyword for one property will not necessarily be shared with the other. As an example, normal, as defined for letter-spacing, means something very different than the normal defined for font-style.

CSS3 defines two global keywords, one of which has fairly widespread support: inherit and initial.

inherit

The keyword inherit makes the value of a property on an element the same as the value of that property on its parent element. In other words, it forces inheritance to occur even in situations where it would not normally operate. In many cases, you dont need to specify inheritance, since many properties inherit naturally. Nevertheless, inherit can still be very useful.

For example, consider the following styles and markup:

#toolbar {background: blue; color: white;}

The div itself will have a blue background and a white foreground, but the links will be styled according to the browsers preference settings. Theyll most likely end up as blue text on a blue background, with white vertical bars between them.

You could write a rule that explicitly sets the links in the toolbar to be white, but you can make things a little more robust by using inherit. You simply add the following rule to the style sheet:

#toolbar a {color: inherit;}

This will cause the links to use the inherited value of color in place of the user agents default styles. Ordinarily, directly assigned styles override inherited styles, but inherit can undo that behavior.

Similarly, you can pull a property value down from a parent even if it wouldnt happen normally. Take border, for example, which is (rightfully) not inherited. If you want a span to inherit the border of its parent, all you need is

Next page
Light

Font size:

Reset

Interval:

Bookmark:

Make

Similar books «Values, Units, and Colors»

Look at similar books to Values, Units, and Colors. We have selected literature similar in name and meaning in the hope of providing readers with more options to find new, interesting, not yet read works.


Reviews about «Values, Units, and Colors»

Discussion, reviews of the book Values, Units, and Colors and just readers' own opinions. Leave your comments, write what you think about the work, its meaning or the main characters. Specify what exactly you liked and what you didn't like, and why you think so.