> For the complete documentation index, see [llms.txt](https://regulaforensics.gitbook.io/android/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://regulaforensics.gitbook.io/android/master-6/custom-settings.md).

# Custom settings

## Contents

* [Process Params](/android/master-6/custom-settings.md#process-params)
  * [Multipage Processing](/android/master-6/custom-settings.md#multipage-processing)
  * [Date Format](/android/master-6/custom-settings.md#date-format)
  * [Logs](/android/master-6/custom-settings.md#logs)
  * [Scenario](/android/master-6/custom-settings.md#scenario)
  * [Barcode Types](/android/master-6/custom-settings.md#barcode-types)
  * [RFID-chip](/android/master-6/custom-settings.md#rfid-chip)
  * [Filters](/android/master-6/custom-settings.md#filters)
  * [Detection](/android/master-6/custom-settings.md#detection)
* [Functionality](/android/master-6/custom-settings.md#functionality)
  * [Camera Frame](/android/master-6/custom-settings.md#camera-frame)
  * [Buttons](/android/master-6/custom-settings.md#buttons)
  * [Detection](/android/master-6/custom-settings.md#detection-1)
  * [Orientation](/android/master-6/custom-settings.md#orientation)
  * [Single Frame Capturing](/android/master-6/custom-settings.md#single-frame-capturing)
* [Customization](/android/master-6/custom-settings.md#customization)
  * [Camera Frame](/android/master-6/custom-settings.md#camera-frame-1)
  * [Status Message](/android/master-6/custom-settings.md#status-message)
  * [Result Status Message](/android/master-6/custom-settings.md#result-status-message)
  * [Animation](/android/master-6/custom-settings.md#animation)
  * [Visual Elements](/android/master-6/custom-settings.md#visual-elements)
  * [Skip Button](/android/master-6/custom-settings.md#skip-button)
  * [Loading Indicator](/android/master-6/custom-settings.md#loading-indicator)
  * [Background](/android/master-6/custom-settings.md#background)
* [Version](/android/master-6/custom-settings.md#version)

## Process Params

### Multipage Processing

Multipage processing allows to read more than one page. Turn on/off multipage:

```java
DocumentReader.Instance().processParams.multipageProcessing = true/false
```

### Date Format

You can change the format string of displayed dates in the results. Mask examples: "dd/mm/yyyy", "mm/dd/yyyy", "dd-mm-yyyy", "mm-dd-yyyy", "dd/mm/yy":

```java
DocumentReader.Instance().processParams.dateFormat = "dd-mm-yyyy"
```

### Logs

If set, Core logs will be written to logcat:

```java
DocumentReader.Instance().processParams.logs = true/false
```

If set, deep logs will be saved (in case of reading problems). Turn on/off logs saving:

```java
DocumentReader.Instance().processParams.debugSaveLogs = true/false
```

If set, input images will be saved (in case of reading problems). Turn on/off images saving:

```java
DocumentReader.Instance().processParams.debugSaveImages = true/false
```

If set, input images will be cropped and saved. Turn on/off image saving:

```java
DocumentReader.Instance().processParams.debugSaveCroppedImages = true/false
```

Allows you to get the path to the folder of the current session. Before using this, enable save logs. Each new session provides different path:

```java
DocumentReader.Instance().processParams.sessionLogFolder
```

### Scenario

Set proper scenario. You can find information of how to get available scenarios [here](/android/master-6/scenarios.md):

```java
DocumentReader.Instance().processParams.scenario = "Barcode"
```

### Barcode Types

Set the types of [barcodes](/android/master-6/enumerations/barcodetypes.md) that you wish to process:

```java
DocumentReader.Instance().processParams.doBarcodes = new String[]{BarcodeTypes.QR, BarcodeTypes.Barcode_1D}
```

### RFID-chip

RFID-chip reading parameters:

```java
DocumentReader.Instance().processParams.rfidScenario
```

### Filters

Set the [list of the document ID's](https://downloads.regulaforensics.com/work/SDK/doc/AllDocs/Documents%20List.xls) to process. All documents will be processed, if empty:

```java
DocumentReader.Instance().processParams.documentIDList = new int[]{-274257313, -2004898043}
```

If you read document which contains MRZ, all fields will be extracted. If you read document with OCR, you can set the list of [field types](/android/master-6/enumerations/evisualfieldtype.md) that you wish to extract, other fields will be skipped during processing. All fields will be extracted, if the *fieldTypesFilter* is empty:

```java
DocumentReader.Instance().processParams.fieldTypesFilter = new int[]{eVisualFieldType.FT_DATE_OF_EXPIRY}
```

### Detection

If you enable this parameter, document focus check will be omitted:

```java
DocumentReader.Instance().processParams.disableFocusingCheck = true/false
```

## Functionality

### Camera Frame

![](https://img.regulaforensics.com/Screenshots/SDK-4.2/Screenshot_1_nexus5x-portrait.png)

Set this setting to override default cropping frame on camera activity provided by scenario using one of [`DocReaderFrame`](/android/master-6/enumerations/docreaderframe.md) members:

```java
DocumentReader.Instance().functionality.cameraFrame = DocReaderFrame.MAX
```

{% hint style="warning" %}
Frame is cropped by camera frame. If you set the camera frame to full screen, Core will crop frame by phone borders. Using this setting may lead to lower performance because of huge frame size. Any changes which are connected with camera frame alter scanning process. You can also set the [camera frame width](/android/master-6/custom-settings.md#camera-frame-1).
{% endhint %}

### Buttons

![](https://img.regulaforensics.com/Screenshots/SDK-4.2/Screenshot_9_nexus5x-portrait.png)

Show/hide torch button:

```java
DocumentReader.Instance().functionality.showTorchButton = true/false
```

Show/hide close button:

```java
DocumentReader.Instance().functionality.showCloseButton = true/false
```

{% hint style="info" %}
You can close camera view manually by using *DocumentReader.Instance().stopScanner()* function.&#x20;
{% endhint %}

*Capture* allows to take picture and process as a single frame. Show/hide *capture* button:

```java
DocumentReader.Instance().functionality.showCaptureButton = true/false
```

If set, frame expanding button will be shown on video capture screen. Show/hide change frame button:

```java
DocumentReader.Instance().functionality.showChangeFrameButton = true/false
```

Show/hide skip next page button:

```java
DocumentReader.Instance().functionality.showSkipNextPageButton = true/false
```

Show/hide the button for switching between cameras during processing:

```java
DocumentReader.Instance().functionality.showCameraSwitchBtn = true/false
```

### Detection

DocumentReader will receive data from Motion Sensor and pause scanning when device is moving. Turn on/off video capture motion control:

```java
DocumentReader.Instance().functionality.videoCaptureMotionControl = true/false
```

If set, scanning will be paused while camera is focusing (it can decrease camera processing speed):

```java
DocumentReader.Instance().functionality.skipFocusingFrames = true/false
```

### Orientation

Defines orientation of activities by using one of [`DocReaderOrientation`](/android/master-6/enumerations/docreaderorientation.md) members:

```java
DocumentReader.Instance().functionality.orientation = DocReaderOrientation.PORTRAIT
```

### Single Frame Capturing

If set, as soon as document is located during video mode, picture will be taken and processed as single frame. It is used for devices with poor-quality video preview:

```java
DocumentReader.Instance().functionality.pictureOnBoundsReady = true/false
```

## Customization

### Camera Frame

![](https://img.regulaforensics.com/Screenshots/SDK-4.2/Screenshot_1_nexus5x-portrait.png)

Set thickness of document bounds border on the video preview (dp):

```java
DocumentReader.Instance().customization.cameraFrameBorderWidth
```

Hex string of document bounds border color in default state:

```java
DocumentReader.Instance().customization.cameraFrameDefaultColor
```

Hex string of document bounds border color in document detected state:

```java
DocumentReader.Instance().customization.cameraFrameActiveColor
```

Defines the shape of document bounds border. Use one of [`FrameShapeType`](/android/master-6/enumerations/frameshapetype.md) members:

```java
DocumentReader.Instance().customization.cameraFrameShapeType = FrameShapeType.CORNER
```

Defines the length (dp) of the corner side in shape mode [`FrameShapeType.CORNER`](/android/master-6/enumerations/frameshapetype.md):

```java
DocumentReader.Instance().customization.cameraFrameLineLength
```

{% hint style="warning" %}
Frame is cropped by camera frame. Any changes with camera frame may alter scanning process. You can change the default camera frame view, even remove it. Discover [Functionality](/android/master-6/custom-settings.md#camera-frame) page to find out how to do it.
{% endhint %}

### Status Message

![](https://img.regulaforensics.com/Screenshots/SDK-4.2/Screenshot_2_nexus5x-portrait.png)

Set a status message next to the frame:

```java
DocumentReader.Instance().customization.status
```

Turn on/off status message:

```java
DocumentReader.Instance().customization.showStatusMessages = true/false
```

Set the text font for the status message, so-called hint message:

```java
DocumentReader.Instance().customization.statusTextFont
```

Size of main text status (sp):

```java
DocumentReader.Instance().customization.statusTextSize
```

Hex string of main text status color:

```java
DocumentReader.Instance().customization.statusTextColor
```

Allows you to change the location of the status. For example, if you set the multiplier to 0.5 and the number of pixels by vertical is equal to 800, your message will be centralized and located at 200 px from top, i.e. (800 / 2) \* 0.5 = 200 px. If multiplier is equal to 1, the message will be centered. If multiplier is equal to zero, default location will be used:

```java
DocumentReader.Instance().customization.statusPositionMultiplier = 0.5D
```

### Result Status Message

![](https://img.regulaforensics.com/Screenshots/SDK-4.2/Screenshot_4_nexus5x-portrait.png)

Turn on/off result status message:

```java
DocumentReader.Instance().customization.showResultStatusMessages = true/false
```

Set the text font for the current status:

```java
DocumentReader.Instance().customization.resultStatusTextFont
```

Set the size of current text status (sp):

```java
DocumentReader.Instance().customization.resultStatusTextSize
```

Hex string of current text status color:

```java
DocumentReader.Instance().customization.resultStatusTextColor
```

Hex string of current text status background color:

```java
DocumentReader.Instance().customization.resultStatusBackgroundColor
```

Allows you to change the location of the results status. For example, if you set the multiplier to 0.5 and the number of pixels by vertical is equal to 800, your message will be centralized and located at 200 px from top, i.e. (800 / 2) \* 0.5 = 200 px. If multiplier is equal to 1, the message will be centered. If multiplier is equal to zero, default location will be used:

```java
DocumentReader.Instance().customization.resultStatusPositionMultiplier = 0.5D
```

### Animation

![](https://img.regulaforensics.com/Screenshots/SDK-4.2/Screenshot_5_nexus5x-portrait.png)

If set, animation showing how to position document will be displayed. Show/hide help animation:

```java
DocumentReader.Instance().customization.showHelpAnimation = true/false
```

If set, expecting page turn animation will be shown. Turn on/off next page animation:

```java
DocumentReader.Instance().customization.showNextPageAnimation = true/false
```

You can set image for help animation. If not set, default image will be used:

```java
DocumentReader.Instance().customization.helpAnimationImageID = R.drawable.icon
```

You can set front image for multipage animation. If not set, default image will be used:

```java
DocumentReader.Instance().customization.multipageAnimationFrontImage = R.drawable.icon
```

You can set back image for multipage animation. If not set, default image will be used:

```java
DocumentReader.Instance().customization.multipageAnimationBackImage = R.drawable.icon
```

### Visual Elements

![](https://img.regulaforensics.com/Screenshots/SDK-4.2/Screenshot_6_nexus5x-portrait.png)

Hex string of visual elements color (one for all):

```java
DocumentReader.Instance().customization.tintColor
```

### Skip Button

![](https://img.regulaforensics.com/Screenshots/SDK-4.2/Screenshot_10_nexus5x-portrait.png)

Set the background color to the multipage button:

```java
DocumentReader.Instance().customization.multipageButtonBackgroundColor
```

### Loading Indicator

![](https://img.regulaforensics.com/Screenshots/SDK-4.2/Screenshot_7_nexus5x-portrait.png)

Hex string of loading indicator(s) color. You can see it if you press the capture button:

```java
DocumentReader.Instance().customization.activityIndicatorColor
```

### Background

![](https://img.regulaforensics.com/Screenshots/SDK-4.2/Screenshot_8_nexus5x-portrait.png)

If set, background will be darkened around the document detection frame. Show/hide background mask:

```java
DocumentReader.Instance().customization.showBackgroundMask = true/false
```

Allows to set image within [camera frame](/android/master-6/custom-settings.md#camera-frame-1):

```java
DocumentReader.Instance().customization.borderBackgroundImage = R.drawable.icon
```

## Version

To get the API version use:

```java
DocumentReader.Instance().version.api
```

To get the Core version use:

```java
DocumentReader.Instance().version.core
```

To get the Core mode use:

```java
DocumentReader.Instance().version.coreMode
```

Allows you to get database id, e.g. KAZ:

```java
DocumentReader.Instance().version.database.databaseID
```

To get the database version use:

```java
DocumentReader.Instance().version.database.version
```

Allows you to get the database export date:

```java
DocumentReader.Instance().version.database.date
```

To get the list of supported database documents use:

```java
DocumentReader.Instance().version.database.databaseDescription
```

Allows to get the number of supported database countries:

```java
DocumentReader.Instance().version.database.countriesNumber
```

Allows to get the number of supported database documents:

```java
DocumentReader.Instance().version.database.documentsNumber
```
