EmojiEditText
class EmojiEditText : EditText
| kotlin.Any | ||||
| ↳ | android.view.View | |||
| ↳ | android.widget.TextView | |||
| ↳ | android.widget.EditText | |||
| ↳ | androidx.emoji.widget.EmojiEditText |
EditText widget enhanced with emoji capability by using EmojiEditTextHelper. When used on devices running API 18 or below, this widget acts as a regular EditText. maxEmojiCount
Summary
Public constructors |
|---|
EmojiEditText(context: Context!) |
EmojiEditText(context: Context!, attrs: AttributeSet!) |
EmojiEditText(context: Context!, attrs: AttributeSet!, defStyleAttr: Int) |
EmojiEditText( |
Public functions |
|
|---|---|
Int |
Returns the maximum number of EmojiSpans to be added to a CharSequence. |
InputConnection! |
onCreateInputConnection(outAttrs: EditorInfo!) |
Unit |
setCustomSelectionActionModeCallback(See setCustomSelectionActionModeCallback |
Unit |
setKeyListener(keyListener: KeyListener?) |
Unit |
setMaxEmojiCount(maxEmojiCount: @IntRange(from = 0) Int)Set the maximum number of EmojiSpans to be added to a CharSequence. |
Inherited Constants |
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
|
Public constructors
EmojiEditText
EmojiEditText(context: Context!, attrs: AttributeSet!, defStyleAttr: Int)
EmojiEditText
EmojiEditText(
context: Context!,
attrs: AttributeSet!,
defStyleAttr: Int,
defStyleRes: Int
)
Public functions
getMaxEmojiCount
fun getMaxEmojiCount(): Int
Returns the maximum number of EmojiSpans to be added to a CharSequence.
| See also | |
|---|---|
setMaxEmojiCount |
|
process |
setCustomSelectionActionModeCallback
fun setCustomSelectionActionModeCallback(
actionModeCallback: ActionMode.Callback!
): Unit
See setCustomSelectionActionModeCallback
setMaxEmojiCount
fun setMaxEmojiCount(maxEmojiCount: @IntRange(from = 0) Int): Unit
Set the maximum number of EmojiSpans to be added to a CharSequence. The number of spans in a CharSequence affects the performance of the EditText insert/delete operations. Insert/delete operations slow down as the number of spans increases.
| Parameters | |
|---|---|
maxEmojiCount: @IntRange(from = 0) Int |
maximum number of EmojiSpans to be added to a single CharSequence, should be equal or greater than 0 |
| See also | |
|---|---|
process |