diff options
author | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-04-19 00:47:55 +0000 |
---|---|---|
committer | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-04-19 00:47:55 +0000 |
commit | 26a029d407be480d791972afb5975cf62c9360a6 (patch) | |
tree | f435a8308119effd964b339f76abb83a57c29483 /other-licenses/atk-1.0 | |
parent | Initial commit. (diff) | |
download | firefox-26a029d407be480d791972afb5975cf62c9360a6.tar.xz firefox-26a029d407be480d791972afb5975cf62c9360a6.zip |
Adding upstream version 124.0.1.upstream/124.0.1
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'other-licenses/atk-1.0')
30 files changed, 4145 insertions, 0 deletions
diff --git a/other-licenses/atk-1.0/atk/atk-enum-types.h b/other-licenses/atk-1.0/atk/atk-enum-types.h new file mode 100644 index 0000000000..f95e70a67b --- /dev/null +++ b/other-licenses/atk-1.0/atk/atk-enum-types.h @@ -0,0 +1,41 @@ + +/* Generated data (by glib-mkenums) */ + +#ifndef __ATK_ENUM_TYPES_H__ +#define __ATK_ENUM_TYPES_H__ + +#include <glib-object.h> + +G_BEGIN_DECLS +/* enumerations from "atkhyperlink.h" */ +GType atk_hyperlink_state_flags_get_type (void); +#define ATK_TYPE_HYPERLINK_STATE_FLAGS (atk_hyperlink_state_flags_get_type()) +/* enumerations from "atkobject.h" */ +GType atk_role_get_type (void); +#define ATK_TYPE_ROLE (atk_role_get_type()) +GType atk_layer_get_type (void); +#define ATK_TYPE_LAYER (atk_layer_get_type()) +/* enumerations from "atkrelationtype.h" */ +GType atk_relation_type_get_type (void); +#define ATK_TYPE_RELATION_TYPE (atk_relation_type_get_type()) +/* enumerations from "atkstate.h" */ +GType atk_state_type_get_type (void); +#define ATK_TYPE_STATE_TYPE (atk_state_type_get_type()) +/* enumerations from "atktext.h" */ +GType atk_text_attribute_get_type (void); +#define ATK_TYPE_TEXT_ATTRIBUTE (atk_text_attribute_get_type()) +GType atk_text_boundary_get_type (void); +#define ATK_TYPE_TEXT_BOUNDARY (atk_text_boundary_get_type()) +GType atk_text_clip_type_get_type (void); +#define ATK_TYPE_TEXT_CLIP_TYPE (atk_text_clip_type_get_type()) +/* enumerations from "atkutil.h" */ +GType atk_key_event_type_get_type (void); +#define ATK_TYPE_KEY_EVENT_TYPE (atk_key_event_type_get_type()) +GType atk_coord_type_get_type (void); +#define ATK_TYPE_COORD_TYPE (atk_coord_type_get_type()) +G_END_DECLS + +#endif /* __ATK_ENUM_TYPES_H__ */ + +/* Generated data ends here */ + diff --git a/other-licenses/atk-1.0/atk/atk.h b/other-licenses/atk-1.0/atk/atk.h new file mode 100644 index 0000000000..39cec7f055 --- /dev/null +++ b/other-licenses/atk-1.0/atk/atk.h @@ -0,0 +1,62 @@ +/* ATK - Accessibility Toolkit + * Copyright 2001 Sun Microsystems Inc. + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either + * version 2 of the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with this library; if not, write to the + * Free Software Foundation, Inc., 59 Temple Place - Suite 330, + * Boston, MA 02111-1307, USA. + */ + +#ifndef __ATK_H__ +#define __ATK_H__ + +#define __ATK_H_INSIDE__ + +// XXX this is a Mozilla hack to avoid using atkversion.h which needs to be run +// through m4, and we don't want to deal with that. Fortunately we don't need +// any of the fancyness in that header to deal with compile time version +// detection. +#define ATK_AVAILABLE_IN_2_12 extern + +#include <atk/atkobject.h> +#include <atk/atkaction.h> +#include <atk/atkcomponent.h> +#include <atk/atkdocument.h> +#include <atk/atkeditabletext.h> +#include <atk/atkgobjectaccessible.h> +#include <atk/atkhyperlink.h> +#include <atk/atkhyperlinkimpl.h> +#include <atk/atkhypertext.h> +#include <atk/atkimage.h> +#include <atk/atknoopobject.h> +#include <atk/atknoopobjectfactory.h> +#include <atk/atkobjectfactory.h> +#include <atk/atkplug.h> +#include <atk/atkregistry.h> +#include <atk/atkrelation.h> +#include <atk/atkrelationset.h> +#include <atk/atkrelationtype.h> +#include <atk/atkselection.h> +#include <atk/atksocket.h> +#include <atk/atkstate.h> +#include <atk/atkstateset.h> +#include <atk/atkstreamablecontent.h> +#include <atk/atktable.h> +#include <atk/atktablecell.h> +#include <atk/atktext.h> +#include <atk/atkutil.h> +#include <atk/atkvalue.h> + +#undef __ATK_H_INSIDE__ + +#endif /* __ATK_H__ */ diff --git a/other-licenses/atk-1.0/atk/atkaction.h b/other-licenses/atk-1.0/atk/atkaction.h new file mode 100644 index 0000000000..8dfee9fe1e --- /dev/null +++ b/other-licenses/atk-1.0/atk/atkaction.h @@ -0,0 +1,112 @@ +/* ATK - Accessibility Toolkit + * Copyright 2001 Sun Microsystems Inc. + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either + * version 2 of the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with this library; if not, write to the + * Free Software Foundation, Inc., 59 Temple Place - Suite 330, + * Boston, MA 02111-1307, USA. + */ + +#ifndef __ATK_ACTION_H__ +#define __ATK_ACTION_H__ + +#include <atk/atkobject.h> + +#ifdef __cplusplus +extern "C" { +#endif /* __cplusplus */ + +/* + * The interface AtkAction should be supported by any object that can + * perform one or more actions. The interface provides the standard + * mechanism for an assistive technology to determine what those actions + * are as well as tell the object to perform them. Any object that can + * be manipulated should support this interface. + */ + + +#define ATK_TYPE_ACTION (atk_action_get_type ()) +#define ATK_IS_ACTION(obj) G_TYPE_CHECK_INSTANCE_TYPE ((obj), ATK_TYPE_ACTION) +#define ATK_ACTION(obj) G_TYPE_CHECK_INSTANCE_CAST ((obj), ATK_TYPE_ACTION, AtkAction) +#define ATK_ACTION_GET_IFACE(obj) (G_TYPE_INSTANCE_GET_INTERFACE ((obj), ATK_TYPE_ACTION, AtkActionIface)) + +#ifndef _TYPEDEF_ATK_ACTION_ +#define _TYPEDEF_ATK_ACTION_ +typedef struct _AtkAction AtkAction; +#endif +typedef struct _AtkActionIface AtkActionIface; + +struct _AtkActionIface +{ + GTypeInterface parent; + + gboolean (*do_action) (AtkAction *action, + gint i); + gint (*get_n_actions) (AtkAction *action); + G_CONST_RETURN gchar* (*get_description) (AtkAction *action, + gint i); + G_CONST_RETURN gchar* (*get_name) (AtkAction *action, + gint i); + G_CONST_RETURN gchar* (*get_keybinding) (AtkAction *action, + gint i); + gboolean (*set_description) (AtkAction *action, + gint i, + const gchar *desc); + G_CONST_RETURN gchar* (*get_localized_name)(AtkAction *action, + gint i); + AtkFunction pad2; +}; + +GType atk_action_get_type (void); + +/* + * These are the function which would be called by an application with + * the argument being a AtkObject object cast to (AtkAction). + * + * The function will just check that * the corresponding + * function pointer is not NULL and will call it. + * + * The "real" implementation of the function for accessible will be + * provided in a support library + */ + +gboolean atk_action_do_action (AtkAction *action, + gint i); +gint atk_action_get_n_actions (AtkAction *action); +G_CONST_RETURN gchar* atk_action_get_description (AtkAction *action, + gint i); +G_CONST_RETURN gchar* atk_action_get_name (AtkAction *action, + gint i); +G_CONST_RETURN gchar* atk_action_get_keybinding (AtkAction *action, + gint i); +gboolean atk_action_set_description (AtkAction *action, + gint i, + const gchar *desc); + +/* NEW in ATK 1.1: */ + +G_CONST_RETURN gchar* atk_action_get_localized_name (AtkAction *action, + gint i); + +/* + * Additional GObject properties exported by AtkAction: + * "accessible_action" + * (an accessible action, or the list of actions, has changed) + */ + +#ifdef __cplusplus +} +#endif /* __cplusplus */ + + +#endif /* __ATK_ACTION_H__ */ diff --git a/other-licenses/atk-1.0/atk/atkcomponent.h b/other-licenses/atk-1.0/atk/atkcomponent.h new file mode 100644 index 0000000000..b0e14ca143 --- /dev/null +++ b/other-licenses/atk-1.0/atk/atkcomponent.h @@ -0,0 +1,221 @@ +/* ATK - Accessibility Toolkit + * Copyright 2001 Sun Microsystems Inc. + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either + * version 2 of the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with this library; if not, write to the + * Free Software Foundation, Inc., 59 Temple Place - Suite 330, + * Boston, MA 02111-1307, USA. + */ + +#ifndef __ATK_COMPONENT_H__ +#define __ATK_COMPONENT_H__ + +#include <atk/atkobject.h> +#include <atk/atkutil.h> + +#ifdef __cplusplus +extern "C" { +#endif /* __cplusplus */ + +/** + *AtkScrollType: + *@ATK_SCROLL_TOP_LEFT: Scroll the object vertically and horizontally to the top + *left corner of the window. + *@ATK_SCROLL_BOTTOM_RIGHT: Scroll the object vertically and horizontally to the + *bottom right corner of the window. + *@ATK_SCROLL_TOP_EDGE: Scroll the object vertically to the top edge of the + window. + *@ATK_SCROLL_BOTTOM_EDGE: Scroll the object vertically to the bottom edge of + *the window. + *@ATK_SCROLL_LEFT_EDGE: Scroll the object vertically and horizontally to the + *left edge of the window. + *@ATK_SCROLL_RIGHT_EDGE: Scroll the object vertically and horizontally to the + *right edge of the window. + *@ATK_SCROLL_ANYWHERE: Scroll the object vertically and horizontally so that + *as much as possible of the object becomes visible. The exact placement is + *determined by the application. + * + * Specifies where an object should be placed on the screen when using scroll_to. + **/ +typedef enum { + ATK_SCROLL_TOP_LEFT, + ATK_SCROLL_BOTTOM_RIGHT, + ATK_SCROLL_TOP_EDGE, + ATK_SCROLL_BOTTOM_EDGE, + ATK_SCROLL_LEFT_EDGE, + ATK_SCROLL_RIGHT_EDGE, + ATK_SCROLL_ANYWHERE +} AtkScrollType; + +/* + * The AtkComponent interface should be supported by any object that is + * rendered on the screen. The interface provides the standard mechanism + * for an assistive technology to determine and set the graphical + * representation of an object. + */ + +#define ATK_TYPE_COMPONENT (atk_component_get_type ()) +#define ATK_IS_COMPONENT(obj) G_TYPE_CHECK_INSTANCE_TYPE ((obj), ATK_TYPE_COMPONENT) +#define ATK_COMPONENT(obj) G_TYPE_CHECK_INSTANCE_CAST ((obj), ATK_TYPE_COMPONENT, AtkComponent) +#define ATK_COMPONENT_GET_IFACE(obj) (G_TYPE_INSTANCE_GET_INTERFACE ((obj), ATK_TYPE_COMPONENT, AtkComponentIface)) + +#ifndef _TYPEDEF_ATK_COMPONENT_ +#define _TYPEDEF_ATK_COMPONENT_ +typedef struct _AtkComponent AtkComponent; +#endif +typedef struct _AtkComponentIface AtkComponentIface; + +typedef void (*AtkFocusHandler) (AtkObject*, gboolean); + +typedef struct _AtkRectangle AtkRectangle; + +struct _AtkRectangle +{ + gint x; + gint y; + gint width; + gint height; +}; + +GType atk_rectangle_get_type (void); + +#define ATK_TYPE_RECTANGLE (atk_rectangle_get_type ()) +struct _AtkComponentIface +{ + GTypeInterface parent; + + guint (* add_focus_handler) (AtkComponent *component, + AtkFocusHandler handler); + + gboolean (* contains) (AtkComponent *component, + gint x, + gint y, + AtkCoordType coord_type); + + AtkObject* (* ref_accessible_at_point) (AtkComponent *component, + gint x, + gint y, + AtkCoordType coord_type); + void (* get_extents) (AtkComponent *component, + gint *x, + gint *y, + gint *width, + gint *height, + AtkCoordType coord_type); + void (* get_position) (AtkComponent *component, + gint *x, + gint *y, + AtkCoordType coord_type); + void (* get_size) (AtkComponent *component, + gint *width, + gint *height); + gboolean (* grab_focus) (AtkComponent *component); + void (* remove_focus_handler) (AtkComponent *component, + guint handler_id); + gboolean (* set_extents) (AtkComponent *component, + gint x, + gint y, + gint width, + gint height, + AtkCoordType coord_type); + gboolean (* set_position) (AtkComponent *component, + gint x, + gint y, + AtkCoordType coord_type); + gboolean (* set_size) (AtkComponent *component, + gint width, + gint height); + + AtkLayer (* get_layer) (AtkComponent *component); + gint (* get_mdi_zorder) (AtkComponent *component); + + /* + * signal handlers + */ + void (* bounds_changed) (AtkComponent *component, + AtkRectangle *bounds); + gdouble (* get_alpha) (AtkComponent *component); + + /* + * Scrolls this object so it becomes visible on the screen. + * Since ATK 2.30 + */ + gboolean (*scroll_to) (AtkComponent *component, + AtkScrollType type); + + gboolean (*scroll_to_point) (AtkComponent *component, + AtkCoordType coords, + gint x, + gint y); +}; + +GType atk_component_get_type (void); + +/* convenience functions */ + +guint atk_component_add_focus_handler (AtkComponent *component, + AtkFocusHandler handler); +gboolean atk_component_contains (AtkComponent *component, + gint x, + gint y, + AtkCoordType coord_type); +AtkObject* atk_component_ref_accessible_at_point(AtkComponent *component, + gint x, + gint y, + AtkCoordType coord_type); +void atk_component_get_extents (AtkComponent *component, + gint *x, + gint *y, + gint *width, + gint *height, + AtkCoordType coord_type); +void atk_component_get_position (AtkComponent *component, + gint *x, + gint *y, + AtkCoordType coord_type); +void atk_component_get_size (AtkComponent *component, + gint *width, + gint *height); +AtkLayer atk_component_get_layer (AtkComponent *component); +gint atk_component_get_mdi_zorder (AtkComponent *component); +gboolean atk_component_grab_focus (AtkComponent *component); +void atk_component_remove_focus_handler (AtkComponent *component, + guint handler_id); +gboolean atk_component_set_extents (AtkComponent *component, + gint x, + gint y, + gint width, + gint height, + AtkCoordType coord_type); +gboolean atk_component_set_position (AtkComponent *component, + gint x, + gint y, + AtkCoordType coord_type); +gboolean atk_component_set_size (AtkComponent *component, + gint width, + gint height); +gdouble atk_component_get_alpha (AtkComponent *component); +gboolean atk_component_scroll_to (AtkComponent *component, + AtkScrollType type); + +gboolean atk_component_scroll_to_point (AtkComponent *component, + AtkCoordType coords, + gint x, + gint y); + +#ifdef __cplusplus +} +#endif /* __cplusplus */ + + +#endif /* __ATK_COMPONENT_H__ */ diff --git a/other-licenses/atk-1.0/atk/atkdocument.h b/other-licenses/atk-1.0/atk/atkdocument.h new file mode 100644 index 0000000000..4b83aa93d2 --- /dev/null +++ b/other-licenses/atk-1.0/atk/atkdocument.h @@ -0,0 +1,80 @@ +/* ATK - Accessibility Toolkit + * Copyright 2001 Sun Microsystems Inc. + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either + * version 2 of the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with this library; if not, write to the + * Free Software Foundation, Inc., 59 Temple Place - Suite 330, + * Boston, MA 02111-1307, USA. + */ + +#ifndef __ATK_DOCUMENT_H__ +#define __ATK_DOCUMENT_H__ + +#include <atk/atkobject.h> +#include <atk/atkutil.h> + +#ifdef __cplusplus +extern "C" { +#endif /* __cplusplus */ + +/* + * The AtkDocument interface should be supported by any object that is a container + * for 'document content' as opposed to a collection of user interface elements. + * + */ + +#define ATK_TYPE_DOCUMENT (atk_document_get_type ()) +#define ATK_IS_DOCUMENT(obj) G_TYPE_CHECK_INSTANCE_TYPE ((obj), ATK_TYPE_DOCUMENT) +#define ATK_DOCUMENT(obj) G_TYPE_CHECK_INSTANCE_CAST ((obj), ATK_TYPE_DOCUMENT, AtkDocument) +#define ATK_DOCUMENT_GET_IFACE(obj) (G_TYPE_INSTANCE_GET_INTERFACE ((obj), ATK_TYPE_DOCUMENT, AtkDocumentIface)) + +#ifndef _TYPEDEF_ATK_DOCUMENT_ +#define _TYPEDEF_ATK_DOCUMENT_ +typedef struct _AtkDocument AtkDocument; +#endif +typedef struct _AtkDocumentIface AtkDocumentIface; + +struct _AtkDocumentIface +{ + GTypeInterface parent; + G_CONST_RETURN gchar* ( *get_document_type) (AtkDocument *document); + gpointer ( *get_document) (AtkDocument *document); + + G_CONST_RETURN gchar* ( *get_document_locale) (AtkDocument *document); + AtkAttributeSet * ( *get_document_attributes) (AtkDocument *document); + G_CONST_RETURN gchar* ( *get_document_attribute_value) (AtkDocument *document, + const gchar *attribute_name); + gboolean ( *set_document_attribute) (AtkDocument *document, + const gchar *attribute_name, + const gchar *attribute_value); + AtkFunction pad1; + AtkFunction pad2; + AtkFunction pad3; + AtkFunction pad4; +}; + +GType atk_document_get_type (void); + +G_CONST_RETURN gchar* atk_document_get_document_type (AtkDocument *document); +gpointer atk_document_get_document (AtkDocument *document); +G_CONST_RETURN gchar* atk_document_get_locale (AtkDocument *document); +AtkAttributeSet* atk_document_get_attributes (AtkDocument *document); +G_CONST_RETURN gchar* atk_document_get_attribute_value (AtkDocument *document, + const gchar *attribute_name); +gboolean atk_document_set_attribute_value (AtkDocument *document, + const gchar *attribute_name, + const gchar *attribute_value); +#ifdef __cplusplus +} +#endif /* __cplusplus */ +#endif /* __ATK_DOCUMENT_H__ */ diff --git a/other-licenses/atk-1.0/atk/atkeditabletext.h b/other-licenses/atk-1.0/atk/atkeditabletext.h new file mode 100644 index 0000000000..02937ff875 --- /dev/null +++ b/other-licenses/atk-1.0/atk/atkeditabletext.h @@ -0,0 +1,105 @@ +/* ATK - Accessibility Toolkit + * Copyright 2001 Sun Microsystems Inc. + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either + * version 2 of the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with this library; if not, write to the + * Free Software Foundation, Inc., 59 Temple Place - Suite 330, + * Boston, MA 02111-1307, USA. + */ + +#ifndef __ATK_EDITABLE_TEXT_H__ +#define __ATK_EDITABLE_TEXT_H__ + +#include <atk/atkobject.h> +#include <atk/atktext.h> + +#ifdef __cplusplus +extern "C" { +#endif /* __cplusplus */ + +/* + * AtkEditableText is used to support access in an "accessibility" context + * to editing features of editable text widgets. + */ + +#define ATK_TYPE_EDITABLE_TEXT (atk_editable_text_get_type ()) +#define ATK_IS_EDITABLE_TEXT(obj) G_TYPE_CHECK_INSTANCE_TYPE ((obj), ATK_TYPE_EDITABLE_TEXT) +#define ATK_EDITABLE_TEXT(obj) G_TYPE_CHECK_INSTANCE_CAST ((obj), ATK_TYPE_EDITABLE_TEXT, AtkEditableText) +#define ATK_EDITABLE_TEXT_GET_IFACE(obj) (G_TYPE_INSTANCE_GET_INTERFACE ((obj), ATK_TYPE_EDITABLE_TEXT, AtkEditableTextIface)) + +#ifndef _TYPEDEF_ATK_EDITABLE_TEXT_ +#define _TYPEDEF_ATK_EDITABLE_TEXT_ +typedef struct _AtkEditableText AtkEditableText; +#endif +typedef struct _AtkEditableTextIface AtkEditableTextIface; + +struct _AtkEditableTextIface +{ + GTypeInterface parent_interface; + + gboolean (* set_run_attributes) (AtkEditableText *text, + AtkAttributeSet *attrib_set, + gint start_offset, + gint end_offset); + void (* set_text_contents) (AtkEditableText *text, + const gchar *string); + void (* insert_text) (AtkEditableText *text, + const gchar *string, + gint length, + gint *position); + void (* copy_text) (AtkEditableText *text, + gint start_pos, + gint end_pos); + void (* cut_text) (AtkEditableText *text, + gint start_pos, + gint end_pos); + void (* delete_text) (AtkEditableText *text, + gint start_pos, + gint end_pos); + void (* paste_text) (AtkEditableText *text, + gint position); + + AtkFunction pad1; + AtkFunction pad2; +}; +GType atk_editable_text_get_type (void); + + +gboolean atk_editable_text_set_run_attributes (AtkEditableText *text, + AtkAttributeSet *attrib_set, + gint start_offset, + gint end_offset); +void atk_editable_text_set_text_contents (AtkEditableText *text, + const gchar *string); +void atk_editable_text_insert_text (AtkEditableText *text, + const gchar *string, + gint length, + gint *position); +void atk_editable_text_copy_text (AtkEditableText *text, + gint start_pos, + gint end_pos); +void atk_editable_text_cut_text (AtkEditableText *text, + gint start_pos, + gint end_pos); +void atk_editable_text_delete_text (AtkEditableText *text, + gint start_pos, + gint end_pos); +void atk_editable_text_paste_text (AtkEditableText *text, + gint position); + +#ifdef __cplusplus +} +#endif /* __cplusplus */ + + +#endif /* __ATK_EDITABLE_TEXT_H__ */ diff --git a/other-licenses/atk-1.0/atk/atkgobjectaccessible.h b/other-licenses/atk-1.0/atk/atkgobjectaccessible.h new file mode 100644 index 0000000000..adb46cd9a9 --- /dev/null +++ b/other-licenses/atk-1.0/atk/atkgobjectaccessible.h @@ -0,0 +1,67 @@ +/* ATK - Accessibility Toolkit + * Copyright 2001 Sun Microsystems Inc. + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either + * version 2 of the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with this library; if not, write to the + * Free Software Foundation, Inc., 59 Temple Place - Suite 330, + * Boston, MA 02111-1307, USA. + */ + +#ifndef __ATK_GOBJECT_ACCESSIBLE_H__ +#define __ATK_GOBJECT_ACCESSIBLE_H__ + +#include <atk/atk.h> + + +#ifdef __cplusplus +extern "C" { +#endif /* __cplusplus */ + +/* + * The AtkGObjectAccessible class is provided as a basis for implementing + * accessibility support for objects which are not GTK+ widgets + */ +#define ATK_TYPE_GOBJECT_ACCESSIBLE (atk_gobject_accessible_get_type ()) +#define ATK_GOBJECT_ACCESSIBLE(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), ATK_TYPE_GOBJECT_ACCESSIBLE, AtkGObjectAccessible)) +#define ATK_GOBJECT_ACCESSIBLE_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), ATK_TYPE_GOBJECT_ACCESSIBLE, AtkGObjectAccessibleClass)) +#define ATK_IS_GOBJECT_ACCESSIBLE(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), ATK_TYPE_GOBJECT_ACCESSIBLE)) +#define ATK_IS_GOBJECT_ACCESSIBLE_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), ATK_TYPE_GOBJECT_ACCESSIBLE)) +#define ATK_GOBJECT_ACCESSIBLE_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), ATK_TYPE_GOBJECT_ACCESSIBLE, AtkGObjectAccessibleClass)) + +typedef struct _AtkGObjectAccessible AtkGObjectAccessible; +typedef struct _AtkGObjectAccessibleClass AtkGObjectAccessibleClass; + +struct _AtkGObjectAccessible +{ + AtkObject parent; +}; + +GType atk_gobject_accessible_get_type (void); + +struct _AtkGObjectAccessibleClass +{ + AtkObjectClass parent_class; + + AtkFunction pad1; + AtkFunction pad2; +}; + +AtkObject *atk_gobject_accessible_for_object (GObject *obj); +GObject *atk_gobject_accessible_get_object (AtkGObjectAccessible *obj); + +#ifdef __cplusplus +} +#endif /* __cplusplus */ + + +#endif /* __ATK_GOBJECT_ACCESSIBLE_H__ */ diff --git a/other-licenses/atk-1.0/atk/atkhyperlink.h b/other-licenses/atk-1.0/atk/atkhyperlink.h new file mode 100644 index 0000000000..a5d3716f00 --- /dev/null +++ b/other-licenses/atk-1.0/atk/atkhyperlink.h @@ -0,0 +1,106 @@ +/* ATK - Accessibility Toolkit + * Copyright 2001 Sun Microsystems Inc. + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either + * version 2 of the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with this library; if not, write to the + * Free Software Foundation, Inc., 59 Temple Place - Suite 330, + * Boston, MA 02111-1307, USA. + */ + +#ifndef __ATK_HYPERLINK_H__ +#define __ATK_HYPERLINK_H__ + +#ifdef __cplusplus +extern "C" { +#endif /* __cplusplus */ + +#include <atk/atkaction.h> + +/* + * AtkHyperlink encapsulates a link or set of links in a hypertext document. + * + * It implements the AtkAction interface. + */ + +/** + *AtkHyperlinkStateFlags + *@ATK_HYPERLINK_IS_INLINE: Link is inline + * + *Describes the type of link + **/ +typedef enum +{ + ATK_HYPERLINK_IS_INLINE = 1 << 0 +} AtkHyperlinkStateFlags; + +#define ATK_TYPE_HYPERLINK (atk_hyperlink_get_type ()) +#define ATK_HYPERLINK(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), ATK_TYPE_HYPERLINK, AtkHyperlink)) +#define ATK_HYPERLINK_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), ATK_TYPE_HYPERLINK, AtkHyperlinkClass)) +#define ATK_IS_HYPERLINK(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), ATK_TYPE_HYPERLINK)) +#define ATK_IS_HYPERLINK_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), ATK_TYPE_HYPERLINK)) +#define ATK_HYPERLINK_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), ATK_TYPE_HYPERLINK, AtkHyperlinkClass)) + +typedef struct _AtkHyperlink AtkHyperlink; +typedef struct _AtkHyperlinkClass AtkHyperlinkClass; + +struct _AtkHyperlink +{ + GObject parent; +}; + +struct _AtkHyperlinkClass +{ + GObjectClass parent; + + gchar* (* get_uri) (AtkHyperlink *link_, + gint i); + AtkObject* (* get_object) (AtkHyperlink *link_, + gint i); + gint (* get_end_index) (AtkHyperlink *link_); + gint (* get_start_index) (AtkHyperlink *link_); + gboolean (* is_valid) (AtkHyperlink *link_); + gint (* get_n_anchors) (AtkHyperlink *link_); + guint (* link_state) (AtkHyperlink *link_); + gboolean (* is_selected_link) (AtkHyperlink *link_); + + /* Signals */ + void ( *link_activated) (AtkHyperlink *link_); + AtkFunction pad1; +}; + +GType atk_hyperlink_get_type (void); + +gchar* atk_hyperlink_get_uri (AtkHyperlink *link_, + gint i); + +AtkObject* atk_hyperlink_get_object (AtkHyperlink *link_, + gint i); + +gint atk_hyperlink_get_end_index (AtkHyperlink *link_); + +gint atk_hyperlink_get_start_index (AtkHyperlink *link_); + +gboolean atk_hyperlink_is_valid (AtkHyperlink *link_); + +gboolean atk_hyperlink_is_inline (AtkHyperlink *link_); + +gint atk_hyperlink_get_n_anchors (AtkHyperlink *link_); +gboolean atk_hyperlink_is_selected_link (AtkHyperlink *link_); + + +#ifdef __cplusplus +} +#endif /* __cplusplus */ + + +#endif /* __ATK_HYPERLINK_H__ */ diff --git a/other-licenses/atk-1.0/atk/atkhyperlinkimpl.h b/other-licenses/atk-1.0/atk/atkhyperlinkimpl.h new file mode 100644 index 0000000000..b08a1d53cf --- /dev/null +++ b/other-licenses/atk-1.0/atk/atkhyperlinkimpl.h @@ -0,0 +1,76 @@ +/* ATK - Accessibility Toolkit + * Copyright 2001 Sun Microsystems Inc. + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either + * version 2 of the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with this library; if not, write to the + * Free Software Foundation, Inc., 59 Temple Place - Suite 330, + * Boston, MA 02111-1307, USA. + */ + +#ifndef __ATK_HYPERLINK_IMPL_H__ +#define __ATK_HYPERLINK_IMPL_H__ + +#include <atk/atkobject.h> +#include <atk/atkhyperlink.h> + +#ifdef __cplusplus +extern "C" { +#endif /* __cplusplus */ + +/* + * The AtkHyperlinkImpl interface should be supported by objects + * exposed within the hierarchy as children of an AtkHypertext container + * which correspond to "links" or embedded content within the text. + * HTML anchors are not, for instance, normally exposed this way, + * but embedded images and components which appear inline in the + * content of a text object are. The AtkHyperlinkIface interface + * allows a means of determining which children are hyperlinks in this + * sense of the word, and for obtaining their corresponding AtkHyperlink + * object, from which the embedding range, URI, etc. can be obtained. + * + * To some extent this interface exists because, for historical + * reasons, AtkHyperlink was defined as an object type, not an interface. + * Thus, in order to interact with AtkObjects via AtkHyperlink semantics, + * a new interface was required. + */ + +#define ATK_TYPE_HYPERLINK_IMPL (atk_hyperlink_impl_get_type ()) +#define ATK_IS_HYPERLINK_IMPL(obj) G_TYPE_CHECK_INSTANCE_TYPE ((obj), ATK_TYPE_HYPERLINK_IMPL) +#define ATK_HYPERLINK_IMPL(obj) G_TYPE_CHECK_INSTANCE_CAST ((obj), ATK_TYPE_HYPERLINK_IMPL, AtkHyperlinkImpl) +#define ATK_HYPERLINK_IMPL_GET_IFACE(obj) G_TYPE_INSTANCE_GET_INTERFACE ((obj), ATK_TYPE_HYPERLINK_IMPL, AtkHyperlinkImplIface) + +#ifndef _TYPEDEF_ATK_HYPERLINK_IMPL_ +#define _TYPEDEF_ATK_HYPERLINK_IMPL__ +typedef struct _AtkHyperlinkImpl AtkHyperlinkImpl; +#endif +typedef struct _AtkHyperlinkImplIface AtkHyperlinkImplIface; + +struct _AtkHyperlinkImplIface +{ + GTypeInterface parent; + + AtkHyperlink* (* get_hyperlink) (AtkHyperlinkImpl *impl); + + AtkFunction pad1; +}; + +GType atk_hyperlink_impl_get_type (void); + +AtkHyperlink *atk_hyperlink_impl_get_hyperlink (AtkHyperlinkImpl *obj); + +#ifdef __cplusplus +} +#endif /* __cplusplus */ + + +#endif /* __ATK_HYPERLINK_IMPL_H__ */ diff --git a/other-licenses/atk-1.0/atk/atkhypertext.h b/other-licenses/atk-1.0/atk/atkhypertext.h new file mode 100644 index 0000000000..18464d9ffc --- /dev/null +++ b/other-licenses/atk-1.0/atk/atkhypertext.h @@ -0,0 +1,80 @@ +/* ATK - Accessibility Toolkit + * Copyright 2001 Sun Microsystems Inc. + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either + * version 2 of the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with this library; if not, write to the + * Free Software Foundation, Inc., 59 Temple Place - Suite 330, + * Boston, MA 02111-1307, USA. + */ + +#ifndef __ATK_HYPERTEXT_H__ +#define __ATK_HYPERTEXT_H__ + +#include <atk/atkobject.h> +#include <atk/atkhyperlink.h> + +#ifdef __cplusplus +extern "C" { +#endif /* __cplusplus */ + +/* + * The AtkHypertext interface provides standard mechanisms for manipulating + * hyperlinks. + */ + +#define ATK_TYPE_HYPERTEXT (atk_hypertext_get_type ()) +#define ATK_IS_HYPERTEXT(obj) G_TYPE_CHECK_INSTANCE_TYPE ((obj), ATK_TYPE_HYPERTEXT) +#define ATK_HYPERTEXT(obj) G_TYPE_CHECK_INSTANCE_CAST ((obj), ATK_TYPE_HYPERTEXT, AtkHypertext) +#define ATK_HYPERTEXT_GET_IFACE(obj) (G_TYPE_INSTANCE_GET_INTERFACE ((obj), ATK_TYPE_HYPERTEXT, AtkHypertextIface)) + +#ifndef _TYPEDEF_ATK_HYPERTEXT_ +#define _TYPEDEF_ATK_HYPERTEXT_ +typedef struct _AtkHypertext AtkHypertext; +#endif +typedef struct _AtkHypertextIface AtkHypertextIface; + +struct _AtkHypertextIface +{ + GTypeInterface parent; + + AtkHyperlink*(* get_link) (AtkHypertext *hypertext, + gint link_index); + gint (* get_n_links) (AtkHypertext *hypertext); + gint (* get_link_index) (AtkHypertext *hypertext, + gint char_index); + + /* + * signal handlers + */ + void (* link_selected) (AtkHypertext *hypertext, + gint link_index); + + AtkFunction pad1; + AtkFunction pad2; + AtkFunction pad3; +}; +GType atk_hypertext_get_type (void); + +AtkHyperlink* atk_hypertext_get_link (AtkHypertext *hypertext, + gint link_index); +gint atk_hypertext_get_n_links (AtkHypertext *hypertext); +gint atk_hypertext_get_link_index (AtkHypertext *hypertext, + gint char_index); + + +#ifdef __cplusplus +} +#endif /* __cplusplus */ + + +#endif /* __ATK_HYPERTEXT_H__ */ diff --git a/other-licenses/atk-1.0/atk/atkimage.h b/other-licenses/atk-1.0/atk/atkimage.h new file mode 100644 index 0000000000..7e60c81801 --- /dev/null +++ b/other-licenses/atk-1.0/atk/atkimage.h @@ -0,0 +1,86 @@ +/* ATK - Accessibility Toolkit + * Copyright 2001 Sun Microsystems Inc. + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either + * version 2 of the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with this library; if not, write to the + * Free Software Foundation, Inc., 59 Temple Place - Suite 330, + * Boston, MA 02111-1307, USA. + */ + +#ifndef __ATK_IMAGE_H__ +#define __ATK_IMAGE_H__ + +#include <atk/atkobject.h> +#include <atk/atkutil.h> + +#ifdef __cplusplus +extern "C" { +#endif /* __cplusplus */ + +/* + * The AtkImage interface should be supported by any object that has an + * associated image. This interface provides the standard mechanism for + * an assistive technology to get descriptive information about images. + */ + +#define ATK_TYPE_IMAGE (atk_image_get_type ()) +#define ATK_IS_IMAGE(obj) G_TYPE_CHECK_INSTANCE_TYPE ((obj), ATK_TYPE_IMAGE) +#define ATK_IMAGE(obj) G_TYPE_CHECK_INSTANCE_CAST ((obj), ATK_TYPE_IMAGE, AtkImage) +#define ATK_IMAGE_GET_IFACE(obj) (G_TYPE_INSTANCE_GET_INTERFACE ((obj), ATK_TYPE_IMAGE, AtkImageIface)) + +#ifndef _TYPEDEF_ATK_IMAGE_ +#define _TYPEDEF_ATK_IMAGE_ +typedef struct _AtkImage AtkImage; +#endif +typedef struct _AtkImageIface AtkImageIface; + +struct _AtkImageIface +{ + GTypeInterface parent; + void ( *get_image_position) (AtkImage *image, + gint *x, + gint *y, + AtkCoordType coord_type); + G_CONST_RETURN gchar* ( *get_image_description) (AtkImage *image); + void ( *get_image_size) (AtkImage *image, + gint *width, + gint *height); + gboolean ( *set_image_description) (AtkImage *image, + const gchar *description); + G_CONST_RETURN gchar* ( *get_image_locale) (AtkImage *image); + + AtkFunction pad1; + +}; + +GType atk_image_get_type (void); + +G_CONST_RETURN gchar* atk_image_get_image_description (AtkImage *image); + +void atk_image_get_image_size (AtkImage *image, + gint *width, + gint *height); + +gboolean atk_image_set_image_description (AtkImage *image, + const gchar *description); +void atk_image_get_image_position (AtkImage *image, + gint *x, + gint *y, + AtkCoordType coord_type); + +G_CONST_RETURN gchar* atk_image_get_image_locale (AtkImage *image); + +#ifdef __cplusplus +} +#endif /* __cplusplus */ +#endif /* __ATK_IMAGE_H__ */ diff --git a/other-licenses/atk-1.0/atk/atknoopobject.h b/other-licenses/atk-1.0/atk/atknoopobject.h new file mode 100644 index 0000000000..3c4e432a85 --- /dev/null +++ b/other-licenses/atk-1.0/atk/atknoopobject.h @@ -0,0 +1,51 @@ +/* ATK - Accessibility Toolkit + * Copyright 2001 Sun Microsystems Inc. + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either + * version 2 of the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with this library; if not, write to the + * Free Software Foundation, Inc., 59 Temple Place - Suite 330, + * Boston, MA 02111-1307, USA. + */ + +#ifndef __ATK_NO_OP_OBJECT_H__ +#define __ATK_NO_OP_OBJECT_H__ + +G_BEGIN_DECLS + +#define ATK_TYPE_NO_OP_OBJECT (atk_no_op_object_get_type ()) +#define ATK_NO_OP_OBJECT(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), ATK_TYPE_NO_OP_OBJECT, AtkNoOpObject)) +#define ATK_NO_OP_OBJECT_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), ATK_TYPE_NO_OP_OBJECT, AtkNoOpObjectClass)) +#define ATK_IS_NO_OP_OBJECT(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), ATK_TYPE_NO_OP_OBJECT)) +#define ATK_IS_NO_OP_OBJECT_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), ATK_TYPE_NO_OP_OBJECT)) +#define ATK_NO_OP_OBJECT_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), ATK_TYPE_NO_OP_OBJECT, AtkNoOpObjectClass)) + +typedef struct _AtkNoOpObject AtkNoOpObject; +typedef struct _AtkNoOpObjectClass AtkNoOpObjectClass; + +struct _AtkNoOpObject +{ + AtkObject parent; +}; + +GType atk_no_op_object_get_type (void); + +struct _AtkNoOpObjectClass +{ + AtkObjectClass parent_class; +}; + +AtkObject *atk_no_op_object_new (GObject *obj); + +G_END_DECLS + +#endif /* __ATK_NO_OP_OBJECT_H__ */ diff --git a/other-licenses/atk-1.0/atk/atknoopobjectfactory.h b/other-licenses/atk-1.0/atk/atknoopobjectfactory.h new file mode 100644 index 0000000000..c324531330 --- /dev/null +++ b/other-licenses/atk-1.0/atk/atknoopobjectfactory.h @@ -0,0 +1,58 @@ +/* ATK - Accessibility Toolkit + * Copyright 2001 Sun Microsystems Inc. + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either + * version 2 of the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with this library; if not, write to the + * Free Software Foundation, Inc., 59 Temple Place - Suite 330, + * Boston, MA 02111-1307, USA. + */ + +#ifndef __ATK_NO_OP_OBJECT_FACTORY_H__ +#define __ATK_NO_OP_OBJECT_FACTORY_H__ + +#include <atk/atkobjectfactory.h> + +#ifdef __cplusplus +extern "C" { +#endif /* __cplusplus */ + +#define ATK_TYPE_NO_OP_OBJECT_FACTORY (atk_no_op_object_factory_get_type ()) +#define ATK_NO_OP_OBJECT_FACTORY(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), ATK_TYPE_NO_OP_OBJECT_FACTORY, AtkNoOpObjectFactory)) +#define ATK_NO_OP_OBJECT_FACTORY_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), ATK_TYPE_NO_OP_OBJECT_FACTORY, AtkNoOpObjectFactoryClass)) +#define ATK_IS_NO_OP_OBJECT_FACTORY(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), ATK_TYPE_NO_OP_OBJECT_FACTORY)) +#define ATK_IS_NO_OP_OBJECT_FACTORY_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), ATK_TYPE_NO_OP_OBJECT_FACTORY)) +#define ATK_NO_OP_OBJECT_FACTORY_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ( (obj), ATK_TYPE_NO_OP_OBJECT_FACTORY, AtkNoOpObjectFactoryClass)) + +typedef struct _AtkNoOpObjectFactory AtkNoOpObjectFactory; +typedef struct _AtkNoOpObjectFactoryClass AtkNoOpObjectFactoryClass; + +struct _AtkNoOpObjectFactory +{ + AtkObjectFactory parent; +}; + +struct _AtkNoOpObjectFactoryClass +{ + AtkObjectFactoryClass parent_class; +}; + +GType atk_no_op_object_factory_get_type(void); + +AtkObjectFactory *atk_no_op_object_factory_new(void); + +#ifdef __cplusplus +} +#endif /* __cplusplus */ + + +#endif /* __ATK_NO_OP_OBJECT_FACTORY_H__ */ diff --git a/other-licenses/atk-1.0/atk/atkobject.h b/other-licenses/atk-1.0/atk/atkobject.h new file mode 100644 index 0000000000..177c098175 --- /dev/null +++ b/other-licenses/atk-1.0/atk/atkobject.h @@ -0,0 +1,875 @@ +/* ATK - Accessibility Toolkit + * Copyright 2001 Sun Microsystems Inc. + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either + * version 2 of the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with this library; if not, write to the + * Free Software Foundation, Inc., 59 Temple Place - Suite 330, + * Boston, MA 02111-1307, USA. + */ + +#ifndef __ATK_OBJECT_H__ +#define __ATK_OBJECT_H__ + +#include <glib-object.h> +#include <atk/atkstate.h> +#include <atk/atkrelationtype.h> + +#ifdef __cplusplus +extern "C" { +#endif /* __cplusplus */ + +/* + * AtkObject represents the minimum information all accessible objects + * return. This information includes accessible name, accessible + * description, role and state of the object, as well information about + * its parent and children. It is also possible to obtain more specific + * accessibility information about a component if it supports one or more + * of the following interfaces: + */ + +/** + *AtkRole: + *@ATK_ROLE_INVALID: Invalid role + *@ATK_ROLE_ACCEL_LABEL: A label which represents an accelerator + *@ATK_ROLE_ALERT: An object which is an alert to the user. Assistive + *Technologies typically respond to ATK_ROLE_ALERT by reading the entire + *onscreen contents of containers advertising this role. Should be used for + *warning dialogs, etc. + *@ATK_ROLE_ANIMATION: An object which is an animated image + *@ATK_ROLE_ARROW: An arrow in one of the four cardinal directions + *@ATK_ROLE_CALENDAR: An object that displays a calendar and allows the user to + *select a date + *@ATK_ROLE_CANVAS: An object that can be drawn into and is used to trap events + *@ATK_ROLE_CHECK_BOX: A choice that can be checked or unchecked and provides a + *separate indicator for the current state + *@ATK_ROLE_CHECK_MENU_ITEM: A menu item with a check box + *@ATK_ROLE_COLOR_CHOOSER: A specialized dialog that lets the user choose a + *color + *@ATK_ROLE_COLUMN_HEADER: The header for a column of data + *@ATK_ROLE_COMBO_BOX: A collapsible list of choices the user can select from + *@ATK_ROLE_DATE_EDITOR: An object whose purpose is to allow a user to edit a + *date + *@ATK_ROLE_DESKTOP_ICON: An inconifed internal frame within a DESKTOP_PANE + *@ATK_ROLE_DESKTOP_FRAME: A pane that supports internal frames and iconified + *versions of those internal frames + *@ATK_ROLE_DIAL: An object whose purpose is to allow a user to set a value + *@ATK_ROLE_DIALOG: A top level window with title bar and a border + *@ATK_ROLE_DIRECTORY_PANE: A pane that allows the user to navigate through and + *select the contents of a directory + *@ATK_ROLE_DRAWING_AREA: An object used for drawing custom user interface + *elements + *@ATK_ROLE_FILE_CHOOSER: A specialized dialog that lets the user choose a file + *@ATK_ROLE_FILLER: A object that fills up space in a user interface + *@ATK_ROLE_FONT_CHOOSER: A specialized dialog that lets the user choose a font + *@ATK_ROLE_FRAME: A top level window with a title bar, border, menubar, etc. + *@ATK_ROLE_GLASS_PANE: A pane that is guaranteed to be painted on top of all + *panes beneath it + *@ATK_ROLE_HTML_CONTAINER: A document container for HTML, whose children + *represent the document content + *@ATK_ROLE_ICON: A small fixed size picture, typically used to decorate + *components + *@ATK_ROLE_IMAGE: An object whose primary purpose is to display an image + *@ATK_ROLE_INTERNAL_FRAME: A frame-like object that is clipped by a desktop + *pane + *@ATK_ROLE_LABEL: An object used to present an icon or short string in an + *interface + *@ATK_ROLE_LAYERED_PANE: A specialized pane that allows its children to be + *drawn in layers, providing a form of stacking order + *@ATK_ROLE_LIST: An object that presents a list of objects to the user and + *allows the user to select one or more of them + *@ATK_ROLE_LIST_ITEM: An object that represents an element of a list + *@ATK_ROLE_MENU: An object usually found inside a menu bar that contains a list + *of actions the user can choose from + *@ATK_ROLE_MENU_BAR: An object usually drawn at the top of the primary dialog + *box of an application that contains a list of menus the user can choose from + *@ATK_ROLE_MENU_ITEM: An object usually contained in a menu that presents an + *action the user can choose + *@ATK_ROLE_OPTION_PANE: A specialized pane whose primary use is inside a DIALOG + *@ATK_ROLE_PAGE_TAB: An object that is a child of a page tab list + *@ATK_ROLE_PAGE_TAB_LIST: An object that presents a series of panels (or page + *tabs), one at a time, through some mechanism provided by the object + *@ATK_ROLE_PANEL: A generic container that is often used to group objects + *@ATK_ROLE_PASSWORD_TEXT: A text object uses for passwords, or other places + *where the text content is not shown visibly to the user + *@ATK_ROLE_POPUP_MENU: A temporary window that is usually used to offer the + *user a list of choices, and then hides when the user selects one of those + *choices + *@ATK_ROLE_PROGRESS_BAR: An object used to indicate how much of a task has been + *completed + *@ATK_ROLE_PUSH_BUTTON: An object the user can manipulate to tell the + *application to do something + *@ATK_ROLE_RADIO_BUTTON: A specialized check box that will cause other radio + *buttons in the same group to become unchecked when this one is checked + *@ATK_ROLE_RADIO_MENU_ITEM: A check menu item which belongs to a group. At each + *instant exactly one of the radio menu items from a group is selected + *@ATK_ROLE_ROOT_PANE: A specialized pane that has a glass pane and a layered + *pane as its children + *@ATK_ROLE_ROW_HEADER: The header for a row of data + *@ATK_ROLE_SCROLL_BAR: An object usually used to allow a user to incrementally + *view a large amount of data. + *@ATK_ROLE_SCROLL_PANE: An object that allows a user to incrementally view a + *large amount of information + *@ATK_ROLE_SEPARATOR: An object usually contained in a menu to provide a + *visible and logical separation of the contents in a menu + *@ATK_ROLE_SLIDER: An object that allows the user to select from a bounded + *range + *@ATK_ROLE_SPLIT_PANE: A specialized panel that presents two other panels at + *the same time + *@ATK_ROLE_SPIN_BUTTON: An object used to get an integer or floating point + *number from the user + *@ATK_ROLE_STATUSBAR: An object which reports messages of minor importance to + *the user + *@ATK_ROLE_TABLE: An object used to represent information in terms of rows and + *columns + *@ATK_ROLE_TABLE_CELL: A cell in a table + *@ATK_ROLE_TABLE_COLUMN_HEADER: The header for a column of a table + *@ATK_ROLE_TABLE_ROW_HEADER: The header for a row of a table + *@ATK_ROLE_TEAR_OFF_MENU_ITEM: A menu item used to tear off and reattach its + *menu + *@ATK_ROLE_TERMINAL: An object that represents an accessible terminal. @Since: + *ATK-0.6 + *@ATK_ROLE_TEXT: An interactive widget that supports multiple lines of text and + * optionally accepts user input, but whose purpose is not to solicit user + *input. Thus ATK_ROLE_TEXT is appropriate for the text view in a plain text + *editor but inappropriate for an input field in a dialog box or web form. For + *widgets whose purpose is to solicit input from the user, see ATK_ROLE_ENTRY + *and ATK_ROLE_PASSWORD_TEXT. For generic objects which display a brief amount + *of textual information, see ATK_ROLE_STATIC. + *@ATK_ROLE_TOGGLE_BUTTON: A specialized push button that can be checked or + *unchecked, but does not provide a separate indicator for the current state + *@ATK_ROLE_TOOL_BAR: A bar or palette usually composed of push buttons or + *toggle buttons + *@ATK_ROLE_TOOL_TIP: An object that provides information about another object + *@ATK_ROLE_TREE: An object used to represent hierarchical information to the + *user + *@ATK_ROLE_TREE_TABLE: An object capable of expanding and collapsing rows as + *well as showing multiple columns of data. @Since: ATK-0.7 + *@ATK_ROLE_UNKNOWN: The object contains some Accessible information, but its + *role is not known + *@ATK_ROLE_VIEWPORT: An object usually used in a scroll pane + *@ATK_ROLE_WINDOW: A top level window with no title or border. + *@ATK_ROLE_HEADER: An object that serves as a document header. @Since: + *ATK-1.1.1 + *@ATK_ROLE_FOOTER: An object that serves as a document footer. @Since: + *ATK-1.1.1 + *@ATK_ROLE_PARAGRAPH: An object which is contains a paragraph of text content. + *@Since: ATK-1.1.1 + *@ATK_ROLE_RULER: An object which describes margins and tab stops, etc. for + *text objects which it controls (should have CONTROLLER_FOR relation to such). + *@Since: ATK-1.1.1 + *@ATK_ROLE_APPLICATION: The object is an application object, which may contain + *@ATK_ROLE_FRAME objects or other types of accessibles. The root accessible of + *any application's ATK hierarchy should have ATK_ROLE_APPLICATION. @Since: + *ATK-1.1.4 + *@ATK_ROLE_AUTOCOMPLETE: The object is a dialog or list containing items for + *insertion into an entry widget, for instance a list of words for completion of + *a text entry. @Since: ATK-1.3 + *@ATK_ROLE_EDITBAR: The object is an editable text object in a toolbar. @Since: + *ATK-1.5 + *@ATK_ROLE_EMBEDDED: The object is an embedded container within a document or + *panel. This role is a grouping "hint" indicating that the contained objects + *share a context. @Since: ATK-1.7.2 + *@ATK_ROLE_ENTRY: The object is a component whose textual content may be + *entered or modified by the user, provided @ATK_STATE_EDITABLE is present. + *@Since: ATK-1.11 + *@ATK_ROLE_CHART: The object is a graphical depiction of quantitative data. It + *may contain multiple subelements whose attributes and/or description may be + *queried to obtain both the quantitative data and information about how the + *data is being presented. The LABELLED_BY relation is particularly important in + *interpreting objects of this type, as is the accessible-description property. + *@Since: ATK-1.11 + *@ATK_ROLE_CAPTION: The object contains descriptive information, usually + *textual, about another user interface element such as a table, chart, or + *image. @Since: ATK-1.11 + *@ATK_ROLE_DOCUMENT_FRAME: The object is a visual frame or container which + *contains a view of document content. Document frames may occur within another + *Document instance, in which case the second document may be said to be + *embedded in the containing instance. HTML frames are often + *ROLE_DOCUMENT_FRAME. Either this object, or a singleton descendant, should + *implement the Document interface. @Since: ATK-1.11 + *@ATK_ROLE_HEADING: The object serves as a heading for content which follows it + *in a document. The 'heading level' of the heading, if availabe, may be + *obtained by querying the object's attributes. + *@ATK_ROLE_PAGE: The object is a containing instance which encapsulates a page + *of information. @ATK_ROLE_PAGE is used in documents and content which support + *a paginated navigation model. @Since: ATK-1.11 + *@ATK_ROLE_SECTION: The object is a containing instance of document content + *which constitutes a particular 'logical' section of the document. The type of + *content within a section, and the nature of the section division itself, may + *be obtained by querying the object's attributes. Sections may be nested. + *@Since: ATK-1.11 + *@ATK_ROLE_REDUNDANT_OBJECT: The object is redundant with another object in the + *hierarchy, and is exposed for purely technical reasons. Objects of this role + *should normally be ignored by clients. @Since: ATK-1.11 + *@ATK_ROLE_FORM: The object is a container for form controls, for instance as + *part of a web form or user-input form within a document. This role is + *primarily a tag/convenience for clients when navigating complex documents, it + *is not expected that ordinary GUI containers will always have ATK_ROLE_FORM. + *@Since: ATK-1.12.0 + *@ATK_ROLE_LINK: The object is a hypertext anchor, i.e. a "link" in a + * hypertext document. Such objects are distinct from 'inline' + * content which may also use the Hypertext/Hyperlink interfaces + * to indicate the range/location within a text object where + * an inline or embedded object lies. @Since: ATK-1.12.1 + *@ATK_ROLE_INPUT_METHOD_WINDOW: The object is a window or similar viewport + * which is used to allow composition or input of a 'complex character', + * in other words it is an "input method window." @Since: ATK-1.12.1 + *@ATK_ROLE_TABLE_ROW: A row in a table. @Since: ATK-2.1.0 + *@ATK_ROLE_TREE_ITEM: An object that represents an element of a tree. @Since: + *ATK-2.1.0 + *@ATK_ROLE_DOCUMENT_SPREADSHEET: A document frame which contains a spreadsheet. + *@Since: ATK-2.1.0 + *@ATK_ROLE_DOCUMENT_PRESENTATION: A document frame which contains a + *presentation or slide content. @Since: ATK-2.1.0 + *@ATK_ROLE_DOCUMENT_TEXT: A document frame which contains textual content, such + *as found in a word processing application. @Since: ATK-2.1.0 + *@ATK_ROLE_DOCUMENT_WEB: A document frame which contains HTML or other markup + *suitable for display in a web browser. @Since: ATK-2.1.0 + *@ATK_ROLE_DOCUMENT_EMAIL: A document frame which contains email content to be + *displayed or composed either in plain text or HTML. @Since: ATK-2.1.0 + *@ATK_ROLE_COMMENT: An object found within a document and designed to present a + *comment, note, or other annotation. In some cases, this object might not be + *visible until activated. @Since: ATK-2.1.0 + *@ATK_ROLE_LIST_BOX: A non-collapsible list of choices the user can select + *from. @Since: ATK-2.1.0 + *@ATK_ROLE_GROUPING: A group of related widgets. This group typically has a + *label. @Since: ATK-2.1.0 + *@ATK_ROLE_IMAGE_MAP: An image map object. Usually a graphic with multiple + *hotspots, where each hotspot can be activated resulting in the loading of + *another document or section of a document. @Since: ATK-2.1.0 + *@ATK_ROLE_NOTIFICATION: A transitory object designed to present a message to + *the user, typically at the desktop level rather than inside a particular + *application. @Since: ATK-2.1.0 + *@ATK_ROLE_INFO_BAR: An object designed to present a message to the user within + *an existing window. @Since: ATK-2.1.0 + *@ATK_ROLE_LEVEL_BAR: A bar that serves as a level indicator to, for instance, + *show the strength of a password or the state of a battery. @Since: ATK-2.7.3 + *@ATK_ROLE_TITLE_BAR: A bar that serves as the title of a window or a + * dialog. @Since: ATK-2.12 + *@ATK_ROLE_BLOCK_QUOTE: An object which contains a text section + * that is quoted from another source. @Since: ATK-2.12 + *@ATK_ROLE_AUDIO: An object which represents an audio element. @Since: ATK-2.12 + *@ATK_ROLE_VIDEO: An object which represents a video element. @Since: ATK-2.12 + *@ATK_ROLE_DEFINITION: A definition of a term or concept. @Since: ATK-2.12 + *@ATK_ROLE_ARTICLE: A section of a page that consists of a + * composition that forms an independent part of a document, page, or + * site. Examples: A blog entry, a news story, a forum post. @Since: + * ATK-2.12 + *@ATK_ROLE_LANDMARK: A region of a web page intended as a + * navigational landmark. This is designed to allow Assistive + * Technologies to provide quick navigation among key regions within a + * document. @Since: ATK-2.12 + *@ATK_ROLE_LOG: A text widget or container holding log content, such + * as chat history and error logs. In this role there is a + * relationship between the arrival of new items in the log and the + * reading order. The log contains a meaningful sequence and new + * information is added only to the end of the log, not at arbitrary + * points. @Since: ATK-2.12 + *@ATK_ROLE_MARQUEE: A container where non-essential information + * changes frequently. Common usages of marquee include stock tickers + * and ad banners. The primary difference between a marquee and a log + * is that logs usually have a meaningful order or sequence of + * important content changes. @Since: ATK-2.12 + *@ATK_ROLE_MATH: A text widget or container that holds a mathematical + * expression. @Since: ATK-2.12 + *@ATK_ROLE_RATING: A widget whose purpose is to display a rating, + * such as the number of stars associated with a song in a media + * player. Objects of this role should also implement + * AtkValue. @Since: ATK-2.12 + *@ATK_ROLE_TIMER: An object containing a numerical counter which + * indicates an amount of elapsed time from a start point, or the time + * remaining until an end point. @Since: ATK-2.12 + *@ATK_ROLE_DESCRIPTION_LIST: An object that represents a list of + * term-value groups. A term-value group represents a individual + * description and consist of one or more names + * (ATK_ROLE_DESCRIPTION_TERM) followed by one or more values + * (ATK_ROLE_DESCRIPTION_VALUE). For each list, there should not be + * more than one group with the same term name. @Since: ATK-2.12 + *@ATK_ROLE_DESCRIPTION_TERM: An object that represents the term, or + * name, part of a term-description group in a description + * list. @Since: ATK-2.12 + *@ATK_ROLE_DESCRIPTION_VALUE: An object that represents the + * description, definition or value of a term-description group in a + * description list. The values within a group are alternatives, + * meaning that you can have several ATK_ROLE_DESCRIPTION_VALUE for a + * given ATK_ROLE_DESCRIPTION_TERM. @Since: ATK-2.12 + *@ATK_ROLE_STATIC: A generic non-container object whose purpose is to display a + * brief amount of information to the user and whose role is known by the + * implementor but lacks semantic value for the user. Examples in which + * ATK_ROLE_STATIC is appropriate include the message displayed in a message box + * and an image used as an alternative means to display text. ATK_ROLE_STATIC + * should not be applied to widgets which are traditionally interactive, objects + * which display a significant amount of content, or any object which has an + * accessible relation pointing to another object. Implementors should expose + *the displayed information through the accessible name of the object. If doing + *so seems inappropriate, it may indicate that a different role should be used. + *For labels which describe another widget, see ATK_ROLE_LABEL. For text views, + *see ATK_ROLE_TEXT. For generic containers, see ATK_ROLE_PANEL. For objects + *whose role is not known by the implementor, see ATK_ROLE_UNKNOWN. @Since: + *ATK-2.16. + *@ATK_ROLE_MATH_FRACTION: An object that represents a mathematical fraction. + * @Since: ATK-2.16. + *@ATK_ROLE_MATH_ROOT: An object that represents a mathematical expression + * displayed with a radical. @Since: ATK-2.16. + *@ATK_ROLE_SUBSCRIPT: An object that contains text that is displayed as a + * subscript. @Since: ATK-2.16. + *@ATK_ROLE_SUPERSCRIPT: An object that contains text that is displayed as a + * superscript. @Since: ATK-2.16. + *@ATK_ROLE_FOOTNOTE: An object that contains the text of a footnote. @Since: + *ATK-2.26. + *@ATK_ROLE_CONTENT_DELETION: Content previously deleted or proposed to be + * deleted, e.g. in revision history or a content view providing suggestions + * from reviewers. (Since: 2.34) + *@ATK_ROLE_CONTENT_INSERTION: Content previously inserted or proposed to be + * inserted, e.g. in revision history or a content view providing suggestions + * from reviewers. (Since: 2.34) + *@ATK_ROLE_MARK: A run of content that is marked or highlighted, such as for + * reference purposes, or to call it out as having a special purpose. If the + * marked content has an associated section in the document elaborating on the + * reason for the mark, then %ATK_RELATION_DETAILS should be used on the mark + * to point to that associated section. In addition, the reciprocal relation + * %ATK_RELATION_DETAILS_FOR should be used on the associated content section + * to point back to the mark. (Since: 2.36) + *@ATK_ROLE_SUGGESTION: A container for content that is called out as a proposed + * change from the current version of the document, such as by a reviewer of the + * content. This role should include either %ATK_ROLE_CONTENT_DELETION and/or + * %ATK_ROLE_CONTENT_INSERTION children, in any order, to indicate what the + * actual change is. (Since: 2.36) + *@ATK_ROLE_LAST_DEFINED: not a valid role, used for finding end of the + *enumeration + * + * Describes the role of an object + * + * These are the built-in enumerated roles that UI components can have in + * ATK. Other roles may be added at runtime, so an AtkRole >= + * ATK_ROLE_LAST_DEFINED is not necessarily an error. + **/ +typedef enum { + ATK_ROLE_INVALID = 0, + ATK_ROLE_ACCEL_LABEL, /*<nick=accelerator-label>*/ + ATK_ROLE_ALERT, + ATK_ROLE_ANIMATION, + ATK_ROLE_ARROW, + ATK_ROLE_CALENDAR, + ATK_ROLE_CANVAS, + ATK_ROLE_CHECK_BOX, + ATK_ROLE_CHECK_MENU_ITEM, + ATK_ROLE_COLOR_CHOOSER, + ATK_ROLE_COLUMN_HEADER, + ATK_ROLE_COMBO_BOX, + ATK_ROLE_DATE_EDITOR, + ATK_ROLE_DESKTOP_ICON, + ATK_ROLE_DESKTOP_FRAME, + ATK_ROLE_DIAL, + ATK_ROLE_DIALOG, + ATK_ROLE_DIRECTORY_PANE, + ATK_ROLE_DRAWING_AREA, + ATK_ROLE_FILE_CHOOSER, + ATK_ROLE_FILLER, + ATK_ROLE_FONT_CHOOSER, + ATK_ROLE_FRAME, + ATK_ROLE_GLASS_PANE, + ATK_ROLE_HTML_CONTAINER, + ATK_ROLE_ICON, + ATK_ROLE_IMAGE, + ATK_ROLE_INTERNAL_FRAME, + ATK_ROLE_LABEL, + ATK_ROLE_LAYERED_PANE, + ATK_ROLE_LIST, + ATK_ROLE_LIST_ITEM, + ATK_ROLE_MENU, + ATK_ROLE_MENU_BAR, + ATK_ROLE_MENU_ITEM, + ATK_ROLE_OPTION_PANE, + ATK_ROLE_PAGE_TAB, + ATK_ROLE_PAGE_TAB_LIST, + ATK_ROLE_PANEL, + ATK_ROLE_PASSWORD_TEXT, + ATK_ROLE_POPUP_MENU, + ATK_ROLE_PROGRESS_BAR, + ATK_ROLE_PUSH_BUTTON, + ATK_ROLE_RADIO_BUTTON, + ATK_ROLE_RADIO_MENU_ITEM, + ATK_ROLE_ROOT_PANE, + ATK_ROLE_ROW_HEADER, + ATK_ROLE_SCROLL_BAR, + ATK_ROLE_SCROLL_PANE, + ATK_ROLE_SEPARATOR, + ATK_ROLE_SLIDER, + ATK_ROLE_SPLIT_PANE, + ATK_ROLE_SPIN_BUTTON, + ATK_ROLE_STATUSBAR, + ATK_ROLE_TABLE, + ATK_ROLE_TABLE_CELL, + ATK_ROLE_TABLE_COLUMN_HEADER, + ATK_ROLE_TABLE_ROW_HEADER, + ATK_ROLE_TEAR_OFF_MENU_ITEM, + ATK_ROLE_TERMINAL, + ATK_ROLE_TEXT, + ATK_ROLE_TOGGLE_BUTTON, + ATK_ROLE_TOOL_BAR, + ATK_ROLE_TOOL_TIP, + ATK_ROLE_TREE, + ATK_ROLE_TREE_TABLE, + ATK_ROLE_UNKNOWN, + ATK_ROLE_VIEWPORT, + ATK_ROLE_WINDOW, + ATK_ROLE_HEADER, + ATK_ROLE_FOOTER, + ATK_ROLE_PARAGRAPH, + ATK_ROLE_RULER, + ATK_ROLE_APPLICATION, + ATK_ROLE_AUTOCOMPLETE, + ATK_ROLE_EDITBAR, + ATK_ROLE_EMBEDDED, + ATK_ROLE_ENTRY, + ATK_ROLE_CHART, + ATK_ROLE_CAPTION, + ATK_ROLE_DOCUMENT_FRAME, + ATK_ROLE_HEADING, + ATK_ROLE_PAGE, + ATK_ROLE_SECTION, + ATK_ROLE_REDUNDANT_OBJECT, + ATK_ROLE_FORM, + ATK_ROLE_LINK, + ATK_ROLE_INPUT_METHOD_WINDOW, + ATK_ROLE_TABLE_ROW, + ATK_ROLE_TREE_ITEM, + ATK_ROLE_DOCUMENT_SPREADSHEET, + ATK_ROLE_DOCUMENT_PRESENTATION, + ATK_ROLE_DOCUMENT_TEXT, + ATK_ROLE_DOCUMENT_WEB, + ATK_ROLE_DOCUMENT_EMAIL, + ATK_ROLE_COMMENT, + ATK_ROLE_LIST_BOX, + ATK_ROLE_GROUPING, + ATK_ROLE_IMAGE_MAP, + ATK_ROLE_NOTIFICATION, + ATK_ROLE_INFO_BAR, + ATK_ROLE_LEVEL_BAR, + ATK_ROLE_TITLE_BAR, + ATK_ROLE_BLOCK_QUOTE, + ATK_ROLE_AUDIO, + ATK_ROLE_VIDEO, + ATK_ROLE_DEFINITION, + ATK_ROLE_ARTICLE, + ATK_ROLE_LANDMARK, + ATK_ROLE_LOG, + ATK_ROLE_MARQUEE, + ATK_ROLE_MATH, + ATK_ROLE_RATING, + ATK_ROLE_TIMER, + ATK_ROLE_DESCRIPTION_LIST, + ATK_ROLE_DESCRIPTION_TERM, + ATK_ROLE_DESCRIPTION_VALUE, + ATK_ROLE_STATIC, + ATK_ROLE_MATH_FRACTION, + ATK_ROLE_MATH_ROOT, + ATK_ROLE_SUBSCRIPT, + ATK_ROLE_SUPERSCRIPT, + ATK_ROLE_FOOTNOTE, + ATK_ROLE_CONTENT_DELETION, + ATK_ROLE_CONTENT_INSERTION, + ATK_ROLE_MARK, + ATK_ROLE_SUGGESTION, + ATK_ROLE_LAST_DEFINED +} AtkRole; + +AtkRole atk_role_register(const gchar* name); + +/** + *AtkLayer: + *@ATK_LAYER_INVALID: The object does not have a layer + *@ATK_LAYER_BACKGROUND: This layer is reserved for the desktop background + *@ATK_LAYER_CANVAS: This layer is used for Canvas components + *@ATK_LAYER_WIDGET: This layer is normally used for components + *@ATK_LAYER_MDI: This layer is used for layered components + *@ATK_LAYER_POPUP: This layer is used for popup components, such as menus + *@ATK_LAYER_OVERLAY: This layer is reserved for future use. + *@ATK_LAYER_WINDOW: This layer is used for toplevel windows. + * + * Describes the layer of a component + * + * These enumerated "layer values" are used when determining which UI + * rendering layer a component is drawn into, which can help in making + * determinations of when components occlude one another. + **/ +typedef enum { + ATK_LAYER_INVALID, + ATK_LAYER_BACKGROUND, + ATK_LAYER_CANVAS, + ATK_LAYER_WIDGET, + ATK_LAYER_MDI, + ATK_LAYER_POPUP, + ATK_LAYER_OVERLAY, + ATK_LAYER_WINDOW +} AtkLayer; + +/** + * AtkAttributeSet: + * + * This is a singly-linked list (a #GSList) of #AtkAttribute. It is + * used by atk_text_get_run_attributes(), atk_text_get_default_attributes() + * and atk_editable_text_set_run_attributes() + **/ +typedef GSList AtkAttributeSet; + +/** + * AtkAttribute: + * @name: The attribute name. Call atk_text_attr_get_name() + * @value: the value of the attribute, represented as a string. + * Call atk_text_attr_get_value() for those which are strings. + * For values which are numbers, the string representation of the number + * is in value. + * + * A string name/value pair representing a text attribute. + **/ +typedef struct _AtkAttribute AtkAttribute; + +struct _AtkAttribute { + gchar* name; + gchar* value; +}; + +#define ATK_TYPE_OBJECT (atk_object_get_type()) +#define ATK_OBJECT(obj) \ + (G_TYPE_CHECK_INSTANCE_CAST((obj), ATK_TYPE_OBJECT, AtkObject)) +#define ATK_OBJECT_CLASS(klass) \ + (G_TYPE_CHECK_CLASS_CAST((klass), ATK_TYPE_OBJECT, AtkObjectClass)) +#define ATK_IS_OBJECT(obj) (G_TYPE_CHECK_INSTANCE_TYPE((obj), ATK_TYPE_OBJECT)) +#define ATK_IS_OBJECT_CLASS(klass) \ + (G_TYPE_CHECK_CLASS_TYPE((klass), ATK_TYPE_OBJECT)) +#define ATK_OBJECT_GET_CLASS(obj) \ + (G_TYPE_INSTANCE_GET_CLASS((obj), ATK_TYPE_OBJECT, AtkObjectClass)) + +#define ATK_TYPE_IMPLEMENTOR (atk_implementor_get_type()) +#define ATK_IS_IMPLEMENTOR(obj) \ + G_TYPE_CHECK_INSTANCE_TYPE((obj), ATK_TYPE_IMPLEMENTOR) +#define ATK_IMPLEMENTOR(obj) \ + G_TYPE_CHECK_INSTANCE_CAST((obj), ATK_TYPE_IMPLEMENTOR, AtkImplementor) +#define ATK_IMPLEMENTOR_GET_IFACE(obj) \ + (G_TYPE_INSTANCE_GET_INTERFACE((obj), ATK_TYPE_IMPLEMENTOR, \ + AtkImplementorIface)) + +typedef struct _AtkImplementor AtkImplementor; /* dummy typedef */ +typedef struct _AtkImplementorIface AtkImplementorIface; + +typedef struct _AtkObject AtkObject; +typedef struct _AtkObjectClass AtkObjectClass; +typedef struct _AtkRelationSet AtkRelationSet; +typedef struct _AtkStateSet AtkStateSet; + +/** + * AtkPropertyValues: + * @property_name: The name of the ATK property which is being presented or + *which has been changed. + * @old_value: The old property value, NULL; in some contexts this value is + *undefined (see note below). + * @new_value: The new value of the named property. + * + * @note: For most properties the old_value field of AtkPropertyValues will + * not contain a valid value. + * + * Currently, the only property for which old_value is used is + * accessible-state; for instance if there is a focus state the + * property change handler will be called for the object which lost the focus + * with the old_value containing an AtkState value corresponding to focused + * and the property change handler will be called for the object which + * received the focus with the new_value containing an AtkState value + * corresponding to focused. + * + **/ +struct _AtkPropertyValues { + const gchar* property_name; + GValue old_value; + GValue new_value; +}; + +typedef struct _AtkPropertyValues AtkPropertyValues; + +typedef gboolean (*AtkFunction)(gpointer data); +/* + * For most properties the old_value field of AtkPropertyValues will + * not contain a valid value. + * + * Currently, the only property for which old_value is used is + * accessible-state; for instance if there is a focus state the + * property change handler will be called for the object which lost the focus + * with the old_value containing an AtkState value corresponding to focused + * and the property change handler will be called for the object which + * received the focus with the new_value containing an AtkState value + * corresponding to focused. + */ +typedef void (*AtkPropertyChangeHandler)(AtkObject*, AtkPropertyValues*); + +struct _AtkObject { + GObject parent; + + gchar* description; + gchar* name; + AtkObject* accessible_parent; + AtkRole role; + AtkRelationSet* relation_set; + AtkLayer layer; +}; + +struct _AtkObjectClass { + GObjectClass parent; + + /* + * Gets the accessible name of the object + */ + G_CONST_RETURN gchar* (*get_name)(AtkObject* accessible); + /* + * Gets the accessible description of the object + */ + G_CONST_RETURN gchar* (*get_description)(AtkObject* accessible); + /* + * Gets the accessible parent of the object + */ + AtkObject* (*get_parent)(AtkObject* accessible); + + /* + * Gets the number of accessible children of the object + */ + gint (*get_n_children)(AtkObject* accessible); + /* + * Returns a reference to the specified accessible child of the object. + * The accessible children are 0-based so the first accessible child is + * at index 0, the second at index 1 and so on. + */ + AtkObject* (*ref_child)(AtkObject* accessible, gint i); + /* + * Gets the 0-based index of this object in its parent; returns -1 if the + * object does not have an accessible parent. + */ + gint (*get_index_in_parent)(AtkObject* accessible); + /* + * Gets the RelationSet associated with the object + */ + AtkRelationSet* (*ref_relation_set)(AtkObject* accessible); + /* + * Gets the role of the object + */ + AtkRole (*get_role)(AtkObject* accessible); + AtkLayer (*get_layer)(AtkObject* accessible); + gint (*get_mdi_zorder)(AtkObject* accessible); + /* + * Gets the state set of the object + */ + AtkStateSet* (*ref_state_set)(AtkObject* accessible); + /* + * Sets the accessible name of the object + */ + void (*set_name)(AtkObject* accessible, const gchar* name); + /* + * Sets the accessible description of the object + */ + void (*set_description)(AtkObject* accessible, const gchar* description); + /* + * Sets the accessible parent of the object + */ + void (*set_parent)(AtkObject* accessible, AtkObject* parent); + /* + * Sets the accessible role of the object + */ + void (*set_role)(AtkObject* accessible, AtkRole role); + /* + * Specifies a function to be called when a property changes value + */ + guint (*connect_property_change_handler)(AtkObject* accessible, + AtkPropertyChangeHandler* handler); + /* + * Removes a property change handler which was specified using + * connect_property_change_handler + */ + void (*remove_property_change_handler)(AtkObject* accessible, + guint handler_id); + void (*initialize)(AtkObject* accessible, gpointer data); + /* + * The signal handler which is executed when there is a change in the + * children of the object + */ + void (*children_changed)(AtkObject* accessible, guint change_index, + gpointer changed_child); + /* + * The signal handler which is executed when there is a focus event + * for an object. + */ + void (*focus_event)(AtkObject* accessible, gboolean focus_in); + /* + * The signal handler which is executed when there is a property_change + * signal for an object. + */ + void (*property_change)(AtkObject* accessible, AtkPropertyValues* values); + /* + * The signal handler which is executed when there is a state_change + * signal for an object. + */ + void (*state_change)(AtkObject* accessible, const gchar* name, + gboolean state_set); + /* + * The signal handler which is executed when there is a change in the + * visible data for an object + */ + void (*visible_data_changed)(AtkObject* accessible); + + /* + * The signal handler which is executed when there is a change in the + * 'active' child or children of the object, for instance when + * interior focus changes in a table or list. This signal should be emitted + * by objects whose state includes ATK_STATE_MANAGES_DESCENDANTS. + */ + void (*active_descendant_changed)(AtkObject* accessible, gpointer* child); + + /* + * Gets a list of properties applied to this object as a whole, as an + * #AtkAttributeSet consisting of name-value pairs. Since ATK 1.12 + */ + AtkAttributeSet* (*get_attributes)(AtkObject* accessible); + + const gchar* (*get_object_locale)(AtkObject* accessible); + + AtkFunction pad1; +}; + +GType atk_object_get_type(void); + +struct _AtkImplementorIface { + GTypeInterface parent; + + AtkObject* (*ref_accessible)(AtkImplementor* implementor); +}; +GType atk_implementor_get_type(void); + +/* + * This method uses the ref_accessible method in AtkImplementorIface, + * if the object's class implements AtkImplementorIface. + * Otherwise it returns %NULL. + * + * IMPORTANT: + * Note also that because this method may return flyweight objects, + * it increments the returned AtkObject's reference count. + * Therefore it is the responsibility of the calling + * program to unreference the object when no longer needed. + * (c.f. gtk_widget_get_accessible() where this is not the case). + */ +AtkObject* atk_implementor_ref_accessible(AtkImplementor* implementor); + +/* + * Properties directly supported by AtkObject + */ + +G_CONST_RETURN gchar* atk_object_get_name(AtkObject* accessible); +G_CONST_RETURN gchar* atk_object_get_description(AtkObject* accessible); +AtkObject* atk_object_get_parent(AtkObject* accessible); +gint atk_object_get_n_accessible_children(AtkObject* accessible); +AtkObject* atk_object_ref_accessible_child(AtkObject* accessible, gint i); +AtkRelationSet* atk_object_ref_relation_set(AtkObject* accessible); +AtkRole atk_object_get_role(AtkObject* accessible); +AtkLayer atk_object_get_layer(AtkObject* accessible); +gint atk_object_get_mdi_zorder(AtkObject* accessible); +AtkAttributeSet* atk_object_get_attributes(AtkObject* accessible); +AtkStateSet* atk_object_ref_state_set(AtkObject* accessible); +gint atk_object_get_index_in_parent(AtkObject* accessible); +void atk_object_set_name(AtkObject* accessible, const gchar* name); +void atk_object_set_description(AtkObject* accessible, + const gchar* description); +void atk_object_set_parent(AtkObject* accessible, AtkObject* parent); +void atk_object_set_role(AtkObject* accessible, AtkRole role); + +guint atk_object_connect_property_change_handler( + AtkObject* accessible, AtkPropertyChangeHandler* handler); +void atk_object_remove_property_change_handler(AtkObject* accessible, + guint handler_id); + +void atk_object_notify_state_change(AtkObject* accessible, AtkState state, + gboolean value); +void atk_object_initialize(AtkObject* accessible, gpointer data); + +G_CONST_RETURN gchar* atk_role_get_name(AtkRole role); +AtkRole atk_role_for_name(const gchar* name); + +/* NEW in 1.1: convenience API */ +gboolean atk_object_add_relationship(AtkObject* object, + AtkRelationType relationship, + AtkObject* target); +gboolean atk_object_remove_relationship(AtkObject* object, + AtkRelationType relationship, + AtkObject* target); +G_CONST_RETURN gchar* atk_role_get_localized_name(AtkRole role); + +/* */ + +/* + * Note: the properties which are registered with the GType + * property registry, for type ATK_TYPE_OBJECT, are as follows: + * + * "accessible-name" + * "accessible-description" + * "accessible-parent" + * "accessible-role" + * "accessible-value" + * "accessible-component-layer" + * "accessible-component-zorder" + * "accessible-table-caption" + * "accessible-table-column-description" + * "accessible-table-column-header" + * "accessible-table-row-description" + * "accessible-table-row-header" + * "accessible-table-summary" + * "accessible-model" + * + * accessibility property change listeners should use the + * normal GObject property interfaces and "property-change" + * signal handler semantics to interpret the property change + * information relayed from AtkObject. + * (AtkObject instances will connect to the "notify" + * signal in their host objects, and relay the signals when appropriate). + */ + +/* For other signals, see related interfaces + * + * AtkActionIface, + * AtkComponentIface, + * AtkHypertextIface, + * AtkImageIface, + * AtkSelectionIface, + * AtkTableIface, + * AtkTextIface, + * AtkValueIface. + * + * The usage model for obtaining these interface instances is: + * ATK_<interfacename>_GET_IFACE(GObject *accessible), + * where accessible, though specified as a GObject, is + * the AtkObject instance being queried. + * More usually, the interface will be used via a cast to the + * interface's corresponding "type": + * + * AtkText textImpl = ATK_TEXT(accessible); + * if (textImpl) + * { + * cpos = atk_text_get_caret_position(textImpl); + * } + * + * If it's known in advance that accessible implements AtkTextIface, + * this is shortened to: + * + * cpos = atk_text_get_caret_position (ATK_TEXT (accessible)); + */ + +#ifdef __cplusplus +} +#endif /* __cplusplus */ + +#endif /* __ATK_OBJECT_H__ */ diff --git a/other-licenses/atk-1.0/atk/atkobjectfactory.h b/other-licenses/atk-1.0/atk/atkobjectfactory.h new file mode 100644 index 0000000000..fb163adb83 --- /dev/null +++ b/other-licenses/atk-1.0/atk/atkobjectfactory.h @@ -0,0 +1,68 @@ +/* ATK - Accessibility Toolkit + * Copyright 2001 Sun Microsystems Inc. + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either + * version 2 of the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with this library; if not, write to the + * Free Software Foundation, Inc., 59 Temple Place - Suite 330, + * Boston, MA 02111-1307, USA. + */ + +#ifndef __ATK_OBJECT_FACTORY_H__ +#define __ATK_OBJECT_FACTORY_H__ + +#include <glib-object.h> +#include <atk/atkobject.h> + +#ifdef __cplusplus +extern "C" { +#endif /* __cplusplus */ + +#define ATK_TYPE_OBJECT_FACTORY (atk_object_factory_get_type ()) +#define ATK_OBJECT_FACTORY(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), ATK_TYPE_OBJECT_FACTORY, AtkObjectFactory)) +#define ATK_OBJECT_FACTORY_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), ATK_TYPE_OBJECT_FACTORY, AtkObjectFactoryClass)) +#define ATK_IS_OBJECT_FACTORY(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), ATK_TYPE_OBJECT_FACTORY)) +#define ATK_IS_OBJECT_FACTORY_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), ATK_TYPE_OBJECT_FACTORY)) +#define ATK_OBJECT_FACTORY_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), ATK_TYPE_OBJECT_FACTORY, AtkObjectFactoryClass)) + +typedef struct _AtkObjectFactory AtkObjectFactory; +typedef struct _AtkObjectFactoryClass AtkObjectFactoryClass; + +struct _AtkObjectFactory +{ + GObject parent; +}; + +struct _AtkObjectFactoryClass +{ + GObjectClass parent_class; + + AtkObject* (* create_accessible) (GObject *obj); + void (* invalidate) (AtkObjectFactory *factory); + GType (* get_accessible_type) (void); + + AtkFunction pad1; + AtkFunction pad2; +}; + +GType atk_object_factory_get_type(void); + +AtkObject* atk_object_factory_create_accessible (AtkObjectFactory *factory, GObject *obj); +void atk_object_factory_invalidate (AtkObjectFactory *factory); +GType atk_object_factory_get_accessible_type (AtkObjectFactory *factory); +#ifdef __cplusplus +} +#endif /* __cplusplus */ + + +#endif /* __GTK_OBJECT_FACTORY_H__ */ + diff --git a/other-licenses/atk-1.0/atk/atkplug.h b/other-licenses/atk-1.0/atk/atkplug.h new file mode 100644 index 0000000000..7d6efd4b9d --- /dev/null +++ b/other-licenses/atk-1.0/atk/atkplug.h @@ -0,0 +1,61 @@ +/* ATK - Accessibility Toolkit + * Copyright 2009 Novell, Inc. + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either + * version 2 of the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with this library; if not, write to the + * Free Software Foundation, Inc., 59 Temple Place - Suite 330, + * Boston, MA 02111-1307, USA. + */ + +#if defined(ATK_DISABLE_SINGLE_INCLUDES) && !defined (__ATK_H_INSIDE__) && !defined (ATK_COMPILATION) +#error "Only <atk/atk.h> can be included directly." +#endif + +#ifndef __ATK_PLUG_H__ +#define __ATK_PLUG_H__ + +G_BEGIN_DECLS + +#define ATK_TYPE_PLUG (atk_plug_get_type ()) +#define ATK_PLUG(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), ATK_TYPE_PLUG, AtkPlug)) +#define ATK_IS_PLUG(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), ATK_TYPE_PLUG)) +#define ATK_PLUG_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), ATK_TYPE_PLUG, AtkPlugClass)) +#define ATK_IS_PLUG_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), ATK_TYPE_PLUG)) +#define ATK_PLUG_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), ATK_TYPE_PLUG, AtkPlugClass)) + +typedef struct _AtkPlug AtkPlug; +typedef struct _AtkPlugClass AtkPlugClass; + +struct _AtkPlug +{ + AtkObject parent; +}; + +GType atk_plug_get_type (void); + +struct _AtkPlugClass +{ + AtkObjectClass parent_class; + + /* to be subscribed to by atk-bridge */ + + /*< protected >*/ + gchar* (* get_object_id) (AtkPlug* obj); +}; + +AtkObject* atk_plug_new (void); +gchar* atk_plug_get_id (AtkPlug* plug); + +G_END_DECLS + +#endif /* __ATK_PLUG_H__ */ diff --git a/other-licenses/atk-1.0/atk/atkregistry.h b/other-licenses/atk-1.0/atk/atkregistry.h new file mode 100644 index 0000000000..3ab0414ae7 --- /dev/null +++ b/other-licenses/atk-1.0/atk/atkregistry.h @@ -0,0 +1,69 @@ +/* ATK - Accessibility Toolkit + * Copyright 2001 Sun Microsystems Inc. + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either + * version 2 of the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with this library; if not, write to the + * Free Software Foundation, Inc., 59 Temple Place - Suite 330, + * Boston, MA 02111-1307, USA. + */ + +#ifndef __ATK_REGISTRY_H__ +#define __ATK_REGISTRY_H__ + +#ifdef __cplusplus +extern "C" { +#endif /* __cplusplus */ + +#include <glib-object.h> +#include "atkobjectfactory.h" + +#define ATK_TYPE_REGISTRY (atk_registry_get_type ()) +#define ATK_REGISTRY(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), ATK_TYPE_REGISTRY, AtkRegistry)) +#define ATK_REGISTRY_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), ATK_TYPE_REGISTRY, AtkRegistryClass)) +#define ATK_IS_REGISTRY(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), ATK_TYPE_REGISTRY)) +#define ATK_IS_REGISTRY_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), ATK_TYPE_REGISTRY)) +#define ATK_REGISTRY_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), ATK_TYPE_REGISTRY, AtkRegistryClass)) + +struct _AtkRegistry +{ + GObject parent; + GHashTable *factory_type_registry; + GHashTable *factory_singleton_cache; +}; + +struct _AtkRegistryClass +{ + GObjectClass parent_class; +}; + +typedef struct _AtkRegistry AtkRegistry; +typedef struct _AtkRegistryClass AtkRegistryClass; + + +GType atk_registry_get_type (void); +void atk_registry_set_factory_type (AtkRegistry *registry, + GType type, + GType factory_type); +GType atk_registry_get_factory_type (AtkRegistry *registry, + GType type); +AtkObjectFactory* atk_registry_get_factory (AtkRegistry *registry, + GType type); + +AtkRegistry* atk_get_default_registry (void); + +#ifdef __cplusplus +} +#endif /* __cplusplus */ + +#endif /* __ATK_REGISTRY_H__ */ + diff --git a/other-licenses/atk-1.0/atk/atkrelation.h b/other-licenses/atk-1.0/atk/atkrelation.h new file mode 100644 index 0000000000..08b0708f14 --- /dev/null +++ b/other-licenses/atk-1.0/atk/atkrelation.h @@ -0,0 +1,88 @@ +/* ATK - Accessibility Toolkit + * Copyright 2001 Sun Microsystems Inc. + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either + * version 2 of the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with this library; if not, write to the + * Free Software Foundation, Inc., 59 Temple Place - Suite 330, + * Boston, MA 02111-1307, USA. + */ + +#ifndef __ATK_RELATION_H__ +#define __ATK_RELATION_H__ + +#ifdef __cplusplus +extern "C" { +#endif /* __cplusplus */ + +#include <glib-object.h> +#include <atk/atkrelationtype.h> + +/* + * An AtkRelation describes a relation between the object and one or more + * other objects. The actual relations that an object has with other objects + * are defined as an AtkRelationSet, which is a set of AtkRelations. + */ + +#define ATK_TYPE_RELATION (atk_relation_get_type ()) +#define ATK_RELATION(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), ATK_TYPE_RELATION, AtkRelation)) +#define ATK_RELATION_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), ATK_TYPE_RELATION, AtkRelationClass)) +#define ATK_IS_RELATION(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), ATK_TYPE_RELATION)) +#define ATK_IS_RELATION_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), ATK_TYPE_RELATION)) +#define ATK_RELATION_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), ATK_TYPE_RELATION, AtkRelationClass)) + +typedef struct _AtkRelation AtkRelation; +typedef struct _AtkRelationClass AtkRelationClass; + +struct _AtkRelation +{ + GObject parent; + + GPtrArray *target; + AtkRelationType relationship; +}; + +struct _AtkRelationClass +{ + GObjectClass parent; +}; + +GType atk_relation_get_type (void); + +AtkRelationType atk_relation_type_register (const gchar *name); +G_CONST_RETURN gchar* atk_relation_type_get_name (AtkRelationType type); +AtkRelationType atk_relation_type_for_name (const gchar *name); + +/* + * Create a new relation for the specified key and the specified list + * of targets. + */ +AtkRelation* atk_relation_new (AtkObject **targets, + gint n_targets, + AtkRelationType relationship); +/* + * Returns the type of a relation. + */ +AtkRelationType atk_relation_get_relation_type (AtkRelation *relation); +/* + * Returns the target list of a relation. + */ +GPtrArray* atk_relation_get_target (AtkRelation *relation); +void atk_relation_add_target (AtkRelation *relation, + AtkObject *target); + + +#ifdef __cplusplus +} +#endif /* __cplusplus */ + +#endif /* __ATK_RELATION_H__ */ diff --git a/other-licenses/atk-1.0/atk/atkrelationset.h b/other-licenses/atk-1.0/atk/atkrelationset.h new file mode 100644 index 0000000000..2225baf906 --- /dev/null +++ b/other-licenses/atk-1.0/atk/atkrelationset.h @@ -0,0 +1,79 @@ +/* ATK - Accessibility Toolkit + * Copyright 2001 Sun Microsystems Inc. + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either + * version 2 of the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with this library; if not, write to the + * Free Software Foundation, Inc., 59 Temple Place - Suite 330, + * Boston, MA 02111-1307, USA. + */ + +#ifndef __ATK_RELATION_SET_H__ +#define __ATK_RELATION_SET_H__ + +#ifdef __cplusplus +extern "C" { +#endif /* __cplusplus */ + +#include <glib-object.h> +#include <atk/atkobject.h> +#include <atk/atkrelation.h> + +#define ATK_TYPE_RELATION_SET (atk_relation_set_get_type ()) +#define ATK_RELATION_SET(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), ATK_TYPE_RELATION_SET, AtkRelationSet)) +#define ATK_RELATION_SET_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), ATK_TYPE_RELATION_SET, AtkRelationSetClass)) +#define ATK_IS_RELATION_SET(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), ATK_TYPE_RELATION_SET)) +#define ATK_IS_RELATION_SET_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), ATK_TYPE_RELATION_SET)) +#define ATK_RELATION_SET_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), ATK_TYPE_RELATION_SET, AtkRelationSetClass)) + +typedef struct _AtkRelationSetClass AtkRelationSetClass; + + +struct _AtkRelationSet +{ + GObject parent; + + GPtrArray *relations; +}; + +struct _AtkRelationSetClass +{ + GObjectClass parent; + + AtkFunction pad1; + AtkFunction pad2; +}; + +GType atk_relation_set_get_type (void); + +AtkRelationSet* atk_relation_set_new (void); +gboolean atk_relation_set_contains (AtkRelationSet *set, + AtkRelationType relationship); +void atk_relation_set_remove (AtkRelationSet *set, + AtkRelation *relation); +void atk_relation_set_add (AtkRelationSet *set, + AtkRelation *relation); +gint atk_relation_set_get_n_relations (AtkRelationSet *set); +AtkRelation* atk_relation_set_get_relation (AtkRelationSet *set, + gint i); +AtkRelation* atk_relation_set_get_relation_by_type (AtkRelationSet *set, + AtkRelationType relationship); +void atk_relation_set_add_relation_by_type (AtkRelationSet *set, + AtkRelationType relationship, + AtkObject *target); + +#ifdef __cplusplus +} +#endif /* __cplusplus */ + + +#endif /* __ATK_RELATION_SET_H__ */ diff --git a/other-licenses/atk-1.0/atk/atkrelationtype.h b/other-licenses/atk-1.0/atk/atkrelationtype.h new file mode 100644 index 0000000000..d1c7410875 --- /dev/null +++ b/other-licenses/atk-1.0/atk/atkrelationtype.h @@ -0,0 +1,115 @@ +/* ATK - Accessibility Toolkit + * Copyright 2002 Sun Microsystems Inc. + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either + * version 2 of the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with this library; if not, write to the + * Free Software Foundation, Inc., 59 Temple Place - Suite 330, + * Boston, MA 02111-1307, USA. + */ + +#if defined(ATK_DISABLE_SINGLE_INCLUDES) && !defined (__ATK_H_INSIDE__) && !defined (ATK_COMPILATION) +#error "Only <atk/atk.h> can be included directly." +#endif + +#ifndef __ATK_RELATION_TYPE_H__ +#define __ATK_RELATION_TYPE_H__ + +#include <glib.h> + +G_BEGIN_DECLS + +/** + *AtkRelationType: + *@ATK_RELATION_NULL: Not used, represens "no relationship" or an error condition. + *@ATK_RELATION_CONTROLLED_BY: Indicates an object controlled by one or more target objects. + *@ATK_RELATION_CONTROLLER_FOR: Indicates an object is an controller for one or more target objects. + *@ATK_RELATION_LABEL_FOR: Indicates an object is a label for one or more target objects. + *@ATK_RELATION_LABELLED_BY: Indicates an object is labelled by one or more target objects. + *@ATK_RELATION_MEMBER_OF: Indicates an object is a member of a group of one or more target objects. + *@ATK_RELATION_NODE_CHILD_OF: Indicates an object is a cell in a treetable which is displayed because a cell in the same column is expanded and identifies that cell. + *@ATK_RELATION_FLOWS_TO: Indicates that the object has content that flows logically to another + * AtkObject in a sequential way, (for instance text-flow). + *@ATK_RELATION_FLOWS_FROM: Indicates that the object has content that flows logically from + * another AtkObject in a sequential way, (for instance text-flow). + *@ATK_RELATION_SUBWINDOW_OF: Indicates a subwindow attached to a component but otherwise has no connection in the UI heirarchy to that component. + *@ATK_RELATION_EMBEDS: Indicates that the object visually embeds + * another object's content, i.e. this object's content flows around + * another's content. + *@ATK_RELATION_EMBEDDED_BY: Reciprocal of %ATK_RELATION_EMBEDS, indicates that + * this object's content is visualy embedded in another object. + *@ATK_RELATION_POPUP_FOR: Indicates that an object is a popup for another object. + *@ATK_RELATION_PARENT_WINDOW_OF: Indicates that an object is a parent window of another object. + *@ATK_RELATION_DESCRIBED_BY: Reciprocal of %ATK_RELATION_DESCRIPTION_FOR. Indicates that one + * or more target objects provide descriptive information about this object. This relation + * type is most appropriate for information that is not essential as its presentation may + * be user-configurable and/or limited to an on-demand mechanism such as an assistive + * technology command. For brief, essential information such as can be found in a widget's + * on-screen label, use %ATK_RELATION_LABELLED_BY. For an on-screen error message, use + * %ATK_RELATION_ERROR_MESSAGE. For lengthy extended descriptive information contained in + * an on-screen object, consider using %ATK_RELATION_DETAILS as assistive technologies may + * provide a means for the user to navigate to objects containing detailed descriptions so + * that their content can be more closely reviewed. + *@ATK_RELATION_DESCRIPTION_FOR: Reciprocal of %ATK_RELATION_DESCRIBED_BY. Indicates that this + * object provides descriptive information about the target object(s). See also + * %ATK_RELATION_DETAILS_FOR and %ATK_RELATION_ERROR_FOR. + *@ATK_RELATION_NODE_PARENT_OF: Indicates an object is a cell in a treetable and is expanded to display other cells in the same column. + *@ATK_RELATION_DETAILS: Reciprocal of %ATK_RELATION_DETAILS_FOR. Indicates that this object + * has a detailed or extended description, the contents of which can be found in the target + * object(s). This relation type is most appropriate for information that is sufficiently + * lengthy as to make navigation to the container of that information desirable. For less + * verbose information suitable for announcement only, see %ATK_RELATION_DESCRIBED_BY. If + * the detailed information describes an error condition, %ATK_RELATION_ERROR_FOR should be + * used instead. @Since: ATK-2.26. + *@ATK_RELATION_DETAILS_FOR: Reciprocal of %ATK_RELATION_DETAILS. Indicates that this object + * provides a detailed or extended description about the target object(s). See also + * %ATK_RELATION_DESCRIPTION_FOR and %ATK_RELATION_ERROR_FOR. @Since: ATK-2.26. + *@ATK_RELATION_ERROR_MESSAGE: Reciprocal of %ATK_RELATION_ERROR_FOR. Indicates that this object + * has one or more errors, the nature of which is described in the contents of the target + * object(s). Objects that have this relation type should also contain %ATK_STATE_INVALID_ENTRY + * in their #AtkStateSet. @Since: ATK-2.26. + *@ATK_RELATION_ERROR_FOR: Reciprocal of %ATK_RELATION_ERROR_MESSAGE. Indicates that this object + * contains an error message describing an invalid condition in the target object(s). @Since: + * ATK_2.26. + *@ATK_RELATION_LAST_DEFINED: Not used, this value indicates the end of the enumeration. + * + *Describes the type of the relation + **/ +typedef enum +{ + ATK_RELATION_NULL = 0, + ATK_RELATION_CONTROLLED_BY, + ATK_RELATION_CONTROLLER_FOR, + ATK_RELATION_LABEL_FOR, + ATK_RELATION_LABELLED_BY, + ATK_RELATION_MEMBER_OF, + ATK_RELATION_NODE_CHILD_OF, + ATK_RELATION_FLOWS_TO, + ATK_RELATION_FLOWS_FROM, + ATK_RELATION_SUBWINDOW_OF, + ATK_RELATION_EMBEDS, + ATK_RELATION_EMBEDDED_BY, + ATK_RELATION_POPUP_FOR, + ATK_RELATION_PARENT_WINDOW_OF, + ATK_RELATION_DESCRIBED_BY, + ATK_RELATION_DESCRIPTION_FOR, + ATK_RELATION_NODE_PARENT_OF, + ATK_RELATION_DETAILS, + ATK_RELATION_DETAILS_FOR, + ATK_RELATION_ERROR_MESSAGE, + ATK_RELATION_ERROR_FOR, + ATK_RELATION_LAST_DEFINED +} AtkRelationType; + +G_END_DECLS + +#endif /* __ATK_RELATION_TYPE_H__ */ diff --git a/other-licenses/atk-1.0/atk/atkselection.h b/other-licenses/atk-1.0/atk/atkselection.h new file mode 100644 index 0000000000..7b16930c1f --- /dev/null +++ b/other-licenses/atk-1.0/atk/atkselection.h @@ -0,0 +1,96 @@ +/* ATK - Accessibility Toolkit + * Copyright 2001 Sun Microsystems Inc. + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either + * version 2 of the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with this library; if not, write to the + * Free Software Foundation, Inc., 59 Temple Place - Suite 330, + * Boston, MA 02111-1307, USA. + */ + +#ifndef __ATK_SELECTION_H__ +#define __ATK_SELECTION_H__ + +#include <atk/atkobject.h> + +#ifdef __cplusplus +extern "C" { +#endif /* __cplusplus */ + +/* + * This AtkSelection interface provides the standard mechanism for an + * assistive technology to determine what the current selected children are, + * as well as modify the selection set. Any object that has children that + * can be selected should support the AtkSelection interface. + */ + +#define ATK_TYPE_SELECTION (atk_selection_get_type ()) +#define ATK_IS_SELECTION(obj) G_TYPE_CHECK_INSTANCE_TYPE ((obj), ATK_TYPE_SELECTION) +#define ATK_SELECTION(obj) G_TYPE_CHECK_INSTANCE_CAST ((obj), ATK_TYPE_SELECTION, AtkSelection) +#define ATK_SELECTION_GET_IFACE(obj) (G_TYPE_INSTANCE_GET_INTERFACE ((obj), ATK_TYPE_SELECTION, AtkSelectionIface)) + +#ifndef _TYPEDEF_ATK_SELECTION_ +#define _TYPEDEF_ATK_SELECTION_ +typedef struct _AtkSelection AtkSelection; +#endif +typedef struct _AtkSelectionIface AtkSelectionIface; + +struct _AtkSelectionIface +{ + GTypeInterface parent; + + gboolean (* add_selection) (AtkSelection *selection, + gint i); + gboolean (* clear_selection) (AtkSelection *selection); + AtkObject* (* ref_selection) (AtkSelection *selection, + gint i); + gint (* get_selection_count) (AtkSelection *selection); + gboolean (* is_child_selected) (AtkSelection *selection, + gint i); + gboolean (* remove_selection) (AtkSelection *selection, + gint i); + gboolean (* select_all_selection) (AtkSelection *selection); + + /* signal handlers */ + + void (*selection_changed) (AtkSelection *selection); + + AtkFunction pad1; + AtkFunction pad2; +}; + +GType atk_selection_get_type (void); + +gboolean atk_selection_add_selection (AtkSelection *selection, + gint i); + +gboolean atk_selection_clear_selection (AtkSelection *selection); + +AtkObject* atk_selection_ref_selection (AtkSelection *selection, + gint i); + +gint atk_selection_get_selection_count (AtkSelection *selection); + +gboolean atk_selection_is_child_selected (AtkSelection *selection, + gint i); + +gboolean atk_selection_remove_selection (AtkSelection *selection, + gint i); + +gboolean atk_selection_select_all_selection (AtkSelection *selection); + +#ifdef __cplusplus +} +#endif /* __cplusplus */ + + +#endif /* __ATK_SELECTION_H__ */ diff --git a/other-licenses/atk-1.0/atk/atksocket.h b/other-licenses/atk-1.0/atk/atksocket.h new file mode 100644 index 0000000000..813d4f3c97 --- /dev/null +++ b/other-licenses/atk-1.0/atk/atksocket.h @@ -0,0 +1,65 @@ +/* ATK - Accessibility Toolkit + * Copyright 2009 Novell, Inc. + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either + * version 2 of the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with this library; if not, write to the + * Free Software Foundation, Inc., 59 Temple Place - Suite 330, + * Boston, MA 02111-1307, USA. + */ + +#if defined(ATK_DISABLE_SINGLE_INCLUDES) && !defined (__ATK_H_INSIDE__) && !defined (ATK_COMPILATION) +#error "Only <atk/atk.h> can be included directly." +#endif + +#ifndef __ATK_SOCKET_H__ +#define __ATK_SOCKET_H__ + +G_BEGIN_DECLS + +#define ATK_TYPE_SOCKET (atk_socket_get_type ()) +#define ATK_SOCKET(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), ATK_TYPE_SOCKET, AtkSocket)) +#define ATK_IS_SOCKET(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), ATK_TYPE_SOCKET)) +#define ATK_SOCKET_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), ATK_TYPE_SOCKET, AtkSocketClass)) +#define ATK_IS_SOCKET_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), ATK_TYPE_SOCKET)) +#define ATK_SOCKET_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), ATK_TYPE_SOCKET, AtkSocketClass)) + +typedef struct _AtkSocket AtkSocket; +typedef struct _AtkSocketClass AtkSocketClass; + +struct _AtkSocket +{ + AtkObject parent; + + /*< private >*/ + gchar* embedded_plug_id; +}; + +GType atk_socket_get_type (void); + +struct _AtkSocketClass +{ + AtkObjectClass parent_class; + + /* to be subscribed to by atk-bridge */ + + /*< protected >*/ + void (* embed) (AtkSocket *obj, gchar* plug_id); +}; + +AtkObject* atk_socket_new (void); +void atk_socket_embed (AtkSocket* obj, gchar* plug_id); +gboolean atk_socket_is_occupied (AtkSocket* obj); + +G_END_DECLS + +#endif /* __ATK_SOCKET_H__ */ diff --git a/other-licenses/atk-1.0/atk/atkstate.h b/other-licenses/atk-1.0/atk/atkstate.h new file mode 100644 index 0000000000..a3912e98da --- /dev/null +++ b/other-licenses/atk-1.0/atk/atkstate.h @@ -0,0 +1,198 @@ +/* ATK - Accessibility Toolkit + * Copyright 2001 Sun Microsystems Inc. + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either + * version 2 of the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with this library; if not, write to the + * Free Software Foundation, Inc., 59 Temple Place - Suite 330, + * Boston, MA 02111-1307, USA. + */ + +#ifndef __ATK_STATE_H__ +#define __ATK_STATE_H__ + +#include <glib-object.h> + +G_BEGIN_DECLS + +/** + *AtkStateType: + *@ATK_STATE_INVALID: Indicates an invalid state - probably an error condition. + *@ATK_STATE_ACTIVE: Indicates a window is currently the active window, or an object is the active subelement within a container or table. ATK_STATE_ACTIVE should not be used for objects which have ATK_STATE_FOCUSABLE or ATK_STATE_SELECTABLE: Those objects should use ATK_STATE_FOCUSED and ATK_STATE_SELECTED respectively. ATK_STATE_ACTIVE is a means to indicate that an object which is not focusable and not selectable is the currently-active item within its parent container. + *@ATK_STATE_ARMED: Indicates that the object is 'armed', i.e. will be activated by if a pointer button-release event occurs within its bounds. Buttons often enter this state when a pointer click occurs within their bounds, as a precursor to activation. ATK_STATE_ARMED has been deprecated since ATK-2.16 and should not be used in newly-written code. + *@ATK_STATE_BUSY: Indicates the current object is busy, i.e. onscreen representation is in the process of changing, or the object is temporarily unavailable for interaction due to activity already in progress. This state may be used by implementors of Document to indicate that content loading is underway. It also may indicate other 'pending' conditions; clients may wish to interrogate this object when the ATK_STATE_BUSY flag is removed. + *@ATK_STATE_CHECKED: Indicates this object is currently checked, for instance a checkbox is 'non-empty'. + *@ATK_STATE_DEFUNCT: Indicates that this object no longer has a valid backing widget (for instance, if its peer object has been destroyed) + *@ATK_STATE_EDITABLE: Indicates that this object can contain text, and that the + * user can change the textual contents of this object by editing those contents + * directly. For an object which is expected to be editable due to its type, but + * which cannot be edited due to the application or platform preventing the user + * from doing so, that object's #AtkStateSet should lack ATK_STATE_EDITABLE and + * should contain ATK_STATE_READ_ONLY. + *@ATK_STATE_ENABLED: Indicates that this object is enabled, i.e. that it currently reflects some application state. Objects that are "greyed out" may lack this state, and may lack the STATE_SENSITIVE if direct user interaction cannot cause them to acquire STATE_ENABLED. See also: ATK_STATE_SENSITIVE + *@ATK_STATE_EXPANDABLE: Indicates this object allows progressive disclosure of its children + *@ATK_STATE_EXPANDED: Indicates this object its expanded - see ATK_STATE_EXPANDABLE above + *@ATK_STATE_FOCUSABLE: Indicates this object can accept keyboard focus, which means all events resulting from typing on the keyboard will normally be passed to it when it has focus + *@ATK_STATE_FOCUSED: Indicates this object currently has the keyboard focus + *@ATK_STATE_HORIZONTAL: Indicates the orientation of this object is horizontal; used, for instance, by objects of ATK_ROLE_SCROLL_BAR. For objects where vertical/horizontal orientation is especially meaningful. + *@ATK_STATE_ICONIFIED: Indicates this object is minimized and is represented only by an icon + *@ATK_STATE_MODAL: Indicates something must be done with this object before the user can interact with an object in a different window + *@ATK_STATE_MULTI_LINE: Indicates this (text) object can contain multiple lines of text + *@ATK_STATE_MULTISELECTABLE: Indicates this object allows more than one of its children to be selected at the same time, or in the case of text objects, that the object supports non-contiguous text selections. + *@ATK_STATE_OPAQUE: Indicates this object paints every pixel within its rectangular region. + *@ATK_STATE_PRESSED: Indicates this object is currently pressed. + *@ATK_STATE_RESIZABLE: Indicates the size of this object is not fixed + *@ATK_STATE_SELECTABLE: Indicates this object is the child of an object that allows its children to be selected and that this child is one of those children that can be selected + *@ATK_STATE_SELECTED: Indicates this object is the child of an object that allows its children to be selected and that this child is one of those children that has been selected + *@ATK_STATE_SENSITIVE: Indicates this object is sensitive, e.g. to user interaction. + * STATE_SENSITIVE usually accompanies STATE_ENABLED for user-actionable controls, + * but may be found in the absence of STATE_ENABLED if the current visible state of the + * control is "disconnected" from the application state. In such cases, direct user interaction + * can often result in the object gaining STATE_SENSITIVE, for instance if a user makes + * an explicit selection using an object whose current state is ambiguous or undefined. + * @see STATE_ENABLED, STATE_INDETERMINATE. + *@ATK_STATE_SHOWING: Indicates this object, the object's parent, the object's parent's parent, and so on, + * are all 'shown' to the end-user, i.e. subject to "exposure" if blocking or obscuring objects do not interpose + * between this object and the top of the window stack. + *@ATK_STATE_SINGLE_LINE: Indicates this (text) object can contain only a single line of text + *@ATK_STATE_STALE: Indicates that the information returned for this object may no longer be + * synchronized with the application state. This is implied if the object has STATE_TRANSIENT, + * and can also occur towards the end of the object peer's lifecycle. It can also be used to indicate that + * the index associated with this object has changed since the user accessed the object (in lieu of + * "index-in-parent-changed" events). + *@ATK_STATE_TRANSIENT: Indicates this object is transient, i.e. a snapshot which may not emit events when its + * state changes. Data from objects with ATK_STATE_TRANSIENT should not be cached, since there may be no + * notification given when the cached data becomes obsolete. + *@ATK_STATE_VERTICAL: Indicates the orientation of this object is vertical + *@ATK_STATE_VISIBLE: Indicates this object is visible, e.g. has been explicitly marked for exposure to the user. + * @note: STATE_VISIBLE is no guarantee that the object is actually unobscured on the screen, only + * that it is 'potentially' visible, barring obstruction, being scrolled or clipped out of the + * field of view, or having an ancestor container that has not yet made visible. + * A widget is potentially onscreen if it has both STATE_VISIBLE and STATE_SHOWING. + * The absence of STATE_VISIBLE and STATE_SHOWING is semantically equivalent to saying + * that an object is 'hidden'. See also STATE_TRUNCATED, which applies if a VISIBLE and SHOWING object + * lies within a viewport which means that its contents are clipped, e.g. a truncated spreadsheet cell or + * an image within a scrolling viewport. Mostly useful for screen-review and magnification algorithms. + *@ATK_STATE_MANAGES_DESCENDANTS: Indicates that "active-descendant-changed" event + * is sent when children become 'active' (i.e. are selected or navigated to onscreen). + * Used to prevent need to enumerate all children in very large containers, like tables. + * The presence of STATE_MANAGES_DESCENDANTS is an indication to the client. + * that the children should not, and need not, be enumerated by the client. + * Objects implementing this state are expected to provide relevant state + * notifications to listening clients, for instance notifications of visibility + * changes and activation of their contained child objects, without the client + * having previously requested references to those children. + *@ATK_STATE_INDETERMINATE: Indicates that the value, or some other quantifiable + * property, of this AtkObject cannot be fully determined. In the case of a large + * data set in which the total number of items in that set is unknown (e.g. 1 of + * 999+), implementors should expose the currently-known set size (999) along + * with this state. In the case of a check box, this state should be used to + * indicate that the check box is a tri-state check box which is currently + * neither checked nor unchecked. + *@ATK_STATE_TRUNCATED: Indicates that an object is truncated, e.g. a text value in a speradsheet cell. + *@ATK_STATE_REQUIRED: Indicates that explicit user interaction with an object is required by the user interface, e.g. a required field in a "web-form" interface. + *@ATK_STATE_INVALID_ENTRY: Indicates that the object has encountered an error condition due to failure of input validation. For instance, a form control may acquire this state in response to invalid or malformed user input. + *@ATK_STATE_SUPPORTS_AUTOCOMPLETION: Indicates that the object in question implements some form of ¨typeahead¨ or + * pre-selection behavior whereby entering the first character of one or more sub-elements + * causes those elements to scroll into view or become selected. Subsequent character input + * may narrow the selection further as long as one or more sub-elements match the string. + * This state is normally only useful and encountered on objects that implement Selection. + * In some cases the typeahead behavior may result in full or partial ¨completion¨ of + * the data in the input field, in which case these input events may trigger text-changed + * events from the AtkText interface. This state supplants @ATK_ROLE_AUTOCOMPLETE. + *@ATK_STATE_SELECTABLE_TEXT:Indicates that the object in question supports text selection. It should only be exposed on objects which implement the Text interface, in order to distinguish this state from @ATK_STATE_SELECTABLE, which infers that the object in question is a selectable child of an object which implements Selection. While similar, text selection and subelement selection are distinct operations. + *@ATK_STATE_DEFAULT: Indicates that the object is the "default" active component, i.e. the object which is activated by an end-user press of the "Enter" or "Return" key. Typically a "close" or "submit" button. + *@ATK_STATE_ANIMATED: Indicates that the object changes its appearance dynamically as an inherent part of its presentation. This state may come and go if an object is only temporarily animated on the way to a 'final' onscreen presentation. + * @note some applications, notably content viewers, may not be able to detect + * all kinds of animated content. Therefore the absence of this state should not + * be taken as definitive evidence that the object's visual representation is + * static; this state is advisory. + *@ATK_STATE_VISITED: Indicates that the object (typically a hyperlink) has already been 'activated', and/or its backing data has already been downloaded, rendered, or otherwise "visited". + *@ATK_STATE_CHECKABLE: Indicates this object has the potential to be + * checked, such as a checkbox or toggle-able table cell. @Since: + * ATK-2.12 + *@ATK_STATE_HAS_POPUP: Indicates that the object has a popup context + * menu or sub-level menu which may or may not be showing. This means + * that activation renders conditional content. Note that ordinary + * tooltips are not considered popups in this context. @Since: ATK-2.12 + *@ATK_STATE_HAS_TOOLTIP: Indicates this object has a tooltip. @Since: ATK-2.16 + *@ATK_STATE_READ_ONLY: Indicates that a widget which is ENABLED and SENSITIVE + * has a value which can be read, but not modified, by the user. Note that this + * state should only be applied to widget types whose value is normally directly + * user modifiable, such as check boxes, radio buttons, spin buttons, text input + * fields, and combo boxes, as a means to convey that the expected interaction + * with that widget is not possible. When the expected interaction with a + * widget does not include modification by the user, as is the case with + * labels and containers, ATK_STATE_READ_ONLY should not be applied. See also + * ATK_STATE_EDITABLE. @Since: ATK-2-16 + *@ATK_STATE_LAST_DEFINED: Not a valid state, used for finding end of enumeration + * + *The possible types of states of an object + **/ +typedef enum +{ + ATK_STATE_INVALID, + ATK_STATE_ACTIVE, + ATK_STATE_ARMED, + ATK_STATE_BUSY, + ATK_STATE_CHECKED, + ATK_STATE_DEFUNCT, + ATK_STATE_EDITABLE, + ATK_STATE_ENABLED, + ATK_STATE_EXPANDABLE, + ATK_STATE_EXPANDED, + ATK_STATE_FOCUSABLE, + ATK_STATE_FOCUSED, + ATK_STATE_HORIZONTAL, + ATK_STATE_ICONIFIED, + ATK_STATE_MODAL, + ATK_STATE_MULTI_LINE, + ATK_STATE_MULTISELECTABLE, + ATK_STATE_OPAQUE, + ATK_STATE_PRESSED, + ATK_STATE_RESIZABLE, + ATK_STATE_SELECTABLE, + ATK_STATE_SELECTED, + ATK_STATE_SENSITIVE, + ATK_STATE_SHOWING, + ATK_STATE_SINGLE_LINE, + ATK_STATE_STALE, + ATK_STATE_TRANSIENT, + ATK_STATE_VERTICAL, + ATK_STATE_VISIBLE, + ATK_STATE_MANAGES_DESCENDANTS, + ATK_STATE_INDETERMINATE, + ATK_STATE_TRUNCATED, + ATK_STATE_REQUIRED, + ATK_STATE_INVALID_ENTRY, + ATK_STATE_SUPPORTS_AUTOCOMPLETION, + ATK_STATE_SELECTABLE_TEXT, + ATK_STATE_DEFAULT, + ATK_STATE_ANIMATED, + ATK_STATE_VISITED, + ATK_STATE_CHECKABLE, + ATK_STATE_HAS_POPUP, + ATK_STATE_HAS_TOOLTIP, + ATK_STATE_READ_ONLY, + ATK_STATE_LAST_DEFINED +} AtkStateType; + +typedef guint64 AtkState; + +AtkStateType atk_state_type_register (const gchar *name); + +const gchar* atk_state_type_get_name (AtkStateType type); +AtkStateType atk_state_type_for_name (const gchar *name); + +G_END_DECLS + +#endif /* __ATK_STATE_H__ */ diff --git a/other-licenses/atk-1.0/atk/atkstateset.h b/other-licenses/atk-1.0/atk/atkstateset.h new file mode 100644 index 0000000000..43c3ea3d1b --- /dev/null +++ b/other-licenses/atk-1.0/atk/atkstateset.h @@ -0,0 +1,81 @@ +/* ATK - Accessibility Toolkit + * Copyright 2001 Sun Microsystems Inc. + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either + * version 2 of the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with this library; if not, write to the + * Free Software Foundation, Inc., 59 Temple Place - Suite 330, + * Boston, MA 02111-1307, USA. + */ + +#ifndef __ATK_STATE_SET_H__ +#define __ATK_STATE_SET_H__ + +#ifdef __cplusplus +extern "C" { +#endif /* __cplusplus */ + +#include <glib-object.h> +#include <atk/atkobject.h> +#include <atk/atkstate.h> + +#define ATK_TYPE_STATE_SET (atk_state_set_get_type ()) +#define ATK_STATE_SET(obj) (G_TYPE_CHECK_INSTANCE_CAST ((obj), ATK_TYPE_STATE_SET, AtkStateSet)) +#define ATK_STATE_SET_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), ATK_TYPE_STATE_SET, AtkStateSetClass)) +#define ATK_IS_STATE_SET(obj) (G_TYPE_CHECK_INSTANCE_TYPE ((obj), ATK_TYPE_STATE_SET)) +#define ATK_IS_STATE_SET_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), ATK_TYPE_STATE_SET)) +#define ATK_STATE_SET_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), ATK_TYPE_STATE_SET, AtkStateSetClass)) + +typedef struct _AtkStateSetClass AtkStateSetClass; + + +struct _AtkStateSet +{ + GObject parent; + +}; + +struct _AtkStateSetClass +{ + GObjectClass parent; +}; + +GType atk_state_set_get_type (void); + +AtkStateSet* atk_state_set_new (void); +gboolean atk_state_set_is_empty (AtkStateSet *set); +gboolean atk_state_set_add_state (AtkStateSet *set, + AtkStateType type); +void atk_state_set_add_states (AtkStateSet *set, + AtkStateType *types, + gint n_types); +void atk_state_set_clear_states (AtkStateSet *set); +gboolean atk_state_set_contains_state (AtkStateSet *set, + AtkStateType type); +gboolean atk_state_set_contains_states (AtkStateSet *set, + AtkStateType *types, + gint n_types); +gboolean atk_state_set_remove_state (AtkStateSet *set, + AtkStateType type); +AtkStateSet* atk_state_set_and_sets (AtkStateSet *set, + AtkStateSet *compare_set); +AtkStateSet* atk_state_set_or_sets (AtkStateSet *set, + AtkStateSet *compare_set); +AtkStateSet* atk_state_set_xor_sets (AtkStateSet *set, + AtkStateSet *compare_set); + +#ifdef __cplusplus +} +#endif /* __cplusplus */ + + +#endif /* __ATK_STATE_SET_H__ */ diff --git a/other-licenses/atk-1.0/atk/atkstreamablecontent.h b/other-licenses/atk-1.0/atk/atkstreamablecontent.h new file mode 100644 index 0000000000..abdbfa9590 --- /dev/null +++ b/other-licenses/atk-1.0/atk/atkstreamablecontent.h @@ -0,0 +1,107 @@ +/* ATK - Accessibility Toolkit + * Copyright 2001 Sun Microsystems Inc. + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either + * version 2 of the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with this library; if not, write to the + * Free Software Foundation, Inc., 59 Temple Place - Suite 330, + * Boston, MA 02111-1307, USA. + */ + +#ifndef __ATK_STREAMABLE_CONTENT_H__ +#define __ATK_STREAMABLE_CONTENT_H__ + +#include <atk/atkobject.h> + +#ifdef __cplusplus +extern "C" { +#endif /* __cplusplus */ + +#define ATK_TYPE_STREAMABLE_CONTENT (atk_streamable_content_get_type ()) +#define ATK_IS_STREAMABLE_CONTENT(obj) G_TYPE_CHECK_INSTANCE_TYPE ((obj), ATK_TYPE_STREAMABLE_CONTENT) +#define ATK_STREAMABLE_CONTENT(obj) G_TYPE_CHECK_INSTANCE_CAST ((obj), ATK_TYPE_STREAMABLE_CONTENT, AtkStreamableContent) +#define ATK_STREAMABLE_CONTENT_GET_IFACE(obj) (G_TYPE_INSTANCE_GET_INTERFACE ((obj), ATK_TYPE_STREAMABLE_CONTENT, AtkStreamableContentIface)) + +#ifndef _TYPEDEF_ATK_STREAMABLE_CONTENT +#define _TYPEDEF_ATK_STREAMABLE_CONTENT +typedef struct _AtkStreamableContent AtkStreamableContent; +#endif +typedef struct _AtkStreamableContentIface AtkStreamableContentIface; + +struct _AtkStreamableContentIface +{ + GTypeInterface parent; + + /* + * Get the number of mime types supported by this object + */ + gint (* get_n_mime_types) (AtkStreamableContent *streamable); + /* + * Gets the specified mime type supported by this object. + * The mime types are 0-based so the first mime type is + * at index 0, the second at index 1 and so on. The mime-type + * at index 0 should be considered the "default" data type for the stream. + * + * This assumes that the strings for the mime types are stored in the + * AtkStreamableContent. Alternatively the G_CONST_RETURN could be removed + * and the caller would be responsible for calling g_free() on the + * returned value. + */ + G_CONST_RETURN gchar* (* get_mime_type) (AtkStreamableContent *streamable, + gint i); + /* + * One possible implementation for this method is that it constructs the + * content appropriate for the mime type and then creates a temporary + * file containing the content, opens the file and then calls + * g_io_channel_unix_new_fd(). + */ + GIOChannel* (* get_stream) (AtkStreamableContent *streamable, + const gchar *mime_type); + +/* + * Returns a string representing a URI in IETF standard format + * (see http://www.ietf.org/rfc/rfc2396.txt) from which the object's content + * may be streamed in the specified mime-type. + * If mime_type is NULL, the URI for the default (and possibly only) mime-type is + * returned. + * + * returns NULL if the mime-type is not supported, or if no URI can be + * constructed. Note that it is possible for get_uri to return NULL but for + * get_stream to work nonetheless, since not all GIOChannels connect to URIs. + */ + G_CONST_RETURN gchar* (* get_uri) (AtkStreamableContent *streamable, + const gchar *mime_type); + + + AtkFunction pad1; + AtkFunction pad2; + AtkFunction pad3; +}; +GType atk_streamable_content_get_type (void); + +gint atk_streamable_content_get_n_mime_types (AtkStreamableContent *streamable); + +G_CONST_RETURN gchar* atk_streamable_content_get_mime_type (AtkStreamableContent *streamable, + gint i); +GIOChannel* atk_streamable_content_get_stream (AtkStreamableContent *streamable, + const gchar *mime_type); + +gchar* atk_streamable_content_get_uri (AtkStreamableContent *streamable, + const gchar *mime_type); + + +#ifdef __cplusplus +} +#endif /* __cplusplus */ + + +#endif /* __ATK_STREAMABLE_CONTENT_H__ */ diff --git a/other-licenses/atk-1.0/atk/atktable.h b/other-licenses/atk-1.0/atk/atktable.h new file mode 100644 index 0000000000..790fbb4481 --- /dev/null +++ b/other-licenses/atk-1.0/atk/atktable.h @@ -0,0 +1,218 @@ +/* ATK - Accessibility Toolkit + * Copyright 2001 Sun Microsystems Inc. + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either + * version 2 of the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with this library; if not, write to the + * Free Software Foundation, Inc., 59 Temple Place - Suite 330, + * Boston, MA 02111-1307, USA. + */ + +#ifndef __ATK_TABLE_H__ +#define __ATK_TABLE_H__ + +#include <atk/atkobject.h> + +#ifdef __cplusplus +extern "C" { +#endif /* __cplusplus */ + +/* + * AtkTable describes a user-interface component that presents data in + * two-dimensional table format. + */ + + +#define ATK_TYPE_TABLE (atk_table_get_type ()) +#define ATK_IS_TABLE(obj) G_TYPE_CHECK_INSTANCE_TYPE ((obj), ATK_TYPE_TABLE) +#define ATK_TABLE(obj) G_TYPE_CHECK_INSTANCE_CAST ((obj), ATK_TYPE_TABLE, AtkTable) +#define ATK_TABLE_GET_IFACE(obj) (G_TYPE_INSTANCE_GET_INTERFACE ((obj), ATK_TYPE_TABLE, AtkTableIface)) + +#ifndef _TYPEDEF_ATK_TABLE_ +#define _TYPEDEF_ATK_TABLE_ +typedef struct _AtkTable AtkTable; +#endif +typedef struct _AtkTableIface AtkTableIface; + +struct _AtkTableIface +{ + GTypeInterface parent; + + AtkObject* (* ref_at) (AtkTable *table, + gint row, + gint column); + gint (* get_index_at) (AtkTable *table, + gint row, + gint column); + gint (* get_column_at_index) (AtkTable *table, + gint index_); + gint (* get_row_at_index) (AtkTable *table, + gint index_); + gint (* get_n_columns) (AtkTable *table); + gint (* get_n_rows) (AtkTable *table); + gint (* get_column_extent_at) (AtkTable *table, + gint row, + gint column); + gint (* get_row_extent_at) (AtkTable *table, + gint row, + gint column); + AtkObject* + (* get_caption) (AtkTable *table); + G_CONST_RETURN gchar* + (* get_column_description) (AtkTable *table, + gint column); + AtkObject* (* get_column_header) (AtkTable *table, + gint column); + G_CONST_RETURN gchar* + (* get_row_description) (AtkTable *table, + gint row); + AtkObject* (* get_row_header) (AtkTable *table, + gint row); + AtkObject* (* get_summary) (AtkTable *table); + void (* set_caption) (AtkTable *table, + AtkObject *caption); + void (* set_column_description) (AtkTable *table, + gint column, + const gchar *description); + void (* set_column_header) (AtkTable *table, + gint column, + AtkObject *header); + void (* set_row_description) (AtkTable *table, + gint row, + const gchar *description); + void (* set_row_header) (AtkTable *table, + gint row, + AtkObject *header); + void (* set_summary) (AtkTable *table, + AtkObject *accessible); + gint (* get_selected_columns) (AtkTable *table, + gint **selected); + gint (* get_selected_rows) (AtkTable *table, + gint **selected); + gboolean (* is_column_selected) (AtkTable *table, + gint column); + gboolean (* is_row_selected) (AtkTable *table, + gint row); + gboolean (* is_selected) (AtkTable *table, + gint row, + gint column); + gboolean (* add_row_selection) (AtkTable *table, + gint row); + gboolean (* remove_row_selection) (AtkTable *table, + gint row); + gboolean (* add_column_selection) (AtkTable *table, + gint column); + gboolean (* remove_column_selection) (AtkTable *table, + gint column); + + /* + * signal handlers + */ + void (* row_inserted) (AtkTable *table, + gint row, + gint num_inserted); + void (* column_inserted) (AtkTable *table, + gint column, + gint num_inserted); + void (* row_deleted) (AtkTable *table, + gint row, + gint num_deleted); + void (* column_deleted) (AtkTable *table, + gint column, + gint num_deleted); + void (* row_reordered) (AtkTable *table); + void (* column_reordered) (AtkTable *table); + void (* model_changed) (AtkTable *table); + + AtkFunction pad1; + AtkFunction pad2; + AtkFunction pad3; + AtkFunction pad4; +}; + +GType atk_table_get_type (void); + +AtkObject* atk_table_ref_at (AtkTable *table, + gint row, + gint column); +gint atk_table_get_index_at (AtkTable *table, + gint row, + gint column); +gint atk_table_get_column_at_index (AtkTable *table, + gint index_); +gint atk_table_get_row_at_index (AtkTable *table, + gint index_); +gint atk_table_get_n_columns (AtkTable *table); +gint atk_table_get_n_rows (AtkTable *table); +gint atk_table_get_column_extent_at (AtkTable *table, + gint row, + gint column); +gint atk_table_get_row_extent_at (AtkTable *table, + gint row, + gint column); +AtkObject* + atk_table_get_caption (AtkTable *table); +G_CONST_RETURN gchar* + atk_table_get_column_description (AtkTable *table, + gint column); +AtkObject* atk_table_get_column_header (AtkTable *table, + gint column); +G_CONST_RETURN gchar* + atk_table_get_row_description (AtkTable *table, + gint row); +AtkObject* atk_table_get_row_header (AtkTable *table, + gint row); +AtkObject* atk_table_get_summary (AtkTable *table); +void atk_table_set_caption (AtkTable *table, + AtkObject *caption); +void atk_table_set_column_description + (AtkTable *table, + gint column, + const gchar *description); +void atk_table_set_column_header (AtkTable *table, + gint column, + AtkObject *header); +void atk_table_set_row_description (AtkTable *table, + gint row, + const gchar *description); +void atk_table_set_row_header (AtkTable *table, + gint row, + AtkObject *header); +void atk_table_set_summary (AtkTable *table, + AtkObject *accessible); +gint atk_table_get_selected_columns (AtkTable *table, + gint **selected); +gint atk_table_get_selected_rows (AtkTable *table, + gint **selected); +gboolean atk_table_is_column_selected (AtkTable *table, + gint column); +gboolean atk_table_is_row_selected (AtkTable *table, + gint row); +gboolean atk_table_is_selected (AtkTable *table, + gint row, + gint column); +gboolean atk_table_add_row_selection (AtkTable *table, + gint row); +gboolean atk_table_remove_row_selection (AtkTable *table, + gint row); +gboolean atk_table_add_column_selection (AtkTable *table, + gint column); +gboolean atk_table_remove_column_selection + (AtkTable *table, + gint column); + +#ifdef __cplusplus +} +#endif /* __cplusplus */ + + +#endif /* __ATK_TABLE_H__ */ diff --git a/other-licenses/atk-1.0/atk/atktablecell.h b/other-licenses/atk-1.0/atk/atktablecell.h new file mode 100644 index 0000000000..0e70d69ca6 --- /dev/null +++ b/other-licenses/atk-1.0/atk/atktablecell.h @@ -0,0 +1,104 @@ +/* ATK - Accessibility Toolkit + * Copyright 2014 SUSE LLC. + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either + * version 2 of the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with this library; if not, write to the + * Free Software Foundation, Inc., 59 Temple Place - Suite 330, + * Boston, MA 02111-1307, USA. + */ + +#if defined(ATK_DISABLE_SINGLE_INCLUDES) && !defined (__ATK_H_INSIDE__) && !defined (ATK_COMPILATION) +#error "Only <atk/atk.h> can be included directly." +#endif + +#ifndef __ATK_TABLE_CELL_H__ +#define __ATK_TABLE_CELL_H__ + +#include <atk/atkobject.h> + +G_BEGIN_DECLS + +#define ATK_TYPE_TABLE_CELL (atk_table_cell_get_type ()) +#define ATK_IS_TABLE_CELL(obj) G_TYPE_CHECK_INSTANCE_TYPE ((obj), ATK_TYPE_TABLE_CELL) +#define ATK_TABLE_CELL(obj) G_TYPE_CHECK_INSTANCE_CAST ((obj), ATK_TYPE_TABLE_CELL, AtkTableCell) +#define ATK_TABLE_CELL_GET_IFACE(obj) (G_TYPE_INSTANCE_GET_INTERFACE ((obj), ATK_TYPE_TABLE_CELL, AtkTableCellIface)) + +#ifndef _TYPEDEF_ATK_TABLE_CELL_ +#define _TYPEDEF_ATK_TABLE_CELL_ +typedef struct _AtkTableCell AtkTableCell; +#endif +typedef struct _AtkTableCellIface AtkTableCellIface; + +/** + * AtkTableCellIface: + * @get_column_span: virtual function that returns the number of + * columns occupied by this cell accessible. @Since: 2.12 + * @get_column_header_cells: virtual function that returns the column + * headers as an array of cell accessibles. @Since: 2.12 + * @get_position: virtual function that retrieves the tabular position + * of this cell. @Since: 2.12 + * @get_row_span: virtual function that returns the number of rows + * occupied by this cell. @Since: 2.12 + * @get_row_header_cells: virtual function that returns the row + * headers as an array of cell accessibles. @Since: 2.12 + * @get_row_column_span: virtual function that get the row an column + * indexes and span of this cell. @Since: 2.12 + * @get_table: virtual function that returns a reference to the + * accessible of the containing table. @Since: 2.12 + */ +struct _AtkTableCellIface +{ + GTypeInterface parent; + + gint (*get_column_span) (AtkTableCell *cell); + GPtrArray * (*get_column_header_cells) (AtkTableCell *cell); + gboolean (*get_position) (AtkTableCell *cell, + gint *row, + gint *column); + gint (*get_row_span) (AtkTableCell *cell); + GPtrArray * (*get_row_header_cells) (AtkTableCell *cell); + gboolean (*get_row_column_span) (AtkTableCell *cell, + gint *row, + gint *column, + gint *row_span, + gint *column_span); + AtkObject * (*get_table) (AtkTableCell *cell); +}; + +ATK_AVAILABLE_IN_2_12 +GType atk_table_cell_get_type (void); + +ATK_AVAILABLE_IN_2_12 +gint atk_table_cell_get_column_span (AtkTableCell *cell); +ATK_AVAILABLE_IN_2_12 +GPtrArray * atk_table_cell_get_column_header_cells (AtkTableCell *cell); +ATK_AVAILABLE_IN_2_12 +gboolean atk_table_cell_get_position (AtkTableCell *cell, + gint *row, + gint *column); +ATK_AVAILABLE_IN_2_12 +gint atk_table_cell_get_row_span (AtkTableCell *cell); +ATK_AVAILABLE_IN_2_12 +GPtrArray * atk_table_cell_get_row_header_cells (AtkTableCell *cell); +ATK_AVAILABLE_IN_2_12 +gboolean atk_table_cell_get_row_column_span (AtkTableCell *cell, + gint *row, + gint *column, + gint *row_span, + gint *column_span); +ATK_AVAILABLE_IN_2_12 +AtkObject * atk_table_cell_get_table (AtkTableCell *cell); + +G_END_DECLS + +#endif /* __ATK_TABLE_CELL_H__ */ diff --git a/other-licenses/atk-1.0/atk/atktext.h b/other-licenses/atk-1.0/atk/atktext.h new file mode 100644 index 0000000000..9b01b25a9f --- /dev/null +++ b/other-licenses/atk-1.0/atk/atktext.h @@ -0,0 +1,436 @@ +/* ATK - The Accessibility Toolkit for GTK+ + * Copyright 2001 Sun Microsystems Inc. + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either + * version 2 of the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with this library; if not, write to the + * Free Software Foundation, Inc., 59 Temple Place - Suite 330, + * Boston, MA 02111-1307, USA. + */ + + +#ifndef __ATK_TEXT_H__ +#define __ATK_TEXT_H__ + +#include <glib-object.h> +#include <atk/atkobject.h> +#include <atk/atkutil.h> + +#ifdef __cplusplus +extern "C" { +#endif /* __cplusplus */ + +/** + *AtkTextAttribute + *@ATK_TEXT_ATTR_INVALID: Invalid attribute + *@ATK_TEXT_ATTR_LEFT_MARGIN: The pixel width of the left margin + *@ATK_TEXT_ATTR_RIGHT_MARGIN: The pixel width of the right margin + *@ATK_TEXT_ATTR_INDENT: The number of pixels that the text is indented + *@ATK_TEXT_ATTR_INVISIBLE: Either "true" or "false" indicating whether text is visible or not + *@ATK_TEXT_ATTR_EDITABLE: Either "true" or "false" indicating whether text is editable or not + *@ATK_TEXT_ATTR_PIXELS_ABOVE_LINES: Pixels of blank space to leave above each newline-terminated line. + *@ATK_TEXT_ATTR_PIXELS_BELOW_LINES: Pixels of blank space to leave below each newline-terminated line. + *@ATK_TEXT_ATTR_PIXELS_INSIDE_WRAP: Pixels of blank space to leave between wrapped lines inside the same newline-terminated line (paragraph). + *@ATK_TEXT_ATTR_BG_FULL_HEIGHT: "true" or "false" whether to make the background color for each character the height of the highest font used on the current line, or the height of the font used for the current character. + *@ATK_TEXT_ATTR_RISE: Number of pixels that the characters are risen above the baseline + *@ATK_TEXT_ATTR_UNDERLINE: "none", "single", "double" or "low" + *@ATK_TEXT_ATTR_STRIKETHROUGH: "true" or "false" whether the text is strikethrough + *@ATK_TEXT_ATTR_SIZE: The size of the characters. + *@ATK_TEXT_ATTR_SCALE: The scale of the characters. The value is a string representation of a double + *@ATK_TEXT_ATTR_WEIGHT: The weight of the characters. + *@ATK_TEXT_ATTR_LANGUAGE: The language used + *@ATK_TEXT_ATTR_FAMILY_NAME: The font family name + *@ATK_TEXT_ATTR_BG_COLOR: The background color. The value is an RGB value of the format "%u,%u,%u" + *@ATK_TEXT_ATTR_FG_COLOR:The foreground color. The value is an RGB value of the format "%u,%u,%u" + *@ATK_TEXT_ATTR_BG_STIPPLE: "true" if a #GdkBitmap is set for stippling the background color. + *@ATK_TEXT_ATTR_FG_STIPPLE: "true" if a #GdkBitmap is set for stippling the foreground color. + *@ATK_TEXT_ATTR_WRAP_MODE: The wrap mode of the text, if any. Values are "none", "char" or "word" + *@ATK_TEXT_ATTR_DIRECTION: The direction of the text, if set. Values are "none", "ltr" or "rtl" + *@ATK_TEXT_ATTR_JUSTIFICATION: The justification of the text, if set. Values are "left", "right", "center" or "fill" + *@ATK_TEXT_ATTR_STRETCH: The stretch of the text, if set. Values are "ultra_condensed", "extra_condensed", "condensed", "semi_condensed", "normal", "semi_expanded", "expanded", "extra_expanded" or "ultra_expanded" + *@ATK_TEXT_ATTR_VARIANT: The capitalization variant of the text, if set. Values are "normal" or "small_caps" + *@ATK_TEXT_ATTR_STYLE: The slant style of the text, if set. Values are "normal", "oblique" or "italic" + *@ATK_TEXT_ATTR_LAST_DEFINED: not a valid text attribute, used for finding end of enumeration + * + * Describes the text attributes supported + **/ +typedef enum +{ + ATK_TEXT_ATTR_INVALID = 0, + ATK_TEXT_ATTR_LEFT_MARGIN, + ATK_TEXT_ATTR_RIGHT_MARGIN, + ATK_TEXT_ATTR_INDENT, + ATK_TEXT_ATTR_INVISIBLE, + ATK_TEXT_ATTR_EDITABLE, + ATK_TEXT_ATTR_PIXELS_ABOVE_LINES, + ATK_TEXT_ATTR_PIXELS_BELOW_LINES, + ATK_TEXT_ATTR_PIXELS_INSIDE_WRAP, + ATK_TEXT_ATTR_BG_FULL_HEIGHT, + ATK_TEXT_ATTR_RISE, + ATK_TEXT_ATTR_UNDERLINE, + ATK_TEXT_ATTR_STRIKETHROUGH, + ATK_TEXT_ATTR_SIZE, + ATK_TEXT_ATTR_SCALE, + ATK_TEXT_ATTR_WEIGHT, + ATK_TEXT_ATTR_LANGUAGE, + ATK_TEXT_ATTR_FAMILY_NAME, + ATK_TEXT_ATTR_BG_COLOR, + ATK_TEXT_ATTR_FG_COLOR, + ATK_TEXT_ATTR_BG_STIPPLE, + ATK_TEXT_ATTR_FG_STIPPLE, + ATK_TEXT_ATTR_WRAP_MODE, + ATK_TEXT_ATTR_DIRECTION, + ATK_TEXT_ATTR_JUSTIFICATION, + ATK_TEXT_ATTR_STRETCH, + ATK_TEXT_ATTR_VARIANT, + ATK_TEXT_ATTR_STYLE, + ATK_TEXT_ATTR_LAST_DEFINED +} AtkTextAttribute; + +AtkTextAttribute atk_text_attribute_register (const gchar *name); + + +#define ATK_TYPE_TEXT (atk_text_get_type ()) +#define ATK_IS_TEXT(obj) G_TYPE_CHECK_INSTANCE_TYPE ((obj), ATK_TYPE_TEXT) +#define ATK_TEXT(obj) G_TYPE_CHECK_INSTANCE_CAST ((obj), ATK_TYPE_TEXT, AtkText) +#define ATK_TEXT_GET_IFACE(obj) (G_TYPE_INSTANCE_GET_INTERFACE ((obj), ATK_TYPE_TEXT, AtkTextIface)) + +#ifndef _TYPEDEF_ATK_TEXT_ +#define _TYPEDEF_ATK_TEXT_ +typedef struct _AtkText AtkText; +#endif +typedef struct _AtkTextIface AtkTextIface; + +/** + *AtkTextBoundary: + *@ATK_TEXT_BOUNDARY_CHAR: Boundary is the boundary between characters + * (including non-printing characters) + *@ATK_TEXT_BOUNDARY_WORD_START: Boundary is the start (i.e. first character) of a word. + *@ATK_TEXT_BOUNDARY_WORD_END: Boundary is the end (i.e. last character) of a word. + *@ATK_TEXT_BOUNDARY_SENTENCE_START: Boundary is the first character in a sentence. + *@ATK_TEXT_BOUNDARY_SENTENCE_END: Boundary is the last (terminal) character in a sentence; + * in languages which use "sentence stop" punctuation such as English, the boundary is thus the + * '.', '?', or similar terminal punctuation character. + *@ATK_TEXT_BOUNDARY_LINE_START: Boundary is the initial character of the content or a + * character immediately following a newline, linefeed, or return character. + *@ATK_TEXT_BOUNDARY_LINE_END: Boundary is the linefeed, or return character. + * + *Text boundary types used for specifying boundaries for regions of text + **/ +typedef enum { + ATK_TEXT_BOUNDARY_CHAR, + ATK_TEXT_BOUNDARY_WORD_START, + ATK_TEXT_BOUNDARY_WORD_END, + ATK_TEXT_BOUNDARY_SENTENCE_START, + ATK_TEXT_BOUNDARY_SENTENCE_END, + ATK_TEXT_BOUNDARY_LINE_START, + ATK_TEXT_BOUNDARY_LINE_END +} AtkTextBoundary; + +/** + *AtkTextGranularity: + *@ATK_TEXT_GRANULARITY_CHAR: Granularity is defined by the boundaries between characters + * (including non-printing characters) + *@ATK_TEXT_GRANULARITY_WORD: Granularity is defined by the boundaries of a word, + * starting at the beginning of the current word and finishing at the beginning of + * the following one, if present. + *@ATK_TEXT_GRANULARITY_SENTENCE: Granularity is defined by the boundaries of a sentence, + * starting at the beginning of the current sentence and finishing at the beginning of + * the following one, if present. + *@ATK_TEXT_GRANULARITY_LINE: Granularity is defined by the boundaries of a line, + * starting at the beginning of the current line and finishing at the beginning of + * the following one, if present. + *@ATK_TEXT_GRANULARITY_PARAGRAPH: Granularity is defined by the boundaries of a paragraph, + * starting at the beginning of the current paragraph and finishing at the beginning of + * the following one, if present. + * + * Text granularity types used for specifying the granularity of the region of + * text we are interested in. + **/ +typedef enum { + ATK_TEXT_GRANULARITY_CHAR, + ATK_TEXT_GRANULARITY_WORD, + ATK_TEXT_GRANULARITY_SENTENCE, + ATK_TEXT_GRANULARITY_LINE, + ATK_TEXT_GRANULARITY_PARAGRAPH +} AtkTextGranularity; + +/** + * AtkTextRectangle: + * @x: The horizontal coordinate of a rectangle + * @y: The vertical coordinate of a rectangle + * @width: The width of a rectangle + * @height: The height of a rectangle + * + * A structure used to store a rectangle used by AtkText. + **/ + +typedef struct _AtkTextRectangle AtkTextRectangle; + +struct _AtkTextRectangle { + gint x; + gint y; + gint width; + gint height; +}; + +/** + * AtkTextRange: + * @bounds: A rectangle giving the bounds of the text range + * @start_offset: The start offset of a AtkTextRange + * @end_offset: The end offset of a AtkTextRange + * @content: The text in the text range + * + * A structure used to describe a text range. + **/ +typedef struct _AtkTextRange AtkTextRange; + +struct _AtkTextRange { + AtkTextRectangle bounds; + gint start_offset; + gint end_offset; + gchar* content; +}; + +/** + *AtkTextClipType + *@ATK_TEXT_CLIP_NONE: No clipping to be done + *@ATK_TEXT_CLIP_MIN: Text clipped by min coordinate is omitted + *@ATK_TEXT_CLIP_MAX: Text clipped by max coordinate is omitted + *@ATK_TEXT_CLIP_BOTH: Only text fully within mix/max bound is retained + * + *Describes the type of clipping required. + **/ +typedef enum { + ATK_TEXT_CLIP_NONE, + ATK_TEXT_CLIP_MIN, + ATK_TEXT_CLIP_MAX, + ATK_TEXT_CLIP_BOTH +} AtkTextClipType; + +struct _AtkTextIface +{ + GTypeInterface parent; + + gchar* (* get_text) (AtkText *text, + gint start_offset, + gint end_offset); + gchar* (* get_text_after_offset) (AtkText *text, + gint offset, + AtkTextBoundary boundary_type, + gint *start_offset, + gint *end_offset); + gchar* (* get_text_at_offset) (AtkText *text, + gint offset, + AtkTextBoundary boundary_type, + gint *start_offset, + gint *end_offset); + gunichar (* get_character_at_offset) (AtkText *text, + gint offset); + gchar* (* get_text_before_offset) (AtkText *text, + gint offset, + AtkTextBoundary boundary_type, + gint *start_offset, + gint *end_offset); + gint (* get_caret_offset) (AtkText *text); + AtkAttributeSet* (* get_run_attributes) (AtkText *text, + gint offset, + gint *start_offset, + gint *end_offset); + AtkAttributeSet* (* get_default_attributes) (AtkText *text); + void (* get_character_extents) (AtkText *text, + gint offset, + gint *x, + gint *y, + gint *width, + gint *height, + AtkCoordType coords); + gint (* get_character_count) (AtkText *text); + gint (* get_offset_at_point) (AtkText *text, + gint x, + gint y, + AtkCoordType coords); + gint (* get_n_selections) (AtkText *text); + gchar* (* get_selection) (AtkText *text, + gint selection_num, + gint *start_offset, + gint *end_offset); + gboolean (* add_selection) (AtkText *text, + gint start_offset, + gint end_offset); + gboolean (* remove_selection) (AtkText *text, + gint selection_num); + gboolean (* set_selection) (AtkText *text, + gint selection_num, + gint start_offset, + gint end_offset); + gboolean (* set_caret_offset) (AtkText *text, + gint offset); + + /* + * signal handlers + */ + void (* text_changed) (AtkText *text, + gint position, + gint length); + void (* text_caret_moved) (AtkText *text, + gint location); + void (* text_selection_changed) (AtkText *text); + + void (* text_attributes_changed) (AtkText *text); + + + void (* get_range_extents) (AtkText *text, + gint start_offset, + gint end_offset, + AtkCoordType coord_type, + AtkTextRectangle *rect); + + AtkTextRange** (* get_bounded_ranges) (AtkText *text, + AtkTextRectangle *rect, + AtkCoordType coord_type, + AtkTextClipType x_clip_type, + AtkTextClipType y_clip_type); + + gchar* (* get_string_at_offset) (AtkText *text, + gint offset, + AtkTextGranularity granularity, + gint *start_offset, + gint *end_offset); + /* + * Scrolls this text range so it becomes visible on the screen. + * + * scroll_substring_to lets the implementation compute an appropriate target + * position on the screen, with type used as a positioning hint. + * + * scroll_substring_to_point lets the client specify a precise target position + * on the screen. + * + * Since ATK 2.32 + */ + gboolean (* scroll_substring_to) (AtkText *text, + gint start_offset, + gint end_offset, + AtkScrollType type); + gboolean (* scroll_substring_to_point) (AtkText *text, + gint start_offset, + gint end_offset, + AtkCoordType coords, + gint x, + gint y); +}; + +GType atk_text_get_type (void); + + +/* + * Additional AtkObject properties used by AtkText: + * "accessible_text" (accessible text has changed) + * "accessible_caret" (accessible text cursor position changed: + * editable text only) + */ + +gchar* atk_text_get_text (AtkText *text, + gint start_offset, + gint end_offset); +gunichar atk_text_get_character_at_offset (AtkText *text, + gint offset); +gchar* atk_text_get_text_after_offset (AtkText *text, + gint offset, + AtkTextBoundary boundary_type, + gint *start_offset, + gint *end_offset); +gchar* atk_text_get_text_at_offset (AtkText *text, + gint offset, + AtkTextBoundary boundary_type, + gint *start_offset, + gint *end_offset); +gchar* atk_text_get_text_before_offset (AtkText *text, + gint offset, + AtkTextBoundary boundary_type, + gint *start_offset, + gint *end_offset); +gchar* atk_text_get_string_at_offset (AtkText *text, + gint offset, + AtkTextGranularity granularity, + gint *start_offset, + gint *end_offset); +gint atk_text_get_caret_offset (AtkText *text); +void atk_text_get_character_extents (AtkText *text, + gint offset, + gint *x, + gint *y, + gint *width, + gint *height, + AtkCoordType coords); +AtkAttributeSet* atk_text_get_run_attributes (AtkText *text, + gint offset, + gint *start_offset, + gint *end_offset); +AtkAttributeSet* atk_text_get_default_attributes (AtkText *text); +gint atk_text_get_character_count (AtkText *text); +gint atk_text_get_offset_at_point (AtkText *text, + gint x, + gint y, + AtkCoordType coords); +gint atk_text_get_n_selections (AtkText *text); +gchar* atk_text_get_selection (AtkText *text, + gint selection_num, + gint *start_offset, + gint *end_offset); +gboolean atk_text_add_selection (AtkText *text, + gint start_offset, + gint end_offset); +gboolean atk_text_remove_selection (AtkText *text, + gint selection_num); +gboolean atk_text_set_selection (AtkText *text, + gint selection_num, + gint start_offset, + gint end_offset); +gboolean atk_text_set_caret_offset (AtkText *text, + gint offset); +void atk_text_get_range_extents (AtkText *text, + + gint start_offset, + gint end_offset, + AtkCoordType coord_type, + AtkTextRectangle *rect); +AtkTextRange** atk_text_get_bounded_ranges (AtkText *text, + AtkTextRectangle *rect, + AtkCoordType coord_type, + AtkTextClipType x_clip_type, + AtkTextClipType y_clip_type); +void atk_text_free_ranges (AtkTextRange **ranges); +void atk_attribute_set_free (AtkAttributeSet *attrib_set); +G_CONST_RETURN gchar* atk_text_attribute_get_name (AtkTextAttribute attr); +AtkTextAttribute atk_text_attribute_for_name (const gchar *name); +G_CONST_RETURN gchar* atk_text_attribute_get_value (AtkTextAttribute attr, + gint index_); + +gboolean atk_text_scroll_substring_to (AtkText *text, + gint start_offset, + gint end_offset, + AtkScrollType type); + +gboolean atk_text_scroll_substring_to_point (AtkText *text, + gint start_offset, + gint end_offset, + AtkCoordType coords, + gint x, + gint y); + +#ifdef __cplusplus +} +#endif /* __cplusplus */ + + +#endif /* __ATK_TEXT_H__ */ diff --git a/other-licenses/atk-1.0/atk/atkutil.h b/other-licenses/atk-1.0/atk/atkutil.h new file mode 100644 index 0000000000..728a10685d --- /dev/null +++ b/other-licenses/atk-1.0/atk/atkutil.h @@ -0,0 +1,245 @@ +/* ATK - Accessibility Toolkit + * Copyright 2001 Sun Microsystems Inc. + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either + * version 2 of the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with this library; if not, write to the + * Free Software Foundation, Inc., 59 Temple Place - Suite 330, + * Boston, MA 02111-1307, USA. + */ + +#ifndef __ATK_UTIL_H__ +#define __ATK_UTIL_H__ + +#include <atk/atkobject.h> + +#ifdef __cplusplus +extern "C" { +#endif /* __cplusplus */ + +#define ATK_TYPE_UTIL (atk_util_get_type ()) +#define ATK_IS_UTIL(obj) G_TYPE_CHECK_INSTANCE_TYPE ((obj), ATK_TYPE_UTIL) +#define ATK_UTIL(obj) G_TYPE_CHECK_INSTANCE_CAST ((obj), ATK_TYPE_UTIL, AtkUtil) +#define ATK_UTIL_CLASS(klass) (G_TYPE_CHECK_CLASS_CAST ((klass), ATK_TYPE_UTIL, AtkUtilClass)) +#define ATK_IS_UTIL_CLASS(klass) (G_TYPE_CHECK_CLASS_TYPE ((klass), ATK_TYPE_UTIL)) +#define ATK_UTIL_GET_CLASS(obj) (G_TYPE_INSTANCE_GET_CLASS ((obj), ATK_TYPE_UTIL, AtkUtilClass)) + + +#ifndef _TYPEDEF_ATK_UTIL_ +#define _TYPEDEF_ATK_UTIL_ +typedef struct _AtkUtil AtkUtil; +typedef struct _AtkUtilClass AtkUtilClass; +typedef struct _AtkKeyEventStruct AtkKeyEventStruct; +#endif + +/** + * AtkEventListener: + * @obj: An #AtkObject instance for whom the callback will be called when + * the specified event (e.g. 'focus:') takes place. + * + * A function which is called when an object emits a matching event, + * as used in #atk_add_focus_tracker. + * Currently the only events for which object-specific handlers are + * supported are events of type "focus:". Most clients of ATK will prefer to + * attach signal handlers for the various ATK signals instead. + * + * @see: atk_add_focus_tracker. + **/ +typedef void (*AtkEventListener) (AtkObject* obj); +/** + * AtkEventListenerInit: + * + * An #AtkEventListenerInit function is a special function that is + * called in order to initialize the per-object event registration system + * used by #AtkEventListener, if any preparation is required. + * + * @see: atk_focus_tracker_init. + **/ +typedef void (*AtkEventListenerInit) (void); +/** + * AtkKeySnoopFunc: + * @event: an AtkKeyEventStruct containing information about the key event for which + * notification is being given. + * @func_data: a block of data which will be passed to the event listener, on notification. + * + * An #AtkKeySnoopFunc is a type of callback which is called whenever a key event occurs, + * if registered via atk_add_key_event_listener. It allows for pre-emptive + * interception of key events via the return code as described below. + * + * Returns: TRUE (nonzero) if the event emission should be stopped and the event + * discarded without being passed to the normal GUI recipient; FALSE (zero) if the + * event dispatch to the client application should proceed as normal. + * + * @see: atk_add_key_event_listener. + **/ +typedef gint (*AtkKeySnoopFunc) (AtkKeyEventStruct *event, + gpointer func_data); + +/** + * AtkKeyEventStruct: + * @type: An AtkKeyEventType, generally one of ATK_KEY_EVENT_PRESS or ATK_KEY_EVENT_RELEASE + * @state: A bitmask representing the state of the modifier keys immediately after the event takes place. + * The meaning of the bits is currently defined to match the bitmask used by GDK in + * GdkEventType.state, see + * http://developer.gnome.org/doc/API/2.0/gdk/gdk-Event-Structures.html#GdkEventKey + * @keyval: A guint representing a keysym value corresponding to those used by GDK and X11: see + * /usr/X11/include/keysymdef.h. + * @length: The length of member #string. + * @string: A string containing one of the following: either a string approximating the text that would + * result from this keypress, if the key is a control or graphic character, or a symbolic name for this keypress. + * Alphanumeric and printable keys will have the symbolic key name in this string member, for instance "A". "0", + * "semicolon", "aacute". Keypad keys have the prefix "KP". + * @keycode: The raw hardware code that generated the key event. This field is raraly useful. + * @timestamp: A timestamp in milliseconds indicating when the event occurred. + * These timestamps are relative to a starting point which should be considered arbitrary, + * and only used to compare the dispatch times of events to one another. + * + * Encapsulates information about a key event. + **/ +struct _AtkKeyEventStruct { + gint type; + guint state; + guint keyval; + gint length; + gchar *string; + guint16 keycode; + guint32 timestamp; +}; + +/** + *AtkKeyEventType: + *@ATK_KEY_EVENT_PRESS: specifies a key press event + *@ATK_KEY_EVENT_RELEASE: specifies a key release event + *@ATK_KEY_EVENT_LAST_DEFINED: Not a valid value; specifies end of enumeration + * + *Specifies the type of a keyboard evemt. + **/ +typedef enum +{ + ATK_KEY_EVENT_PRESS, + ATK_KEY_EVENT_RELEASE, + ATK_KEY_EVENT_LAST_DEFINED +} AtkKeyEventType; + +struct _AtkUtil +{ + GObject parent; +}; + +struct _AtkUtilClass +{ + GObjectClass parent; + guint (* add_global_event_listener) (GSignalEmissionHook listener, + const gchar *event_type); + void (* remove_global_event_listener) (guint listener_id); + guint (* add_key_event_listener) (AtkKeySnoopFunc listener, + gpointer data); + void (* remove_key_event_listener) (guint listener_id); + AtkObject* (* get_root) (void); + G_CONST_RETURN gchar* (* get_toolkit_name) (void); + G_CONST_RETURN gchar* (* get_toolkit_version) (void); +}; +GType atk_util_get_type (void); + +/** + *AtkCoordType: + *@ATK_XY_SCREEN: specifies xy coordinates relative to the screen + *@ATK_XY_WINDOW: specifies xy coordinates relative to the widget's + * top-level window + *@ATK_XY_PARENT: specifies xy coordinates relative to the widget's + * immediate parent. + * + *Specifies how xy coordinates are to be interpreted. Used by functions such + *as atk_component_get_position() and atk_text_get_character_extents() + **/ +typedef enum { + ATK_XY_SCREEN, + ATK_XY_WINDOW, + ATK_XY_PARENT +}AtkCoordType; + +/* + * Adds the specified function to the list of functions to be called + * when an object receives focus. + */ +guint atk_add_focus_tracker (AtkEventListener focus_tracker); + +/* + * Removes the specified focus tracker from the list of function + * to be called when any object receives focus + */ +void atk_remove_focus_tracker (guint tracker_id); + +/* + * atk_focus_tracker_init: + * @init: An #AtkEventListenerInit function to be called + * prior to any focus-tracking requests. + * + * Specifies the function to be called for focus tracker initialization. + * removal. This function should be called by an implementation of the + * ATK interface if any specific work needs to be done to enable + * focus tracking. + */ +void atk_focus_tracker_init (AtkEventListenerInit init); + +/* + * Cause the focus tracker functions which have been specified to be + * executed for the object. + */ +void atk_focus_tracker_notify (AtkObject *object); + +/* + * Adds the specified function to the list of functions to be called + * when an event of type event_type occurs. + */ +guint atk_add_global_event_listener (GSignalEmissionHook listener, + const gchar *event_type); + +/* + * Removes the specified event listener + */ +void atk_remove_global_event_listener (guint listener_id); + +/* + * Adds the specified function to the list of functions to be called + * when an keyboard event occurs. + */ +guint atk_add_key_event_listener (AtkKeySnoopFunc listener, gpointer data); + +/* + * Removes the specified event listener + */ +void atk_remove_key_event_listener (guint listener_id); + +/* + * Returns the root accessible container for the current application. + */ +AtkObject* atk_get_root(void); + +AtkObject* atk_get_focus_object (void); + +/* + * Returns name string for the GUI toolkit. + */ +G_CONST_RETURN gchar *atk_get_toolkit_name (void); + +/* + * Returns version string for the GUI toolkit. + */ +G_CONST_RETURN gchar *atk_get_toolkit_version (void); + +#ifdef __cplusplus +} +#endif /* __cplusplus */ + + +#endif /* __ATK_UTIL_H__ */ diff --git a/other-licenses/atk-1.0/atk/atkvalue.h b/other-licenses/atk-1.0/atk/atkvalue.h new file mode 100644 index 0000000000..f66c015284 --- /dev/null +++ b/other-licenses/atk-1.0/atk/atkvalue.h @@ -0,0 +1,95 @@ +/* ATK - Accessibility Toolkit + * Copyright 2001 Sun Microsystems Inc. + * + * This library is free software; you can redistribute it and/or + * modify it under the terms of the GNU Library General Public + * License as published by the Free Software Foundation; either + * version 2 of the License, or (at your option) any later version. + * + * This library is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU + * Library General Public License for more details. + * + * You should have received a copy of the GNU Library General Public + * License along with this library; if not, write to the + * Free Software Foundation, Inc., 59 Temple Place - Suite 330, + * Boston, MA 02111-1307, USA. + */ + +#ifndef __ATK_VALUE_H__ +#define __ATK_VALUE_H__ + +#include <atk/atkobject.h> + +#ifdef __cplusplus +extern "C" { +#endif /* __cplusplus */ + +/* + * The AtkValue interface should be supported by any object that + * supports a numerical value (e.g., a scroll bar). This interface + * provides the standard mechanism for an assistive technology to + * determine and set the numerical value as well as get the minimum + * and maximum values. + */ + +#define ATK_TYPE_VALUE (atk_value_get_type ()) +#define ATK_IS_VALUE(obj) G_TYPE_CHECK_INSTANCE_TYPE ((obj), ATK_TYPE_VALUE) +#define ATK_VALUE(obj) G_TYPE_CHECK_INSTANCE_CAST ((obj), ATK_TYPE_VALUE, AtkValue) +#define ATK_VALUE_GET_IFACE(obj) (G_TYPE_INSTANCE_GET_INTERFACE ((obj), ATK_TYPE_VALUE, AtkValueIface)) + +#ifndef _TYPEDEF_ATK_VALUE_ +#define _TYPEDEF_ATK_VALUE__ +typedef struct _AtkValue AtkValue; +#endif +typedef struct _AtkValueIface AtkValueIface; + +struct _AtkValueIface +{ + GTypeInterface parent; + + void (* get_current_value) (AtkValue *obj, + GValue *value); + void (* get_maximum_value) (AtkValue *obj, + GValue *value); + void (* get_minimum_value) (AtkValue *obj, + GValue *value); + gboolean (* set_current_value) (AtkValue *obj, + const GValue *value); + void (* get_minimum_increment) (AtkValue *obj, + GValue *value); + AtkFunction pad1; +}; + +GType atk_value_get_type (void); + +void atk_value_get_current_value (AtkValue *obj, + GValue *value); + + +void atk_value_get_maximum_value (AtkValue *obj, + GValue *value); + +void atk_value_get_minimum_value (AtkValue *obj, + GValue *value); + +gboolean atk_value_set_current_value (AtkValue *obj, + const GValue *value); + +void atk_value_get_minimum_increment (AtkValue *obj, + GValue *value); + +/* + * Additional GObject properties exported by GaccessibleValue: + * "accessible_value" + * (the accessible value has changed) + */ + + +#ifdef __cplusplus +} +#endif /* __cplusplus */ + + +#endif /* __ATK_VALUE_H__ */ |