TextStyle constructor

TextStyle({
  1. String? type,
  2. num? fontSize,
  3. TextDecoration? textDecoration,
  4. FontName? fontName,
  5. LetterSpacing? letterSpacing,
  6. Object? lineHeight,
  7. LeadingTrim? leadingTrim,
  8. num? paragraphIndent,
  9. num? paragraphSpacing,
  10. num? listSpacing,
  11. bool? hangingPunctuation,
  12. bool? hangingList,
  13. TextCase? textCase,
  14. dynamic boundVariables,
  15. void setBoundVariable(
    1. VariableBindableTextField, [
    2. Variable?
    ])?,
  16. String? id,
  17. List<StyleConsumers>? consumers,
  18. String? name,
  19. Future<List<StyleConsumers>> getStyleConsumersAsync()?,
  20. void remove()?,
})

Implementation

factory TextStyle({
  _i2.String? type,
  _i2.num? fontSize,
  _i3.TextDecoration? textDecoration,
  _i3.FontName? fontName,
  _i3.LetterSpacing? letterSpacing,
  _i2.Object? lineHeight,
  _i3.LeadingTrim? leadingTrim,
  _i2.num? paragraphIndent,
  _i2.num? paragraphSpacing,
  _i2.num? listSpacing,
  _i2.bool? hangingPunctuation,
  _i2.bool? hangingList,
  _i3.TextCase? textCase,
  _i2.dynamic boundVariables,
  void Function(
    _i3.VariableBindableTextField, [
    _i3.Variable?,
  ])? setBoundVariable,
  _i2.String? id,
  _i2.List<_i3.StyleConsumers>? consumers,
  _i2.String? name,
  _i2.Future<_i2.List<_i3.StyleConsumers>> Function()? getStyleConsumersAsync,
  void Function()? remove,
}) =>
    TextStyle._(
      type: type,
      fontSize: fontSize,
      textDecoration: textDecoration?.name ?? _i7.undefined,
      fontName: fontName ?? _i7.undefined,
      letterSpacing: letterSpacing ?? _i7.undefined,
      lineHeight: lineHeight ?? _i7.undefined,
      leadingTrim: leadingTrim?.name ?? _i7.undefined,
      paragraphIndent: paragraphIndent,
      paragraphSpacing: paragraphSpacing,
      listSpacing: listSpacing,
      hangingPunctuation: hangingPunctuation,
      hangingList: hangingList,
      textCase: textCase?.name ?? _i7.undefined,
      boundVariables: boundVariables,
      setBoundVariable: setBoundVariable == null
          ? null
          : _i5.allowInterop(setBoundVariable),
      id: id,
      consumers: consumers,
      name: name,
      getStyleConsumersAsync: getStyleConsumersAsync == null
          ? null
          : _i5.allowInterop(getStyleConsumersAsync),
      remove: remove == null ? null : _i5.allowInterop(remove),
    );