# XEditText **Repository Path**: tongfu/XEditText ## Basic Information - **Project Name**: XEditText - **Description**: XEditText: clear contents easily; show/hide password; separeta contents automatically, such as credit card number; disable Emoji inputs; 带删除功能的EditText;显示或者隐藏密码;可设置自动添加分隔符分割电话号码、银行卡号等;支持禁止Emoji表情符号输入。 - **Primary Language**: Java - **License**: Not specified - **Default Branch**: master - **Homepage**: None - **GVP Project**: No ## Statistics - **Stars**: 0 - **Forks**: 0 - **Created**: 2024-07-30 - **Last Updated**: 2024-11-27 ## Categories & Tags **Categories**: Uncategorized **Tags**: None ## README [ ![Download](https://api.bintray.com/packages/woxingxiao/maven/xedittext/images/download.svg) ](https://bintray.com/woxingxiao/maven/xedittext/_latestVersion) # XEditText Wrapped common usage of `EditText`. ## Features - To clear all text content just by one click on the right. The clear drawable is customizable. - Perfectly fit for password input scenario. The toggle drawable is also customizable. - You can customize the **Separator** or **Pattern** to separate the text content. But the text content by COPY, CUT, and PASTE will no longer be affected by **Separator** or **Pattern** you set. - Disable Emoji input. - Support RTL.🆕 - Support drawable tint.🆕 - Customizable padding of drawables' interaction rect area.🆕 ## Screenshot *** ![demo1](https://github.com/woxingxiao/XEditText/blob/master/screenshots/demo1.gif) ![demo2](https://github.com/woxingxiao/XEditText/blob/master/screenshots/demo2.gif) ![demo3](https://github.com/woxingxiao/XEditText/blob/master/screenshots/demo3.gif) ## Gradle AndroidX: ```groovy dependencies{ //e.g.:implementation 'com.xw.repo:xedittext-androidx:2.3.0' implementation 'com.xw.repo:xedittext-androidx:${LATEST_VERSION}' } ``` Support: ```groovy dependencies{ //e.g.:implementation 'com.xw.repo:xedittext:2.3.0' implementation 'com.xw.repo:xedittext:${LATEST_VERSION}' } ``` *** ## Usage ```xml app:x_clearDrawable="@mipmap/ic_clear" app:x_hidePwdDrawable="@mipmap/ic_hide" app:x_showPwdDrawable="@mipmap/ic_show"/> ``` **Call `.setOnXTextChangeListener()` instead of `.addTextChangedListener()` Call `.setOnXFocusChangeListener()` instead of `.setOnFocusChangeListener()`** Check the sample for more details. ## License ``` The MIT License (MIT) Copyright (c) 2016 woxingxiao Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. ```