disable textfield

How to Disable TextField in Flutter

Even though rare, you may want to disable your TextInput widget in some scenarios. In this Flutter tutorial, let’s check how to disable TextField. Disabling TextField is very easy. TextField has a property named enabled. Just make the enabled prop false to disable the TextField. Following is the complete example. Following is the output. That’s …

How to Disable TextField in Flutter Read More »

flutter textfield read only

How to Make TextField Read Only in Flutter

I already have a blog post on how to disable Flutter TextField. In this tutorial, let’s learn how to make TextField read-only in Flutter. You might be thinking what’s the difference between disabling and making read-only. When TextField made read-only you cannot change the text but you can select the text. The property readOnly helps …

How to Make TextField Read Only in Flutter Read More »

inputoutlineborder color flutter

How to Change TextField Border Color in Flutter

I already have a blog post on how to add borders to TextField using OutlineInputBorder class. In this blog post, let’s check how to change the default color of TextField border in Flutter. You can change the border color of your TextField using InputDecoration class, OutlineInputBorder class, and BorderSide class. See the code snippet given …

How to Change TextField Border Color in Flutter Read More »

flutter textfield border

How to Add Borders to TextField in Flutter

Every Flutter developer knows the importance of the TextField widget. Having borders around TextField can make the component significant. In this tutorial, let’s learn how to set borders for TextField in Flutter. By default, TextField doesn’t have any borders. You can style TextField using InputDecoration class. The OutlineInputBorder class helps you to add borders around …

How to Add Borders to TextField in Flutter Read More »

flutter textfield remove underline

How to Remove TextField Underline in Flutter

By default, TextField widget of Flutter has an underline. Sometimes, you may want to get rid of this line. In this Flutter tutorial, let’s check how to remove underline in TextField. You can remove underline by using InputBorder class as given below. Following is the complete example. That’s how you remove Flutter TextField underline. Thank …

How to Remove TextField Underline in Flutter Read More »

flutter hint text style

How to Change Placeholder Text Style of TextField in Flutter

TextField is a very important widget that helps users to input text. Sometimes you may want to change the default placeholder style of TextField. In this Flutter tutorial, let’s check how to change the hintText style of the TextField widget. Changing the hintText style is quite simple. You just need to use InputDecoration’s property named …

How to Change Placeholder Text Style of TextField in Flutter Read More »

flutter textfield with multiline

How to Add TextField with Multi-Line Support in Flutter

By default, a TextField widget is limited to single line. But in case your users need to input large text then the TextField should be extensible. In this Flutter tutorial, let’s check how to add multi line support to the TextField widget. You add multiple lines to the TextField by using the property maxLines. There …

How to Add TextField with Multi-Line Support in Flutter Read More »

elevated button padding

How to set Padding for Elevated Button in Flutter

Padding is an important aspect that determines the clarity of your mobile app UI. In this Flutter tutorial, let’s check how to apply padding to the ElevatedButton widget. You can set padding to elevated button using the Padding class. Make Padding widget parent to the elevated button. Following is the complete example. See the output …

How to set Padding for Elevated Button in Flutter Read More »