Main Page Widgets Namespaces Book

# Atk::Object Class Reference

Inheritance diagram for Atk::Object:

[legend]
List of all members.

## Detailed Description

The base object class for the Accessibility Toolkit API.

This class is the primary class for accessibility support via the Accessibility ToolKit (ATK). Objects which are instances of Atk::Object (or instances of Atk::Object-derived types) are queried for properties which relate basic (and generic) properties of a UI component such as name and description. Instances of Atk::Object may also be queried as to whether they implement other ATK interfaces (e.g. Atk::Action, Atk::Component, etc.), as appropriate to the role which a given UI component plays in a user interface.

All UI components in an application which provide useful information or services to the user must provide corresponding Atk::Object instances on request (in GTK+, for instance, usually on a call to Gtk::Widget::get_accessible()), either via ATK support built into the toolkit for the widget class or ancestor class, or in the case of custom widgets, if the inherited Atk::Object implementation is insufficient, via instances of a new Atk::Object subclass.

## Public Member Functions

virtual | ~Object ()
AtkObject* | gobj ()
| Provides access to the underlying C GObject.
const AtkObject* | gobj () const
| Provides access to the underlying C GObject.
AtkObject* | gobj_copy ()
| Provides access to the underlying C instance. The caller is responsible for unrefing it. Use when directly setting fields in structs.
Glib::ustring | get_name () const
| Gets the accessible name of the accessible.
Glib::ustring | get_description () const
| Gets the accessible description of the accessible.
Glib::RefPtr<Atk::Object> | get_parent ()
| Gets the accessible parent of the accessible.
int | get_n_accessible_children () const
| Gets the number of accessible children of the accessible.
Glib::RefPtr<Atk::Object> | get_accessible_child (int i)
| Gets a reference to the specified accessible child of the object.
Glib::RefPtr<RelationSet> | get_relation_set ()
| Gets the Atk::RelationSet associated with the object.
Role | get_role () const
| Gets the role of the accessible.
Glib::RefPtr<StateSet> | get_state_set ()
| Gets a reference to the state set of the accessible; the caller must unreference it when it is no longer needed.
int | get_index_in_parent ()
| Gets the 0-based index of this accessible in its parent; returns -1 if the accessible does not have an accessible parent.
void | set_name (const Glib::ustring& name)
| Sets the accessible name of the accessible.
void | set_description (const Glib::ustring& description)
| Sets the accessible description of the accessible.
void | set_parent (const Glib::RefPtr<Atk::Object>& parent)
| Sets the accessible parent of the accessible.
void | set_role (Role role)
| Sets the role of the accessible.
void | notify_state_change (State state, bool value)
| Emits a state-change signal for the specified state.
bool | add_relationship (RelationType relationship, const Glib::RefPtr<Object>& target)
| Adds a relationship of the specified type with the specified target.
bool | remove_relationship (RelationType relationship, const Glib::RefPtr<Object>& target)
| Removes a relationship of the specified type with the specified target.
Glib::SignalProxy2< void, guint, gpointer > | signal_children_changed ()
Glib::SignalProxy1< void, bool > | signal_focus_event ()
Glib::SignalProxy1< void, AtkPropertyValues* > | signal_property_change ()
Glib::SignalProxy2< void, const Glib::ustring&, bool > | signal_state_change ()
Glib::SignalProxy0<void> | signal_visible_data_changed ()
Glib::SignalProxy1< void, void** > | signal_active_descendant_changed ()
Glib::PropertyProxy<Glib::ustring> | property_accessible_name ()
| You rarely need to use properties because there are get_ and set_ methods for almost all of them.
Glib::PropertyProxy_ReadOnly< Glib::ustring > | property_accessible_name () const
| You rarely need to use properties because there are get_ and set_ methods for almost all of them.
Glib::PropertyProxy<Glib::ustring> | property_accessible_description ()
| You rarely need to use properties because there are get_ and set_ methods for almost all of them.
Glib::PropertyProxy_ReadOnly< Glib::ustring > | property_accessible_description () const
| You rarely need to use properties because there are get_ and set_ methods for almost all of them.
Glib::PropertyProxy< Glib::RefPtr< Atk::Object > > | property_accessible_parent ()
| You rarely need to use properties because there are get_ and set_ methods for almost all of them.
Glib::PropertyProxy_ReadOnly< Glib::RefPtr<Atk::Object >> | property_accessible_parent () const
| You rarely need to use properties because there are get_ and set_ methods for almost all of them.
Glib::PropertyProxy<double> | property_accessible_value ()
| You rarely need to use properties because there are get_ and set_ methods for almost all of them.
Glib::PropertyProxy_ReadOnly< double > | property_accessible_value () const
| You rarely need to use properties because there are get_ and set_ methods for almost all of them.
Glib::PropertyProxy<int> | property_accessible_role ()
| You rarely need to use properties because there are get_ and set_ methods for almost all of them.
Glib::PropertyProxy_ReadOnly< int > | property_accessible_role () const
| You rarely need to use properties because there are get_ and set_ methods for almost all of them.
Glib::PropertyProxy_ReadOnly< int > | property_accessible_component_layer () const
| You rarely need to use properties because there are get_ and set_ methods for almost all of them.
Glib::PropertyProxy_ReadOnly< int > | property_accessible_component_mdi_zorder () const
| You rarely need to use properties because there are get_ and set_ methods for almost all of them.
Glib::PropertyProxy<Glib::ustring> | property_accessible_table_caption ()
| You rarely need to use properties because there are get_ and set_ methods for almost all of them.
Glib::PropertyProxy_ReadOnly< Glib::ustring > | property_accessible_table_caption () const
| You rarely need to use properties because there are get_ and set_ methods for almost all of them.
Glib::PropertyProxy<Glib::ustring> | property_accessible_table_column_description ()
| You rarely need to use properties because there are get_ and set_ methods for almost all of them.
Glib::PropertyProxy_ReadOnly< Glib::ustring > | property_accessible_table_column_description () const
| You rarely need to use properties because there are get_ and set_ methods for almost all of them.
Glib::PropertyProxy< Glib::RefPtr< Atk::Object > > | property_accessible_table_column_header ()
| You rarely need to use properties because there are get_ and set_ methods for almost all of them.
Glib::PropertyProxy_ReadOnly< Glib::RefPtr<Atk::Object >> | property_accessible_table_column_header () const
| You rarely need to use properties because there are get_ and set_ methods for almost all of them.
Glib::PropertyProxy<Glib::ustring> | property_accessible_table_row_description ()
| You rarely need to use properties because there are get_ and set_ methods for almost all of them.
Glib::PropertyProxy_ReadOnly< Glib::ustring > | property_accessible_table_row_description () const
| You rarely need to use properties because there are get_ and set_ methods for almost all of them.
Glib::PropertyProxy< Glib::RefPtr< Atk::Object > > | property_accessible_table_row_header ()
| You rarely need to use properties because there are get_ and set_ methods for almost all of them.
Glib::PropertyProxy_ReadOnly< Glib::RefPtr<Atk::Object >> | property_accessible_table_row_header () const
| You rarely need to use properties because there are get_ and set_ methods for almost all of them.
Glib::PropertyProxy< Glib::RefPtr< Atk::Object > > | property_accessible_table_summary ()
| You rarely need to use properties because there are get_ and set_ methods for almost all of them.
Glib::PropertyProxy_ReadOnly< Glib::RefPtr<Atk::Object >> | property_accessible_table_summary () const
| You rarely need to use properties because there are get_ and set_ methods for almost all of them.

## Protected Member Functions

virtual void | on_children_changed (guint change_index, gpointer changed_child)
virtual void | on_focus_event (bool focus_in)
virtual void | on_property_change (AtkPropertyValues* values)
virtual void | on_state_change (const Glib::ustring& name, bool state_set)
virtual void | on_visible_data_changed ()
virtual void | on_active_descendant_changed (void** child)

## Related Functions

(Note that these are not member functions.)
Glib::RefPtr<Atk::Object> | wrap (AtkObject* object, bool take_copy=false)

## Constructor & Destructor Documentation

virtual Atk::Object::~Object | ( |  | ) | `[virtual]`

| Reimplemented from Glib::Object.

## Member Function Documentation

bool Atk::Object::add_relationship | ( | RelationType | relationship,
|  | const Glib::RefPtr<Object>& | target
| ) |

Adds a relationship of the specified type with the specified target.

Parameters:

  | relationship | The Atk::RelationType of the relation.
  | target | The Atk::Object which is to be the target of the relation.

Returns:
  `true` if the relationship is added.

Glib::RefPtr<Atk::Object> Atk::Object::get_accessible_child | ( | int | i | ) |

Gets 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.

Parameters:

  | i | A `int` representing the position of the child, starting from 0.

Returns:
  An Atk::Object representing the specified accessible child of the accessible.

Glib::ustring Atk::Object::get_description | ( |  | ) | const

Gets the accessible description of the accessible.

Returns:
  A character string representing the accessible description of the accessible.

int Atk::Object::get_index_in_parent | ( |  | ) |

Gets the 0-based index of this accessible in its parent; returns -1 if the accessible does not have an accessible parent.

Returns:
  An integer which is the index of the accessible in its parent.

int Atk::Object::get_n_accessible_children | ( |  | ) | const

Gets the number of accessible children of the accessible.

Returns:
  An integer representing the number of accessible children of the accessible.

Glib::ustring Atk::Object::get_name | ( |  | ) | const

Gets the accessible name of the accessible.

Returns:
  A character string representing the accessible name of the object.

Glib::RefPtr<Atk::Object> Atk::Object::get_parent | ( |  | ) |

Gets the accessible parent of the accessible.

Returns:
  A Atk::Object representing the accessible parent of the accessible.

Glib::RefPtr<RelationSet> Atk::Object::get_relation_set | ( |  | ) |

Gets the Atk::RelationSet associated with the object.

Returns:
  An Atk::RelationSet representing the relation set of the object.

Role Atk::Object::get_role | ( |  | ) | const

Gets the role of the accessible.

Returns:
  An Atk::Role which is the role of the accessible.

Glib::RefPtr<StateSet> Atk::Object::get_state_set | ( |  | ) |

Gets a reference to the state set of the accessible; the caller must unreference it when it is no longer needed.

Returns:
  A reference to an Atk::StateSet which is the state set of the accessible.

const AtkObject* Atk::Object::gobj | ( |  | ) | const`[inline]`

| Provides access to the underlying C GObject. Reimplemented from Glib::ObjectBase. Reimplemented in Atk::NoOpObject, and Atk::ObjectAccessible.

AtkObject* Atk::Object::gobj | ( |  | ) | `[inline]`

| Provides access to the underlying C GObject. Reimplemented from Glib::ObjectBase. Reimplemented in Atk::NoOpObject, and Atk::ObjectAccessible.

AtkObject* Atk::Object::gobj_copy | ( |  | ) |

| Provides access to the underlying C instance. The caller is responsible for unrefing it. Use when directly setting fields in structs. Reimplemented in Atk::NoOpObject, and Atk::ObjectAccessible.

void Atk::Object::notify_state_change | ( | State | state,
|  | bool | value
| ) |

Emits a state-change signal for the specified state.

Parameters:

  | state | An Atk::State whose state is changed.
  | value | A `bool` which indicates whether the state is being set on or off.

virtual void Atk::Object::on_active_descendant_changed | ( | void ** | child | ) | `[protected, virtual]`

virtual void Atk::Object::on_children_changed | ( | guint | change_index,
|  | gpointer | changed_child
| ) | `[protected, virtual]`

virtual void Atk::Object::on_focus_event | ( | bool | focus_in | ) | `[protected, virtual]`

virtual void Atk::Object::on_property_change | ( | AtkPropertyValues* | values | ) | `[protected, virtual]`

virtual void Atk::Object::on_state_change | ( | const Glib::ustring& | name,
|  | bool | state_set
| ) | `[protected, virtual]`

virtual void Atk::Object::on_visible_data_changed | ( |  | ) | `[protected, virtual]`

Glib::PropertyProxy_ReadOnly<int> Atk::Object::property_accessible_component_layer | ( |  | ) | const

You rarely need to use properties because there are get_ and set_ methods for almost all of them.

Returns:
  A PropertyProxy that allows you to get or set the property of the value, or receive notification when the value of the property changes.

Glib::PropertyProxy_ReadOnly<int> Atk::Object::property_accessible_component_mdi_zorder | ( |  | ) | const

You rarely need to use properties because there are get_ and set_ methods for almost all of them.

Returns:
  A PropertyProxy that allows you to get or set the property of the value, or receive notification when the value of the property changes.

Glib::PropertyProxy_ReadOnly<Glib::ustring> Atk::Object::property_accessible_description | ( |  | ) | const

You rarely need to use properties because there are get_ and set_ methods for almost all of them.

Returns:
  A PropertyProxy that allows you to get or set the property of the value, or receive notification when the value of the property changes.

Glib::PropertyProxy<Glib::ustring> Atk::Object::property_accessible_description | ( |  | ) |

You rarely need to use properties because there are get_ and set_ methods for almost all of them.

Returns:
  A PropertyProxy that allows you to get or set the property of the value, or receive notification when the value of the property changes.

Glib::PropertyProxy_ReadOnly<Glib::ustring> Atk::Object::property_accessible_name | ( |  | ) | const

You rarely need to use properties because there are get_ and set_ methods for almost all of them.

Returns:
  A PropertyProxy that allows you to get or set the property of the value, or receive notification when the value of the property changes.

Glib::PropertyProxy<Glib::ustring> Atk::Object::property_accessible_name | ( |  | ) |

You rarely need to use properties because there are get_ and set_ methods for almost all of them.

Returns:
  A PropertyProxy that allows you to get or set the property of the value, or receive notification when the value of the property changes.

Glib::PropertyProxy_ReadOnly<Glib::RefPtr<Atk::Object>> Atk::Object::property_accessible_parent | ( |  | ) | const

You rarely need to use properties because there are get_ and set_ methods for almost all of them.

Returns:
  A PropertyProxy that allows you to get or set the property of the value, or receive notification when the value of the property changes.

Glib::PropertyProxy<Glib::RefPtr<Atk::Object>> Atk::Object::property_accessible_parent | ( |  | ) |

You rarely need to use properties because there are get_ and set_ methods for almost all of them.

Returns:
  A PropertyProxy that allows you to get or set the property of the value, or receive notification when the value of the property changes.

Glib::PropertyProxy_ReadOnly<int> Atk::Object::property_accessible_role | ( |  | ) | const

You rarely need to use properties because there are get_ and set_ methods for almost all of them.

Returns:
  A PropertyProxy that allows you to get or set the property of the value, or receive notification when the value of the property changes.

Glib::PropertyProxy<int> Atk::Object::property_accessible_role | ( |  | ) |

You rarely need to use properties because there are get_ and set_ methods for almost all of them.

Returns:
  A PropertyProxy that allows you to get or set the property of the value, or receive notification when the value of the property changes.

Glib::PropertyProxy_ReadOnly<Glib::ustring> Atk::Object::property_accessible_table_caption | ( |  | ) | const

You rarely need to use properties because there are get_ and set_ methods for almost all of them.

Returns:
  A PropertyProxy that allows you to get or set the property of the value, or receive notification when the value of the property changes.

Glib::PropertyProxy<Glib::ustring> Atk::Object::property_accessible_table_caption | ( |  | ) |

You rarely need to use properties because there are get_ and set_ methods for almost all of them.

Returns:
  A PropertyProxy that allows you to get or set the property of the value, or receive notification when the value of the property changes.

Glib::PropertyProxy_ReadOnly<Glib::ustring> Atk::Object::property_accessible_table_column_description | ( |  | ) | const

You rarely need to use properties because there are get_ and set_ methods for almost all of them.

Returns:
  A PropertyProxy that allows you to get or set the property of the value, or receive notification when the value of the property changes.

Glib::PropertyProxy<Glib::ustring> Atk::Object::property_accessible_table_column_description | ( |  | ) |

You rarely need to use properties because there are get_ and set_ methods for almost all of them.

Returns:
  A PropertyProxy that allows you to get or set the property of the value, or receive notification when the value of the property changes.

Glib::PropertyProxy_ReadOnly<Glib::RefPtr<Atk::Object>> Atk::Object::property_accessible_table_column_header | ( |  | ) | const

You rarely need to use properties because there are get_ and set_ methods for almost all of them.

Returns:
  A PropertyProxy that allows you to get or set the property of the value, or receive notification when the value of the property changes.

Glib::PropertyProxy<Glib::RefPtr<Atk::Object>> Atk::Object::property_accessible_table_column_header | ( |  | ) |

You rarely need to use properties because there are get_ and set_ methods for almost all of them.

Returns:
  A PropertyProxy that allows you to get or set the property of the value, or receive notification when the value of the property changes.

Glib::PropertyProxy_ReadOnly<Glib::ustring> Atk::Object::property_accessible_table_row_description | ( |  | ) | const

You rarely need to use properties because there are get_ and set_ methods for almost all of them.

Returns:
  A PropertyProxy that allows you to get or set the property of the value, or receive notification when the value of the property changes.

Glib::PropertyProxy<Glib::ustring> Atk::Object::property_accessible_table_row_description | ( |  | ) |

You rarely need to use properties because there are get_ and set_ methods for almost all of them.

Returns:
  A PropertyProxy that allows you to get or set the property of the value, or receive notification when the value of the property changes.

Glib::PropertyProxy_ReadOnly<Glib::RefPtr<Atk::Object>> Atk::Object::property_accessible_table_row_header | ( |  | ) | const

You rarely need to use properties because there are get_ and set_ methods for almost all of them.

Returns:
  A PropertyProxy that allows you to get or set the property of the value, or receive notification when the value of the property changes.

Glib::PropertyProxy<Glib::RefPtr<Atk::Object>> Atk::Object::property_accessible_table_row_header | ( |  | ) |

You rarely need to use properties because there are get_ and set_ methods for almost all of them.

Returns:
  A PropertyProxy that allows you to get or set the property of the value, or receive notification when the value of the property changes.

Glib::PropertyProxy_ReadOnly<Glib::RefPtr<Atk::Object>> Atk::Object::property_accessible_table_summary | ( |  | ) | const

You rarely need to use properties because there are get_ and set_ methods for almost all of them.

Returns:
  A PropertyProxy that allows you to get or set the property of the value, or receive notification when the value of the property changes.

Glib::PropertyProxy<Glib::RefPtr<Atk::Object>> Atk::Object::property_accessible_table_summary | ( |  | ) |

You rarely need to use properties because there are get_ and set_ methods for almost all of them.

Returns:
  A PropertyProxy that allows you to get or set the property of the value, or receive notification when the value of the property changes.

Glib::PropertyProxy_ReadOnly<double> Atk::Object::property_accessible_value | ( |  | ) | const

You rarely need to use properties because there are get_ and set_ methods for almost all of them.

Returns:
  A PropertyProxy that allows you to get or set the property of the value, or receive notification when the value of the property changes.

Glib::PropertyProxy<double> Atk::Object::property_accessible_value | ( |  | ) |

You rarely need to use properties because there are get_ and set_ methods for almost all of them.

Returns:
  A PropertyProxy that allows you to get or set the property of the value, or receive notification when the value of the property changes.

bool Atk::Object::remove_relationship | ( | RelationType | relationship,
|  | const Glib::RefPtr<Object>& | target
| ) |

Removes a relationship of the specified type with the specified target.

Parameters:

  | relationship | The Atk::RelationType of the relation.
  | target | The Atk::Object which is the target of the relation to be removed.

Returns:
  `true` if the relationship is removed.

void Atk::Object::set_description | ( | const Glib::ustring& | description | ) |

Sets the accessible description of the accessible.

Parameters:

  | description | A character string to be set as the accessible description.

void Atk::Object::set_name | ( | const Glib::ustring& | name | ) |

Sets the accessible name of the accessible.

Parameters:

  | name | A character string to be set as the accessible name.

void Atk::Object::set_parent | ( | const Glib::RefPtr<Atk::Object>& | parent | ) |

Sets the accessible parent of the accessible.

Parameters:

  | parent | An Atk::Object to be set as the accessible parent.

void Atk::Object::set_role | ( | Role | role | ) |

Sets the role of the accessible.

Parameters:

  | role | An Atk::Role to be set as the role.

Glib::SignalProxy1<void,void**> Atk::Object::signal_active_descendant_changed | ( |  | ) |

Glib::SignalProxy2<void,guint,gpointer> Atk::Object::signal_children_changed | ( |  | ) |

Glib::SignalProxy1<void,bool> Atk::Object::signal_focus_event | ( |  | ) |

Glib::SignalProxy1<void,AtkPropertyValues*> Atk::Object::signal_property_change | ( |  | ) |

Glib::SignalProxy2<void,const Glib::ustring&,bool> Atk::Object::signal_state_change | ( |  | ) |

Glib::SignalProxy0<void> Atk::Object::signal_visible_data_changed | ( |  | ) |

## Friends And Related Function Documentation

Glib::RefPtr<Atk::Object> wrap | ( | AtkObject* | object,
|  | bool | take_copy = `false`
| ) | `[related]`

Parameters:

  | object | The C instance
  | take_copy | False if the result should take ownership of the C instance. True if it should take a new copy or ref.

Returns:
  A C++ instance that wraps this C instance.

The documentation for this class was generated from the following file:

- atk/atkmm/object.h