SpellCheckState

constructor(textState: TextEditorState, spellChecker: EditorSpellChecker?, enableSpellChecking: Boolean = true, spellCheckMode: SpellCheckMode = SpellCheckMode.Word, scanContext: CoroutineContext = Dispatchers.Default)(source)

Parameters

enableSpellChecking

Whether spell checking is active initially; exposed via spellCheckingEnabled.

scanContext

The context the dictionary lookups run in. Checks start on the UI dispatcher and an EditorSpellChecker typically hops to a worker per lookup, so gathering them here keeps the caller's dispatcher out of the loop. Span mutations still happen on the caller's dispatcher once the scan returns.