diff options
Diffstat (limited to 'Source/WebCore/platform/text/TextCheckerClient.h')
-rw-r--r-- | Source/WebCore/platform/text/TextCheckerClient.h | 15 |
1 files changed, 3 insertions, 12 deletions
diff --git a/Source/WebCore/platform/text/TextCheckerClient.h b/Source/WebCore/platform/text/TextCheckerClient.h index 8abbed4..d16ade1 100644 --- a/Source/WebCore/platform/text/TextCheckerClient.h +++ b/Source/WebCore/platform/text/TextCheckerClient.h @@ -45,16 +45,6 @@ struct GrammarDetail { String userDescription; }; -enum TextCheckingType { - TextCheckingTypeSpelling = 1 << 1, - TextCheckingTypeGrammar = 1 << 2, - TextCheckingTypeLink = 1 << 5, - TextCheckingTypeQuote = 1 << 6, - TextCheckingTypeDash = 1 << 7, - TextCheckingTypeReplacement = 1 << 8, - TextCheckingTypeCorrection = 1 << 9 -}; - struct TextCheckingResult { TextCheckingType type; int location; @@ -72,15 +62,16 @@ public: virtual void checkSpellingOfString(const UChar*, int length, int* misspellingLocation, int* misspellingLength) = 0; virtual String getAutoCorrectSuggestionForMisspelledWord(const String& misspelledWord) = 0; virtual void checkGrammarOfString(const UChar*, int length, Vector<GrammarDetail>&, int* badGrammarLocation, int* badGrammarLength) = 0; + #if USE(UNIFIED_TEXT_CHECKING) - virtual void checkTextOfParagraph(const UChar* text, int length, uint64_t checkingTypes, Vector<TextCheckingResult>& results) = 0; + virtual void checkTextOfParagraph(const UChar* text, int length, TextCheckingTypeMask checkingTypes, Vector<TextCheckingResult>& results) = 0; #endif // For spellcheckers that support multiple languages, it's often important to be able to identify the language in order to // provide more accurate correction suggestions. Caller can pass in more text in "context" to aid such spellcheckers on language // identification. Noramlly it's the text surrounding the "word" for which we are getting correction suggestions. virtual void getGuessesForWord(const String& word, const String& context, Vector<String>& guesses) = 0; - virtual void requestCheckingOfString(SpellChecker*, int, const String&) = 0; + virtual void requestCheckingOfString(SpellChecker*, int, TextCheckingTypeMask, const String&) = 0; }; } |