Home

# Class goog.ui.PlainTextSpellChecker

Plain text spell checker implementation.

extends goog.ui.AbstractSpellChecker

Instance Method Summary
| `check()` Checks spelling for all text and displays correction UI.
| `checkAsync_(string text)` Starts asynchrnonous spell checking.
| `continueAsync_()` Continues asynchrnonous spell checking.
| `createDom()` Creates the initial DOM representation for the component.
| `disposeInternal()` Disposes of the component. Calls {@code exitDocument}, which is expected to remove event handlers and clean up the component. Propagates the call to the component's children, if any. Removes the component's DOM from the document unless it was decorated.
| `enterDocument()` Called when the component's element is known to be in the document.
| `exitDocument()` Called by dispose to clean up the elements and listeners created by a component, or by a parent component/application who has removed the component from the document but wants to reuse it later. If the component contains child components, this call is propagated to its children. It should be possible for the component to be rendered again once this method has been called.
| `finishCheck_()` Final stage of spell checking - displays the correction UI.
| `getElementProperties(?goog.spell.SpellCheck.WordStatus status) ⇒ ?Object` Returns desired element properties for the specified status.
| `handleOverlayKeyEvent(?goog.events.BrowserEvent e) ⇒ (boolean|undefined)` Handles key down for overlay.
| `initAccessibility_()` Specify ARIA roles and states as appropriate.
| `initSuggestionsMenu()` Initializes suggestions menu. Populates menu with separator and ignore option that are always valid. Suggestions are later added above the separator.
| `initTextArray_(string text)` Breaks text into included and excluded ranges using the marker RegExp supplied by the caller.
| `navigate_(?goog.ui.AbstractSpellChecker.Direction direction) ⇒ boolean` Navigate keyboard focus in the given direction.
| `onCorrectionAction(?goog.events.Event event)` Handles correction menu actions.
| `onCorrectionBlur_(?goog.events.BrowserEvent event)` Handles blur on the menu.
| `onDictionaryCharged_(?goog.events.Event e)` Loads few initial dictionary words into the cache.
| `onWindowResize_(?goog.events.BrowserEvent event)` Handles window resize events.
| `onWordClick_(?goog.events.BrowserEvent event)` Handles the click events.
| `positionOverlay_()` Updates the position and size of the overlay to match the original element.
| `preChargeDictionary_(string text)` Start the scan after the dictionary was loaded.
| `processRange(?Node node, string text)` Processes range of text - recognized words and separators.
| `processWord(?Node node, string word, ?goog.spell.SpellCheck.WordStatus status)` Processes word.
| `reFocus_()` Sets the focus back on the previously focused word element.
| `resizeOverlay_()` Resizes overlay to match the size of the bound element then displays the overlay. Helper for {@link #onWindowResize_}.
| `resume()` Hides correction UI.
| `spellCheckLoop_() ⇒ ?goog.ui.AbstractSpellChecker.AsyncResult` Processes the included and skips the excluded text ranges.