{"repo":"CottaCush/CurrencyEditText","free":true,"listed":false,"github":"https://github.com/CottaCush/CurrencyEditText","clone":"git clone https://github.com/CottaCush/CurrencyEditText.git","description":"💰 A library to dynamically format your EditTexts to take currency inputs","language":"Kotlin","stars":132,"topics":["edittext","kotlin","currency-formatter","textwatcher","android-library","currencyedittext"],"license":"Apache-2.0","category":"ui-components","readme_excerpt":"CurrencyEditText A library to dynamically format your EditTexts to take currency inputs. Gradle Dependency Add the dependency to your app's build.gradle : For versions, kindly head over to the releases page Usage Add the CurrencyEditText to your layout. That's all for basic setup. Your editText should automatically format currency inputs. Customisation Currency Symbol You can specify the currency symbol using the currencySymbol and useCurrencySymbolAsHint attributes in xml. The formatted currency value will be prepended with the currencySymbol value. The currencySymbol value can also be used as hint, as described by the useCurrencySymbolAsHint attribute. or programmatically: Locale The CurrencyEditText uses the default Locale if no locale is specified. Locale can be specified programmatically via Locales can also be specified using locale-tags. The locale tag method requires API 21 and above. Instructions on how to construct valid Locale and locale-tags can be found here. or programmatically via Decimal Places The maximum number of decimal digits can be specified using the maxNumberOfDecimalDigits attributes in the xml, requiring a minimum value of 1. It has a default value of 2. or programmatically: Getting the input value Numeric values for the editText can be gotten as shown below. If you need a BigDecimal to continue your monetary calculations right away, you can get it by Using the formatter directly If you'd like to use the library with any EditText widget, you can atta","default_branch":null,"files":null,"tree":[],"storefront":"/r/CottaCush","claimed":false,"request_supported":{"post":"https://gitbuyer.com/r/CottaCush/CurrencyEditText/request-supported","requests":0},"note":"indexed from public GitHub; nothing is for sale on this page. Clone it from GitHub. Paid listings live at /search."}