2 * @file libsexy/sexy-spell-entry.h Entry widget
4 * @Copyright (C) 2004-2006 Christian Hammond.
6 * This library is free software; you can redistribute it and/or
7 * modify it under the terms of the GNU Lesser General Public
8 * License as published by the Free Software Foundation; either
9 * version 2 of the License, or (at your option) any later version.
11 * This library is distributed in the hope that it will be useful,
12 * but WITHOUT ANY WARRANTY; without even the implied warranty of
13 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14 * Lesser General Public License for more details.
16 * You should have received a copy of the GNU Lesser General Public
17 * License along with this library; if not, write to the
18 * Free Software Foundation, Inc., 59 Temple Place - Suite 330,
19 * Boston, MA 02111-1307, USA.
21 #ifndef _SEXY_SPELL_ENTRY_H_
22 #define _SEXY_SPELL_ENTRY_H_
24 typedef struct _SexySpellEntry SexySpellEntry
;
25 typedef struct _SexySpellEntryClass SexySpellEntryClass
;
26 typedef struct _SexySpellEntryPriv SexySpellEntryPriv
;
28 #include <gtk/gtkentry.h>
30 #define SEXY_TYPE_SPELL_ENTRY (sexy_spell_entry_get_type())
31 #define SEXY_SPELL_ENTRY(obj) (G_TYPE_CHECK_INSTANCE_CAST((obj), SEXY_TYPE_SPELL_ENTRY, SexySpellEntry))
32 #define SEXY_SPELL_ENTRY_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST((klass), SEXY_TYPE_SPELL_ENTRY, SexySpellEntryClass))
33 #define SEXY_IS_SPELL_ENTRY(obj) (G_TYPE_CHECK_INSTANCE_TYPE((obj), SEXY_TYPE_SPELL_ENTRY))
34 #define SEXY_IS_SPELL_ENTRY_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE((klass), SEXY_TYPE_SPELL_ENTRY))
35 #define SEXY_SPELL_ENTRY_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS((obj), SEXY_TYPE_SPELL_ENTRY, SexySpellEntryClass))
37 #define SEXY_SPELL_ERROR (sexy_spell_error_quark())
40 SEXY_SPELL_ERROR_BACKEND
,
43 struct _SexySpellEntry
45 GtkEntry parent_object
;
47 SexySpellEntryPriv
*priv
;
49 void (*gtk_reserved1
)(void);
50 void (*gtk_reserved2
)(void);
51 void (*gtk_reserved3
)(void);
52 void (*gtk_reserved4
)(void);
55 struct _SexySpellEntryClass
57 GtkEntryClass parent_class
;
60 gboolean (*word_check
)(SexySpellEntry
*entry
, const gchar
*word
);
62 void (*gtk_reserved1
)(void);
63 void (*gtk_reserved2
)(void);
64 void (*gtk_reserved3
)(void);
65 void (*gtk_reserved4
)(void);
70 GType
sexy_spell_entry_get_type(void);
71 GtkWidget
*sexy_spell_entry_new(void);
72 GQuark
sexy_spell_error_quark(void);
74 GSList
*sexy_spell_entry_get_languages(const SexySpellEntry
*entry
);
75 gchar
*sexy_spell_entry_get_language_name(const SexySpellEntry
*entry
, const gchar
*lang
);
76 gboolean
sexy_spell_entry_language_is_active(const SexySpellEntry
*entry
, const gchar
*lang
);
77 gboolean
sexy_spell_entry_activate_language(SexySpellEntry
*entry
, const gchar
*lang
, GError
**error
);
78 void sexy_spell_entry_deactivate_language(SexySpellEntry
*entry
, const gchar
*lang
);
79 gboolean
sexy_spell_entry_set_active_languages(SexySpellEntry
*entry
, GSList
*langs
, GError
**error
);
80 GSList
*sexy_spell_entry_get_active_languages(SexySpellEntry
*entry
);
81 gboolean
sexy_spell_entry_is_checked(SexySpellEntry
*entry
);
82 void sexy_spell_entry_set_checked(SexySpellEntry
*entry
, gboolean checked
);
83 void sexy_spell_entry_activate_default_languages(SexySpellEntry
*entry
);