Floting Labels : Text Input Layout

We have already covered FloatingActionButton and SnackBar from Material Design. Today we will discuss about TextInputLayout.

There is a nice and interesting approach to customize edittext in Material Design. They didn’t touch EditText directly, instead TextInputLayout will be used to enhance its functionality.

We have seen lot of libraries for floating labels but in Material Design we can directly use it with the help of TextInputLayout.

Add design support library in gradle file.

Add TextInputLayout in your xml :
Continue Reading

Floating action button

Floating action button (FAB) is simply a circle button with rounded shadow, floats above the UI and used to display any promoted action.

Floating action button can be an either of two sizes :

  1. normal (56dp)
  2. mini (40dp)

To use Floating action button you need to do following steps :

1. Add design support library in gradle file.

compile 'com.android.support:design:22.2.0'

2. Include FloatingActionButton in xml layout. you need to include xmlns:app=”http://schemas.android.com/apk/res-auto as namespace the top of your layout.

Continue Reading