0

I have a design where the editText should have some hidden chars set as password. And after clicking edittext, they should disappear.

enter image description here

Just like this, the circles should be there however once clicked or when eye icon(for making it visible) is clicked, nothing should be there.

Benazir Sh
  • 81
  • 10
  • [This post](https://stackoverflow.com/questions/27395030/android-hide-password) may help you with your question – Pepe Salad Sep 14 '21 at 06:41
  • Does this answer your question? [How to switch between hide and view password](https://stackoverflow.com/questions/3685790/how-to-switch-between-hide-and-view-password) – Nitish Sep 14 '21 at 06:48
  • I guess I did not formulate my question properly. What I want is some dummy text in password field, but it should be with dots. As soon as the user clicks the editText, those circles should disappear – Benazir Sh Sep 14 '21 at 06:52
  • So user can type his/her password. The circles are just part of design. But I cannot think of way of implementing it – Benazir Sh Sep 14 '21 at 06:54
  • Benazir Sh the answer is below check it – Khaby Lame Sep 14 '21 at 06:56
  • What I want is some dummy text in password field, but it should be with dots. - you can set hint for this in the edit text – Nitish Sep 14 '21 at 06:57
  • hint is appearing is letters, not in dots – Benazir Sh Sep 14 '21 at 07:06
  • just set special characters as hint - android:hint="•••••••" – Nitish Sep 14 '21 at 07:15

2 Answers2

0

You need to add these 2 lines in your EditText code;

    android:inputType="textPassword"
    android:hint="●●●●●●
Khaby Lame
  • 228
  • 2
  • 16
0

android:hint="•••••••" decided to do so

Benazir Sh
  • 81
  • 10