2005-02-02 00:12:53 +03:00
|
|
|
/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
|
2012-05-21 15:12:37 +04:00
|
|
|
/* This Source Code Form is subject to the terms of the Mozilla Public
|
|
|
|
* License, v. 2.0. If a copy of the MPL was not distributed with this
|
|
|
|
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
|
2005-02-02 00:12:53 +03:00
|
|
|
|
|
|
|
#include "nsISupports.idl"
|
|
|
|
#include "domstubs.idl"
|
|
|
|
|
|
|
|
interface nsIEditor;
|
|
|
|
interface nsIEditorSpellCheck;
|
|
|
|
|
2018-05-24 20:18:34 +03:00
|
|
|
webidl Node;
|
2018-05-17 19:01:37 +03:00
|
|
|
webidl Range;
|
|
|
|
|
2013-06-06 04:07:54 +04:00
|
|
|
[scriptable, uuid(b7b7a77c-40c4-4196-b0b7-b0338243b3fe)]
|
2005-02-02 00:12:53 +03:00
|
|
|
interface nsIInlineSpellChecker : nsISupports
|
|
|
|
{
|
|
|
|
readonly attribute nsIEditorSpellCheck spellChecker;
|
|
|
|
|
2012-01-05 20:26:14 +04:00
|
|
|
void init(in nsIEditor aEditor);
|
|
|
|
void cleanup(in boolean aDestroyingFrames);
|
2005-02-02 00:12:53 +03:00
|
|
|
|
|
|
|
attribute boolean enableRealTimeSpell;
|
|
|
|
|
2018-05-17 19:01:37 +03:00
|
|
|
void spellCheckRange(in Range aSelection);
|
2005-02-02 00:12:53 +03:00
|
|
|
|
2018-05-24 20:18:34 +03:00
|
|
|
Range getMisspelledWord(in Node aNode, in long aOffset);
|
2019-03-26 13:06:43 +03:00
|
|
|
[can_run_script]
|
2018-05-24 20:18:34 +03:00
|
|
|
void replaceWord(in Node aNode, in long aOffset, in AString aNewword);
|
2005-02-02 00:12:53 +03:00
|
|
|
void addWordToDictionary(in AString aWord);
|
2011-12-30 01:06:56 +04:00
|
|
|
void removeWordFromDictionary(in AString aWord);
|
2015-05-28 18:58:42 +03:00
|
|
|
|
2005-02-02 00:12:53 +03:00
|
|
|
void ignoreWord(in AString aWord);
|
2005-02-04 04:39:02 +03:00
|
|
|
void ignoreWords([array, size_is(aCount)] in wstring aWordsToIgnore, in unsigned long aCount);
|
2011-08-12 23:12:45 +04:00
|
|
|
void updateCurrentDictionary();
|
2013-06-06 04:07:54 +04:00
|
|
|
|
|
|
|
readonly attribute boolean spellCheckPending;
|
2005-02-02 00:12:53 +03:00
|
|
|
};
|