diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml
index 3faca98..737c2d4 100644
--- a/.github/workflows/build.yml
+++ b/.github/workflows/build.yml
@@ -15,12 +15,13 @@ jobs:
os: [ubuntu-latest, windows-latest]
steps:
- uses: actions/checkout@v2
- - uses: actions/setup-java@v1
+ - uses: actions/setup-java@v4
with:
- java-version: '21.x'
+ distribution: 'temurin'
+ java-version: '21'
- uses: subosito/flutter-action@v2
with:
- flutter-version: '3.24.3'
+ flutter-version: '3.35.6'
- run: dart --version
- run: flutter --version
- run: flutter pub get
@@ -44,12 +45,13 @@ jobs:
os: [macos-15]
steps:
- uses: actions/checkout@v2
- - uses: actions/setup-java@v1
+ - uses: actions/setup-java@v4
with:
- java-version: '21.x'
+ distribution: 'temurin'
+ java-version: '21'
- uses: subosito/flutter-action@v2
with:
- flutter-version: '3.24.3'
+ flutter-version: '3.35.6'
- run: dart --version
- run: flutter --version
- run: flutter pub get
diff --git a/CHANGELOG.md b/CHANGELOG.md
index 53b3cbb..d78ad18 100644
--- a/CHANGELOG.md
+++ b/CHANGELOG.md
@@ -1,3 +1,14 @@
+## 1.3.0
+
+* Bumped Android to 4.4.0
+* Bumped iOS to 2.3.0
+* Added `userCanChangeDPI` and `userCanChangePageSize` to control visibility of DPI and page-size buttons in the per-image edit menu (both platforms).
+* Added `editMenuButtonText`, `dpiEditButtonText`, `pageSizeEditButtonText`, `doneButtonText`, and `undoCropButtonText` for localizing the edit mode and crop screen controls (iOS only).
+* Each image in the result now includes `DetectedTexts`, a list of detected text strings with bounding box positions. Populated when `performOnDeviceOCR` is `true`.
+* `DPI.auto` (the default) now outputs images at native camera resolution regardless of `pageFormat` on both platforms.
+* Deprecated `deleteOptionsButtonText` — will be removed in a future version.
+* Minimum iOS version bumped to 15.
+
## 1.2.0
* Bumped Android to 4.3.0
diff --git a/README.md b/README.md
index 6448bd3..73194ba 100644
--- a/README.md
+++ b/README.md
@@ -181,6 +181,12 @@ config.userCanCropManually = false;
// Whether to hide or show the color changing button in the Review Screen. (default shown/true)
config.userCanChangeColorSetting = false;
+// Whether to show the DPI button in the edit menu. (default false)
+config.userCanChangeDPI = false;
+
+// Whether to show the Page Size button in the edit menu. (default false)
+config.userCanChangePageSize = false;
+
// To add extra horizontal and / or vertical padding to the cropped image.
config.cropPadding.width = 100;
config.cropPadding.height = 100;
@@ -264,19 +270,6 @@ config.imageMovingSensitivityAndroid = 50;
#### iOS only
```dart
-
-// The text inside of the color selection alert dialog button named original.
-config.imageColorOriginalText = "original";
-
-// The text inside of the color selection alert dialog button named grayscale.
-config.imageColorGrayscaleText = "grayscale";
-
-// The text inside of the color selection alert dialog button named enhanced.
-config.imageColorEnhancedText = "enhanced";
-
-// The text inside of the color selection alert dialog button named black and white.
-config.imageColorBlackAndWhiteText = "Black & White";
-
// Whether the camera has a view finder overlay (a helper grid so the user knows where the document should be), should be a Boolean.
config.isViewFinderEnabled = true;
@@ -310,6 +303,10 @@ Add or edit the file `android/app/src/res/values/colors.xml`, add the following:
#444444
#ffffff
#2dc36a
+ #ffffff
+ #000000
+ #d32f2f
+ #1976d2
```
@@ -436,6 +433,42 @@ config.continueButtonText = "Continue"
// The text shown in the crop screen to save the bounding box.
config.saveCropButtonText = "Save"
+
+// The text inside of the color selection alert dialog button named original.
+config.imageColorOriginalText = "original";
+
+// The text inside of the color selection alert dialog button named grayscale.
+config.imageColorGrayscaleText = "grayscale";
+
+// The text inside of the color selection alert dialog button named enhanced.
+config.imageColorEnhancedText = "enhanced";
+
+// The text inside of the color selection alert dialog button named black and white.
+config.imageColorBlackAndWhiteText = "Black & White";
+
+// The text above the shutter button to indicate auto capture status.
+config.autoCaptureButtonText = "Auto";
+
+// The text above the shutter button to indicate auto capture status.
+config.manualButtonText = "Manual";
+
+// The title in the delete action alert dialog. (Deprecated: will be removed in a future version)
+config.deleteOptionsButtonText = "Delete or Retake?";
+
+// The text on the edit button in the review screen.
+config.editMenuButtonText = "Edit";
+
+// The text on the DPI button inside the edit menu.
+config.dpiEditButtonText = "DPI";
+
+// The text on the Page Size button inside the edit menu.
+config.pageSizeEditButtonText = "Page Size";
+
+// The text on the done button inside the edit menu.
+config.doneButtonText = "Done";
+
+// The text on the undo button in the crop screen.
+config.undoCropButtonText = "Undo";
```
### Customize image in CameraMode instructions
diff --git a/android/build.gradle b/android/build.gradle
index c42d4c1..0a61577 100644
--- a/android/build.gradle
+++ b/android/build.gradle
@@ -77,7 +77,7 @@ android {
}
dependencies {
- def fallbackKlippaScannerVersion = "4.3.0"
+ def fallbackKlippaScannerVersion = "4.4.0"
def klippaScannerVersion = project.hasProperty('klippaScannerVersion') ? project.klippaScannerVersion : fallbackKlippaScannerVersion
implementation "com.klippa:scanner:$klippaScannerVersion"
}
diff --git a/android/src/main/kotlin/com/klippa/scanner/klippa_scanner_sdk/KlippaScannerSdkPlugin.kt b/android/src/main/kotlin/com/klippa/scanner/klippa_scanner_sdk/KlippaScannerSdkPlugin.kt
index 8919493..7c42af2 100644
--- a/android/src/main/kotlin/com/klippa/scanner/klippa_scanner_sdk/KlippaScannerSdkPlugin.kt
+++ b/android/src/main/kotlin/com/klippa/scanner/klippa_scanner_sdk/KlippaScannerSdkPlugin.kt
@@ -289,6 +289,14 @@ class KlippaScannerSdkPlugin: FlutterPlugin, MethodCallHandler, ActivityAware, P
scannerSession.menu.userCanChangeColorSetting = it
}
+ call.argument("UserCanChangeDPI")?.let {
+ scannerSession.menu.userCanChangeDPI = it
+ }
+
+ call.argument("UserCanChangePageSize")?.let {
+ scannerSession.menu.userCanChangePageSize = it
+ }
+
call.argument("UserCanPickMediaFromStorage")?.let {
scannerSession.menu.userCanPickMediaFromStorage = it
}
@@ -401,10 +409,20 @@ class KlippaScannerSdkPlugin: FlutterPlugin, MethodCallHandler, ActivityAware, P
}
private fun klippaScannerDidFinishScanningWithResult(result: KlippaScannerResult) {
- val images: MutableList