TextViewer.asset constructor
TextViewer.asset(})
Implementation
factory TextViewer.asset(
String assetPath, {
TextStyle textStyle = const TextStyle(),
TextStyle? highLightTextStyle,
TextStyle? focusTextStyle,
Color highLightColor = Colors.yellow,
Color focusColor = Colors.amber,
bool ignoreCase = true,
}) {
return TextViewer._(
assetPath: assetPath,
textStyle: textStyle,
highLightTextStyle: highLightTextStyle ??
textStyle.copyWith(background: Paint()..color = highLightColor),
focusTextStyle: focusTextStyle ??
textStyle.copyWith(background: Paint()..color = focusColor),
highLightColor: highLightColor,
focusColor: focusColor,
ignoreCase: ignoreCase,
);
}