GnomeSpell

Name

GnomeSpell — one line description goes here.

Synopsis


#include <gnome.h>


struct      GnomeSpell
struct      GnomeSpellInfo
GtkWidget*  gnome_spell_new                 (void);
gint        gnome_spell_check               (GnomeSpell *gtkspell,
                                             gchar *str);
void        gnome_spell_accept              (GnomeSpell *gtkspell,
                                             gchar *word);
void        gnome_spell_insert              (GnomeSpell *gtkspell,
                                             gchar *word,
                                             gint lowercase);
int         gnome_spell_next                (GnomeSpell *gtkspell);
void        gnome_spell_kill                (GnomeSpell *gtkspell);

Object Hierarchy


  GtkObject
   +----GtkWidget
         +----GtkContainer
               +----GtkBox
                     +----GtkVBox
                           +----GnomeSpell

Signal Prototypes


'found-word'
            void        user_function      (GnomeSpell *spell,
                                            gpointer arg1,
                                            gpointer user_data);
'handled-word'
            void        user_function      (GnomeSpell *spell,
                                            gpointer arg1,
                                            gpointer user_data);

Description

Details


GnomeSpell

struct GnomeSpell;


GnomeSpellInfo

struct GnomeSpellInfo {
	gchar* original;
	gchar* replacement;
	gchar* word;
	guint offset;
	GSList * words;
};


gnome_spell_new()

GtkWidget*  gnome_spell_new                 (void);

Create a new GNOME spell checker object.

Returns : Pointer to new GNOME spell checker object, or NULL on failure.


gnome_spell_check()

gint        gnome_spell_check               (GnomeSpell *gtkspell,
                                             gchar *str);

Perform spell-checking on one or more words.

FIXME: there is a problem when you call gnome_spell_check(spell, "bogus bogus"): if you accept bogus the first time, it will be reported again because ispell checked it before... The easiest solution is to spell-check a word at a time (but it's slow).

gtkspell : str : String to be spell-checked.Returns : 1 if spelling is ok, 0 if not, -1 on system error.


gnome_spell_accept()

void        gnome_spell_accept              (GnomeSpell *gtkspell,
                                             gchar *word);

Adds a single word to the runtime list of words that the spelling checker should ignore.

gtkspell : word : Word to be ignored.


gnome_spell_insert()

void        gnome_spell_insert              (GnomeSpell *gtkspell,
                                             gchar *word,
                                             gint lowercase);

Adds a single word to the spelling checker's private dictionary.

gtkspell : word : Word to be added to private dictionary.lowercase : 


gnome_spell_next()

int         gnome_spell_next                (GnomeSpell *gtkspell);

Adds a single word to the runtime list of words that the spelling checker should ignore.

gtkspell : Returns


gnome_spell_kill()

void        gnome_spell_kill                (GnomeSpell *gtkspell);

Terminates the external spelling checker process, if present.

gtkspell : 

Signals


The 'found-word' signal

void        user_function                  (GnomeSpell *spell,
                                            gpointer arg1,
                                            gpointer user_data);

spell :the object which received the signal.arg1 : user_data :user data set when the signal handler was connected.


The 'handled-word' signal

void        user_function                  (GnomeSpell *spell,
                                            gpointer arg1,
                                            gpointer user_data);

spell :the object which received the signal.arg1 : user_data :user data set when the signal handler was connected.