Example #1
0
 /**
  * This method can be called to enable or disable heuristic indentation for the output done using
  * this output context.
  *
  * <p>Here are some example calls:
  *
  * <blockquote>
  *
  * context.setIndentation("\n ", 1, 2); // indent by lf and 2 spaces per level
  * context.setIndentation(null, 0, 0); // disable indentation
  * context.setIndentation("\r\n\t\t\t\t\t\t\t\t", 2, 1); // indent by windows lf and 1 tab per
  * level
  *
  * </blockquote>
  *
  * @param indentStr String to use for indentation; if non-null, will enable indentation, if null,
  *     will disable it. Used in conjunction with the other arguments
  * @param startOffset Initial character offset for the first level of indentation (current
  *     context; usually root context): basically, number of leading characters from <code>
  *     indentStr</code> to output.
  * @param step Number of characters to add from the indentation String for each new level (and to
  *     subtract when closing levels).
  */
 public void setIndentation(String indentStr, int startOffset, int step) {
   _context.setIndentation(indentStr, startOffset, step);
 }