Share via


EditorInfo.GetInitialTextAfterCursor(Int32, Int32) Method

Definition

Get <var>length</var> characters of text after the current cursor position.

public string? GetInitialTextAfterCursor (int length, int flags);
member this.GetInitialTextAfterCursor : int * int -> string

Parameters

length
Int32

The expected length of the text.

flags
Int32

Supplies additional options controlling how the text is returned. May be either 0 or InputConnection#GET_TEXT_WITH_STYLES.

Returns

the text after the cursor position; the length of the returned text might be less than <var>length</var>. When there is no text after the cursor, an empty string will be returned. It could also be null when the editor or system could not support this protocol.

Remarks

Get <var>length</var> characters of text after the current cursor position. May be null when the protocol is not supported.

Java documentation for android.view.inputmethod.EditorInfo.getInitialTextAfterCursor(int, int).

Portions of this page are modifications based on work created and shared by the Android Open Source Project and used according to terms described in the Creative Commons 2.5 Attribution License.

Applies to