GiniConfiguration
@objc
public final class GiniConfiguration : NSObject
The GiniConfiguration
class allows customizations to the look and feel of the Gini Capture SDK.
If there are limitations regarding which API can be used, this is clearly stated for the specific attribute.
Note
Text can also be set by using the appropriate keys in aLocalizable.strings
file in the projects bundle.
The library will prefer whatever value is set in the following order: attribute in configuration,
key in strings file in project bundle, key in strings file in GiniCapture
bundle.
Note
Images can only be set by providing images with the same filename in an assets file or as individual files in the projects bundle. The library will prefer whatever value is set in the following order: asset file in project bundle, asset file inGiniCapture
bundle.
Attention
If there are conflicting pairs of image and text for an interface element (e.g.navigationBarCameraTitleCloseButton
) the image will always be preferred,
while making sure the accessibility label is set.
-
Supported document types by Gini Capture SDK.
See moreDeclaration
Swift
@objc public enum GiniCaptureImportFileTypes : Int
-
Returns a
GiniConfiguration
instance which allows to set individual configurations to change the look and feel of the Gini Capture SDK.Declaration
Swift
public override init()
Return Value
Instance of
GiniConfiguration
.
-
Sets custom validations that can be done apart from the default ones (file size, file type…). It should throw a
CustomDocumentValidationError
error.Declaration
Swift
@objc public var customDocumentValidations: ((GiniCaptureDocument) -> CustomDocumentValidationResult)
-
Sets the font used in the GiniCapture library by default.
Declaration
Swift
@objc public lazy var customFont: GiniCaptureFont { get set }
-
Can be turned on during development to unlock extra information and to save captured images to camera roll.
Warning
Should never be used outside of a development enviroment.Declaration
Swift
@objc public var debugModeOn: Bool
-
Used to handle all the logging messages in order to log them in a different way.
Declaration
Swift
@objc public var logger: GiniLogger
-
Indicates whether the multipage feature is enabled or not. In case of
true
, multiple pages can be processed, showing a different review screen when capturing.Declaration
Swift
@objc public var multipageEnabled: Bool
-
Sets the tint color of the navigation bar in all screens of the Gini Capture SDK to the globally specified color or to a default color.
Note
Screen API only.Declaration
Swift
@objc public var navigationBarTintColor: UIColor
-
Sets the tint color of all navigation items in all screens of the Gini Capture SDK to the globally specified color.
Note
Screen API only.Declaration
Swift
@objc public var navigationBarItemTintColor: UIColor?
-
Sets the font of all navigation items in all screens of the Gini Capture SDK to the globally specified font or a default font.
Note
Screen API only.Declaration
Swift
@objc public var navigationBarItemFont: UIFont
-
Sets the title color in the navigation bar in all screens of the Gini Capture SDK to the globally specified color or to a default color.
Note
Screen API only.Declaration
Swift
@objc public var navigationBarTitleColor: UIColor
-
Sets the title font in the navigation bar in all screens of the Gini Capture SDK to the globally specified font or to a default font.
Note
Screen API only.Declaration
Swift
@objc public var navigationBarTitleFont: UIFont
-
Sets the tint color of the UIDocumentPickerViewController navigation bar.
Note
Use only if you have a customUIAppearance
for your UINavigationBarNote
Only iOS >= 11.0Declaration
Swift
@objc public var documentPickerNavigationBarTintColor: UIColor?
-
Sets the background color of an informal notice. Notices are small pieces of information appearing underneath the navigation bar.
Declaration
Swift
@objc public var noticeInformationBackgroundColor: UIColor
-
Sets the text color of an informal notice. Notices are small pieces of information appearing underneath the navigation bar.
Declaration
Swift
@objc public var noticeInformationTextColor: UIColor
-
Sets the background color of an error notice. Notices are small pieces of information appearing underneath the navigation bar.
Declaration
Swift
@objc public var noticeErrorBackgroundColor: UIColor
-
Sets the text color of an error notice. Notices are small pieces of information appearing underneath the navigation bar.
Declaration
Swift
@objc public var noticeErrorTextColor: UIColor
-
Indicates whether the open with feature is enabled or not. In case of
true
, a new option with the open with tutorial wil be shown in the Help menu.Declaration
Swift
@objc public var openWithEnabled: Bool
-
Indicates whether the QR Code scanning feature is enabled or not.
Declaration
Swift
@objc public var qrCodeScanningEnabled: Bool
-
Indicates the status bar style in the Gini Capture SDK.
Note
IfUIViewControllerBasedStatusBarAppearance
is set tofalse
in theInfo.plist
, it may not work in future versions of iOS since theUIApplication.setStatusBarStyle
method was deprecated on iOS 9.0.Declaration
Swift
@objc public var statusBarStyle: UIStatusBarStyle
-
Sets the text color of the descriptional text when camera access was denied.
Declaration
Swift
@objc public var cameraNotAuthorizedTextColor: UIColor
-
Sets the text color of the button title when camera access was denied.
Declaration
Swift
@objc public var cameraNotAuthorizedButtonTitleColor: UIColor
-
Sets the color of the loading indicator on the camera screen to the specified color.
Declaration
Swift
@objc public var cameraSetupLoadingIndicatorColor: UIColor
-
Sets the color of camera preview corner guides.
Declaration
Swift
@objc public var cameraPreviewCornerGuidesColor: UIColor
-
Sets the background color of camera container view.
Declaration
Swift
@objc public var cameraContainerViewBackgroundColor: GiniColor
-
Sets the color of camera preview frame.
Declaration
Swift
@objc public var cameraPreviewFrameColor: GiniColor
-
Sets the background color of camera buttons view.
Declaration
Swift
@objc public var cameraButtonsViewBackgroundColor: GiniColor
-
Set the types supported by the file import feature.
GiniCaptureImportFileTypes.none
by default.Declaration
Swift
@objc public var fileImportSupportedTypes: GiniCaptureImportFileTypes
-
Sets the background color of the new file import button hint.
Declaration
Swift
@objc public var fileImportToolTipBackgroundColor: UIColor
-
Sets the text color of the new file import button hint.
Declaration
Swift
@objc public var fileImportToolTipTextColor: UIColor
-
Sets the color of the close button for the file import button hint.
Declaration
Swift
@objc public var fileImportToolTipCloseButtonColor: UIColor
-
Sets the background style when the tooltip is shown.
Declaration
Swift
public var toolTipOpaqueBackgroundStyle: OpaqueViewStyle { get set }
-
Sets the text color of the item selected background check.
Declaration
Swift
@objc public var galleryPickerItemSelectedBackgroundCheckColor: UIColor
-
Sets the background color for gallery screen.
Declaration
Swift
@objc public var galleryScreenBackgroundColor: GiniColor
-
Indicates whether the flash toggle should be shown in the camera screen.
Declaration
Swift
@objc public var flashToggleEnabled: Bool
-
When the flash toggle is enabled, this flag indicates if the flash is on by default.
Declaration
Swift
@objc public var flashOnByDefault: Bool
-
Sets the color of the captured images stack indicator label.
Declaration
Swift
@objc public var imagesStackIndicatorLabelTextcolor: UIColor
-
Sets the close button text in the navigation bar on the camera screen.
Note
Screen API only.Declaration
Swift
@objc public var navigationBarCameraTitleCloseButton: String
-
Sets the help button text in the navigation bar on the camera screen.
Note
Screen API only.Declaration
Swift
@objc public var navigationBarCameraTitleHelpButton: String
-
Sets the text color of the QR Code popup button.
Declaration
Swift
@objc public var qrCodePopupButtonColor: UIColor
-
Sets the text color of the QR Code popup label.
Declaration
Swift
@objc public var qrCodePopupTextColor: GiniColor
-
Sets the text color of the QR Code popup background.
Declaration
Swift
@objc public var qrCodePopupBackgroundColor: GiniColor
-
Sets the button color of the unsupported QR Code popup.
Declaration
Swift
@objc public var unsupportedQrCodePopupButtonColor: UIColor
-
Sets the text color of the unsupported QR Code popup.
Declaration
Swift
@objc public var unsupportedQrCodePopupTextColor: GiniColor
-
Sets the background color of the unsupported QR Code popup.
Declaration
Swift
@objc public var unsupportedQrCodePopupBackgroundColor: GiniColor
-
Sets the continue button text in the navigation bar on the onboarding screen.
Note
Screen API only.Declaration
Swift
@objc public var navigationBarOnboardingTitleContinueButton: String
-
Sets the color of the page controller’s page indicator items.
Declaration
Swift
@objc public var onboardingPageIndicatorColor: GiniColor
-
Sets the color of the page controller’s current page indicator item.
Declaration
Swift
@objc public var onboardingCurrentPageIndicatorColor: GiniColor
-
Sets alpha to the color of the page controller’s current page indicator item.
Declaration
Swift
@objc public var onboardingCurrentPageIndicatorAlpha: CGFloat
-
Indicates whether the onboarding screen should be presented at each start of the Gini Capture SDK.
Note
Screen API only.Declaration
Swift
@objc public var onboardingShowAtLaunch: Bool
-
Indicates whether the onboarding screen should be presented at the first start of the Gini Capture SDK. It is advised to do so.
Note
OverwritesonboardingShowAtLaunch
for the first launch.Note
Screen API only.Declaration
Swift
@objc public var onboardingShowAtFirstLaunch: Bool
-
Sets the color ot the text for all onboarding pages.
Declaration
Swift
@objc public var onboardingTextColor: GiniColor
-
Sets the background color for all onboarding pages.
Declaration
Swift
@objc public var onboardingScreenBackgroundColor: GiniColor
-
All onboarding pages which will be presented in a horizontal scroll view to the user. By default the Gini Capture SDK comes with three pages advising the user to keep the document flat, hold the device parallel and capture the whole document.
Note
Any array of views can be passed, but for your convenience we provide theGINIOnboardingPage
class.Declaration
Swift
@objc public var onboardingPages: [UIView] { get set }
-
Sets the back button text in the navigation bar on the review screen. Use this if you only want to show the title.
Note
Screen API only.Declaration
Swift
@objc public var navigationBarReviewTitleBackButton: String
-
Sets the close button text in the navigation bar on the review screen. Use this if you only want to show the title.
Note
Screen API only.Declaration
Swift
@objc public var navigationBarReviewTitleCloseButton: String
-
Sets the continue button text in the navigation bar on the review screen.
Note
Screen API only.Declaration
Swift
@objc public var navigationBarReviewTitleContinueButton: String
-
Sets the background color of the bottom section on the review screen containing the rotation button.
Note
Background will have a 20% transparency, to have enough space for the document image on smaller devices.Declaration
Swift
@objc public var reviewBottomViewBackgroundColor: UIColor
-
Sets the font of the text appearing at the bottom of the review screen.
Declaration
Swift
@objc public var reviewTextBottomFont: UIFont
-
Sets the color of the text appearing at the bottom of the review screen.
Declaration
Swift
@objc public var reviewTextBottomColor: UIColor
-
Sets the color of the pages container and toolbar.
Declaration
Swift
@objc public var multipagePagesContainerAndToolBarColor: GiniColor
-
Sets the color of the circle indicator.
Declaration
Swift
@objc public var indicatorCircleColor: GiniColor
-
Sets the tint color of the toolbar items.
Declaration
Swift
@objc public var multipageToolbarItemsColor: UIColor
-
Sets the tint color of the page indicator.
Declaration
Swift
@objc public var multipagePageIndicatorColor: UIColor
-
Sets the background color of the page selected indicator.
Declaration
Swift
@objc public var multipagePageSelectedIndicatorColor: UIColor
-
Sets the background color of the page background.
Declaration
Swift
@objc public var multipagePageBackgroundColor: GiniColor
-
Sets the tint color of the draggable icon in the page collection cell.
Declaration
Swift
@objc public var multipageDraggableIconColor: UIColor
-
Sets the background style when the tooltip is shown in the multipage screen.
Declaration
Swift
public var multipageToolTipOpaqueBackgroundStyle: OpaqueViewStyle
-
Sets the background color for the successfull upload icon.
Declaration
Swift
public var multipagePageSuccessfullUploadIconBackgroundColor: UIColor
-
Sets the background color for the failed upload icon.
Declaration
Swift
public var multipagePageFailureUploadIconBackgroundColor: UIColor
-
Sets the color of the loading indicator on the analysis screen to the specified color.
Declaration
Swift
@objc public var analysisLoadingIndicatorColor: UIColor
-
Sets the color of the PDF information view on the analysis screen to the specified color.
Declaration
Swift
@objc public var analysisPDFInformationBackgroundColor: UIColor
-
Sets the color of the PDF information view on the analysis screen to the specified color.
Declaration
Swift
@objc public var analysisPDFInformationTextColor: UIColor
-
Sets the back button text in the navigation bar on the analysis screen. Use this if you only want to show the title.
Note
Screen API only.Declaration
Swift
@objc public var navigationBarAnalysisTitleBackButton: String
-
Sets the background color for all help screens.
Declaration
Swift
@objc public var helpScreenBackgroundColor: GiniColor
-
Sets the background color for the cells on help screen.
Declaration
Swift
@objc public var helpScreenCellsBackgroundColor: GiniColor
-
Sets the back button text in the navigation bar on the help menu screen. Use this if you only want to show the title.
Note
Screen API only.Declaration
Swift
@objc public var navigationBarHelpMenuTitleBackToCameraButton: String
-
Sets the back button text in the navigation bar on the help screen. Use this if you only want to show the title.
Note
Screen API only.Declaration
Swift
@objc public var navigationBarHelpScreenTitleBackToMenuButton: String
-
Indicates whether the supported format screens should be shown. In case of
false
, the option won’t be shown in the Help menu.Declaration
Swift
@objc public var shouldShowSupportedFormatsScreen: Bool
-
Sets the color of the unsupported formats icon background to the specified color.
Declaration
Swift
@objc public var nonSupportedFormatsIconColor: UIColor
-
Sets the color of the supported formats icon background to the specified color.
Declaration
Swift
@objc public var supportedFormatsIconColor: UIColor
-
Sets the text of the app name for the Open with tutorial texts.
Declaration
Swift
@objc public var openWithAppNameForTexts: String
-
Sets the color of the step indicator for the Open with tutorial.
Declaration
Swift
@objc public var stepIndicatorColor: UIColor
-
Sets the color of the bottom button to the specified color.
Declaration
Swift
@objc public var noResultsBottomButtonColor: UIColor
-
Sets the text color of the bottom button to the specified color.
Declaration
Swift
@objc public var noResultsBottomButtonTextColor: GiniColor
-
Sets the corner radius of the bottom button.
Declaration
Swift
@objc public var noResultsBottomButtonCornerRadius: CGFloat
-
Sets the color of the warning container background to the specified color.
Declaration
Swift
@objc public var noResultsWarningContainerIconColor: UIColor
-
Sets if the Drag&Drop step should be shown in the “Open with” tutorial.
Declaration
Swift
@objc public var shouldShowDragAndDropTutorial: Bool
-
Sets the text color for the select more photos button on the albums screen.
Declaration
Swift
@objc public var albumsScreenSelectMorePhotosTextColor: GiniColor
-
Set an array of additional custom help menu items . Those items will be presented as table view cells on the help menu screen. By selecting the cell the user will be redirected to the page, which represented by viewController provided by customer during the
HelpMenuViewController.Item
initialization.Declaration
Swift
public var customMenuItems: [HelpMenuViewController.Item]
-
Sets if the default error logging implementation is on.
Declaration
Swift
@objc public var giniErrorLoggerIsOn: Bool { get set }
-
Should sets if the custom error logging is implemented.
Declaration
Swift
public var customGiniErrorLoggerDelegate: GiniCaptureErrorLoggerDelegate? { get set }
-
Should be set if the default name “Localizable.strings” are not used.
Declaration
Swift
public var localizedStringsTableName: String?
-
Undocumented
Declaration
Swift
@objc public var closeButtonResource: PreferredButtonResource?
-
Undocumented
Declaration
Swift
@objc public var helpButtonResource: PreferredButtonResource?
-
Undocumented
Declaration
Swift
@objc public var backToCameraButtonResource: PreferredButtonResource?
-
Undocumented
Declaration
Swift
@objc public var backToMenuButtonResource: PreferredButtonResource?
-
Undocumented
Declaration
Swift
@objc public var nextButtonResource: PreferredButtonResource?
-
Undocumented
Declaration
Swift
@objc public var cancelButtonResource: PreferredButtonResource?