The screendump of a document under influence of three stylesheets:

The HTML listing:

<HTML> <HEAD> <LINK REL="style" HREF="../../viola/sgml/styles/HTML_sodium.stg"> </HEAD> <BODY> <H1>Simple stylesheets test</H1> <P> This document has links to three very simple stylesheets. The first stylesheet took effect from the beginning of this document. <P> Note that the above H1 is center aligned as specified by the stylesheet. Similarily, the following H2 is aligned to the right. <SECTION> <P>This and the next paragraph are living in a SECTION, and SECTIONs should have borders around it. <P>Some more text. </SECTION> <H2>Context Sensitivity</H2> <P> The following three ADDRESSes are each under influence of three different stylesheets. The point illustrated here is context sensitivity. That is, the Paragraphs take on different styles depending on whether they're inside or outside of the ADDRESS. A brief study of the stylesheet listings should make the evident enabling mechanism. <ADDRESS> <P>wei@ora.com <P>Digital Media Group, O'Reilly & Associates </ADDRESS> <LINK REL="style" HREF="../../viola/sgml/styles/HTML_address1.stg"> <P>Second stylesheet in effect starting from here. The text inside the address paragraphs should be blinking. <ADDRESS> <P>wei@ora.com <P>Digital Media Group, O'Reilly & Associates </ADDRESS> <LINK REL="style" HREF="../../viola/sgml/styles/HTML_address2.stg"> <P>Third stylesheet in effect starting from here. <ADDRESS> <P>wei@ora.com <P>Digital Media Group, O'Reilly & Associates </ADDRESS> </BODY> </HTML> And the stylesheets. Here's "HTML_sodium.stg": (BODY,HPANE,INPUT,P FGColor=black BGColor=grey70 BDColor=grey70 align=left (SECTION border=1 BDColor=red) (H1 FGColor=white BGColor=red BDColor=black align=center (H2,H3 FGColor=white BGColor=maroon BDColor=maroon align=right) (A FGColor=red) (BOLD,EMPH,STRONG fontWeight=bold) (CMD,KBD,SCREEN,LISTING,EXAMPLE fontSpacing=mono) (I fontSlant=italic) (ADDRESS align=left FGColor=black BGColor=grey70 BDColor=grey70 (P fontSlant=italic blinkColorOn=green blinkColorOff=black blink=1000)) )

The second stylesheet, "HTML_address1.stg":

(P FGColor=black BGColor=grey70 BDColor=grey70 align=left (ADDRESS align=left FGColor=black BGColor=grey70 BDColor=grey70 (P fontSlant=italic blinkColorOn=green blinkColorOff=black blink=1000)) )

And the third stylesheet, "HTML_address2.stg":

(P FGColor=black BGColor=grey70 BDColor=grey70 align=left (ADDRESS align=right (P fontSlant=italic)) )