[docmaker] Cosmetics.
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73
diff --git a/src/tools/docmaker/content.py b/src/tools/docmaker/content.py
index 9aa85ba..28fc85d 100644
--- a/src/tools/docmaker/content.py
+++ b/src/tools/docmaker/content.py
@@ -383,7 +383,7 @@ class DocSection:
class ContentProcessor:
def __init__( self ):
- """initialize a block content processor"""
+ """Initialize a block content processor."""
self.reset()
self.sections = {} # dictionary of documentation sections
@@ -394,7 +394,7 @@ class ContentProcessor:
self.headers = {} # dictionary of header macros
def set_section( self, section_name ):
- """set current section during parsing"""
+ """Set current section during parsing."""
if not self.sections.has_key( section_name ):
section = DocSection( section_name )
self.sections[section_name] = section
@@ -406,15 +406,14 @@ class ContentProcessor:
chapter = DocChapter( block )
self.chapters.append( chapter )
-
def reset( self ):
- """reset the content processor for a new block"""
+ """Reset the content processor for a new block."""
self.markups = []
self.markup = None
self.markup_lines = []
def add_markup( self ):
- """add a new markup section"""
+ """Add a new markup section."""
if self.markup and self.markup_lines:
# get rid of last line of markup if it's empty
@@ -430,8 +429,8 @@ class ContentProcessor:
self.markup_lines = []
def process_content( self, content ):
- """process a block content and return a list of DocMarkup objects
- corresponding to it"""
+ """Process a block content and return a list of DocMarkup objects
+ corresponding to it."""
markup = None
markup_lines = []
first = 1
@@ -595,7 +594,7 @@ class DocBlock:
return self.source.location()
def get_markup( self, tag_name ):
- """return the DocMarkup corresponding to a given tag in a block"""
+ """Return the DocMarkup corresponding to a given tag in a block."""
for m in self.markups:
if m.tag == string.lower( tag_name ):
return m
diff --git a/src/tools/docmaker/docmaker.py b/src/tools/docmaker/docmaker.py
index 4df0c98..4fb1abf 100644
--- a/src/tools/docmaker/docmaker.py
+++ b/src/tools/docmaker/docmaker.py
@@ -49,7 +49,7 @@ def usage():
def main( argv ):
- """main program loop"""
+ """Main program loop."""
global output_dir