parameters: (output_dir, bug_counter)
return_statement: return name
docstring: Bug summary is a HTML table to give a better overview of the bugs.
docstring_summary: Bug summary is a HTML table to give a better overview of the bugs.
docstring_tokens: Bug summary is a HTML table to give a better overview of the bugs .
function: def bug_summary(output_dir, bug_counter):
      """ Bug summary is a HTML table to give a better overview of the bugs. """
  
      name = os.path.join(output_dir, 'summary.html.fragment')
      with open(name, 'w') as handle:
          indent = 4
          handle.write(reindent("""
          |<h2>Bug Summary</h2>
          |<table>
          |  <thead>
          |    <tr>
          |      <td>Bug Type</td>
          |      <td>Quantity</td>
          |      <td class="sorttable_nosort">Display?</td>
          |    </tr>
          |  </thead>
          |  <tbody>""", indent))
          handle.write(reindent("""
          |    <tr style="font-weight:bold">
          |      <td class="SUMM_DESC">All Bugs</td>
          |      <td class="Q">{0}</td>
          |      <td>
          |        <center>
          |          <input checked type="checkbox" id="AllBugsCheck"
          |                 onClick="CopyCheckedStateToCheckButtons(this);"/>
          |        </center>
          |      </td>
          |    </tr>""", indent).format(bug_counter.total))
          for category, types in bug_counter.categories.items():
              handle.write(reindent("""
          |    <tr>
          |      <th>{0}</th><th colspan=2></th>
          |    </tr>""", indent).format(category))
              for bug_type in types.values():
                  handle.write(reindent("""
          |    <tr>
          |      <td class="SUMM_DESC">{bug_type}</td>
          |      <td class="Q">{bug_count}</td>
          |      <td>
          |        <center>
          |          <input checked type="checkbox"
          |                 onClick="ToggleDisplay(this,'{bug_type_class}');"/>
          |        </center>
          |      </td>
          |    </tr>""", indent).format(**bug_type))
          handle.write(reindent("""
          |  </tbody>
          |</table>""", indent))
          handle.write(comment('SUMMARYBUGEND'))
      return name
function_tokens: def bug_summary ( output_dir , bug_counter ) : name = os . path . join ( output_dir , 'summary.html.fragment' ) with open ( name , 'w' ) as handle : indent = 4 handle . write ( reindent ( """
          |<h2>Bug Summary</h2>
          |<table>
          |  <thead>
          |    <tr>
          |      <td>Bug Type</td>
          |      <td>Quantity</td>
          |      <td class="sorttable_nosort">Display?</td>
          |    </tr>
          |  </thead>
          |  <tbody>""" , indent ) ) handle . write ( reindent ( """
          |    <tr style="font-weight:bold">
          |      <td class="SUMM_DESC">All Bugs</td>
          |      <td class="Q">{0}</td>
          |      <td>
          |        <center>
          |          <input checked type="checkbox" id="AllBugsCheck"
          |                 onClick="CopyCheckedStateToCheckButtons(this);"/>
          |        </center>
          |      </td>
          |    </tr>""" , indent ) . format ( bug_counter . total ) ) for category , types in bug_counter . categories . items ( ) : handle . write ( reindent ( """
          |    <tr>
          |      <th>{0}</th><th colspan=2></th>
          |    </tr>""" , indent ) . format ( category ) ) for bug_type in types . values ( ) : handle . write ( reindent ( """
          |    <tr>
          |      <td class="SUMM_DESC">{bug_type}</td>
          |      <td class="Q">{bug_count}</td>
          |      <td>
          |        <center>
          |          <input checked type="checkbox"
          |                 onClick="ToggleDisplay(this,'{bug_type_class}');"/>
          |        </center>
          |      </td>
          |    </tr>""" , indent ) . format ( * * bug_type ) ) handle . write ( reindent ( """
          |  </tbody>
          |</table>""" , indent ) ) handle . write ( comment ( 'SUMMARYBUGEND' ) ) return name