【发布时间】:2019-01-27 22:45:34
【问题描述】:
我想将我的对象放在堆栈的右上角。 这就是我所拥有的。我知道如果我将 all(LTRB) 设置为 0.0,图像就会放在中心。有没有更简单的方法让我把图片放在右上角?
Widget _buildRemoveIcon()
{
return Positioned(
top:0.0,
left:60.0,
right: 0.0,
bottom:0.0,
child: Padding(
padding: const EdgeInsets.all(8.0),
child: new IconButton(
icon: Icon(
Icons.cancel,
color: Colors.red,
),
onPressed: () {
}), //
),
);
}
【问题讨论】: