File: Synopsis/Formatters/HTML/Fragments/SummaryCommenter.py
 1#
 2# Copyright (C) 2000 Stephen Davies
 3# Copyright (C) 2000 Stefan Seefeld
 4# All rights reserved.
 5# Licensed to the public under the terms of the GNU LGPL (>= 2),
 6# see the file COPYING for details.
 7#
 8
 9from Synopsis.Formatters.HTML.Tags import *
10from Default import Default
11
12class SummaryCommenter(Default):
13    """Adds summary annotations to all declarations."""
14
15    def format_declaration(self, decl):
16        summary = self.processor.documentation.summary(decl, self.view)
17        return div('doc', summary or '')
18