AnnotationsView.OnAnnotationLocatedListener


public fun interface AnnotationsView.OnAnnotationLocatedListener


Callback interface for annotation hit events.

Summary

Public methods

abstract void
onAnnotationsLocated(
    float x,
    float y,
    @NonNull List<@NonNull KeyedPdfAnnotation> annotations
)

Called when one or more annotations are successfully located at a specific touch location.

Public methods

onAnnotationsLocated

Added in 1.0.0-alpha19
abstract void onAnnotationsLocated(
    float x,
    float y,
    @NonNull List<@NonNull KeyedPdfAnnotation> annotations
)

Called when one or more annotations are successfully located at a specific touch location.

Parameters
float x

The x-coordinate of the touch event in view coordinates.

float y

The y-coordinate of the touch event in view coordinates.

@NonNull List<@NonNull KeyedPdfAnnotation> annotations

The list of KeyedPdfAnnotation objects found at the (x, y) location, typically ordered by visual stacking order (Z-index) (top-bottom).