TextViewKt

public final class TextViewKt


Summary

Public methods

static final @NonNull TextWatcher
TextViewKt.addTextChangedListener(
    @NonNull TextView receiver,
    @NonNull Function4<@NonNull CharSequence, @NonNull Integer, @NonNull Integer, @NonNull IntegerUnit> beforeTextChanged,
    @NonNull Function4<@NonNull CharSequence, @NonNull Integer, @NonNull Integer, @NonNull IntegerUnit> onTextChanged,
    @NonNull Function1<@NonNull EditableUnit> afterTextChanged
)

Add a text changed listener to this TextView using the provided actions

static final @NonNull TextWatcher
TextViewKt.doAfterTextChanged(
    @NonNull TextView receiver,
    @NonNull Function1<@NonNull EditableUnit> action
)

Add an action which will be invoked after the text changed.

static final @NonNull TextWatcher

Add an action which will be invoked before the text changed.

static final @NonNull TextWatcher

Add an action which will be invoked when the text is changing.

Public methods

TextViewKt.addTextChangedListener

@NonNull
public static final TextWatcher TextViewKt.addTextChangedListener(
    @NonNull TextView receiver,
    @NonNull Function4<@NonNull CharSequence, @NonNull Integer, @NonNull Integer, @NonNull IntegerUnit> beforeTextChanged,
    @NonNull Function4<@NonNull CharSequence, @NonNull Integer, @NonNull Integer, @NonNull IntegerUnit> onTextChanged,
    @NonNull Function1<@NonNull EditableUnit> afterTextChanged
)

Add a text changed listener to this TextView using the provided actions

Returns
TextWatcher

the TextWatcher added to the TextView

TextViewKt.doAfterTextChanged

@NonNull
public static final TextWatcher TextViewKt.doAfterTextChanged(
    @NonNull TextView receiver,
    @NonNull Function1<@NonNull EditableUnit> action
)

Add an action which will be invoked after the text changed.

Returns
TextWatcher

the TextWatcher added to the TextView

TextViewKt.doBeforeTextChanged

@NonNull
public static final TextWatcher TextViewKt.doBeforeTextChanged(
    @NonNull TextView receiver,
    @NonNull Function4<@NonNull CharSequence, @NonNull Integer, @NonNull Integer, @NonNull IntegerUnit> action
)

Add an action which will be invoked before the text changed.

Returns
TextWatcher

the TextWatcher added to the TextView

TextViewKt.doOnTextChanged

@NonNull
public static final TextWatcher TextViewKt.doOnTextChanged(
    @NonNull TextView receiver,
    @NonNull Function4<@NonNull CharSequence, @NonNull Integer, @NonNull Integer, @NonNull IntegerUnit> action
)

Add an action which will be invoked when the text is changing.

Returns
TextWatcher

the TextWatcher added to the TextView