parameters: (self, tokensource, outfile)
docstring: Format all provided tokens and dump them into output file.
docstring_summary: Format all provided tokens and dump them into output file.
docstring_tokens: Format all provided tokens and dump them into output file .
function: def format(self, tokensource, outfile):
          """ Format all provided tokens and dump them into output file. """
          for ttype, value in tokensource:
              color = self.getColor(ttype, value)
              while color is None:
                  ttype = ttype[:-1]
                  color = self.getColor(ttype, value)
              if color:
                  spl = value.split('\n')
                  for line in spl[:-1]:
                      if line:
                          outfile.write(idaformat(color, line))
                      outfile.write('\n')
                  val = spl[-1]
                  if val:
                      outfile.write(idaformat(color, val))
              else:
                  outfile.write(value)
function_tokens: def format ( self , tokensource , outfile ) : for ttype , value in tokensource : color = self . getColor ( ttype , value ) while color is None : ttype = ttype [ : - 1 ] color = self . getColor ( ttype , value ) if color : spl = value . split ( '\n' ) for line in spl [ : - 1 ] : if line : outfile . write ( idaformat ( color , line ) ) outfile . write ( '\n' ) val = spl [ - 1 ] if val : outfile . write ( idaformat ( color , val ) ) else : outfile . write ( value )