当先锋百科网

首页 1 2 3 4 5 6 7

第一种:Flexible

Row(
  children: <Widget>[
    Align(
      alignment: Alignment.centerLeft,
      child: Text('123'),
    ),
    Flexible(fit: FlexFit.tight, child: SizedBox()),
    Align(
      alignment: Alignment.centerRight,
      child:
          Image.asset('lib/images/arrow_right.png'),
    )
  ],
)

第二种:spaceBetween

Row(
  mainAxisAlignment: MainAxisAlignment.spaceBetween,
  children: <Widget>[
    Align(
      alignment: Alignment.centerLeft,
      child: Text('123'),
    ),
    Align(
      alignment: Alignment.centerRight,
      child:
          Image.asset('lib/images/arrow_right.png'),
    )
  ],
)