2002-01-08 Michael Meeks <michael@ximian.com>
[platform/core/uifw/at-spi2-atk.git] / cspi / spi.h
index ebe6119..4afe11e 100644 (file)
@@ -1,8 +1,6 @@
 #ifndef _SPI_H
 #define _SPI_H
 
-#include <glib/gmacros.h>
-
 #include <cspi/spi-impl.h>
 /*
  * Definitions for AccessibleRole, AccessibleState,
@@ -17,7 +15,9 @@
  */
 #include <libspi/keymasks.h>
 
-G_BEGIN_DECLS
+#ifdef  __cplusplus
+extern "C" {
+#endif
 
 /*
  * Enumerated type for text boundary types
@@ -43,11 +43,15 @@ typedef enum
 
 typedef enum
 {
+  SPI_RELATION_NULL,
   SPI_RELATION_LABEL_FOR,
   SPI_RELATION_LABELED_BY,
   SPI_RELATION_CONTROLLER_FOR,
   SPI_RELATION_CONTROLLED_BY,
-  SPI_RELATION_MEMBER_OF
+  SPI_RELATION_MEMBER_OF,
+  SPI_RELATION_NODE_CHILD_OF,
+  SPI_RELATION_EXTENDED,
+  SPI_RELATION_LAST_DEFINED
 } AccessibleRelationType;
 
 
@@ -61,7 +65,8 @@ typedef enum {
   SPI_KEY_PRESS,
   SPI_KEY_RELEASE, 
   SPI_KEY_PRESSRELEASE,
-  SPI_KEY_SYM
+  SPI_KEY_SYM,
+  SPI_KEY_STRING
 } AccessibleKeySynthType;
 
 typedef enum {
@@ -111,9 +116,10 @@ typedef enum {
  **/
 typedef struct _AccessibleKeySet
 {
-       unsigned long *keysyms;
-       unsigned short *keycodes;
-       short len;
+  unsigned long  *keysyms;
+  unsigned short *keycodes;
+  char          **keystrings;
+  short           len;
 } AccessibleKeySet;
 
 /**
@@ -125,905 +131,189 @@ typedef struct _AccessibleKeySet
 
 typedef unsigned long AccessibleKeyMaskType;
 
-/*
- *
- * Basic SPI initialization and event loop function prototypes
- *
- */
-
-int
-SPI_init (SPIBoolean isGNOMEApp);
-
-/**
- * SPI_event_main:
- *
- * Starts/enters the main event loop for the SPI services.
- *
- * (NOTE: This method does not return control, it is exited via a call to exit()
- * from within an event handler).
- *
- **/
-void
-SPI_event_main (void);
-
-/**
- * SPI_event_is_ready:
- *
- * Checks to see if an SPI event is waiting in the event queue.
- * Used by clients that don't wish to use SPI_event_main().
- * Not Yet Implemented.
- *
- * Returns: #TRUE if an event is waiting, otherwise #FALSE.
- *
- **/
-SPIBoolean
-SPI_eventIsReady ();
-
-/**
- * SPI_nextEvent:
- *
- * Gets the next event in the SPI event queue; blocks if no event
- * is pending.
- * Used by clients that don't wish to use SPI_event_main().
- * Not Yet Implemented.
- *
- * Returns: the next #AccessibleEvent in the SPI event queue.
- *
- **/
-AccessibleEvent *
-SPI_nextEvent (SPIBoolean waitForEvent);
-
-/**
- * SPI_exit:
- *
- * Disconnects from the Accessibility Registry and releases resources.
- *
- **/
-void
-SPI_exit (void);
-
-/*
- * Event Listener creation and support.
- */
-
-/**
- * createAccessibleEventListener:
- * @callback : an #AccessibleEventListenerCB callback function, or NULL.
- *
- * Create a new #AccessibleEventListener with a specified callback function.
- *
- * Returns: a pointer to a newly-created #AccessibleEventListener.
- *
- **/
-AccessibleEventListener *
-createAccessibleEventListener (AccessibleEventListenerCB callback,
-                              void                     *user_data);
-
-/**
- * AccessibleEventListener_addCallback:
- * @listener: the #AccessibleEventListener instance to modify.
- * @callback: an #AccessibleEventListenerCB function pointer.
- *
- * Add an in-process callback function to an existing AccessibleEventListener.
- *
- * Returns: #TRUE if successful, otherwise #FALSE.
- *
- **/
-SPIBoolean
-AccessibleEventListener_addCallback (AccessibleEventListener  *listener,
-                                    AccessibleEventListenerCB callback,
-                                    void                     *user_data);
-
-/**
- * AccessibleEventListener_removeCallback:
- * @listener: the #AccessibleEventListener instance to modify.
- * @callback: an #AccessibleEventListenerCB function pointer.
- *
- * Remove an in-process callback function from an existing AccessibleEventListener.
- *
- * Returns: #TRUE if successful, otherwise #FALSE.
- *
- **/
-SPIBoolean
-AccessibleEventListener_removeCallback (AccessibleEventListener  *listener,
-                                       AccessibleEventListenerCB callback);
-
-/**
- * createAccessibleKeystrokeListener:
- * @callback : an #AccessibleKeystrokeListenerCB callback function, or NULL.
- *
- * Create a new #AccessibleKeystrokeListener with a specified callback function.
- *
- * Returns: a pointer to a newly-created #AccessibleKeystrokeListener.
- *
- **/
-AccessibleKeystrokeListener *
-createAccessibleKeystrokeListener (AccessibleKeystrokeListenerCB callback,
-                                  void                         *user_data);
-
-/**
- * KeystrokeListener_addCallback:
- * @listener: the #KeystrokeListener instance to modify.
- * @callback: an #KeystrokeListenerCB function pointer.
- *
- * Add an in-process callback function to an existing #KeystrokeListener.
- *
- * Returns: #TRUE if successful, otherwise #FALSE.
- *
- **/
-SPIBoolean
-AccessibleKeystrokeListener_addCallback (AccessibleKeystrokeListener  *listener,
-                                        AccessibleKeystrokeListenerCB callback,
-                                        void                         *user_data);
-
-/**
- * AccessibleKeystrokeListener_removeCallback:
- * @listener: the #AccessibleKeystrokeListener instance to modify.
- * @callback: an #AccessibleKeystrokeListenerCB function pointer.
- *
- * Remove an in-process callback function from an existing #AccessibleKeystrokeListener.
- *
- * Returns: #TRUE if successful, otherwise #FALSE.
- *
- **/
-SPIBoolean
-AccessibleKeystrokeListener_removeCallback (AccessibleKeystrokeListener *listener,
-                                           AccessibleKeystrokeListenerCB callback);
-
-void AccessibleKeystrokeListener_unref (AccessibleKeystrokeListener *listener);
-
-/*
- *
- * Global functions serviced by the registry
- *
- */
-
-/**
- * registerGlobalEventListener:
- * @listener: the #AccessibleEventListener to be registered against an event type.
- * @callback: a character string indicating the type of events for which
- *            notification is requested.  Format is
- *            EventClass:major_type:minor_type:detail
- *            where all subfields other than EventClass are optional.
- *            EventClasses include "Focus", "Window", "Mouse",
- *            and toolkit events (e.g. "Gtk", "AWT").
- *            Examples: "focus:", "Gtk:GtkWidget:button_press_event".
- *
- * NOTE: this string may be UTF-8, but should not contain byte value 56 (ascii ':'),
- *            except as a delimiter, since non-UTF-8 string delimiting
- *            functions are used internally.  In general, listening to
- *            toolkit-specific events is not recommended.
- *
- * Add an in-process callback function to an existing AccessibleEventListener.
- *
- * Returns: #TRUE if successful, otherwise #FALSE.
- *
- **/
-SPIBoolean
-registerGlobalEventListener (AccessibleEventListener *listener,
-                             char *eventType);
-SPIBoolean
-deregisterGlobalEventListener (AccessibleEventListener *listener,
-                               char *eventType);
-SPIBoolean
-deregisterGlobalEventListenerAll (AccessibleEventListener *listener);
-
-
-/**
- * getDesktopCount:
- *
- * Get the number of virtual desktops.
- * NOTE: currently multiple virtual desktops are not implemented, this
- *       function always returns '1'.
- *
- * Returns: an integer indicating the number of active virtual desktops.
- *
- **/
-int
-getDesktopCount ();
 
-/**
- * getDesktop:
- * @i: an integer indicating which of the accessible desktops is to be returned.
- *
- * Get the virtual desktop indicated by index @i.
- * NOTE: currently multiple virtual desktops are not implemented, this
- *       function always returns '1'.
- *
- * Returns: a pointer to the 'i-th' virtual desktop's #Accessible representation.
- *
- **/
-Accessible*
-getDesktop (int i);
-
-/**
- * getDesktopList:
- * @list: a pointer to an array of #Accessible objects.
- *
- * Get the list of virtual desktops.  On return, @list will point
- *     to a newly-created array of virtual desktop pointers.
- *     It is the responsibility of the caller to free this array when
- *     it is no longer needed.
- *
- * Not Yet Implemented.
- *
- * Returns: an integer indicating how many virtual desktops have been
- *          placed in the list pointed to by parameter @list.
- **/
-int
-getDesktopList (Accessible **list);
-
-/**
- * registerAccessibleKeystrokeListener:
- * @listener: a pointer to the #AccessibleKeystrokeListener for which
- *            keystroke events are requested.
- *
- * [Partially Implemented.]
- *
- **/
-void
-registerAccessibleKeystrokeListener (AccessibleKeystrokeListener *listener,
-                                    AccessibleKeySet *keys,
-                                    AccessibleKeyMaskType modmask,
-                                    AccessibleKeyEventMask eventmask,
-                                    AccessibleKeyListenerSyncType sync_type);
-
-void
-deregisterAccessibleKeystrokeListener (AccessibleKeystrokeListener *listener,
-                                      AccessibleKeyMaskType modmask);
-
-/**
- * generateKeyEvent:
- * @keyval: a #long integer indicating the keycode or keysym of the key event
- *           being synthesized.
- * @synth_type: a #AccessibleKeySynthType flag indicating whether @keyval
- *           is to be interpreted as a keysym rather than a keycode
- *           (SPI_KEYSYM) and whether to synthesize
- *           SPI_KEY_PRESS, SPI_KEY_RELEASE, or both (SPI_KEY_PRESSRELEASE).
- *
- * Synthesize a keyboard event (as if a hardware keyboard event occurred in the
- * current UI context).
- *
- **/
-void
-generateKeyEvent (long int keyval, AccessibleKeySynthType synth_type);
-
-/**
- * generateMouseEvent:
- * @x: a #long int indicating the screen x coordinate of the mouse event.
- * @y: a #long int indicating the screen y coordinate of the mouse event.
- * @name: a string indicating which mouse event to be synthesized
- *        (e.g. "button1", "button2", "mousemove").
- *
- * Synthesize a mouse event at a specific screen coordinate.
- * Not Yet Implemented.
- *
- **/
-void
-generateMouseEvent (long int x, long int y, char *name);
-
-/*
- *
- * Accessible function prototypes
- *
- */
-
-/**
- * Accessible_ref:
- * @obj: a pointer to the #Accessible object on which to operate.
- *
- * Increment the reference count for an #Accessible object.
- *
- * Returns: (no return code implemented yet).
- *
- **/
-int
-Accessible_ref (Accessible *obj);
-
-/**
- * Accessible_unref:
- * @obj: a pointer to the #Accessible object on which to operate.
- *
- * Decrement the reference count for an #Accessible object.
- *
- * Returns: (no return code implemented yet).
- *
- **/
-int
-Accessible_unref (Accessible *obj);
-
-/**
- * Accessible_getName:
- * @obj: a pointer to the #Accessible object on which to operate.
- *
- * Get the name of an #Accessible object.
- *
- * Returns: a UTF-8 string indicating the name of the #Accessible object.
- *
- **/
-char *
-Accessible_getName (Accessible *obj);
-
-/**
- * Accessible_getDescription:
- * @obj: a pointer to the #Accessible object on which to operate.
- *
- * Get the description of an #Accessible object.
- *
- * Returns: a UTF-8 string describing the #Accessible object.
- *
- **/
-char *
-Accessible_getDescription (Accessible *obj);
-
-/**
- * Accessible_getParent:
- * @obj: a pointer to the #Accessible object to query.
- *
- * Get an #Accessible object's parent container.
- *
- * Returns: a pointer to the #Accessible object which contains the given
- *          #Accessible instance, or NULL if the @obj has no parent container.
- *
- **/
-Accessible *
-Accessible_getParent (Accessible *obj);
-
-/**
- * Accessible_getChildCount:
- * @obj: a pointer to the #Accessible object on which to operate.
- *
- * Get the number of children contained by an #Accessible object.
- *
- * Returns: a #long indicating the number of #Accessible children
- *          contained by an #Accessible object.
- *
- **/
-long
-Accessible_getChildCount (Accessible *obj);
-
-/**
- * Accessible_getChildAtIndex:
- *
- * @obj: a pointer to the #Accessible object on which to operate.
- * @childIndex: a #long indicating which child is specified.
- *
- * Get the #Accessible child of an #Accessible object at a given index.
- *
- * Returns: a pointer to the #Accessible child object at index
- *          @childIndex.
- *
- **/
-Accessible *
-Accessible_getChildAtIndex (Accessible *obj,
-                            long int childIndex);
-
-/**
- * Accessible_getIndexInParent:
- *
- * @obj: a pointer to the #Accessible object on which to operate.
- *
- * Get the index of an #Accessible object in its containing #Accessible.
- *
- * Returns: a #long indicating the index of the #Accessible object
- *          in its parent (i.e. containing) #Accessible instance,
- *          or -1 if @obj has no containing parent.
- *
- **/
-long
-Accessible_getIndexInParent (Accessible *obj);
-
-/**
- * Accessible_getRelationSet:
- * @obj: a pointer to the #Accessible object on which to operate.
- *
- * Not Yet Implemented.
- *
- * Returns: a pointer to an array of #AccessibleRelations.
- *
- **/
-AccessibleRelation **
-Accessible_getRelationSet (Accessible *obj);
-
-/**
- * Accessible_getRole:
- * @obj: a pointer to the #Accessible object on which to operate.
- *
- * Get the UI role of an #Accessible object.
- *
- * Returns: a UTF-8 string indicating the UI role of the #Accessible object.
- *
- **/
-const char *
-Accessible_getRole (Accessible *obj);
-
-/**
- * Accessible_getStateSet:
- * @obj: a pointer to the #Accessible object on which to operate.
- *
- * Not Yet Implemented.
- *
- * Returns: a pointer to an #AccessibleStateSet representing the object's current state.
- *
- **/
-AccessibleStateSet *
-Accessible_getStateSet (Accessible *obj);
+/* Basic SPI initialization and event loop function prototypes */
+
+int              SPI_init         (void);
+void             SPI_event_main   (void);
+void             SPI_event_quit   (void);
+SPIBoolean       SPI_eventIsReady (void);
+AccessibleEvent *SPI_nextEvent    (SPIBoolean waitForEvent);
+int              SPI_exit         (void);
+
+/* Event Listener creation and support.  */
+
+void                      SPI_freeAccessibleKeySet (
+                                                  AccessibleKeySet         *keyset);
+AccessibleKeySet        * SPI_createAccessibleKeySet (
+                                                  int                       len,
+                                                  const char               *keysyms,
+                                                  short                    *keycodes,
+                                                  const char              **keystrings);
+AccessibleEventListener * SPI_createAccessibleEventListener (
+                                                  AccessibleEventListenerCB callback,
+                                                  void                     *user_data);
+SPIBoolean                AccessibleEventListener_addCallback (
+                                                  AccessibleEventListener  *listener,
+                                                  AccessibleEventListenerCB callback,
+                                                  void                     *user_data);
+SPIBoolean                AccessibleEventListener_removeCallback (
+                                                  AccessibleEventListener  *listener,
+                                                  AccessibleEventListenerCB callback);
+void                      AccessibleEventListener_unref (
+                                                  AccessibleEventListener  *listener);
+
+/* Keystroke Listener creation and support.  */
+
+AccessibleKeystrokeListener * SPI_createAccessibleKeystrokeListener (
+                                       AccessibleKeystrokeListenerCB callback,
+                                       void                         *user_data);
+SPIBoolean                    AccessibleKeystrokeListener_addCallback (
+                                       AccessibleKeystrokeListener  *listener,
+                                       AccessibleKeystrokeListenerCB callback,
+                                       void                         *user_data);
+SPIBoolean                    AccessibleKeystrokeListener_removeCallback (
+                                       AccessibleKeystrokeListener *listener,
+                                       AccessibleKeystrokeListenerCB callback);
+void                          AccessibleKeystrokeListener_unref (
+                                       AccessibleKeystrokeListener *listener);
+
+/* Global functions serviced by the registry */
+
+SPIBoolean SPI_registerGlobalEventListener           (
+                                      AccessibleEventListener *listener,
+                                      const char              *eventType);
+SPIBoolean SPI_deregisterGlobalEventListener         (
+                                      AccessibleEventListener *listener,
+                                      const char              *eventType);
+SPIBoolean SPI_deregisterGlobalEventListenerAll      (
+                                      AccessibleEventListener *listener);
+SPIBoolean SPI_registerAccessibleKeystrokeListener   (
+                                       AccessibleKeystrokeListener *listener,
+                                      AccessibleKeySet             *keys,
+                                      AccessibleKeyMaskType         modmask,
+                                      AccessibleKeyEventMask        eventmask,
+                                      AccessibleKeyListenerSyncType sync_type);
+SPIBoolean SPI_deregisterAccessibleKeystrokeListener (
+                                      AccessibleKeystrokeListener *listener,
+                                      AccessibleKeyMaskType        modmask);
+
+int         SPI_getDesktopCount                  (void);
+Accessible *SPI_getDesktop                       (int i);
+int         SPI_getDesktopList                   (Accessible ***desktop_list);
+void        SPI_freeDesktopList                  (Accessible  **desktop_list);
+
+SPIBoolean  SPI_generateKeyboardEvent            (long int                    keyval,
+                                                 char                       *keystring,
+                                                 AccessibleKeySynthType      synth_type);
+
+SPIBoolean  SPI_generateMouseEvent               (long int x, long int y, char *name);
+
+/* Accessible function prototypes  */
+
+void                 Accessible_ref              (Accessible *obj);
+void                 Accessible_unref            (Accessible *obj);
+char *               Accessible_getName          (Accessible *obj);
+char *               Accessible_getDescription   (Accessible *obj);
+Accessible *         Accessible_getParent        (Accessible *obj);
+long                 Accessible_getChildCount    (Accessible *obj);
+Accessible *         Accessible_getChildAtIndex  (Accessible *obj,
+                                                 long int    childIndex);
+long                 Accessible_getIndexInParent (Accessible *obj);
+AccessibleRelation **Accessible_getRelationSet   (Accessible *obj);
+AccessibleRole       Accessible_getRole          (Accessible *obj);
+char *               Accessible_getRoleName      (Accessible *obj);
+AccessibleStateSet * Accessible_getStateSet      (Accessible *obj);
 
 /* Interface query methods */
 
-/**
- * Accessible_isAction:
- * @obj: a pointer to the #Accessible instance to query.
- *
- * Query whether the specified #Accessible implements #AccessibleAction.
- *
- * Returns: #TRUE if @obj implements the #AccessibleAction interface,
- *          #FALSE otherwise.
- **/
-SPIBoolean
-Accessible_isAction (Accessible *obj);
-
-/**
- * Accessible_isApplication:
- * @obj: a pointer to the #Accessible instance to query.
- *
- * Query whether the specified #Accessible implements #AccessibleApplication.
- *
- * Returns: #TRUE if @obj implements the #AccessibleApplication interface,
- *          #FALSE otherwise.
- **/
-SPIBoolean
-Accessible_isApplication (Accessible *obj);
-
-/**
- * Accessible_isComponent:
- * @obj: a pointer to the #Accessible instance to query.
- *
- * Query whether the specified #Accessible implements #AccessibleComponent.
- *
- * Returns: #TRUE if @obj implements the #AccessibleComponent interface,
- *          #FALSE otherwise.
- **/
-SPIBoolean
-Accessible_isComponent (Accessible *obj);
-
-/**
- * Accessible_isEditableText:
- * @obj: a pointer to the #Accessible instance to query.
- *
- * Query whether the specified #Accessible implements #AccessibleEditableText.
- *
- * Returns: #TRUE if @obj implements the #AccessibleEditableText interface,
- *          #FALSE otherwise.
- **/
-SPIBoolean
-Accessible_isEditableText (Accessible *obj);
-
-/**
- * Accessible_isHypertext:
- * @obj: a pointer to the #Accessible instance to query.
- *
- * Query whether the specified #Accessible implements #AccessibleHypertext.
- *
- * Returns: #TRUE if @obj implements the #AccessibleHypertext interface,
- *          #FALSE otherwise.
- **/
-SPIBoolean
-Accessible_isHypertext (Accessible *obj);
-
-/**
- * Accessible_isImage:
- * @obj: a pointer to the #Accessible instance to query.
- *
- * Query whether the specified #Accessible implements #AccessibleImage.
- *
- * Returns: #TRUE if @obj implements the #AccessibleImage interface,
- *          #FALSE otherwise.
-**/
-SPIBoolean
-Accessible_isImage (Accessible *obj);
-
-/**
-  * Accessible_isSelection:
- * @obj: a pointer to the #Accessible instance to query.
- *
- * Query whether the specified #Accessible implements #AccessibleSelection.
- *
- * Returns: #TRUE if @obj implements the #AccessibleSelection interface,
- *          #FALSE otherwise.
-**/
-SPIBoolean
-Accessible_isSelection (Accessible *obj);
-
-/**
- * Accessible_isTable:
- * @obj: a pointer to the #Accessible instance to query.
- *
- * Query whether the specified #Accessible implements #AccessibleTable.
- *
- * Returns: #TRUE if @obj implements the #AccessibleTable interface,
- *          #FALSE otherwise.
-**/
-SPIBoolean
-Accessible_isTable (Accessible *obj);
-
-/**
- * Accessible_isText:
- * @obj: a pointer to the #Accessible instance to query.
- *
- * Query whether the specified #Accessible implements #AccessibleText.
- *
- * Returns: #TRUE if @obj implements the #AccessibleText interface,
- *          #FALSE otherwise.
-**/
-SPIBoolean
-Accessible_isText (Accessible *obj);
-
-SPIBoolean
-Accessible_isValue (Accessible *obj);
-
-/**
- * Accessible_getAction:
- * @obj: a pointer to the #Accessible instance to query.
- *
- * Get the #AccessibleAction interface for an #Accessible.
- *
- * Returns: a pointer to an #AccessibleAction interface instance, or
- *          NULL if @obj does not implement #AccessibleAction.
- **/
-AccessibleAction *
-Accessible_getAction (Accessible *obj);
-
-/**
- * Accessible_getApplication:
- * @obj: a pointer to the #Accessible instance to query.
- *
- * Get the #AccessibleApplication interface for an #Accessible.
- *
- * Returns: a pointer to an #AccessibleApplication interface instance, or
- *          NULL if @obj does not implement #AccessibleApplication.
- **/
-AccessibleApplication *
-Accessible_getApplication (Accessible *obj);
-
-/**
- * Accessible_getComponent:
- * @obj: a pointer to the #Accessible instance to query.
- *
- * Get the #AccessibleComponent interface for an #Accessible.
- *
- * Returns: a pointer to an #AccessibleComponent interface instance, or
- *          NULL if @obj does not implement #AccessibleComponent.
- **/
-AccessibleComponent *
-Accessible_getComponent (Accessible *obj);
-
-/**
- * Accessible_getEditableText:
- *
- * Not Yet Implemented.
- *
- **/
-AccessibleEditableText *
-Accessible_getEditableText (Accessible *obj);
-
-/**
- * Accessible_getHypertext:
- *
- * Not Yet Implemented.
- *
- **/
-AccessibleHypertext *
-Accessible_getHypertext (Accessible *obj);
-
-/**
- * Accessible_getImage:
- *
- * Not Yet Implemented.
- *
- **/
-AccessibleImage *
-Accessible_getImage (Accessible *obj);
-
-/**
- * Accessible_getSelection:
- *
- * Not Yet Implemented.
- *
- **/
-AccessibleSelection *
-Accessible_getSelection (Accessible *obj);
-
-/**
- * Accessible_getTable:
- *
- * Not Yet Implemented.
- *
- **/
-AccessibleTable *
-Accessible_getTable (Accessible *obj);
-
-/**
- * Accessible_getText:
- *
- * Not Yet Implemented.
- *
- **/
-AccessibleText *
-Accessible_getText (Accessible *obj);
-
-AccessibleValue *
-Accessible_getValue (Accessible *obj);
-
-/**
- * Accessible_queryInterface:
- * @obj: a pointer to the #Accessible instance to query.
- * @interface_name: a UTF-8 character string specifiying the requested interface.
- *
- * Query an #Accessible object to for a named interface.
- *
- * Returns: an instance of the named interface object, if it is implemented
- *          by @obj, or NULL otherwise.
- *
- **/
-GenericInterface *
-Accessible_queryInterface (Accessible *obj, char *interface_name);
-
-/*
- *
- * AccessibleAction function prototypes
- *
- */
-
-int
-AccessibleAction_ref (AccessibleAction *obj);
-
-int
-AccessibleAction_unref (AccessibleAction *obj);
-
-long
-AccessibleAction_getNActions (AccessibleAction *obj);
-
-/**
- * AccessibleAction_getName:
- * @obj: a pointer to the #AccessibleAction implementor to query.
- * @i: a long integer indicating which action to query.
- *
- * Get the name of the '@i-th' action invokable on an
- *      object implementing #AccessibleAction.
- *
- * Returns: the 'event type' name of the action, as a UTF-8 string.
- *
- **/
-char *
-AccessibleAction_getName (AccessibleAction *obj, long int i);
-
-/**
- * AccessibleAction_getDescription:
- * @obj: a pointer to the #AccessibleAction to query.
- * @i: a long integer indicating which action to query.
- *
- * Get the description of '@i-th' action invokable on an
- *      object implementing #AccessibleAction.
- *
- * Returns: a UTF-8 string describing the '@i-th' invokable action.
- *
- **/
-char *
-AccessibleAction_getDescription (AccessibleAction *obj,
-                                 long int i);
-
-SPIBoolean
-AccessibleAction_doAction (AccessibleAction *obj,
-                           long int i);
-
-/**
- * AccessibleAction_getKeybinding:
- * @obj: a pointer to the #AccessibleAction implementor to query.
- * @i: a long integer indicating which action to query.
- *
- * Get the keybindings for the @i-th action invokable on an
- *      object implementing #AccessibleAction, if any are defined.
- *
- * Returns: a UTF-8 string which can be parsed to determine the @i-th
- * invokable action's keybindings.
- *
- **/
-char *
-AccessibleAction_getKeyBinding (AccessibleAction *obj,
-                                long int i);
-
-/*
- *
- * AccessibleApplication function prototypes
- *
- */
-
-/**
- * AccessibleApplication_unref:
- * @obj: a pointer to the #AccessibleApplication on which to operate.
- *
- * Decrement the reference count for an #AccessibleApplication.
- *
- * Returns: (no return code implemented yet).
- *
- **/
-int
-AccessibleApplication_ref (AccessibleApplication *obj);
-
-/**
- * AccessibleApplication_unref:
- * @obj: a pointer to the #AccessibleApplication object on which to operate.
- *
- * Decrement the reference count for an #AccessibleApplication.
- *
- * Returns: (no return code implemented yet).
- *
- **/
-int
-AccessibleApplication_unref (AccessibleApplication *obj);
-
-/**
- * AccessibleApplication_getToolkitName:
- * @obj: a pointer to the #AccessibleApplication to query.
- *
- * Get the name of the UI toolkit used by an #AccessibleApplication.
- *
- * Returns: a UTF-8 string indicating which UI toolkit is
- *          used by an application.
- *
- **/
-char *
-AccessibleApplication_getToolkitName (AccessibleApplication *obj);
-
-/**
- * AccessibleApplication_getVersion:
- * @obj: a pointer to the #AccessibleApplication being queried.
- *
- * Get the version of the at-spi bridge exported by an
- *      #AccessibleApplication instance.
- *
- * Returns: a UTF-8 string indicating the application's
- *          at-spi version.
- *
- **/
-char *
-AccessibleApplication_getVersion (AccessibleApplication *obj);
-
-/**
- * AccessibleApplication_getID:
- * @obj: a pointer to the #AccessibleApplication being queried.
- *
- * Get the unique ID assigned by the Registry to an
- *      #AccessibleApplication instance.
- * (Not Yet Implemented by the registry).
- *
- * Returns: a unique #long integer associated with the application
- *          by the Registry, or 0 if the application is not registered.
- **/
-long
-AccessibleApplication_getID (AccessibleApplication *obj);
-
-/**
- * AccessibleApplication_pause:
- * @obj: a pointer to the #Accessible object on which to operate.
- *
- * Attempt to pause the application (used when client event queue is
- *  over-full).
- * Not Yet Implemented.
- *
- * Returns: #TRUE if the application was paused successfully, #FALSE otherwise.
- *
- **/
-SPIBoolean
-AccessibleApplication_pause (AccessibleApplication *obj);
-
-/**
- * AccessibleApplication_resume:
- * @obj: a pointer to the #Accessible object on which to operate.
- *
- * Attempt to resume the application (used after #AccessibleApplication_pause).
- * Not Yet Implemented.
- *
- * Returns: #TRUE if application processing resumed successfully, #FALSE otherwise.
- *
- **/
-SPIBoolean
-AccessibleApplication_resume (AccessibleApplication *obj);
-
-/*
- *
- * AccessibleComponent function prototypes
- *
- */
-
-int
-AccessibleComponent_ref (AccessibleComponent *obj);
-
-int
-AccessibleComponent_unref (AccessibleComponent *obj);
-
-SPIBoolean
-AccessibleComponent_contains (AccessibleComponent *obj,
-                              long int x,
-                              long int y,
-                              AccessibleCoordType ctype);
-
-Accessible *
-AccessibleComponent_getAccessibleAtPoint (AccessibleComponent *obj,
-                                          long int x,
-                                          long int y,
-                                          AccessibleCoordType ctype);
-
-/**
- * AccessibleComponent_getExtents:
- * @obj: a pointer to the #AccessibleComponent to query.
- * @x: a pointer to a #long into which the minimum x coordinate will be returned.
- * @y: a pointer to a #long into which the minimum y coordinate will be returned.
- * @width: a pointer to a #long into which the x extents (width) will be returned.
- * @height: a pointer to a #long into which the y extents (height) will be returned.
- * @ctype: the desired coordinate system into which to return the results,
- *         (e.g. COORD_TYPE_WINDOW, COORD_TYPE_SCREEN).
- *
- * Get the bounding box of the specified #AccessibleComponent.
- *
- **/
-void
-AccessibleComponent_getExtents (AccessibleComponent *obj,
-                                long int *x,
-                                long int *y,
-                                long int *width,
-                                long int *height,
-                                AccessibleCoordType ctype);
-
-void
-AccessibleComponent_getPosition (AccessibleComponent *obj,
-                                 long int *x,
-                                 long int *y,
-                                 AccessibleCoordType ctype);
-
-void
-AccessibleComponent_getSize (AccessibleComponent *obj,
-                             long int *width,
-                             long int *height);
-
-/**
- * AccessibleComponent_getLayer:
- * @obj: a pointer to the #AccessibleComponent to query.
- *
- * Query which layer the component is painted into, to help determine its 
- *      visibility in terms of stacking order.
- *
- * Returns: the #AccessibleComponentLayer into which this component is painted.
- **/
+SPIBoolean Accessible_isAction            (Accessible *obj);
+SPIBoolean Accessible_isApplication       (Accessible *obj);
+SPIBoolean Accessible_isComponent         (Accessible *obj);
+SPIBoolean Accessible_isEditableText      (Accessible *obj);
+SPIBoolean Accessible_isHypertext         (Accessible *obj);
+SPIBoolean Accessible_isImage             (Accessible *obj);
+SPIBoolean Accessible_isSelection         (Accessible *obj);
+SPIBoolean Accessible_isStreamableContent (Accessible *obj);
+SPIBoolean Accessible_isTable             (Accessible *obj);
+SPIBoolean Accessible_isText              (Accessible *obj);
+SPIBoolean Accessible_isValue             (Accessible *obj);
+
+AccessibleAction *            Accessible_getAction            (Accessible *obj);
+AccessibleApplication *       Accessible_getApplication       (Accessible *obj);
+AccessibleComponent *         Accessible_getComponent         (Accessible *obj);
+AccessibleEditableText *      Accessible_getEditableText      (Accessible *obj);
+AccessibleHypertext *         Accessible_getHypertext         (Accessible *obj);
+AccessibleImage *             Accessible_getImage             (Accessible *obj);
+AccessibleSelection *         Accessible_getSelection         (Accessible *obj);
+AccessibleStreamableContent * Accessible_getStreamableContent (Accessible *obj);
+AccessibleTable *             Accessible_getTable             (Accessible *obj);
+AccessibleText *              Accessible_getText              (Accessible *obj);
+AccessibleValue *             Accessible_getValue             (Accessible *obj);
+AccessibleUnknown *           Accessible_queryInterface       (Accessible *obj,
+                                                  const char *interface_name);
+
+/* AccessibleAction function prototypes  */
+
+void       AccessibleAction_ref            (AccessibleAction *obj);
+void       AccessibleAction_unref          (AccessibleAction *obj);
+long       AccessibleAction_getNActions    (AccessibleAction *obj);
+char      *AccessibleAction_getName        (AccessibleAction *obj,
+                                           long int          i);
+char      *AccessibleAction_getDescription (AccessibleAction *obj,
+                                           long int          i);
+SPIBoolean AccessibleAction_doAction       (AccessibleAction *obj,
+                                           long int          i);
+char      *AccessibleAction_getKeyBinding  (AccessibleAction *obj,
+                                           long int          i);
+
+/* AccessibleApplication function prototypes  */
+
+void       AccessibleApplication_ref            (AccessibleApplication *obj);
+void       AccessibleApplication_unref          (AccessibleApplication *obj);
+char      *AccessibleApplication_getToolkitName (AccessibleApplication *obj);
+char      *AccessibleApplication_getVersion     (AccessibleApplication *obj);
+long       AccessibleApplication_getID          (AccessibleApplication *obj);
+SPIBoolean AccessibleApplication_pause          (AccessibleApplication *obj);
+SPIBoolean AccessibleApplication_resume         (AccessibleApplication *obj);
+
+/* AccessibleComponent function prototypes */
+
+void        AccessibleComponent_ref         (AccessibleComponent *obj);
+void        AccessibleComponent_unref       (AccessibleComponent *obj);
+SPIBoolean  AccessibleComponent_contains    (AccessibleComponent *obj,
+                                            long int             x,
+                                            long int             y,
+                                            AccessibleCoordType  ctype);
+Accessible *AccessibleComponent_getAccessibleAtPoint (
+                                             AccessibleComponent *obj,
+                                            long int             x,
+                                            long int             y,
+                                            AccessibleCoordType  ctype);
+void        AccessibleComponent_getExtents  (AccessibleComponent *obj,
+                                            long int            *x,
+                                            long int            *y,
+                                            long int            *width,
+                                            long int            *height,
+                                            AccessibleCoordType  ctype);
+void        AccessibleComponent_getPosition (AccessibleComponent *obj,
+                                            long int            *x,
+                                            long int            *y,
+                                            AccessibleCoordType  ctype);
+void        AccessibleComponent_getSize     (AccessibleComponent *obj,
+                                            long int            *width,
+                                            long int            *height);
 AccessibleComponentLayer
-AccessibleComponent_getLayer (AccessibleComponent *obj);
+            AccessibleComponent_getLayer    (AccessibleComponent *obj);
+void        AccessibleComponent_grabFocus   (AccessibleComponent *obj);
+short       AccessibleComponent_getMDIZOrder(AccessibleComponent *obj);
 
-/**
- * AccessibleComponent_getMDIZOrder:
- * @obj: a pointer to the #AccessibleComponent to query.
- *
- * Query the z stacking order of a component which is in the MDI layer.
- *
- * Returns: a short integer indicating the stacking order of the component 
- *       in the MDI layer, or -1 if the component is not in the MDI layer.
- **/
-short
-AccessibleComponent_getMDIZOrder (AccessibleComponent *obj);
+/* AccessibleEditableText function prototypes  */
 
 void
-AccessibleComponent_grabFocus (AccessibleComponent *obj);
-
-/*
- *
- * AccessibleEditableText function prototypes
- *
- */
-
-int
 AccessibleEditableText_ref (AccessibleEditableText *obj);
 
-int
+void
 AccessibleEditableText_unref (AccessibleEditableText *obj);
 
 SPIBoolean
@@ -1066,6 +356,10 @@ AccessibleEditableText_pasteText (AccessibleEditableText *obj,
  * AccessibleHyperlink function prototypes
  *
  */
+void
+AccessibleHyperlink_ref (AccessibleHyperlink *obj);
+void
+AccessibleHyperlink_unref (AccessibleHyperlink *obj);
 
 long
 AccessibleHyperlink_getNAnchors (AccessibleHyperlink *obj);
@@ -1092,10 +386,10 @@ AccessibleHyperlink_isValid (AccessibleHyperlink *obj);
  *
  */
 
-int
+void
 AccessibleHypertext_ref (AccessibleHypertext *obj);
 
-int
+void
 AccessibleHypertext_unref (AccessibleHypertext *obj);
 
 long
@@ -1115,10 +409,10 @@ AccessibleHypertext_getLinkIndex (AccessibleHypertext *obj,
  *
  */
 
-int
+void
 AccessibleImage_ref (AccessibleImage *obj);
 
-int
+void
 AccessibleImage_unref (AccessibleImage *obj);
 
 char *
@@ -1148,11 +442,8 @@ AccessibleImage_getImageExtents (AccessibleImage *obj,
  *
  */
 
-int
-AccessibleRelation_ref (AccessibleRelation *obj);
-
-int
-AccessibleRelation_unref (AccessibleRelation *obj);
+void AccessibleRelation_ref   (AccessibleRelation *obj);
+void AccessibleRelation_unref (AccessibleRelation *obj);
 
 AccessibleRelationType
 AccessibleRelation_getRelationType (AccessibleRelation *obj);
@@ -1170,11 +461,8 @@ AccessibleRelation_getTarget (AccessibleRelation *obj, int i);
  *
  */
 
-int
-AccessibleSelection_ref (AccessibleSelection *obj);
-
-int
-AccessibleSelection_unref (AccessibleSelection *obj);
+void AccessibleSelection_ref   (AccessibleSelection *obj);
+void AccessibleSelection_unref (AccessibleSelection *obj);
 
 long
 AccessibleSelection_getNSelectedChildren (AccessibleSelection *obj);
@@ -1208,11 +496,8 @@ AccessibleSelection_clearSelection (AccessibleSelection *obj);
  *
  */
 
-int
-AccessibleStateSet_ref (AccessibleStateSet *obj);
-
-int
-AccessibleStateSet_unref (AccessibleStateSet *obj);
+void AccessibleStateSet_ref   (AccessibleStateSet *obj);
+void AccessibleStateSet_unref (AccessibleStateSet *obj);
 
 SPIBoolean
 AccessibleStateSet_contains (AccessibleStateSet *obj,
@@ -1230,26 +515,38 @@ SPIBoolean
 AccessibleStateSet_equals (AccessibleStateSet *obj,
                            AccessibleStateSet *obj2);
 
-void
+AccessibleStateSet *
 AccessibleStateSet_compare (AccessibleStateSet *obj,
-                            AccessibleStateSet *obj2,
-                            AccessibleStateSet **differenceSet);
+                            AccessibleStateSet *obj2);
 
 SPIBoolean
 AccessibleStateSet_isEmpty (AccessibleStateSet *obj);
 
-
+void
+AccessibleStreamableContent_ref (AccessibleStreamableContent *obj);
+void
+AccessibleStreamableContent_unref (AccessibleStreamableContent *obj);
+char **
+AccessibleStreamableContent_getContentTypes (AccessibleStreamableContent *obj);
+SPIBoolean
+AccessibleStreamableContent_open (AccessibleStreamableContent *obj,
+                                 const char *content_type);
+SPIBoolean
+AccessibleStreamableContent_seek (AccessibleStreamableContent *obj,
+                                 long int offset);
+SPIBoolean
+AccessibleStreamableContent_read (AccessibleStreamableContent *obj,
+                                 void *buff,
+                                 long int nbytes,
+                                 unsigned int read_type);
 /*
  *
  * AccessibleTable function prototypes
  *
  */
 
-int
-AccessibleTable_ref (AccessibleTable *obj);
-
-int
-AccessibleTable_unref (AccessibleTable *obj);
+void AccessibleTable_ref   (AccessibleTable *obj);
+void AccessibleTable_unref (AccessibleTable *obj);
 
 Accessible *
 AccessibleTable_getCaption (AccessibleTable *obj);
@@ -1340,11 +637,8 @@ AccessibleTable_isSelected (AccessibleTable *obj,
  *
  */
 
-int
-AccessibleText_ref (AccessibleText *obj);
-
-int
-AccessibleText_unref (AccessibleText *obj);
+void AccessibleText_ref   (AccessibleText *obj);
+void AccessibleText_unref (AccessibleText *obj);
 
 long
 AccessibleText_getCharacterCount (AccessibleText *obj);
@@ -1433,34 +727,21 @@ AccessibleText_setSelection (AccessibleText *obj,
                             long int startOffset,
                             long int endOffset);
 
-/*
- *
- * AccessibleValue Function Prototypes:
- *
- */
-
-int
-AccessibleValue_ref (AccessibleValue *obj);
+/* AccessibleValue Function Prototypes:  */
 
-int
-AccessibleValue_unref (AccessibleValue *obj);
+void       AccessibleValue_ref             (AccessibleValue *obj);
+void       AccessibleValue_unref           (AccessibleValue *obj);
+double     AccessibleValue_getMinimumValue (AccessibleValue *obj);
+double     AccessibleValue_getCurrentValue (AccessibleValue *obj);
+double     AccessibleValue_getMaximumValue (AccessibleValue *obj);
+SPIBoolean AccessibleValue_setCurrentValue (AccessibleValue *obj,
+                                           double           newValue);
 
-float
-AccessibleValue_getMinimumValue (AccessibleValue *obj);
+/* Misc methods */
+void SPI_freeString (char *s);
 
-float
-AccessibleValue_getCurrentValue (AccessibleValue *obj);
-
-float
-AccessibleValue_getMaximumValue (AccessibleValue *obj);
-
-SPIBoolean
-AccessibleValue_setCurrentValue (AccessibleValue *obj,
-                                 float newValue);
-
-void
-SPI_freeString (char *s);
-
-G_END_DECLS
+#ifdef  __cplusplus
+}
+#endif
 
 #endif