summaryrefslogtreecommitdiff
path: root/Source/WebKit2/UIProcess/TextChecker.h
diff options
context:
space:
mode:
Diffstat (limited to 'Source/WebKit2/UIProcess/TextChecker.h')
-rw-r--r--Source/WebKit2/UIProcess/TextChecker.h20
1 files changed, 14 insertions, 6 deletions
diff --git a/Source/WebKit2/UIProcess/TextChecker.h b/Source/WebKit2/UIProcess/TextChecker.h
index bd08d354d..41378c23f 100644
--- a/Source/WebKit2/UIProcess/TextChecker.h
+++ b/Source/WebKit2/UIProcess/TextChecker.h
@@ -42,8 +42,11 @@ public:
static void setContinuousSpellCheckingEnabled(bool);
static void setGrammarCheckingEnabled(bool);
+
+ static void setTestingMode(bool);
+ static bool isTestingMode();
-#if PLATFORM(MAC)
+#if PLATFORM(COCOA)
static void setAutomaticSpellingCorrectionEnabled(bool);
static void setAutomaticQuoteSubstitutionEnabled(bool);
static void setAutomaticDashSubstitutionEnabled(bool);
@@ -62,23 +65,28 @@ public:
static void toggleSubstitutionsPanelIsShowing();
#endif
+#if PLATFORM(GTK)
+ static void setSpellCheckingLanguages(const Vector<String>&);
+ static Vector<String> loadedSpellCheckingLanguages();
+#endif
+
static void continuousSpellCheckingEnabledStateChanged(bool);
static void grammarCheckingEnabledStateChanged(bool);
static int64_t uniqueSpellDocumentTag(WebPageProxy*);
static void closeSpellDocumentWithTag(int64_t);
#if USE(UNIFIED_TEXT_CHECKING)
- static Vector<WebCore::TextCheckingResult> checkTextOfParagraph(int64_t spellDocumentTag, const UChar* text, int length, uint64_t checkingTypes);
+ static Vector<WebCore::TextCheckingResult> checkTextOfParagraph(int64_t spellDocumentTag, StringView text, int32_t insertionPoint, uint64_t checkingTypes, bool initialCapitalizationEnabled);
#endif
- static void checkSpellingOfString(int64_t spellDocumentTag, const UChar* text, uint32_t length, int32_t& misspellingLocation, int32_t& misspellingLength);
- static void checkGrammarOfString(int64_t spellDocumentTag, const UChar* text, uint32_t length, Vector<WebCore::GrammarDetail>&, int32_t& badGrammarLocation, int32_t& badGrammarLength);
+ static void checkSpellingOfString(int64_t spellDocumentTag, StringView text, int32_t& misspellingLocation, int32_t& misspellingLength);
+ static void checkGrammarOfString(int64_t spellDocumentTag, StringView text, Vector<WebCore::GrammarDetail>&, int32_t& badGrammarLocation, int32_t& badGrammarLength);
static bool spellingUIIsShowing();
static void toggleSpellingUIIsShowing();
static void updateSpellingUIWithMisspelledWord(int64_t spellDocumentTag, const String& misspelledWord);
static void updateSpellingUIWithGrammarString(int64_t spellDocumentTag, const String& badGrammarPhrase, const WebCore::GrammarDetail&);
- static void getGuessesForWord(int64_t spellDocumentTag, const String& word, const String& context, Vector<String>& guesses);
+ static void getGuessesForWord(int64_t spellDocumentTag, const String& word, const String& context, int32_t insertionPoint, Vector<String>& guesses, bool initialCapitalizationEnabled);
static void learnWord(int64_t spellDocumentTag, const String& word);
static void ignoreWord(int64_t spellDocumentTag, const String& word);
- static void requestCheckingOfString(PassRefPtr<TextCheckerCompletion>);
+ static void requestCheckingOfString(PassRefPtr<TextCheckerCompletion>, int32_t insertionPoint);
};
} // namespace WebKit