Skip to content

hardik-trivedi/FloatingLabel

Repository files navigation

FloatingLabel

FloatingLabel Allows you to create a blow kind of EditText.

To explain the concept well I have taken below image from http://dribbble.com/shots/1254439--GIF-Float-Label-Form-Interaction

Animation Example

Floating Lable project is in initial mode, where a few customization is provided like changing Text color of EditText and Its Lable

<com.hardik.floatinglabel.FloatingLabelViewandroid:id="@+id/label1"android:layout_width="fill_parent"android:layout_height="wrap_content"floatview:floatHintText="Whatever hint you want to display"floatview:textColor="@color/blue"floatview:textTypeface="some_custome_font.ttf"/>

Features

Float Hint Text

  • Specifies the text for float hint label
 floatview:floatHintText="@string/app_name" 

Float Hint Text Color

  • Specifies text color for float hint label both for focused mode and unfocused mode
 floatview:floatHintTextColorFocused="@color/blue" floatview:floatHintTextColorUnFocused="@color/green" 

Float Hint Text Style

  • Specifies the text style, bold,normal,italic
 floatview:floatHintTextStyle="bold" 

Float Hint Text Gravity

  • Specifies gravity of text left,right,top,bottom
 floatview:floatHintTextGravity="right" 

Float Hint Text Size

  • Specifies text size
 floatview:floatHintTextSize="20" 

Float Hint Text Custom Typeface

  • Specifies custom font. (It has to be in to the assets folder e.g. /assets/some_font.ttf)
 floatview:floatHintTextTypeface="Ithornet.ttf" 

Float Hint Text Background

  • Specifies custom background. You can specify both color and drawable.
 floatview:floatHintTextBackground="@drawable/label_bg" 

Actual Text

  • Specifies the text for editable text box
 floatview:text="Label 1" 

Actual Text Color

  • Specifies text color for editable text box
 floatview:textColor="@color/red" 

Actual Text Style

  • Specifies the text style, bold,normal,italic
 floatview:textStyle="bold" 

Actual Text Gravity

  • Specifies gravity of text left,right,top,bottom
 floatview:textGravity="right" 

Actual Text Size

  • Specifies text size
 floatview:textSize="20" 

Actual Text Custom Typeface

  • Specifies custom font. (It has to be in to the assets folder e.g. /assets/some_font.ttf)
 floatview:textTypeface="Ithornet.ttf" 

Actual Text Background

 floatview:textBackground="@drawable/edt_bg" 

Actual Text As Password

 floatview:isPassword="true" 

About

Android Floating Label

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Contributors 3

  •  
  •  
  •  

Languages