diff --git a/docs/contributing/contribution_quickref.rst b/docs/contributing/contribution_quickref.rst index f5f142bea0c5..a51fd2006b7d 100644 --- a/docs/contributing/contribution_quickref.rst +++ b/docs/contributing/contribution_quickref.rst @@ -84,6 +84,7 @@ To run it: :ref:`More information about Linux ` / :ref:`More information about MacOS ` +.. _write_a_patch: To write a patch ---------------- diff --git a/extensions/spellcheck/docs/index.rst b/extensions/spellcheck/docs/index.rst new file mode 100644 index 000000000000..9b4911e7c312 --- /dev/null +++ b/extensions/spellcheck/docs/index.rst @@ -0,0 +1,28 @@ +Adding new words to the en-US dictionary +======================================== + +Occasionally bugs are filed pointing out situations where perfectly +legitimate words are missing from the English spell check dictionary in +Firefox. This article describes the process for adding a word to the +dictionary. + +The process is pretty straight-forward: + +#. Get a clone of mozilla-central (see :ref:`Firefox Contributors' Quick Reference`), if + you don't already have one, and make sure you can build it + successfully. +#. Get into the dictionary sources directory using this command: + ``cd extensions/spellcheck/locales/en-US/hunspell/dictionary-sources`` +#. There's a special script used for editing dictionaries. The script + only works if you have the environment variable ``EDITOR`` set to the + executable of an editor program; if you don't have it set, you can use + ``EDITOR=vim sh edit-dictionary`` to edit using vim (or you can + substitute some other editor), or you can just type + ``sh edit-dictionary`` if you have an ``EDITOR`` already specified. +#. Add and remove words in the dictionary file, then quit the editor. +#. Use ``sh merge-dictionaries`` to process the dictionary changes you've + made. +#. Move the revised dictionary file into position: ``mv en-US.dic ..`` +#. Build Firefox and test your updated dictionary. Once you're + satisfied, use the process described in :ref:`write_a_patch` to create a + patch. diff --git a/extensions/spellcheck/moz.build b/extensions/spellcheck/moz.build index 7ed9b4111618..7493edfd6285 100644 --- a/extensions/spellcheck/moz.build +++ b/extensions/spellcheck/moz.build @@ -13,5 +13,7 @@ if CONFIG["MOZ_WIDGET_TOOLKIT"] != "android": MOCHITEST_CHROME_MANIFESTS += ["tests/chrome/chrome.ini"] MOCHITEST_MANIFESTS += ["tests/mochitest/mochitest.ini"] +SPHINX_TREES["/extensions/spellcheck"] = "docs" + with Files("**"): BUG_COMPONENT = ("Core", "Spelling checker") diff --git a/toolkit/docs/index.rst b/toolkit/docs/index.rst index 808a68b280c0..52dd0b567e1f 100644 --- a/toolkit/docs/index.rst +++ b/toolkit/docs/index.rst @@ -25,3 +25,4 @@ This is the nascent documentation of the Toolkit code that is shared across Fire content/toolkit_widgets/index components/url-classifier/url-classifier/index components/extensions/webextensions/index + /extensions/spellcheck/index