HighlightAnnotation
class HighlightAnnotation : PdfAnnotation
kotlin.Any | ||
↳ | android.graphics.pdf.component.PdfAnnotation | |
↳ | android.graphics.pdf.component.HighlightAnnotation |
Represents a highlight annotation in a PDF document.
If the highlight color is not explicitly set using #setColor(android.graphics.Color), the default color is yellow.
Summary
Public constructors | |
---|---|
HighlightAnnotation(boundsList: MutableList<RectF!>) Creates a new highlight annotation with the specified bounds list. |
Public methods | |
---|---|
MutableList<RectF!> |
Returns the bounding rectangles of the highlight annotation. |
Int |
getColor() Returns the highlight color of the annotation. |
Unit |
setBoundsList(boundsList: MutableList<RectF!>) Sets the bounding rectangles of the highlight annotation. |
Unit |
Sets the highlight color of the annotation. |
Inherited functions | |
---|---|
Public constructors
HighlightAnnotation
HighlightAnnotation(boundsList: MutableList<RectF!>)
Creates a new highlight annotation with the specified bounds list.
The default highlight color is yellow
Parameters | |
---|---|
boundsList |
MutableList<RectF!>: The bounding rectangle of the annotation. This value cannot be null . |
Public methods
getBoundsList
fun getBoundsList(): MutableList<RectF!>
Returns the bounding rectangles of the highlight annotation.
Return | |
---|---|
MutableList<RectF!> |
The bounding rectangles. This value cannot be null . |
getColor
fun getColor(): Int
Returns the highlight color of the annotation.
Return | |
---|---|
Int |
The highlight color. |
setBoundsList
fun setBoundsList(boundsList: MutableList<RectF!>): Unit
Sets the bounding rectangles of the highlight annotation. Each rect in the list mBoundsList represent an absolute position of highlight inside the page of the document
Parameters | |
---|---|
boundsList |
MutableList<RectF!>: The new bounding rectangles. This value cannot be null . |
Exceptions | |
---|---|
java.lang.IllegalArgumentException |
if the given bounds list is empty |
setColor
fun setColor(color: Int): Unit
Sets the highlight color of the annotation.
Parameters | |
---|---|
color |
Int: The new highlight color. |