[Docstring-checkins] CVS: dps/dps/transforms frontmatter.py,1.5,1.6
Status: Pre-Alpha
Brought to you by:
goodger
From: David G. <go...@us...> - 2002-03-04 04:45:52
|
Update of /cvsroot/docstring/dps/dps/transforms In directory usw-pr-cvs1:/tmp/cvs-serv14024/dps/dps/transforms Modified Files: frontmatter.py Log Message: Updated abstract. Index: frontmatter.py =================================================================== RCS file: /cvsroot/docstring/dps/dps/transforms/frontmatter.py,v retrieving revision 1.5 retrieving revision 1.6 diff -C2 -d -r1.5 -r1.6 *** frontmatter.py 22 Feb 2002 02:08:34 -0000 1.5 --- frontmatter.py 4 Mar 2002 04:45:49 -0000 1.6 *************** *** 166,170 **** field names are transformed to the corresponding DTD elements, becoming child elements of the "docinfo" element (except for the ! "abstract" element, which comes after "docinfo"). For example, given this document fragment after parsing:: --- 166,170 ---- field names are transformed to the corresponding DTD elements, becoming child elements of the "docinfo" element (except for the ! abstract, which becomes a "topic" element after "docinfo"). For example, given this document fragment after parsing:: *************** *** 179,183 **** <field_body> <paragraph> ! Kilgore Trout <field> <field_name> --- 179,183 ---- <field_body> <paragraph> ! A. Name <field> <field_name> *************** *** 196,200 **** <docinfo> <author> ! Kilgore Trout <status> frontmatter.py --- 196,200 ---- <docinfo> <author> ! A. Name <status> frontmatter.py *************** *** 266,275 **** if issubclass(biblioclass, nodes.authors): self.extract_authors(field, name, docinfo) ! elif issubclass(biblioclass, nodes.abstract): if abstract: field[-1] += self.doctree.reporter.warning( 'There can only be one abstract.') raise TransformError ! abstract = nodes.abstract('', *field[1].children) else: docinfo.append(biblioclass('', *field[1].children)) --- 266,278 ---- if issubclass(biblioclass, nodes.authors): self.extract_authors(field, name, docinfo) ! elif issubclass(biblioclass, nodes.topic): if abstract: field[-1] += self.doctree.reporter.warning( 'There can only be one abstract.') raise TransformError ! title = nodes.title( ! name, self.language.labels['abstract']) ! abstract = nodes.topic('', title, CLASS='abstract', ! *field[1].children) else: docinfo.append(biblioclass('', *field[1].children)) |