~ubuntu-branches/ubuntu/quantal/ibus/quantal

« back to all changes in this revision

Viewing changes to src/ibusengine.h

  • Committer: Bazaar Package Importer
  • Author(s): Barry Warsaw
  • Date: 2011-08-11 17:00:57 UTC
  • mfrom: (6.2.14 sid)
  • Revision ID: james.westby@ubuntu.com-20110811170057-6dmbfs4s3cchzl7x
Tags: 1.3.99.20110419-1ubuntu1
* Merge with Debian unstable.  Remaining Ubuntu changes:
  - Indicator support:
    + Add 05_appindicator.patch: Use an indicator rather than a notification
      icon.
    + debian/control: Recommend python-appindicator.
  - debian/control: Install im-switch instead of im-config by default.
  - debian/README.source: Removed, it was outdated and no longer correct
  - debian/patches/01_ubuntu_desktop: Fix "Desktop entry needs the
    X-Ubuntu-Gettext-Domain key"  (LP: #457632)
  - debian/patches/02_title_update.patch: Rename "IBus Preferences" to
    "Keyboard Input Methods"
  - debian/patches/06_locale_parser.patch: Cherry-picked from upstream.

Show diffs side-by-side

added added

removed removed

Lines of Context:
19
19
 * Free Software Foundation, Inc., 59 Temple Place - Suite 330,
20
20
 * Boston, MA 02111-1307, USA.
21
21
 */
 
22
 
 
23
#if !defined (__IBUS_H_INSIDE__) && !defined (IBUS_COMPILATION)
 
24
#error "Only <ibus.h> can be included directly"
 
25
#endif
 
26
 
22
27
/**
23
28
 * SECTION: ibusengine
24
29
 * @short_description: Input method engine abstract.
60
65
 
61
66
typedef struct _IBusEngine IBusEngine;
62
67
typedef struct _IBusEngineClass IBusEngineClass;
 
68
typedef struct _IBusEnginePrivate IBusEnginePrivate;
63
69
 
64
70
/**
65
71
 * IBusEngine:
71
77
 * IBusEngine properties.
72
78
 */
73
79
struct _IBusEngine {
 
80
    /*< private >*/
74
81
    IBusService parent;
 
82
    IBusEnginePrivate *priv;
 
83
 
75
84
    /* instance members */
76
85
    /*< public >*/
77
86
    gboolean enabled;
83
92
};
84
93
 
85
94
struct _IBusEngineClass {
 
95
    /*< private >*/
86
96
    IBusServiceClass parent;
87
97
 
88
98
    /* class members */
 
99
    /*< public >*/
 
100
    /* signals */
89
101
    gboolean    (* process_key_event)
90
102
                                    (IBusEngine     *engine,
91
103
                                     guint           keyval,
124
136
                                     guint           index,
125
137
                                     guint           button,
126
138
                                     guint           state);
 
139
    void        (* set_surrounding_text)
 
140
                                    (IBusEngine     *engine,
 
141
                                     IBusText       *text,
 
142
                                     guint           cursor_index);
127
143
 
128
144
    /*< private >*/
129
145
    /* padding */
130
 
    gpointer pdummy[8];
 
146
    gpointer pdummy[7];
131
147
};
132
148
 
133
149
GType        ibus_engine_get_type       (void);
136
152
 * ibus_engine_new:
137
153
 * @name: Name of the IBusObject.
138
154
 * @path: Path for IBusService.
139
 
 * @connection: An opened IBusConnection.
140
 
 * @returns: A newly allocated IBusEngine.
141
 
 *
142
 
 * New an IBusEngine.
143
 
 */
144
 
IBusEngine  *ibus_engine_new            (const gchar        *name,
145
 
                                         const gchar        *path,
146
 
                                         IBusConnection     *connection);
 
155
 * @connection: An opened GDBusConnection.
 
156
 * @returns: A newly allocated IBusEngine.
 
157
 *
 
158
 * New an IBusEngine.
 
159
 */
 
160
IBusEngine  *ibus_engine_new            (const gchar        *engine_name,
 
161
                                         const gchar        *object_path,
 
162
                                         GDBusConnection    *connection);
 
163
/**
 
164
 * ibus_engine_new_type:
 
165
 * @engine_type: GType of subclass of IBUS_TYPE_ENGINE
 
166
 * @engine_name: Name of the IBusObject.
 
167
 * @object_path: Path for IBusService.
 
168
 * @connection: An opened GDBusConnection.
 
169
 * @returns: A newly allocated IBusEngine.
 
170
 *
 
171
 * New an IBusEngine.
 
172
 */
 
173
IBusEngine  *ibus_engine_new_type       (GType               engine_type,
 
174
                                         const gchar        *engine_name,
 
175
                                         const gchar        *object_path,
 
176
                                         GDBusConnection    *connection);
 
177
 
147
178
 
148
179
/**
149
180
 * ibus_engine_commit_text:
367
398
                                         guint               nchars);
368
399
 
369
400
/**
 
401
 * ibus_engine_get_surrounding_text:
 
402
 * @engine: An IBusEngine.
 
403
 * @text: Location to store surrounding text.
 
404
 * @cursor_pos: Cursor position in characters in @text.
 
405
 *
 
406
 * Get surrounding text.
 
407
 *
 
408
 * @see_also #IBusEngine::set-surrounding-text
 
409
 */
 
410
void ibus_engine_get_surrounding_text(IBusEngine         *engine,
 
411
                                      IBusText          **text,
 
412
                                      guint              *cursor_pos);
 
413
 
 
414
 
 
415
/**
370
416
 * ibus_engine_get_name:
371
417
 * @engine: An IBusEngine.
372
418
 * @returns: Name of IBusEngine.