imeSetComposition method
This method sets the current candidate text for ime.
Use imeCommitComposition to commit the final text.
Use imeSetComposition with empty string as text to cancel composition.
text
The text to insert
selectionStart
selection start
selectionEnd
selection end
replacementStart
replacement start
replacementEnd
replacement end
Implementation
Future<void> imeSetComposition(
String text, int selectionStart, int selectionEnd,
{int? replacementStart, int? replacementEnd}) async {
await _client.send('Input.imeSetComposition', {
'text': text,
'selectionStart': selectionStart,
'selectionEnd': selectionEnd,
if (replacementStart != null) 'replacementStart': replacementStart,
if (replacementEnd != null) 'replacementEnd': replacementEnd,
});
}