~azzar1/unity/add-show-desktop-key

« back to all changes in this revision

Viewing changes to ivle/worksheet/rst.py

  • Committer: William Grant
  • Date: 2010-02-15 01:12:46 UTC
  • Revision ID: grantw@unimelb.edu.au-20100215011246-2kxz9ro0gnrvqueo
Document how to tag releases in bzr.

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
 
#!/usr/bin/python
2
1
#
3
2
# Natural Language Toolkit: Documentation generation script
4
3
#
1556
1555
        self.body.append('<exercise weight="1" src="')
1557
1556
 
1558
1557
    def depart_exercise(self, node):
1559
 
        self.body.append('"/>')
 
1558
        self.body.append('"/>\n')
1560
1559
 
1561
1560
    def visit_challenge(self, node):
1562
1561
        self.body.append('<exercise weight="0" src="')
1563
1562
 
1564
1563
    def depart_challenge(self, node):
1565
 
        self.body.append('"/>')
 
1564
        self.body.append('"/>\n')
1566
1565
 
1567
1566
    def visit_literal(self, node):
1568
1567
        """Process text to prevent tokens from wrapping."""
1697
1696
            writer=CustomizedHTMLWriter(), reader=CustomizedReader())
1698
1697
        match = _OUTPUT_RE.search(output)
1699
1698
        if match:
1700
 
            return match.group(1)
 
1699
            return "<div>" + match.group(1) + "</div>"
1701
1700
        else:
1702
1701
            raise ValueError('Could not process exercise definition')
1703
1702