Flutter - How To Change TextField's/TextFormField's Border Colors

preview_player
Показать описание
If you have ever wondered how to completely control and change the colors of any TextField or TextFormField, then this video is your answer.

I go over how to change the colors of these widgets no matter what state TextField/TextFormField can find itself in.

Through the decoration property and by using InputDecoration() everything is possible!

(In the beginning I also show a line of code that takes the focus away from whatever it is in)

00:00 - Intro
00:15 - How to Remove Focus From a Widget
00:30 - Giving a Border to the TextField
01:05 - Rounding the Border
01:30 - All Border Properties
01:47 - enabledBorder
02:45 - disabledBorder
03:36 - focusedBorder
04:28 - "border" Property Explained
04:50 - errorBorder
05:13 - focusedErrorBorder
05:28 - Changing Error Text Color
06:12 - Default TextField Colors Explained
06:30 - Flutter Mentor Out

#textfield #borders #colors

Credits:

OUTRO SONG:
Рекомендации по теме
Комментарии
Автор

That was very useful, thank you so much

zaidrj
Автор

thank you so much and the outro song is gooood~!

KiTO키토
Автор

thank you very much for the instructions, would it be possible for me to change the color of the text that "goes up" in the form? without using labelStyle

viktorfraga
Автор

My textfield underline is hitting on screen. How can i change this?

saratm
Автор

How do I change the height of this textfield? it's too tall, I want to smaller

yoshinohmm
Автор

how to change background color, when error?

Nurimendizhen
Автор

is it possible to use linearGradient on a textfield??

yan-cordeiro