Torch Switch Control
Defined in framework ScanditDataCaptureCore
- SDCTorchSwitchControl
@interface SDCTorchSwitchControl : NSObject <SDCControl>
Added in version 6.0.0
Control that allows to toggle the torch on and off. The torch switch control hides itself automatically in case the active frame source doesn’t have a torch.
You can add this control to a view by calling SDCDataCaptureView.addControl:.
- + torchSwitchControlFromJSONString:error:
+ (nullable
instancetype
)torchSwitchControlFromJSONString:(nonnull NSString *)JSONString error:(NSError **)errorAdded in version 6.8.0
Constructs a new torch switch control with the provided JSON serialization.
- torchOffImage
@property (nonatomic, strong, nonnull) UIImage *torchOffImage
Added in version 6.2.0
Sets the image encoded as a base64 string to use for the control button when the torch is off.
- torchOffPressedImage
@property (nonatomic, strong, nonnull) UIImage *torchOffPressedImage
Added in version 6.2.0
Sets the image encoded as a base64 string to use for the control button when the torch is off and the button is pressed.
- torchOnImage
@property (nonatomic, strong, nonnull) UIImage *torchOnImage
Added in version 6.2.0
Sets the image encoded as a base64 string to use for the control button when the torch is on.
- torchOnPressedImage
@property (nonatomic, strong, nonnull) UIImage *torchOnPressedImage
Added in version 6.2.0
Sets the image encoded as a base64 string to use for the control button when the torch is on and the button is pressed.
- accessibilityLabelWhenOff
@property (nonatomic, copy, nullable) NSString *accessibilityLabelWhenOff
Added in version 6.14.0
Accessibility label text used for the control button when the torch is off.
- accessibilityHintWhenOff
@property (nonatomic, copy, nullable) NSString *accessibilityHintWhenOff
Added in version 6.14.0
Accessibility hint text used for the control button when the torch is off.
- accessibilityLabelWhenOn
@property (nonatomic, copy, nullable) NSString *accessibilityLabelWhenOn
Added in version 6.14.0
Accessibility label text used for the control button when the torch is on.
- accessibilityHintWhenOn
@property (nonatomic, copy, nullable) NSString *accessibilityHintWhenOn
Added in version 6.14.0
Accessibility hint text used for the control button when the torch is on.
- - updateFromJSONString:error:
- (
BOOL
)updateFromJSONString:(nonnull NSString *)JSONString error:(NSError **)errorAdded in version 6.8.0
Updates the control according to a JSON serialization.
- defaultTorchOffImage
@property (class, nonatomic, nonnull, readonly) UIImage *defaultTorchOffImage
Added in version 6.10.0
The default image used for the control button when the torch is off.
- defaultTorchOffPressedImage
@property (class, nonatomic, nonnull, readonly) UIImage *defaultTorchOffPressedImage
Added in version 6.10.0
The default image used for the control button when the torch is off and the button is pressed.