Tải bản đầy đủ (.pdf) (10 trang)

Sams Teach Yourself Web Publishing with HTML and CSS in One Hour a Day (5th Edition) P88 pptx

Bạn đang xem bản rút gọn của tài liệu. Xem và tải ngay bản đầy đủ của tài liệu tại đây (63.82 KB, 10 trang )

Paged Media Properties
Usage Specifies page breaks before the following element or after the preceding element.
CSS2 Values
auto | always | avoid | left | right | inherit
Initial
auto
Applies to Block-level elements.
Inherited No.

page-break-inside
Usage Forces a page break inside the parent element.
CSS2 Values
avoid | auto | inherit
Initial
auto
Applies to Block-level elements.
Inherited Yes.

size
Usage Specifies the size and orientation of a page box.
CSS2 Values
<length> | auto | portrait | landscape | inherit
Initial
auto
Applies to Page context.
Inherited N/A.

widows
Usage Specifies the minimum number of lines of a paragraph that must be left at the top of a
page.
CSS2 Values


<integer> | inherit
Initial
2
Applies to Block-level elements.
Inherited Yes.



file:///G|/1/0672328860/app03lev1sec11.html (2 von 2) [19.12.2006 13:50:43]
Table Properties


Table Properties
The CSS table model is based on the HTML 4.01 table model, which consists of tables, captions, rows,
row groups, columns, column groups, and cells. In CSS2, tables can be rendered visually and aurally.
Authors can specify how headers and data will be spoken through attributes defined previously in "
Aural
Style Sheet Properties."
border-collapse
Usage Selects a table's border model.
CSS2 Values
collapse | separate | inherit
Initial
collapse
Applies to Table and inline table elements.
Inherited Yes.

border-spacing
Usage In separated borders model, specifies the distance that separates the adjacent cell
borders.

CSS2 Values
<length> | <length> ? | inherit
Initial
0
Applies to Table and inline table elements.
Inherited Yes.

caption-side
Usage Specifies the position of the caption box with respect to the table box.
CSS2 Values
top | bottom | left | right | inherit
Initial
top
Applies to Table caption elements.
Inherited Yes.

column-span, row-span
Usage Specifies the number of columns or rows (respectively) spanned by a cell.
file:///G|/1/0672328860/app03lev1sec12.html (1 von 2) [19.12.2006 13:50:43]
Table Properties
CSS2 Values <integer> | inherit
Initial
1
Applies to Table cell, table column, and table column group elements (column-span); table cell
elements (
row-span).
Inherited No.

empty-cells
Usage In the separated tables model, specifies how borders around cells that have no visible

content are rendered.
CSS2 Values
borders | no-borders | inherit
Initial
borders
Applies to Table cell elements.
Inherited Yes.

table-layout
Usage Controls the algorithm used to lay out the table cells.
CSS2 Values
auto | fixed | inherit
Initial
auto
Applies to Table and inline table elements.
Inherited No.
Notes
fixed table layout depends on the width of the table and its columns. auto table layout
depends on the contents of the cells.



file:///G|/1/0672328860/app03lev1sec12.html (2 von 2) [19.12.2006 13:50:43]
User Interface Properties


User Interface Properties
User interface properties enable customization of cursor appearance, color preferences, font
preferences, and dynamic outlines.
cursor

Usage Specifies the type of cursor that displays for a pointing device.
CSS2 Values
<uri> | auto | crosshair | default | pointer | move | e-resize | ne-resize | nw-resize | n-
resize
| se-resize | sw-resize | s-resize | w-resize | text | wait | help | inherit
Initial
auto
Applies to All elements.
Inherited Yes.

outline
Usage Shorthand property for setting outline-color, _outline-style, and outline-width.
CSS2 Values
outline-color | outline-style | outline-width | inherit
Initial See individual properties.
Applies to All elements.
Inherited No.
Notes Similar to
border property, creates an outline around visual objects such as buttons,
active form fields, image maps, and so on. Using
outline property rather than border
property does not cause reflow when displaying or suppressing the outline. Outlines also
can be nonrectangular.

outline-color
Usage Specifies the color of the outline.
CSS2 Values
<color> | invert | inherit
Initial
invert

Applies to All elements.
Inherited No.

outline-style
file:///G|/1/0672328860/app03lev1sec13.html (1 von 2) [19.12.2006 13:50:44]
User Interface Properties
Usage Specifies the style of the outline.
CSS2 Values Same as
<border-style> | inherit
Initial
none
Applies to All elements.
Inherited No.

outline-width
Usage Specifies the width of the outline.
CSS2 Values Same as
<border-width> | inherit
Initial
medium
Applies to All elements.
Inherited No.



file:///G|/1/0672328860/app03lev1sec13.html (2 von 2) [19.12.2006 13:50:44]
Cascading Style Sheet Units


Cascading Style Sheet Units

Several cascading style sheet attributes use standard units to define measurements, styles, colors, and
other identifiers. Throughout this appendix, unit measurements have been enclosed within angle
brackets (
< >). The following section lists the values associated with each unit type.
<absolute-size>
Absolute sizes refer to font sizes computed and kept by the user's browser. The following values are
from smallest to largest:
xx-small
x-small
small
medium
large
x-large
xx-large

<angle>
Angle values are used with aural style sheets. Their format is an optional sign character (+ or -)
immediately followed by a number. The following are angle units:
deg
Degrees
grad
Gradients
rad
Radians

<border-style>
These properties specify the type of line that surrounds a box's border. The borderstyle value type can
take one of the following:
none
Forces border width to zero

dotted
A series of dots
dashed
A series of short line segments
solid
A single line segment
file:///G|/1/0672328860/app03lev1sec14.html (1 von 5) [19.12.2006 13:50:44]
Cascading Style Sheet Units
double
Two solid lines, with the sum of the two lines and the space between them equaling the value
of
border-width
groove
Renders a border that looks as though it were carved into the canvas
ridge
Renders a border that looks as though it were coming out of the canvas
inset
Renders a border that looks like the entire box is embedded in the canvas
outset
Renders a border that looks like the entire box is coming out of the canvas

<border-width>
The border-width property sets the width of the border area. It can take one of the following values:
thin
A thin border
medium
A medium border
thick
A thick border
<length>

An explicit value (cannot be negative)

<color>
Colors can be defined by keyword (as defined in HTML 4.01) or by a numerical RGB specification.
Following are the accepted formats:
Keyword:
aqua | black | blue | fuchsia | gray | green | lime | maroon | navy | olive | purple
|
red | silver | teal | white | yellow
#rgb
Example for blue: { color: #00f }
#rrggbb
Example for blue: { color: #0000ff }
rgb
(integer range) Example for blue: { color: rgb(0,0,255) }
rgb
(float range) Example for blue: { color: rgb(0%, 0%, 100%) }

<family-name>
Fonts can be specified by the name of a font family of choice. Examples of this are Arial, Times New
Roman
, Helvetica, Baskerville, and so on. Font family names that contain white space (tabs, line feeds,
carriage returns, form feeds, and so on) should be enclosed by quotation marks.
<frequency>
Frequency identifiers are used with aural style sheets. The format is a number immediately followed by
one of the following identifiers:
file:///G|/1/0672328860/app03lev1sec14.html (2 von 5) [19.12.2006 13:50:44]
Cascading Style Sheet Units
Hz
Hertz

kHz
Kilohertz

<generic-family>
Authors are encouraged to use generic font family names as a last alternative, in case a user does not
have a specified font on his or her system. Generic font family names are keywords and must not be
enclosed in quotation marks. The following are examples of each:
serif
Times New Roman, MS Georgia, Garamond
sans-serif
Arial, Helvetica, Futura, Gill Sans
cursive
Zapf-Chancery, Caflisch Script
fantasy
Critter, Cottonwood
monospace
Courier, MS Courier New, Prestige

<generic-voice>
Generic voices are the aural equivalent of generic font family names (refer to the preceding section) and
are used in conjunction with
<voice-family>. The following are possible generic voice values:
male
female
child

<integer>
An integer consists of one or more digits (0 through 9). It may be preceded by a - or a + to indicate the
sign. See also
<number>.

<length>
Lengths are specified by an optional sign character (+ or -) immediately followed by a number with or
without a decimal point, immediately followed by one of the following unit identifiers:
Relative values
em
The font size of the relevant font
ex
The x-height of the relevant font
px
Pixels, relative to the viewing device
Absolute values
file:///G|/1/0672328860/app03lev1sec14.html (3 von 5) [19.12.2006 13:50:44]
Cascading Style Sheet Units
pt
Points (1/72nd of an inch)
in
Inches
cm
Centimeters
mm
Millimeters
pc
Picas (12 points, or 1/6 of an inch)

<number>
A number can consist of an integer, or it can be zero or more digits, followed by a dot (.), followed by
one or more digits. A number may be preceded by a
- or a + to indicate its sign. See also <integer>.
<percentage>
Percentage values are always relative to another value, such as a length. The format is an optional sign

character (
+ or -), immediately followed by a number, immediately followed by %.
<relative-size>
Relative sizes are interpreted relative to the font size of the parent element. The following are possible
values:
larger
smaller

<shape>
In CSS2, the only valid shape value is rect(<top> <right> <bottom> <left>, where the four descriptors
specify offsets from the respective sides of the box.
<specific-voice>
Specific voice values are the aural style sheet equivalent of font-family. Values are specific names of a
voice (for example: teacher, comedian, preacher, and so on).
<time>
Time units are used with aural style sheets. Their format is a number immediately followed by one of the
following identifiers:
ms
milliseconds
s
seconds
file:///G|/1/0672328860/app03lev1sec14.html (4 von 5) [19.12.2006 13:50:44]
Cascading Style Sheet Units

<uri>
URI (Uniform Resource Indicator) values are used to designate addresses of page elements such as
images. The format of a URI is
url (followed by optional white space, followed by an optional single
quote or double quotation mark, followed by the URI itself, followed by an optional single or double
quote, followed by optional white space). To clarify, here is an example of the proper syntax:

body { background: url(" }=



file:///G|/1/0672328860/app03lev1sec14.html (5 von 5) [19.12.2006 13:50:44]

×