Next Page > Hide TOC

Legacy Documentclose button

Important: The information in this document is obsolete and should not be used for new development.

NSIgnoreMisspelledWords

Package
com.apple.cocoa.application
Companion guide

Overview

Implement this interface to have the Ignore button in the Spelling panel function properly. The Ignore button allows the user to accept a word that the spelling checker believes is misspelled. In order for this action to update the “ignored words” list for the document being checked, the NSIgnoreMisspelledWords interface must be implemented.

This interface is necessary because a list of ignored words is useful only if it pertains to the entire document being checked, but the spelling checker (NSSpellChecker object) does not check the entire document for spelling at once. The spelling checker returns as soon as it finds a misspelled word. Thus, it checks only a subset of the document at any one time. The user usually wants to check the entire document, so usually several spelling checks are run in succession until no misspelled words are found. This interface allows the list of ignored words to be maintained per document, even though the spelling checks are not run per document.

The NSIgnoreMisspelledWords interface specifies a single method, ignoreSpelling.

The second argument to the NSSpellChecker method ignoreWord is a tag that the NSSpellChecker can use to distinguish the documents being checked. Once the NSSpellChecker has a way to distinguish the various documents, it can append new ignored words to the appropriate list.

To make the ignored words feature useful, the application must store a document’s ignored words list with the document. See the NSSpellChecker class description for more information.

Tasks

Ignoring Spellings

Instance Methods

ignoreSpelling

public abstract void ignoreSpelling(Object sender)

Discussion

Implement this action method to allow an application to ignore misspelled words on a document-by-document basis. This message is sent by the NSSpellChecker instance to the object whose text is being checked.



Next Page > Hide TOC


© 1997, 2007 Apple Inc. All Rights Reserved. (Last updated: 2007-02-01)


Did this document help you?
Yes: Tell us what works for you.
It’s good, but: Report typos, inaccuracies, and so forth.
It wasn’t helpful: Tell us what would have helped.