# If you do create graphics for the web avoid trouble

• Test Prep
• P1nkD
• 9
• 100% (18) 18 out of 18 people found this document helpful

This preview shows page 8 - 9 out of 9 pages.

##### We have textbook solutions for you!
The document you are viewing contains questions related to this textbook. The document you are viewing contains questions related to this textbook.
Chapter 2 / Exercise 105
Mathematical Practices, Mathematics for Teachers: Activities, Models, and Real-Life Examples
Larson Expert Verified
PTS:1REF:358 | 3595.How are color names, RGB color values, and hexadecimal color values used?
##### We have textbook solutions for you!
The document you are viewing contains questions related to this textbook. The document you are viewing contains questions related to this textbook.
Chapter 2 / Exercise 105
Mathematical Practices, Mathematics for Teachers: Activities, Models, and Real-Life Examples
Larson Expert Verified
ANS:Using Color Names: The color name values let you quickly state color using common names. Al-though the color names are easy to use, they allow only a small range of color expression. To use a wider variety of available color, you must use a more specific value, such as RGB or hexadecimal.Using RGB Color Values: The RGB color model is used to specify numeric values that express the blending of the red, green, and blue color channels.When you specify RGB values, you are mixing the three basic colors to create a fourth color. Each of the three color channels can be specified in range from 0 to 100%, with 0 representing the absence of the color, and 100% representing the full brillianceof the color. If all three values are set to 0, the resulting color is black, which is the absence of all color.If all three color values are set to 100%, the resulting color is white, which is the inclusion of all col-ors.The syntax for specifying RGB is the keyword rgb followed by three numerical values in parentheses—the first for red, the second for green, the third for blue.The following rule states a percentage RGB value:p {color: rgb(0, 100%, 100%);}RGB color values can be specified as an integer value as well. The integer scale ranges from 0 to 255 with 255 equal to 100%.The following rules specify the same color:p {color: rgb(0%, 100%, 100%);}/* percentages */p {color: rgb(0, 255, 255);}/* integers */Using Hexadecimal Color Values: HTML uses hexadecimal numbers to express RGB color values, and you can use them in CSS as well. Hexadecimal numbers are a base-16 numbering system, so the numbers run from 0 through 9 and then A through F. When compared to standard base-10 numbers, hexadecimal values look strange because they include letters in the numbering scheme. Hexadecimal color values are six-digit numbers; the first two define the red value, the second two define the green, and the third two define the blue. The hexadecimal scale ranges from 00 to FF with FF equal to 100%. Hexadecimal values are always preceded by a pound sign (#).The following rules specify the same color:p {color: #00FFFF;}/* hexadecimal */p {color: rgb(0%, 100%, 100%);}/* percentages */p {color: rgb(0, 255, 255);}/* integers */PTS:1REF:365 | 366
• • • 