(Preliminary Documentation) Copyright ã1994 by NeXT Computer, Inc.  All Rights Reserved.

NSSpellServer 

Inherits From:	NSObject 

Declared In:	appkit/NSSpellServer.h 

Checking in Your Service 

- (BOOL)registerLanguage:(NSString *)language	Registers a spelling server for language by vendor.
byVendor:(NSString *)vendor	

Assigning a Delegate 

- (id)delegate	Returns the NSSpellServer's delegate. 
- (void)setDelegate:(id)anObject	Sets the delegate of the NSSpellServer. 

Running the Service 

- (void)run	Makes the NSSpellServer start listening for spell-checking requests.  This method should not return

Checking User Dictionaries 

- (BOOL)isWordInUserDictionaries:(NSString *)word
caseSensitive:(BOOL)flag	Returns whether word is in any open user dictionary;  the search is case-sensitive if flag is YES.

Methods Implemented by the Delegate 

- (NSRange)spellServer:(NSSpellServer *)sender	Search for a mispelled word in stringToCheck, using
findMisspelledWordInString:		language, and marking the first misspelled word found 
     (NSString *)stringToCheck       		by returning its range within the string object.  In 
language:(NSString  *)language		wordCount return by reference the number of words
wordCount:(int *)wordCount		from the beginning of the string object until the 
countOnly:(BOOL)countOnly	 	misspelled word (or the end-of-string).  If countOnly is YES,  just count the words in the string object;  do not spell-check.  Send isWordInUserDictionaries:caseSensitive: to the spelling server to  determine if word exists in the user's language dictionaries.
- (NSArray *)spellServer:(NSSpellServer *)sender	Search for alternatives to the misspelled word in
suggestGuessesForWord:(NSString *)word		language.   Return guesses as an array of string objects.
inLanguage:(NSString *)language	  
- (void)spellServer:(NSSpellServer *)sender	Notifies the delegate of a word added to the user's hidden
didLearnWord:(NSString *)word		word list.  
- (void)spellServer:(NSSpellServer *)sender	Notifies the delagte of a word removed from the user's
didForgetWord:(NSString *)word		 hidden word list.