DocumentScannerJsonConfiguration

data class DocumentScannerJsonConfiguration(var version: String? = null, var screen: String? = null, var acceptedAngleScore: Double? = null, var acceptedSizeScore: Double? = null, var acceptedBrightnessThreshold: Double? = null, var autoSnappingButtonHidden: Boolean? = null, var autoSnappingButtonTitle: String? = null, var autoSnappingEnabled: Boolean? = null, var autoSnappingSensitivity: Double? = null, var bottomBarBackgroundColor: JsonColor? = null, var bottomBarButtonsColor: JsonColor? = null, var cameraModule: JsonCameraModule? = null, var cameraBackgroundColor: JsonColor? = null, var cameraPreviewMode: JsonCameraPreviewMode? = null, var touchToFocusEnabled: Boolean? = null, var cancelButtonTitle: String? = null, var defaultPageFilter: JsonImageFilterType? = null, var enableCameraButtonTitle: String? = null, var enableCameraExplanationText: String? = null, var flashButtonHidden: Boolean? = null, var flashButtonTitle: String? = null, var flashEnabled: Boolean? = null, var forceUserGuidance: Boolean? = null, var ignoreOrientationMismatch: Boolean? = null, var imageScale: Double? = null, var multiPageButtonHidden: Boolean? = null, var multiPageButtonTitle: String? = null, var multiPageEnabled: Boolean? = null, var orientationLockMode: JsonOrientationLockMode? = null, var pageCounterButtonTitle: String? = null, var photoQualityPrioritization: JsonCapturePhotoQualityPrioritization? = null, var polygonBackgroundColor: JsonColor? = null, var polygonBackgroundColorOK: JsonColor? = null, var polygonColor: JsonColor? = null, var polygonColorOK: JsonColor? = null, var polygonLineWidth: Double? = null, var polygonCornerRadius: Double? = null, var polygonAutoSnapProgressColor: JsonColor? = null, var polygonAutoSnapProgressLineWidth: Double? = null, var polygonAutoSnapProgressEnabled: Boolean? = null, var requiredAspectRatios: List<JsonAspectRatio>? = null, var shutterButtonAutoInnerColor: JsonColor? = null, var shutterButtonAutoOuterColor: JsonColor? = null, var shutterButtonManualInnerColor: JsonColor? = null, var shutterButtonManualOuterColor: JsonColor? = null, var textHintBadAngles: String? = null, var textHintBadAspectRatio: String? = null, var textHintNothingDetected: String? = null, var textHintOffCenter: String? = null, var textHintOK: String? = null, var textHintTooDark: String? = null, var textHintTooNoisy: String? = null, var textHintTooSmall: String? = null, var topBarBackgroundColor: JsonColor? = null, var topBarButtonsActiveColor: JsonColor? = null, var topBarButtonsInactiveColor: JsonColor? = null, var userGuidanceBackgroundColor: JsonColor? = null, var userGuidanceTextColor: JsonColor? = null, var userGuidanceFontSize: Double? = null, var documentImageSizeLimit: JsonSize? = null, var shutterButtonHidden: Boolean? = null, var maxNumberOfPages: Int? = null, var useButtonsAllCaps: Boolean? = null, var accessibilityConfiguration: JsonDocumentScannerAccessibilityConfiguration? = null) : Parcelable

Constructors

Link copied to clipboard
constructor(version: String? = null, screen: String? = null, acceptedAngleScore: Double? = null, acceptedSizeScore: Double? = null, acceptedBrightnessThreshold: Double? = null, autoSnappingButtonHidden: Boolean? = null, autoSnappingButtonTitle: String? = null, autoSnappingEnabled: Boolean? = null, autoSnappingSensitivity: Double? = null, bottomBarBackgroundColor: JsonColor? = null, bottomBarButtonsColor: JsonColor? = null, cameraModule: JsonCameraModule? = null, cameraBackgroundColor: JsonColor? = null, cameraPreviewMode: JsonCameraPreviewMode? = null, touchToFocusEnabled: Boolean? = null, cancelButtonTitle: String? = null, defaultPageFilter: JsonImageFilterType? = null, enableCameraButtonTitle: String? = null, enableCameraExplanationText: String? = null, flashButtonHidden: Boolean? = null, flashButtonTitle: String? = null, flashEnabled: Boolean? = null, forceUserGuidance: Boolean? = null, ignoreOrientationMismatch: Boolean? = null, imageScale: Double? = null, multiPageButtonHidden: Boolean? = null, multiPageButtonTitle: String? = null, multiPageEnabled: Boolean? = null, orientationLockMode: JsonOrientationLockMode? = null, pageCounterButtonTitle: String? = null, photoQualityPrioritization: JsonCapturePhotoQualityPrioritization? = null, polygonBackgroundColor: JsonColor? = null, polygonBackgroundColorOK: JsonColor? = null, polygonColor: JsonColor? = null, polygonColorOK: JsonColor? = null, polygonLineWidth: Double? = null, polygonCornerRadius: Double? = null, polygonAutoSnapProgressColor: JsonColor? = null, polygonAutoSnapProgressLineWidth: Double? = null, polygonAutoSnapProgressEnabled: Boolean? = null, requiredAspectRatios: List<JsonAspectRatio>? = null, shutterButtonAutoInnerColor: JsonColor? = null, shutterButtonAutoOuterColor: JsonColor? = null, shutterButtonManualInnerColor: JsonColor? = null, shutterButtonManualOuterColor: JsonColor? = null, textHintBadAngles: String? = null, textHintBadAspectRatio: String? = null, textHintNothingDetected: String? = null, textHintOffCenter: String? = null, textHintOK: String? = null, textHintTooDark: String? = null, textHintTooNoisy: String? = null, textHintTooSmall: String? = null, topBarBackgroundColor: JsonColor? = null, topBarButtonsActiveColor: JsonColor? = null, topBarButtonsInactiveColor: JsonColor? = null, userGuidanceBackgroundColor: JsonColor? = null, userGuidanceTextColor: JsonColor? = null, userGuidanceFontSize: Double? = null, documentImageSizeLimit: JsonSize? = null, shutterButtonHidden: Boolean? = null, maxNumberOfPages: Int? = null, useButtonsAllCaps: Boolean? = null, accessibilityConfiguration: JsonDocumentScannerAccessibilityConfiguration? = null)

Properties

Link copied to clipboard

The minimum score in percent (0 - 100) of the perspective distortion to accept a detected document. Default is 75.0.

Link copied to clipboard

The brightness threshold to accept a detected document in the range of 0 (very dark) to 255 (very bright). If the average brightness value of the detectors input image is below this value, the status of the detection will be set to ERROR_TOO_DARK.

Link copied to clipboard

The minimum document width or height in percent (0 - 100) of the screen size to accept a detected document. Default is 80.0.

Link copied to clipboard

Allows you to customize the accessibility configuration for the Document Scanner UI

Link copied to clipboard

Controls whether the auto-snapping toggle button is hidden or not.

Link copied to clipboard

Title of the auto-snapping toggle button.

Link copied to clipboard

When auto-snapping is enabled the document scanner will take a photo automatically when a document is detected, conditions are good and the auto-snapping time-out elapses. In this mode the user can still tap the shutter button to snap a document.

Link copied to clipboard

Controls the auto-snapping speed. Sensitivity must be within the 0..1 range. A value of 1.0 triggers automatic capturing immediately, a value of 0.0 delays the automatic by 3 seconds. The default value is 0.66 (2 seconds)

Link copied to clipboard

The background color of the bottom shutter-bar.

Link copied to clipboard

The color of the title of all buttons in the bottom shutter-bar (Cancel button, etc.), as well as the camera permission prompt button.

Link copied to clipboard

The color of the camera background (relevant only when the camera preview mode is CameraPreviewMode.FIT_IN).

Link copied to clipboard

The preferred camera module (default - BACK)

Link copied to clipboard

Preview mode of the camera. Fit-In or Fill-In.

Link copied to clipboard

Title of the cancel button.

Link copied to clipboard

The default image filter type for new documents pages. Defaults to ImageFilterTypeNone.

Link copied to clipboard

Limits the maximum size of the document image. If width or height are zero, this property is effectively ignored.

Link copied to clipboard

Title of the button that opens the screen where the user can allow the usage of the camera by the app.

Link copied to clipboard

Text that will be displayed when the app is not allowed to use the camera, prompting the user to enable the usage of the camera.

Link copied to clipboard

Controls whether the flash toggle button is hidden or not.

Link copied to clipboard

Title of the flash toggle button.

Link copied to clipboard

Controls whether the flash should be initially enabled. The default value is FALSE.

Link copied to clipboard

Shows the user guidance elements if autosnapping is disabled.

Link copied to clipboard

Sets whether to ignore the OK_BUT_ORIENTATION_MISMATCH detection status. By default OrientationMismatch is not ignored.

Link copied to clipboard

The image scaling factor. The factor must be within the 0..1 range. A factor of 1 means that the resulting images retain their original size. When the factor is less than 1, resulting images will be made smaller by that factor. By default the scale is 1.

Link copied to clipboard

Maximum number of pages to scan. Ignored when set to null, or when multiPageEnabled is FALSE. Default value is null.

Link copied to clipboard

Controls whether the multi-page toggle button is hidden or not.

Link copied to clipboard

Title of the multi-page mode toggle button.

Link copied to clipboard

Controls multi-page mode. When enabled, the user can take multiple document photos before closing the screen by tapping the page counter button. When disabled, the screen will be closed immediately after the first document photo is made. The default value is FALSE.

Link copied to clipboard

UI Interface orientation lock mode

Link copied to clipboard

Title suffix of the button that finishes the document scanning when multi-page scanning is enabled. The button's title has the format "# Pages", where '#' shows the number of images captured up to now and the suffix "Pages" is set using this method.

Link copied to clipboard

The prioritization of still image quality and capturing speed. Defaults to CapturePhotoQualityPrioritization.BALANCED. If you experience lots of blurry still images try to set this property to CapturePhotoQualityPrioritization.QUALITY. Note: Has no effect on devices prior to iOS 13.0!. iOS only.

Link copied to clipboard

Stroke color of polygon auto snap progress animation. Default is green. Can't be nil.

Link copied to clipboard

Whether polygon auto snap progress animation is enabled or not. Default is true.

Link copied to clipboard

Line width of polygon auto snap progress animation. Default is 5.0.

Link copied to clipboard

The background color of the detected document outline when the document's angle, size or aspect ratio is not yet sufficiently good. (All net.doo.snap.lib.detector.DetectionResult with OK_BUT_XXX).

Link copied to clipboard

The background color of the detected document outline when we are ready to snap OK.

Link copied to clipboard

The color of the detected document outline when the document's angle, size or aspect ratio is not yet sufficiently good. (All detection statuses in net.doo.snap.lib.detector.DetectionResult that have the OK_BUT_XXX prefix).

Link copied to clipboard

The color of the detected document outline when we are ready to snap OK.

Link copied to clipboard

The radius to use when drawing rounded corners of the polygon. Default is 8.0.

Link copied to clipboard

Width of the detected document outline.

Link copied to clipboard

An optional array of aspect ratios the documents have to conform to.

Link copied to clipboard

The configuration object should be applied for this screen

Link copied to clipboard

Whether polygon auto snap progress animation is enabled or not. Default is true.

Link copied to clipboard

The background color of the shutter button in auto-snapping mode.

Link copied to clipboard

Hides the shutter button if set to TRUE. Shows it otherwise. Defaults to FALSE. If set to TRUE, auto-snapping is enabled and the property autoSnappingEnabled of the behaviour configuration will have no effect. Also the auto-snapping button will be hidden.

Link copied to clipboard

The foreground color of the shutter button in manual mode.

Link copied to clipboard

The background color of the shutter button in manual mode.

Link copied to clipboard

Text hint that will be shown when the current detection status is OK_BUT_BAD_ANGLES

Link copied to clipboard

Text hint that will be shown when the current detection status is OK_BUT_BAD_ASPECT_RATIO

Link copied to clipboard

Text hint that will be shown when the current detection status is ERROR_NOTHING_DETECTED

Link copied to clipboard

The text being displayed on the user-guidance label, when a document was detected, but its center is too far away from the image center.

Link copied to clipboard

Text hint that will be shown when the current detection status is OK

Link copied to clipboard

Text hint that will be shown when the current detection status is ERROR_TOO_DARK

Link copied to clipboard

Text hint that will be shown when the current detection status is ERROR_TOO_NOISY

Link copied to clipboard

Text hint that will be shown when the current detection status is OK_BUT_TOO_SMALL

Link copied to clipboard

The background color of the top toolbar.

Link copied to clipboard

The color of all active toggle buttons in the toolbar.

Link copied to clipboard

The color of all inactive toggle buttons in the toolbar.

Link copied to clipboard

Whether touch-to-focus is enabled on camera preview. Enabled by default. Android only.

Link copied to clipboard

Controls whether buttons should use all capitals style, as defined by the Android Material Design. Defaults to TRUE. Android only.

Link copied to clipboard

The background color of the user guidance hints.

Link copied to clipboard

Font size of the user guidance. Default is 17.0.

Link copied to clipboard

The text color of the user guidance hints.

Link copied to clipboard

A version of the configuration object