public String diff_prettyHtml(LinkedList<Diff> diffs) {
    StringBuilder html = new StringBuilder();
    int i = 0;
    for (Diff aDiff : diffs) {
      String text = aDiff.text.replace("&", "&amp;").replace("<", "&lt;")
          .replace(">", "&gt;").replace("\n", "&para;<br>");
      switch (aDiff.operation) {
      case INSERT:
        html.append("<ins style=\"background:#e6ffe6;\">").append(text)
            .append("</ins>");
        break;
      case DELETE:
        html.append("<del style=\"background:#ffe6e6;\">").append(text)
            .append("</del>");
        break;
      case EQUAL:
        html.append("<span>").append(text).append("</span>");
        break;
      }
      if (aDiff.operation != Operation.DELETE) {
        i += aDiff.text.length();
      }
    }
    return html.toString();
  }