Class LineBreaker.Result

java.lang.Object
icyllis.modernui.graphics.text.LineBreaker.Result
Enclosing class:
LineBreaker

public static class LineBreaker.Result extends Object
Holds the result of the line breaking algorithm.
See Also:
  • Method Details

    • getLineCount

      public int getLineCount()
      Returns the number of lines in the paragraph.
      Returns:
      number of lines
    • getLineBreakOffset

      public int getLineBreakOffset(int lineIndex)
      Returns character offset of the break for a given line.
      Parameters:
      lineIndex - an index of the line.
      Returns:
      the break offset.
    • getLineWidth

      public float getLineWidth(int lineIndex)
      Returns width of a given line in pixels.
      Parameters:
      lineIndex - an index of the line.
      Returns:
      width of the line in pixels
    • getLineAscent

      public float getLineAscent(int lineIndex)
      Returns font ascent of the line in pixels.
      Parameters:
      lineIndex - an index of the line.
      Returns:
      font ascent of the line in pixels.
    • getLineDescent

      public float getLineDescent(int lineIndex)
      Returns font descent of the line in pixels.
      Parameters:
      lineIndex - an index of the line.
      Returns:
      font descent of the line in pixels.
    • hasLineTab

      public boolean hasLineTab(int lineIndex)
      Returns true if the line has a TAB character.
      Parameters:
      lineIndex - an index of the line.
      Returns:
      true if the line has a TAB character