copyWith method

NZMarkdownStyle copyWith({
  1. TextStyle? h1,
  2. TextStyle? h2,
  3. TextStyle? h3,
  4. TextStyle? p,
  5. TextStyle? code,
  6. TextStyle? blockquote,
  7. Color? codeBackground,
  8. Color? blockquoteBorderColor,
  9. EdgeInsets? padding,
})

拷贝并生成新的样式

Implementation

NZMarkdownStyle copyWith({
  TextStyle? h1,
  TextStyle? h2,
  TextStyle? h3,
  TextStyle? p,
  TextStyle? code,
  TextStyle? blockquote,
  Color? codeBackground,
  Color? blockquoteBorderColor,
  EdgeInsets? padding,
}) {
  return NZMarkdownStyle(
    h1: h1 ?? this.h1,
    h2: h2 ?? this.h2,
    h3: h3 ?? this.h3,
    p: p ?? this.p,
    code: code ?? this.code,
    blockquote: blockquote ?? this.blockquote,
    codeBackground: codeBackground ?? this.codeBackground,
    blockquoteBorderColor:
        blockquoteBorderColor ?? this.blockquoteBorderColor,
    padding: padding ?? this.padding,
  );
}