【发布时间】:2018-12-26 16:17:09
【问题描述】:
我在我的主页上添加了一张卡片并使用了“Image.asset”来为其提供背景图片。我现在想在这张卡片上添加一些文字,但一直不知道怎么做...任何帮助将不胜感激!
Card(
semanticContainer: true,
clipBehavior: Clip.antiAliasWithSaveLayer,
child: Image.asset(
'assets/images/image.png',
fit: BoxFit.cover,
),
shape: RoundedRectangleBorder(
borderRadius: BorderRadius.circular(10.0),
),
elevation: 5,
margin: EdgeInsets.symmetric(vertical: 9, horizontal: 10),
),
以上是我目前拥有的代码(没有我想添加的任何文本)。
【问题讨论】: