Download Html & Css PDF

TitleHtml & Css
Author
TagsHtml Tutorial Html
LanguageEnglish
File Size18.8 MB
Total Pages514
Table of Contents
                            HTML & CSS
	Credits
	Contents
	Introduction
	Chapter 1: Structure
	Chapter 2: Text
	Chapter 3: Lists
	Chapter 4: Links
	Chapter 5: Images
	Chapter 6: Tables
	Chapter 7: Forms
	Chapter 8: Extra Markup
	Chapter 9: Flash, Video & Audio
	Chapter 10: Introducing CSS
	Chapter 11: Color
	Chapter 12: Text
	Chapter 13: Boxes
	Chapter 14: Lists, Tables & Forms
	Chapter 15: Layout
	Chapter 16: Images
	Chapter 17: HTML5 Layout
	Chapter 18: Process & Design
	Chapter 19: Practical Information
	Index
                        
Document Text Contents
Page 257

artiCle

250COLOR 250COLOR

R e s u lt

body {
background-color: rgb(200,200,200);}
h1 {
background-color: DarkCyan;}
h2 {
background-color: #ee3e80;}
p {
background-color: white;}

chapter-11/background-color.htmlC s s
CSS treats each HTML element
as if it appears in a box, and the
background-color property
sets the color of the background
for that box.

You can specify your choice of
background color in the same
three ways you can specify
foreground colors: RGB values,
hex codes, and color names
(covered on the next page).

If you do not specify a
background color, then the
background is transparent.

By default, most browser
windows have a white
background, but browser users
can set a background color for
their windows, so if you want
to be sure that the background
is white you can use the
background-color property on
the <body> element.

We have also used the padding
property to separate the text
from the edges of the boxes.
This makes it easier to read and
you will learn more about this
property on page 313.

baCkground Color
background-color

Page 258

251 COLOR

Every color on a computer screen is created by mixing amounts of red,
green, and blue. To find the color you want, you can use a color picker.

understanding Color

Computer monitors are made
up of thousands of tiny squares
called pixels (if you look very
closely at your monitor you
should be able to see them).

When the screen is not turned
on, it's black because it's not
emitting any light. When it's
on, each pixel can be a different
color, creating a picture.

The color of every pixel on the
screen is expressed in terms of
a mix of red, green, and blue —
just like on a television screen.

Color picking tools are available
in image editing programs like
Photoshop and GIMP. You can
see the RGB values specified
next to the radio buttons that
say R, G, B.

The hex value is provided
next to the pound or hash
# symbol. There is also a
good color picking tool at:
colorschemedesigner.com

Page 513

INDEX

action 151
align 103–105
alt 99
autoplay 214, 219
bgcolor 138
border 138
checked 155, 156
cite 52
class 184, 431
codecs 215
cols 154
colspan 133
content 191, 192
controls 214, 219
description 191
for 163
frameborder 190
global attributes 183
height 100, 189, 214

href 77, 79, 88, 235
http-equiv 192
id 87, 88, 151, 163
id attribute 183, 431
loop 214, 219
maxlength 152, 153
method 151
multiple 158
name 152-157, 160, 191
placeholder 168
poster 214
preload 214, 219
rel 235
robots 191
rows 154
rowspan 134
scrolling 190
seamless 190
selected 157

size 152, 153, 158
src 99, 189, 214, 215, 219, 220
style 236
target 86
title 53, 99
type 152, 155, 159
type (audio/video) 220, 215
type (CSS) 235-236
type="date" 166
type="email" 167
type="hidden" 162
type="image" 161
type="password" 153
type="search" 168
type="submit" 160
type="url" 167
value 155-157, 160
width 100, 137, 189, 214

HTML ATTRIBUTeS

Page 514

INDEX

background-attachment
property 414

background-color 250
background-image property 413
background-image property

(gradients) 419
background-position property

415
background property 416
background-repeat property

414
border-bottom-color 311
border-bottom-style 310
border-collapse property 340
border-color 311
border-image property 319
border-left-color 311
border-left-style 310
border property 312
border-radius property 321
border-right-color 311
border-right-style 310
border-spacing property 340
border-style 310
border-top-color 311
border-top-style 310

bottom property 366–371
box-shadow property 320
clear property 372
color 249
cursor property 347
display property 317
empty-cells property 339
float property 364, 370–375
float property (images) 411
@font-face 277
font-face 271
font-family 271, 273
font-size 274, 276
font-style property 280
height (images) 409–410
hsl / hsla 255–256
left property 366–371
letter-spacing 284
line-height 283
list-style-image property 334
list-style-position property 335
list-style property 336
list-style-type property 333
margin-bottom property 314
margin-left property 314
margin property 314

margin-right property 314
margin-top property 314
opacity 254
padding-bottom property 313
padding-left property 313
padding property 313
padding property (tables) 337
padding-right property 313
padding-top property 313
position property 366, 367
rgba 254
right property 366–371
text-align 285
text-decoration 282
text-indent 287
text-shadow 288
text-transform 281
top property 366–371
vertical-align 286
visibility property 318
width (images) 409–410
width property (floating

elements) 371
width property (tables) 337
word-spacing 284
z-index property 364, 369

CSS PROPeRTIeS

:active 291
:first-letter 289
:first-line 289
:focus 291, 342

:hover 291, 343, 342
highlighting table rows 337

:link 290
:visited 290

@font-face 277
@import rule 395
!important 239

PSeUdO-CLASSeS, eLeMenTS & RULeS

Similer Documents