我想要移除OutlineButton上的边框,但是遇到了问题。
OutlinedButton(
onPressed: () {},
child: const Text('Pext Page'),
)
please help me!!
我想要移除OutlineButton上的边框,但是遇到了问题。
OutlinedButton(
onPressed: () {},
child: const Text('Pext Page'),
)
please help me!!
OutlinedButton(
onPressed: () {},
child: Text('Outlined button'),
style: OutlinedButton.styleFrom(
side: BorderSide(
color: Colors.transparent,
),
),
),
使用无边框
OutlinedButton(
onPressed: () {},
style: OutlinedButton.styleFrom(
side: BorderSide.none,
),
child: const Text('Outlined button'),
),
或者您也可以使用TextButton
TextButton(
onPressed: () {},
child: Text('Text button'),
),
BorderSide(color: Colors.transparent)
替换为BorderSide.none
,并且达到相同的效果。 - Najki