我想垂直对齐左侧元素,并与带有填充的右侧元素相同,这就是我得到的结果,元素未对齐,并且我无法在第二行中插入填充,以便左侧元素对齐
return InkWell(
child: Column(
children: <Widget>[
Row(
children:<Widget> [
Padding(padding:EdgeInsets.fromLTRB(18.0, 0.0, 0.0, 0.0)),
Text(
product.libelle,
style: theme.textTheme.title,
maxLines: 1,
textAlign: TextAlign.left,
),]),
Row(
mainAxisAlignment: MainAxisAlignment.spaceBetween,
children:<Widget> [
Text(
product.description,
style: theme.textTheme.subtitle,
maxLines: 1,
),
RaisedButton( onPressed: () {},
child: new Text("S\'abonner"),
)
]),
),
);
Run Code Online (Sandbox Code Playgroud) 我想在列小部件的左侧放置一些文本小部件,我尝试将 textAlign 属性添加到文本中,但它不起作用:
Column(
children: <Widget>[
Text("some text",textAlign:TextAlign.left),
])
Run Code Online (Sandbox Code Playgroud) flutter ×2