Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Added configurations for the addition of letters under buttons, as well as other relevant configurations. Merging does not affect previous builds #26

Open
wants to merge 19 commits into
base: master
Choose a base branch
from

Conversation

alexanderma-okta
Copy link

Summary of changes

The goal of the changes is to add letters to the keypad under the numbers, as well as make some small changes, such as making the numbers bold and the color behavior of the back button (it used to turn the delete button white after clicking the delete button once, but now it will flash a predetermined color and then go back to the default color).

Changes to Implementation

Each button used to be a "Button" in Android XML but I changed it to a LinearLayout to accommodate both the text and numbers in the button. I also split the variables textColor and textSize into numberTextColor, lettersTextColor, numberTextSize, lettersTextSize, and made appropriate addition of functions/changes to the code to reflect this.

Each button's text used to be set to a number depending on its position. I leveraged this to set each position a specified text as well.

XML property changes

Deprecated (but still compatible) XML Configurations :

  • keypadTextColor: Sets color of both the numbers and the letters
  • keypadTextSize: Sets size of both the numbers and letters

Added XML Configurations:

  • keypadUseDeprecatedColorOptions: Use the deprecated options on color and size over new options (set to false to use new ones)
  • keypadNumbersTextColor: Sets the color of the numbers
  • keypadNumbersTextSize: Sets the font size of the numbers
  • keypadLettersTextColor: Sets the color of the letters
  • keypadLettersTextSize: Sets the font size of the letters
  • keypadShowLetters: Changes the visibility of the letters
  • keypadNumbersBold: Sets the boldness of the numbers text
  • keypadLettersBold: Sets the boldness of letter text
  • keypadDeleteButtonColor: Sets the color of the delete button
  • keypadDefaultDeleteColor: Set to true if you change the color of the delete button

Snapshots of changes

Before

promo

After

screen shot 2017-06-26 at 4 26 02 pm screen shot 2017-06-26 at 4 49 25 pm

…nfigurations such as the colour of the letters. Added configuration to make the font bold.
Adding letters to buttons along with other UI tweaking configurations (backwards compatible)
@aritraroy
Copy link
Owner

Sorry for getting so late to you. The PR seems good at a glance. But there are few things that I need to decide if I want to include or not. Will get back to it very soon.

@aritraroy
Copy link
Owner

Also wanted to understand the motivation behind adding letters under the numbers. Is it just for cosmetic purposes? Or does it serve some real use case?

@chandrashirashyad-okta
Copy link

@aritraroy, This came from our UX designer. It is a standard practice as in phone number pad. Some people have hard time remembering PIN numbers. They can remember their PIN by translating the pin to some real word. Words are easier to remember.

By the way, thanks for sharing this wonderful library.

@alexanderlin-okta
Copy link

@aritraroy @tarslangil What version of the library do you plan on including these changes?

@tarslangil
Copy link

@alexanderlin-okta Could you add your version of library to any gradle repository? As i understand this library is not maintained any more.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

8 participants