14 css formatting elements

11
CSS Formatting Elements Setting values with CSS

Upload: rap-payne

Post on 27-Jan-2015

106 views

Category:

Technology


0 download

DESCRIPTION

 

TRANSCRIPT

Page 1: 14 css formatting elements

CSS Formatting Elements Setting values with CSS

Page 2: 14 css formatting elements

We can make tons of adjustments to look and feel with CSS alone

We can take this: And make it look like this:

Page 3: 14 css formatting elements

Backgrounds

� Can customize the color � Or insert an image as the background

Page 4: 14 css formatting elements

"   Color gradients background-image: -webkit-linear-gradient(top, #ff0000, #999999);!

background-image: -moz-linear-gradient(top, #ff0000, #999999);!

background-image: -ms-linear-gradient(top, #ff0000, #999999);!

background-image: -o-linear-gradient(top, #ff0000, #999999);!

background-image: linear-gradient(to bottom, #ff0000, #999999);!

Page 5: 14 css formatting elements

Browser-specific CSS properties •  -moz-* •  Gecko engine •  Mozilla Firefox

•  -ms-* •  Trident engine •  Microsoft Internet Explorer

•  -webkit-* •  Webkit engine •  Google Chrome •  Apple Safari

•  -o-* •  Presto engine •  Opera Opera

Page 6: 14 css formatting elements

Hands-on color gradients

Page 7: 14 css formatting elements

Text effects

" text-shadow " text-overflow " word-wrap " word-break

Page 8: 14 css formatting elements

Border effects

" dropshadow " rounded corners " border image

Page 9: 14 css formatting elements

Hands-on CSS formatting

Page 10: 14 css formatting elements

Conclusion

� CSS styles give the site its look and feel by setting colors, fonts, sizes, layouts, spacing and so much more

� The new CSS3 features have expanded that by adding gradients, shadows, rounded corners and many other features

�  Sometimes we have to specify the browser type with a prefix on the property being set

Page 11: 14 css formatting elements

Further study

� List of engine-specific features and prefixes ◦  http://peter.sh/experiments/vendor-prefixed-css-

property-overview/

� Playground to learn CSS ◦  http://css3please.com/

� Color picker and gradient generator ◦  http://colorzilla.com