Flutter-添加边框
2019-07-27 本文已影响0人
hie
Container(
height: 34,
decoration: BoxDecoration(
borderRadius: BorderRadius.circular(17),///圆角
border: Border.all(color: colorE6E6E6,width: 1)///边框颜色、宽
),
child: Row(
crossAxisAlignment: CrossAxisAlignment.center,
children: <Widget>[
SizedBox(width: 10,),
Image.asset("images/message-top-search.png",width: 17,height: 17,),
SizedBox(width: 10,),
Expanded(
child: TextField(
style: TextStyle(
fontSize: 13,
color: color333333
),///输入时文字样式
cursorColor: themeColor,///光标颜色
maxLines: 1,
decoration: InputDecoration(
labelText: '搜索您想咨询的问题',///默认文字
border: InputBorder.none,///去掉下划线
hintStyle: TextStyle(
color: color999999
),///默认文字样式
),
),
),
],
),
)