Flutter 显示更大的图标[抖动]
我想显示一个更大的图标,而不增加一个小部件的总大小,可能只是显示图标的一部分 我怎样才能做到这一点呢?请回答我的问题 帮助了我 我使用了Flutter 显示更大的图标[抖动],flutter,Flutter,我想显示一个更大的图标,而不增加一个小部件的总大小,可能只是显示图标的一部分 我怎样才能做到这一点呢?请回答我的问题 帮助了我 我使用了Transform.scale来缩放它 return FittedBox( child: FlatButton( color: Colors.red, onPressed: () {}, shape: RoundedRectangleBorder( borderRadius: BorderRadius.circular(
Transform.scale
来缩放它
return FittedBox(
child: FlatButton(
color: Colors.red,
onPressed: () {},
shape: RoundedRectangleBorder(
borderRadius: BorderRadius.circular(45),
),
child: Row(
children: [
Transform.scale(
child: Icon(LetsGoIcons.fighting, color: Colors.white),
scale: 2,
),
SizedBox(width: 10),
Text("Fighting",
style: TextStyle(
fontWeight: FontWeight.bold,
color: Colors.white,
letterSpacing: 0.7,
fontSize: 18))
],
),
)
);
只需设置size属性即可增加大小
图标(Icons.clear,大小:18.0)
请发布您目前尝试的代码,这是否回答了您的问题@莫比纳是的。谢谢