copyWith method

NumberWheelStyle copyWith({
  1. LuckyFill? background,
  2. LuckyFill? trackFill,
  3. LuckyFill? hubFill,
  4. LuckyFill? ballFill,
  5. Color? textColor,
  6. double? fontSize,
  7. String? fontFamily,
})

返回只替换非空参数的副本。

Implementation

NumberWheelStyle copyWith(
        {LuckyFill? background,
        LuckyFill? trackFill,
        LuckyFill? hubFill,
        LuckyFill? ballFill,
        Color? textColor,
        double? fontSize,
        String? fontFamily}) =>
    NumberWheelStyle(
        background: background ?? this.background,
        trackFill: trackFill ?? this.trackFill,
        hubFill: hubFill ?? this.hubFill,
        ballFill: ballFill ?? this.ballFill,
        textColor: textColor ?? this.textColor,
        fontSize: fontSize ?? this.fontSize,
        fontFamily: fontFamily ?? this.fontFamily);