【发布时间】:2019-08-15 12:29:05
【问题描述】:
我正在尝试使用颤振构建一个水平按钮组,但我没有达到预期的效果,在使用 dart 构建 UI 时我是新手,如何调整代码以达到预期的结果?
您将在下面找到我目前的进度和想要的结果!
当前按钮行
//Horizontal buttons row
Wrap(
direction: Axis.horizontal,
children: <Widget>[
ButtonTheme(
minWidth: 40.0,
child: RaisedButton(
color: Colors.white,
onPressed: () {},
child: Text("A"),
),
),
ButtonTheme(
minWidth: 40.0,
child: RaisedButton(
color: Colors.white,
onPressed: () {},
child: Text("B"),
),
),
ButtonTheme(
minWidth: 40.0,
child: RaisedButton(
color: Colors.white,
onPressed: () {},
child: Text("C"),
),
),
ButtonTheme(
minWidth: 40.0,
child: RaisedButton(
color: Colors.white,
onPressed: () {},
child: Text("D"),
),
),
ButtonTheme(
minWidth: 40.0,
child: RaisedButton(
color: Colors.white,
onPressed: () {},
child: Text("E"),
),
),
ButtonTheme(
minWidth: 40.0,
child: RaisedButton(
color: Colors.white,
onPressed: () {},
child: Text("F"),
),
),
ButtonTheme(
minWidth: 40.0,
child: RaisedButton(
color: Colors.white,
onPressed: () {},
child: Text("G"),
),
),
],
)
【问题讨论】:
标签: user-interface flutter dart