Перейти к основному содержимому

Class TextInputBaseFieldTextSelectionExtensions

Namespace: Aspid.FastTools.UIElements
Assembly: Aspid.FastTools.dll

Provides text-selection extension methods for TextInputBaseField<T>.

public static class TextInputBaseFieldTextSelectionExtensions

Inheritance​

object ← TextInputBaseFieldTextSelectionExtensions

Methods​

AddOnCursorIndexChange<TField, TValue>(TField, Action)​

Subscribes to the OnCursorIndexChange event of textSelection.

public static TField AddOnCursorIndexChange<TField, TValue>(this TField element, Action value) where TField : TextInputBaseField<TValue>

Parameters​

element TField

The element to modify.

value Action

The callback to subscribe.

Returns​

TField

The element, for chaining.

Type Parameters​

TField

The field type.

TValue

The value type held by the field.

AddOnSelectIndexChange<TField, TValue>(TField, Action)​

Subscribes to the OnSelectIndexChange event of textSelection.

public static TField AddOnSelectIndexChange<TField, TValue>(this TField element, Action value) where TField : TextInputBaseField<TValue>

Parameters​

element TField

The element to modify.

value Action

The callback to subscribe.

Returns​

TField

The element, for chaining.

Type Parameters​

TField

The field type.

TValue

The value type held by the field.

RemoveOnCursorIndexChange<TField, TValue>(TField, Action)​

Unsubscribes from the OnCursorIndexChange event of textSelection.

public static TField RemoveOnCursorIndexChange<TField, TValue>(this TField element, Action value) where TField : TextInputBaseField<TValue>

Parameters​

element TField

The element to modify.

value Action

The callback to remove.

Returns​

TField

The element, for chaining.

Type Parameters​

TField

The field type.

TValue

The value type held by the field.

RemoveOnSelectIndexChange<TField, TValue>(TField, Action)​

Unsubscribes from the OnSelectIndexChange event of textSelection.

public static TField RemoveOnSelectIndexChange<TField, TValue>(this TField element, Action value) where TField : TextInputBaseField<TValue>

Parameters​

element TField

The element to modify.

value Action

The callback to remove.

Returns​

TField

The element, for chaining.

Type Parameters​

TField

The field type.

TValue

The value type held by the field.

SetCursorIndex<TField, TValue>(TField, int)​

Sets cursorIndex.

public static TField SetCursorIndex<TField, TValue>(this TField element, int value) where TField : TextInputBaseField<TValue>

Parameters​

element TField

The element to modify.

value int

The cursor index to set.

Returns​

TField

The element, for chaining.

Type Parameters​

TField

The field type.

TValue

The value type held by the field.

SetDoubleClickSelectsWord<TField, TValue>(TField, bool)​

Sets doubleClickSelectsWord.

public static TField SetDoubleClickSelectsWord<TField, TValue>(this TField element, bool value) where TField : TextInputBaseField<TValue>

Parameters​

element TField

The element to modify.

value bool

When true, a double click selects the word under the pointer.

Returns​

TField

The element, for chaining.

Type Parameters​

TField

The field type.

TValue

The value type held by the field.

SetSelectAllOnFocus<TField, TValue>(TField, bool)​

Sets selectAllOnFocus.

public static TField SetSelectAllOnFocus<TField, TValue>(this TField element, bool value) where TField : TextInputBaseField<TValue>

Parameters​

element TField

The element to modify.

value bool

When true, the whole text is selected when the field receives focus.

Returns​

TField

The element, for chaining.

Type Parameters​

TField

The field type.

TValue

The value type held by the field.

SetSelectAllOnMouseUp<TField, TValue>(TField, bool)​

Sets selectAllOnMouseUp.

public static TField SetSelectAllOnMouseUp<TField, TValue>(this TField element, bool value) where TField : TextInputBaseField<TValue>

Parameters​

element TField

The element to modify.

value bool

When true, the whole text is selected on the first mouse up.

Returns​

TField

The element, for chaining.

Type Parameters​

TField

The field type.

TValue

The value type held by the field.

SetSelectIndex<TField, TValue>(TField, int)​

Sets selectIndex.

public static TField SetSelectIndex<TField, TValue>(this TField element, int value) where TField : TextInputBaseField<TValue>

Parameters​

element TField

The element to modify.

value int

The selection index to set.

Returns​

TField

The element, for chaining.

Type Parameters​

TField

The field type.

TValue

The value type held by the field.

SetSelectable<TField, TValue>(TField, bool)​

Sets isSelectable of textSelection.

public static TField SetSelectable<TField, TValue>(this TField element, bool value) where TField : TextInputBaseField<TValue>

Parameters​

element TField

The element to modify.

value bool

When true, the text can be selected.

Returns​

TField

The element, for chaining.

Type Parameters​

TField

The field type.

TValue

The value type held by the field.

SetTripleClickSelectsLine<TField, TValue>(TField, bool)​

Sets tripleClickSelectsLine.

public static TField SetTripleClickSelectsLine<TField, TValue>(this TField element, bool value) where TField : TextInputBaseField<TValue>

Parameters​

element TField

The element to modify.

value bool

When true, a triple click selects the line under the pointer.

Returns​

TField

The element, for chaining.

Type Parameters​

TField

The field type.

TValue

The value type held by the field.