Flutter 提升按钮颤振的自定义颜色
当我使用此库为RaisedButton添加自定义颜色时 它给了我这个错误Flutter 提升按钮颤振的自定义颜色,flutter,Flutter,当我使用此库为RaisedButton添加自定义颜色时 它给了我这个错误 The argument type 'Color (where Color is defined in /Users/abeer/flutter/.pub-cache/hosted/pub.dartlang.org/color-2.1.1/lib/color.dart)' can't be assigned to the parameter type 'Color (where Color is defined in /
The argument type 'Color (where Color is defined in /Users/abeer/flutter/.pub-cache/hosted/pub.dartlang.org/color-2.1.1/lib/color.dart)' can't be assigned to the parameter type 'Color (where Color is defined in /Users/abeer/flutter/bin/cache/pkg/sky_engine/lib/ui/painting.dart)
为什么要使用颜色库中的rbgColor,只需使用
Color.fromRGBO(r, g, b, opacity)
定义所需rgb的颜色。与括号一起使用
Colors. black[50]
支票问题
Colors. black[50]