Next / Previous / Contents / Shipman's homepage

4.7. XHTML rendering of narrative elements

An instance of the Narrative class from the birdnotes.py module is basically a container for one or more Paragraph instances.

A Paragraph instance, in turn, is a container for a sequence of text strings, each of which may or may not be marked up with either a genus or cite tag. The XHTML rendering of a Paragraph is:

        <div class='para'>
          text
        </div>

where text is a mixture of untagged text and text wrapped in span elements. For the styling of this block, see Section 5.11, “div.para: Ordinary paragraphs”.

Input text marked up with a genus tag is wrapped like this:

          <span class='genus'>...</span>

Text marked with cite will look like this:

          <span class='cite'>...</span>