Include InputDecoration border color and icons color
TextFormField(
keyboardType: TextInputType.number,
decoration: const InputDecoration(
prefix: Icon(
Icons.abc,
color: Colors.blue,
),
suffixIcon: Icon(
Icons.ac_unit,
color: Colors.blue,
),
suffixIconColor: Colors.blue,
enabledBorder: UnderlineInputBorder(
borderSide: BorderSide(color: Colors.blue),
),
focusedBorder: UnderlineInputBorder(
borderSide: BorderSide(color: Colors.blue),
),
border: UnderlineInputBorder(
borderSide: BorderSide(color: Colors.blue),
)),
style: TextStyle(
color: Colors.purple,
),
),
More about InputDecoration
enabledBorder: UnderlineInputBorder(
borderSide: BorderSide(color: Colors.red),
),
focusedBorder: UnderlineInputBorder(
borderSide: BorderSide(color: Colors.red),
),
border: UnderlineInputBorder(
borderSide: BorderSide(color: Colors.red),
)),
Just add this in your decoration
The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.