setLocationLineColor method

Future<void> setLocationLineColor(
  1. String hexColor
)

Sets the color of the lines used to indicate the location of detected barcodes on the camera feed.

hexColor: The color to set for the location line in hexadecimal format.

Example usage:

String lineColor = '#FF0000'; // Red color
_barkoder.setLocationLineColor(lineColor);
print('Location line color set to: $lineColor');

Implementation

Future<void> setLocationLineColor(String hexColor) {
  if (_isBarkoderViewNotMounted) {
    return Future.error(PlatformException(
        code: BarkoderErrors.barkoderViewNotMounted,
        message: BarkoderErrors.barkodeViewNotMountedDesc));
  }

  return _methodChannel.invokeMethod('setLocationLineColor', hexColor);
}