8000 [css2] updated tutorial · w3c/csswg-drafts@c714d81 · GitHub 7FFF
Skip to content

Commit c714d81

Browse files
committed
[css2] updated tutorial
added design principles --HG-- extra : convert_revision : svn%3A73dc7c4b-06e6-40f3-b4f7-9ed1dbc14bfc/trunk%40302
1 parent e4e2699 commit c714d81

1 file changed

Lines changed: 34 additions & 51 deletions

File tree

css2/intro.src

Lines changed: 34 additions & 51 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
22
<html lang="en">
3-
<!-- $Id: intro.src,v 1.5 1997-10-29 04:38:52 ian Exp $ -->
3+
<!-- $Id: intro.src,v 1.6 1997-10-29 20:20:31 howcome Exp $ -->
44
<HEAD>
55
<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1">
66
<TITLE>Introduction to CSS2</TITLE>
@@ -16,15 +16,16 @@ style sheets. For this tutorial, you will need to know a little
1616
<a rel="biblioentry" href="./refs.html#ref-HTML40">[HTML40]</a>
1717
and some basic desktop publishing terminology.
1818

19-
<P>We begin with the following (incomplete) HTML body:
19+
<P>We begin with the following little HTML document:
2020

2121
<PRE>
22-
&lt;BODY&gt;
23-
&lt;H1&gt;Getting started with style sheets&lt;/H1&gt;
24-
<em>...Some text about style sheets...</em>
25-
&lt;H1&gt;Style sheet tricks&lt;/H1&gt;
26-
<em>...Some text about style sheet tricks...</em>
27-
&lt;/BODY&gt;
22+
&lt;HTML&gt;
23+
&lt;TITLE&gt;Bach's home page&lt;/TITLE&gt;
24+
&lt;BODY&gt;
25+
&lt;H1&gt;Bach's home page&lt;/H1&gt;
26+
<b>&lt;P&gt;Johann Sebastian Bach was a prolific composer.</b>
27+
&lt;/BODY&gt;
28+
&lt;/HTML&gt;
2829
</PRE>
2930

3031
<P>To set the text color of the H1 elements to blue, you can write the
@@ -45,17 +46,16 @@ specification for details and recommended usage.
4546
document in a STYLE element:
4647

4748
<PRE>
48-
&lt;HEAD&gt;
49-
&lt;STYLE&gt;
50-
H1 { color: blue }
51-
&lt;/STYLE&gt;
52-
&lt;/HEAD&gt;
53-
&lt;BODY&gt;
54-
&lt;H1&gt;Getting started with style sheets&lt;/H1&gt;
55-
<em>...Some text about style sheets...</em>
56-
&lt;H1&gt;Style sheet tricks&lt;/H1&gt;
57-
<em>...Some text about style sheet tricks...</em>
58-
&lt;/BODY&gt;
49+
&lt;HTML&gt;
50+
&lt;TITLE&gt;Bach's home page&lt;/TITLE&gt;
51+
&lt;STYLE TYPE="text/css">
52+
H1 { color: blue }
53+
&lt:STYLE>
54+
&lt;BODY&gt;
55+
&lt;H1&gt;Bach's home page&lt;/H1&gt;
56+
&lt;P&gt;Johann Sebastian Bach was a prolific composer.
57+
&lt;/BODY&gt;
58+
&lt;/HTML&gt;
5959
</PRE>
6060

6161
<P>Note that what appears within the STYLE element's start and end
@@ -77,51 +77,34 @@ types are defined in the <a rel="biblioentry"
7777
href="./refs.html#ref-HTML40">[HTML40]</a> specification.
7878

7979
<P> The <span class="propinst-color">'color'</span> property is one of around
80-
50 properties defined in this specification that determine the
80+
70 properties defined in this specification that determine the
8181
presentation of an HTML document.
8282

8383
<P>HTML authors only need to write style sheets if they want to
8484
suggest a specific style for their documents. Each user agent (UA)
8585
will have a default style sheet that presents documents in a
8686
reasonable -- but arguably mundane -- manner. This specification
87-
includes a <a href="./sample.html">sample style sheet</a> to
88-
present HTML documents as suggested in the HTML 2.0 specification.
87+
includes a <a href="./sample.html">sample style sheet</a> which
88+
describes how HTML documents typically are rendered.
8989

90-
<P>This specification also defines the
91-
<a href="./grammar.html">formal grammar</a> of the CSS2 language.
9290

93-
<P><em>The tutorial will be expanded, perhaps using examples from
94-
the CSS1 book.</em>
91+
<P><em>The tutorial will be expanded.</em>
9592

96-
<H2>Design principles behind CSS2</H2>
97-
<em>To be written ... </em>
98-
99-
<H3>The cascade</H3>
100-
101-
<P> In CSS, more than one style sheet can simultaneously influence a
102-
document's presentation. There are two main reasons for allowing
103-
multiple style sheets to combine and overlap: modularity and
104-
author/reader balance.
10593

106-
<DL>
107-
<DT> modularity
108-
<DD> A style sheet designer can combine several (partial) style sheets
109-
to reduce redundancy:
94+
<H2>Design principles behind CSS2</H2>
11095

111-
<PRE>
112-
@import url(http://www.style.org/pastoral);
113-
@import url(http://www.style.org/marine);
96+
<UL>
97+
<LI>backward compatibility
98+
<LI>complementary to structured documents
99+
<LI>cascading
100+
<LI>platform &amp; device independence
101+
<LI>accessibility
102+
<LI>maintainability
103+
<LI>network performance
104+
</UL>
114105

115-
H1 { color: red } /* override imported sheets */
116-
</PRE>
106+
<P><EM>These will be expanded</EM>
117107

118-
<DT> author/reader balance
119-
<DD> Both readers and authors can influence
120-
the presentation through style sheets. To do so, they use the same
121-
style sheet language thus reflecting a fundamental feature of the Web:
122-
everyone can become a publisher. The UA is free to choose the
123-
mechanism for referencing personal style sheets.
124-
</DL>
125108

126109
</BODY>
127110
</HTML>

0 commit comments

Comments
 (0)