Você está na página 1de 6

This document contains text automatically extracted from a PDF or image file.

Formatting may have


been lost and not all text may have been recognized.
To remove this note, right-click and select "Delete table".
CSS CSS Help Help Sheet Sheet
Write styles for any element
background
border
External Style Sheet
border-bottom
border-left
border-right
border-top
Internal Style
font
list-style
margin
padding
Inline Style
font-style italic, normal
font-variant normal, small-caps
font-weight bold, normal, lighter, bolder,
integer [100-900]
blink, line-through, none,
overline, underline
capitalise, lowercase, uppercase
Syntax Syntax
height
height; width;
selector {property: value;}
margin-top;
<link rel=”stylesheet” type=”text/css”
href=”style.css” />
width
margin-right;
margin-bottom;
margin-left;
padding-top;
<style type=”text/css”>
border
selector {property: value}
margin
padding </style>
padding-right;
padding-bottom;
padding-left;
<tag style=”property: value”> border-width Width of the border
/* Comments */
General General
border-style dashed; dotted; double; groove; inset;
outset; ridge; solid; none;
class
ID
border-color Colour of the border
:hover
:active
:focus
div
span
color
clear If any oating elements around the element
both, left, right, none
cursor
:link
:visited
: rst-line
oat Floats to a speci ed side
: rst-letter
left, right, none
display
left The left position of an element
over ow
auto, length values [pt, in, cm, px]
all
top The top position of an element
braille
auto, length values [pt, in, cm, px]
embossed
visibility
position static, relative, absolute
z-index Above or below overlapping elements
auto, integer [higher numbers on top]
handheld
print
Font Font
projection
screen
speech
tty
background-color Colour of background
tv
background-image Background image url(’’)
font-size Size of the font
font-family Speci c font[s] to be used.
background-repeat repeat, no-repeat, repeat-x, repeat-y
background-
Length
Text Text
attachment
background-
position
Background image scrolls with element
scroll, xed
(x y), top, center, bottom, left, right
%
em
pt
px
letter-spacing Space between letters
Keywords
line-height Vertical space between baselines
bolder
text-align Horizontal alignment
text-
list-style-
type
lighter
larger
decoration
text-indent First line indentation
text-
transform
vertical-align Vertical alignment
word-spacing Spacing between words
Type of bullet or numbering in the list
disc; circle; square; decimal; lower-roman;
upper-roman; lower-alpha; upper-alpha; none
list-style-
position
Position of the bullet or number in a list
inside; outside
Developing for
IE6 is a lost cause.
list-style-
image
Image to be used as the bullet in the list

Download this Help Sheet now at gosquared.com/liquidicity


Original by the awesome Leslie Frank: http://lesliefranke.com/2005/10/css-cheat-sheet/
Put it on your wall

GoSquared GoSquared
String preceded by a full stop (.)
String preceded by a hash (#)
Formats structure or block of text
Inline formatting
Foreground colour
Appearance of the cursor
block; inline; list-item; none
How to handle content that
over ows its box.
visible; hidden; scroll; auto
visible; hidden

List List

Background Background

Position Position

Border Border

Margins + Padding Margins + Padding

© 2010 Go Squared Ltd.

Shorthand Shorthand

Comments Comments

Pseudo Selectors Pseudo Selectors

Media Types Media Types

Units Units

Você também pode gostar