多行文本输入框 带计数 限制文字数量
Step 1. Add the JitPack repository to your build file
Add it in your root build.gradle at the end of repositories:
allprojects {
repositories {
...
maven { url 'https://jitpack.io' }
}
}
dependencies {
compile 'com.github.louisgeek:ClassicLinesEditView:x.x.x'
}
attr
<!--
默认 app:maxCount="240"
默认 app:IgnoreCnOrEn="true"
-->
<com.classichu.lineseditview.LinesEditView
android:layout_margin="10dp"
android:layout_width="match_parent"
android:layout_height="wrap_content"
/>
code
mClassicLinesEditView.setHintText("hintText");
mClassicLinesEditView.setContentText("ContentText");
Log.i(TAG, "onCreate: getHintText"+mClassicLinesEditView.getHintText());
Log.i(TAG, "onCreate: getContentText"+mClassicLinesEditView.getContentText());