# class Speller

###

Module | kdecore
Namespace | Sonnet
Class | Speller
Inherits |

Spell checker object.

class used for actuall spell checking

### enums

- Attribute { CheckUppercase, SkipRunTogether }

enum details

### methods

- Speller (lang)

  returns ctor

  Argument | Type | Default
  --- | --- | ---
  lang | QString | QString()

- Speller (speller)

  returns ctor

  Argument | Type | Default
  --- | --- | ---
  speller | Sonnet.Speller |

- addToPersonal (word)

  returns bool

  Argument | Type | Default
  --- | --- | ---
  word | QString |

  Adds word to the list of of personal words. Returns true on success

- addToSession (word)

  returns bool

  Argument | Type | Default
  --- | --- | ---
  word | QString |

  Adds word to the words recognizable in the current session. Returns true on success

- availableBackends ( )

  returns QStringList

  Returns names of all supported backends (e.g. ISpell, ASpell)

- availableLanguageNames ( )

  returns QStringList

  Returns a localized list of names of supported languages.

- availableLanguages ( )

  returns QStringList

  Returns a list of supported languages.

- checkAndSuggest (word, suggestions)

  returns bool

  Argument | Type | Default
  --- | --- | ---
  word | QString |
  suggestions | QStringList |

  Convience method calling isCorrect() and suggest() if the word isn't correct.

- defaultClient ( )

  returns QString

- defaultLanguage ( )

  returns QString

- isCorrect (word)

  returns bool

  Argument | Type | Default
  --- | --- | ---
  word | QString |

  Checks the given word. Returns false if the word is misspelled. true otherwise

- isMisspelled (word)

  returns bool

  Argument | Type | Default
  --- | --- | ---
  word | QString |

  Checks the given word. Returns true if the word is misspelled. false otherwise

- isValid ( )

  returns bool

  Returns true is the speller supports currently selected language.

- language ( )

  returns QString

  Returns language supported by this speller.

- restore (config)

  returns Nothing

  Argument | Type | Default
  --- | --- | ---
  config | KConfig |

- save (config)

  returns Nothing

  Argument | Type | Default
  --- | --- | ---
  config | KConfig |

- setAttribute (attr, b)

  returns Nothing

  Argument | Type | Default
  --- | --- | ---
  attr | Sonnet::Speller.Attribute |
  b | bool | 1

- setDefaultClient (client)

  returns Nothing

  Argument | Type | Default
  --- | --- | ---
  client | QString |

- setDefaultLanguage (lang)

  returns Nothing

  Argument | Type | Default
  --- | --- | ---
  lang | QString |

- setLanguage (lang)

  returns Nothing

  Argument | Type | Default
  --- | --- | ---
  lang | QString |

  Sets the language supported by this speller.

- storeReplacement (bad, good)

  returns bool

  Argument | Type | Default
  --- | --- | ---
  bad | QString |
  good | QString |

  Stores user defined good replacement for the bad word. Returns true on success

- suggest (word)

  returns QStringList

  Argument | Type | Default
  --- | --- | ---
  word | QString |

  Fetches suggestions for the word.

  Returns list of all suggestions for the word

- testAttribute (attr)

  returns bool

  Argument | Type | Default
  --- | --- | ---
  attr | Sonnet::Speller.Attribute |

### enums - detail

- Attribute { CheckUppercase, SkipRunTogether }

  | CheckUppercase | - | - |
  | SkipRunTogether | - | - |