getPageTextRects

abstract fun getPageTextRects(@IntRange(from = 0) pageIndex: Int, startIndex: Int, length: Int): List<RectF>

Returns the rects of the range of characters on a page.

Return

List of rects of the characters on page in PDF point (1/72 of an inch) units. May be an empty list if the character is not represented visually.

Parameters

pageIndex

Page number of the page, zero indexed.

startIndex

Index of the starting character.

length

Number of characters in sequence.


abstract fun getPageTextRects(@IntRange(from = 0) pageIndex: Int, startIndex: Int, length: Int, markupPadding: Boolean): List<RectF>

Returns the rects of the range of characters on a page.

Return

List of rects of the characters on page in PDF point (1/72 of an inch) units. May be an empty list if the character is not represented visually.

Parameters

pageIndex

Page number of the page, zero indexed.

startIndex

Index of the starting character.

length

Number of characters in sequence.

markupPadding

Take the font height into account in the rects to make better suited for being displayed around the text.