Skip to content
master
Switch branches/tags
Go to file
Code

Latest commit

 

Git stats

Files

Permalink
Failed to load latest commit information.
Type
Name
Latest commit message
Commit time
app
 
 
 
 
 
 
 
 
 
 
 
 

RevealPassword

An android small library to show and hide password in a EditText.

Download

Download the latest version in JitPack or Gradle bellow

implementation 'com.github.pedrofsn:RevealPassword:1.0.2'

How to use

Using only XML:

    <br.com.redcode.revealpassword.library.EditTextWithImageForRevealPassword
        android:layout_width="match_parent"
        android:layout_height="wrap_content"
        app:drawableRevealPassword="@android:drawable/ic_menu_add"
        app:hint="Custom Hint Hardcoded" />

Using XML and JAVA/Kotlin:

    <EditText
        android:id="@+id/editTextSampleFunction"
        android:layout_width="match_parent"
        android:layout_height="wrap_content"
        android:layout_marginTop="10dp"
        android:inputType="textWebPassword"
        android:text="\@pedrofsn" />

    <Button
        android:id="@+id/buttonShowHidePassword"
        android:layout_width="wrap_content"
        android:layout_height="wrap_content"
        android:text="Show/hide password" />
 buttonShowHidePassword.setOnClickListener { editTextSampleFunction.showOrHidePassword() }

You can see more samples in XML and Java/Kotlin.

Sample printscreen:

Sample printscreen

Attention: If you're using TextInputLayout from Material Components. You can use builtin solution for this problem domain.

About

An android small library to show and hide password in a EditText

Resources

Packages

No packages published

Languages