[英]Not able to change TextFormField Border Width
我正在嘗試更改TextFromField
邊框的寬度,但它不起作用。
下面是我的代碼。
TextFormField(
decoration: InputDecoration(
border: OutlineInputBorder(
borderSide: new BorderSide(color: Colors.white,width:2)),
fillColor: Colors.white,
labelText: 'Enter your username or email address'
),
),
您應該使用enableBorder
。 嘗試這樣的事情
TextFormField(
decoration: InputDecoration(
enabledBorder: OutlineInputBorder(
borderSide: new BorderSide(color: Colors.red, width: 10)),
fillColor: Colors.white,
labelText: 'Enter your username'),
)
參考這里:
聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.