DynaWeb Publishers Guide
|2. Publishing DynaText Books Using DynaWeb|
|Introduction To Stylesheets|
This section provides a high-level overview of the information needed in order to construct a functional dynaweb.wv stylesheet, including a step-by-step walkthrough for converting your SGML styles into their HTML counterparts. If you are not acquainted with stylesheets, additional information can be found in the Publishing: Document Preparation book located with your DynaText documentation..
Stylesheets provide information about the styles used inside your documents - in this case, your DynaText books. Examples of this information are font size and color. All of this information (called property values) is used by DynaText to control the way your information is displayed on the screen and in print. DynaText reads the information from the stylesheet and applies it wherever that style is used inside a document.
In order to understand how to create a DynaWeb stylesheet, you will need to understand the concepts of style groups and inheritance.
A style group contains property values that can be applied to a number of different styles. The style group sets the attributes and values for the entire group. Individual styles that belong to the group have no attributes of their own, rather, they draw their attributes and values from the group definition.
Each DynaWeb style group corresponds to a specific HTML element, for which the group is named; for example, the h1 style group corresponds to the HTML H1 element. By using the appropriate DynaWeb style groups, you can easily set up your conversion stylesheets to convert books from your DTD to the HTML DTD.
Inheritance is the method by which individual styles get their values from style groups. Styles that belong to a style group derive the attributes from the group. However, an attribute set inside an individual style overrides the derived value from that style's group.
DynaWeb supplies a stock stylesheet that you can add into an existing fulltext.v stylesheet. The htmlgrps.v stylesheet contains pre-set style groups that correspond to the basic HTML styles. You can easily assign existing SGML styles to the style group that provides the HTML tags the style needs. The SGML style then derives the necessary properties, such as text-before and text-after, from the style group.