Label Capture Basic Overlay Listener
Defined in package com.scandit.datacapture.label.ui
- LabelCaptureBasicOverlayListener
interface LabelCaptureBasicOverlayListenerAdded in version 8.6.0
LabelCaptureBasicOverlayListener can be implemented to customize the visual appearance of highlighted labels and their fields in the basic overlay. When label capture identifies a new field, or when the LabelField.state property changes, brushForField() is called to determine the brush of the field.
- brushForField(overlay, field, label)
fun brushForField(overlay: LabelCaptureBasicOverlay, field: LabelField, label: CapturedLabel): Brush?
Added in version 8.6.0
Called to determine the visual style for a specific field when its state changes. This method allows you to provide custom styling based on field content, validation status, or other contextual information.
- brushForLabel(overlay, label)
fun brushForLabel(overlay: LabelCaptureBasicOverlay, label: CapturedLabel): Brush?
Added in version 8.6.0
Called to determine the visual style for a label when any of its fields change state or data. This method allows you to provide custom styling for entire labels based on their completion status, validation results, or other contextual information.
- onLabelTapped(overlay, label)
fun onLabelTapped(overlay: LabelCaptureBasicOverlay, label: CapturedLabel)
Added in version 8.6.0
Called when a user taps on a captured label in the overlay. This method allows you to handle user interactions with labels, such as showing detailed information, triggering validation flows, or providing additional options.
This method is called from the main thread, making it safe to perform UI operations directly.