How to set Padding for Elevated Button in Flutter

elevated button padding

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 … Read more

How to Add an Image as Icon in Flutter

image as icon flutter

As a mobile app developer, you may have to use your own images as icons in your project. Let’s check how to add images as icons in Flutter. ImageIcon widget is the most suitable widget to use images as icons in Flutter. You can use its property image to assign your own image. Following is … Read more

How to Create Elevated Button with Icon and Text in Flutter

elevated button with icon flutter

Many Flutter developers use ElevatedButton as their preferred button. In this blog post, let’s learn how to create an Elevated Button with Icon in Flutter. You can add Elevated Button with icon and text using ElevatedButton.icon constructor. Then you can make use of properties such as icon and label to add icon and text. Following … Read more

Change Elevated Button Color on Press in Flutter

elevated button onpress color flutter

I already have published few blog posts on the ElevatedButton widget. ElevatedButton is the ready-to-go button for many Flutter developers. In this blog post let’s check how to change the color of the elevated button at the time of pressing. You can change the background color of the ElevatedButton using MaterialStateProperty class. You can change … Read more

How to Make TextField Number only in Flutter

Flutter Number Keyboard

TextField is one of the most commonly used widgets in Flutter. It helps users to enter their text input. In this tutorial, let’s learn how to make the textfield number only by changing the keyboard type in Flutter. The keyboardType property of TextField class helps you to change the keyboard type. The TextInputType.number makes your … Read more

How to Make Text Clickable in Flutter

Flutter clickable text example

Usually, a text doesn’t have any click events. But there are cases, such as hyperlinks, where we need a text which is pressable or clickable. In this Flutter tutorial, let’s check how to make text clickable. I am using RichText widget for this example. It helps us to make a specific text clickable. The TextSpan … Read more