code: function(str, css)
    {
      if (str == null || str.length == 0 || str == '\n' || css == null)
        return str;
  
      var _this = this,
          results = [],
          lines,
          line,
          spaces,
          i,
          l
          ;
  
      str = str.replace(/</g, '&lt;');
  
      // Replace two or more sequential spaces with &nbsp; leaving last space untouched.
      str = str.replace(/ {2,}/g, function(m)
      {
        spaces = '';
  
        for (i = 0, l = m.length; i < l - 1; i++)
          spaces += _this.opts.space;
  
        return spaces + ' ';
      });
  
      lines = getLines(str);
  
      // Split each line and apply <span class="...">...</span> to them so that leading spaces aren't included.
      for (i = 0, l = lines.length; i < l; i++)
      {
        line = lines[i];
        spaces = '';
  
        if (line.length > 0)
        {
          line = line.replace(/^(&nbsp;| )+/, function(s)
          {
            spaces = s;
            return '';
          });
  
          line = line.length === 0
            ? spaces
            : spaces + '<code class="' + css + '">' + line + '</code>'
            ;
        }
  
        results.push(line);
      }
  
      return results.join('\n');
    }
docs: Wraps each line of the string into <code/> tag with given style applied to it.
  
  @param {String} str   Input string.
  @param {String} css   Style name to apply to the string.
  @return {String}      Returns input string with each line surrounded by <span/> tag.