gtkmm  4.8.0
Public Types | Public Member Functions | Static Public Member Functions | Protected Member Functions | Related Functions | List of all members
Gtk::Accessible Class Reference

Accessible interface. More...

#include <gtkmm/accessible.h>

Inheritance diagram for Gtk::Accessible:
Inheritance graph
[legend]

Public Types

enum class  Role {
  ALERT ,
  ALERT_DIALOG ,
  BANNER ,
  BUTTON ,
  CAPTION ,
  CELL ,
  CHECKBOX ,
  COLUMN_HEADER ,
  COMBO_BOX ,
  COMMAND ,
  COMPOSITE ,
  DIALOG ,
  DOCUMENT ,
  FEED ,
  FORM ,
  GENERIC ,
  GRID ,
  GRID_CELL ,
  GROUP ,
  HEADING ,
  IMG ,
  INPUT ,
  LABEL ,
  LANDMARK ,
  LEGEND ,
  LINK ,
  LIST ,
  LIST_BOX ,
  LIST_ITEM ,
  LOG ,
  MAIN ,
  MARQUEE ,
  MATH ,
  METER ,
  MENU ,
  MENU_BAR ,
  MENU_ITEM ,
  MENU_ITEM_CHECKBOX ,
  MENU_ITEM_RADIO ,
  NAVIGATION ,
  NONE ,
  NOTE ,
  OPTION ,
  PRESENTATION ,
  PROGRESS_BAR ,
  RADIO ,
  RADIO_GROUP ,
  RANGE ,
  REGION ,
  ROW ,
  ROW_GROUP ,
  ROW_HEADER ,
  SCROLLBAR ,
  SEARCH ,
  SEARCH_BOX ,
  SECTION ,
  SECTION_HEAD ,
  SELECT ,
  SEPARATOR ,
  SLIDER ,
  SPIN_BUTTON ,
  STATUS ,
  STRUCTURE ,
  SWITCH ,
  TAB ,
  TABLE ,
  TAB_LIST ,
  TAB_PANEL ,
  TEXT_BOX ,
  TIME ,
  TIMER ,
  TOOLBAR ,
  TOOLTIP ,
  TREE ,
  TREE_GRID ,
  TREE_ITEM ,
  WIDGET ,
  WINDOW
}
 The accessible role for a Gtk::Accessible implementation. More...
 
enum class  State {
  BUSY ,
  CHECKED ,
  DISABLED ,
  EXPANDED ,
  HIDDEN ,
  INVALID ,
  PRESSED ,
  SELECTED
}
 The possible accessible states of a Gtk::Accessible. More...
 
enum class  Property {
  AUTOCOMPLETE ,
  DESCRIPTION ,
  HAS_POPUP ,
  KEY_SHORTCUTS ,
  LABEL ,
  LEVEL ,
  MODAL ,
  MULTI_LINE ,
  MULTI_SELECTABLE ,
  ORIENTATION ,
  PLACEHOLDER ,
  READ_ONLY ,
  REQUIRED ,
  ROLE_DESCRIPTION ,
  SORT ,
  VALUE_MAX ,
  VALUE_MIN ,
  VALUE_NOW ,
  VALUE_TEXT
}
 The possible accessible properties of a Gtk::Accessible. More...
 
enum class  Relation {
  ACTIVE_DESCENDANT ,
  COL_COUNT ,
  COL_INDEX ,
  COL_INDEX_TEXT ,
  COL_SPAN ,
  CONTROLS ,
  DESCRIBED_BY ,
  DETAILS ,
  ERROR_MESSAGE ,
  FLOW_TO ,
  LABELLED_BY ,
  OWNS ,
  POS_IN_SET ,
  ROW_COUNT ,
  ROW_INDEX ,
  ROW_INDEX_TEXT ,
  ROW_SPAN ,
  SET_SIZE
}
 The possible accessible relations of a Gtk::Accessible. More...
 

Public Member Functions

 Accessible (Accessible && src) noexcept
 
Accessibleoperator= (Accessible && src) noexcept
 
 ~Accessible () noexcept override
 
GtkAccessible * gobj ()
 Provides access to the underlying C GObject. More...
 
const GtkAccessible * gobj () const
 Provides access to the underlying C GObject. More...
 
Role get_accessible_role () const
 Retrieves the Gtk::Accessible::Role for the given Gtk::Accessible. More...
 
void update_state (State state, const Glib::ValueBase & value)
 Updates an accessible state. More...
 
void update_property (Property property, const Glib::ValueBase & value)
 Updates an accessible property. More...
 
void update_relation (Relation relation, const Glib::ValueBase & value)
 Updates an accessible relation. More...
 
void reset_state (State state)
 Resets the accessible state to its default value. More...
 
void reset_property (Property property)
 Resets the accessible property to its default value. More...
 
void reset_relation (Relation relation)
 Resets the accessible relation to its default value. More...
 
Glib::PropertyProxy< Roleproperty_accessible_role ()
 The accessible role of the given Gtk::Accessible implementation. More...
 
Glib::PropertyProxy_ReadOnly< Roleproperty_accessible_role () const
 The accessible role of the given Gtk::Accessible implementation. More...
 

Static Public Member Functions

static void add_interface (GType gtype_implementer)
 
static GType get_type ()
 Get the GType for this class, for use with the underlying GObject type system. More...
 

Protected Member Functions

 Accessible ()
 You should derive from this class to use it. More...
 

Related Functions

(Note that these are not member functions.)

Glib::RefPtr< Gtk::Accessiblewrap (GtkAccessible * object, bool take_copy=false)
 A Glib::wrap() method for this object. More...
 

Detailed Description

Accessible interface.

Gtk::Accessible provides an interface for describing a UI element, like a Gtk::Widget, in a way that can be consumed by Assistive Technologies, or “AT”. Every accessible implementation has:

The role cannot be changed after instantiating a Gtk::Accessible implementation.

The attributes are updated every time a UI element's state changes in a way that should be reflected by assistive technologies. For instance, if a Gtk::Widget visibility changes, the Gtk::Accessible::State::HIDDEN state will also change to reflect Gtk::Widget::property_visible().

Since gtkmm 3.98:

Constructor & Destructor Documentation

◆ Accessible() [1/2]

Gtk::Accessible::Accessible ( )
protected

You should derive from this class to use it.

◆ Accessible() [2/2]

Gtk::Accessible::Accessible ( Accessible &&  src)
noexcept

◆ ~Accessible()

Gtk::Accessible::~Accessible ( )
overridenoexcept

Member Function Documentation

◆ add_interface()

static void Gtk::Accessible::add_interface ( GType  gtype_implementer)
static

◆ get_accessible_role()

Role Gtk::Accessible::get_accessible_role ( ) const

Retrieves the Gtk::Accessible::Role for the given Gtk::Accessible.

Returns
A Gtk::Accessible::Role.

◆ get_type()

static GType Gtk::Accessible::get_type ( )
static

Get the GType for this class, for use with the underlying GObject type system.

◆ gobj() [1/2]

GtkAccessible* Gtk::Accessible::gobj ( )
inline

Provides access to the underlying C GObject.

◆ gobj() [2/2]

const GtkAccessible* Gtk::Accessible::gobj ( ) const
inline

Provides access to the underlying C GObject.

◆ operator=()

Accessible& Gtk::Accessible::operator= ( Accessible &&  src)
noexcept

◆ property_accessible_role() [1/2]

Glib::PropertyProxy< Role > Gtk::Accessible::property_accessible_role ( )

The accessible role of the given Gtk::Accessible implementation.

The accessible role cannot be changed once set.

Default value: Gtk::Accessible::Role::NONE

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

◆ property_accessible_role() [2/2]

Glib::PropertyProxy_ReadOnly< Role > Gtk::Accessible::property_accessible_role ( ) const

The accessible role of the given Gtk::Accessible implementation.

The accessible role cannot be changed once set.

Default value: Gtk::Accessible::Role::NONE

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

◆ reset_property()

void Gtk::Accessible::reset_property ( Property  property)

Resets the accessible property to its default value.

Parameters
propertyA Gtk::Accessible::Property.

◆ reset_relation()

void Gtk::Accessible::reset_relation ( Relation  relation)

Resets the accessible relation to its default value.

Parameters
relationA Gtk::Accessible::Relation.

◆ reset_state()

void Gtk::Accessible::reset_state ( State  state)

Resets the accessible state to its default value.

Parameters
stateA Gtk::Accessible::State.

◆ update_property()

void Gtk::Accessible::update_property ( Property  property,
const Glib::ValueBase &  value 
)

Updates an accessible property.

This function should be called by Gtk::Widget types whenever an accessible property change must be communicated to assistive technologies.

Parameters
propertyA Gtk::Accessible::Property.
valueA Glib::ValueBase.

◆ update_relation()

void Gtk::Accessible::update_relation ( Relation  relation,
const Glib::ValueBase &  value 
)

Updates an accessible relation.

This function should be called by Gtk::Widget types whenever an accessible relation change must be communicated to assistive technologies.

Parameters
relationA Gtk::Accessible::Relation.
valueA Glib::ValueBase.

◆ update_state()

void Gtk::Accessible::update_state ( State  state,
const Glib::ValueBase &  value 
)

Updates an accessible state.

This function should be called by Gtk::Widget types whenever an accessible state change must be communicated to assistive technologies.

Parameters
stateA Gtk::Accessible::State.
valueA Glib::ValueBase.

Friends And Related Function Documentation

◆ wrap()

Glib::RefPtr< Gtk::Accessible > wrap ( GtkAccessible *  object,
bool  take_copy = false 
)
related

A Glib::wrap() method for this object.

Parameters
objectThe C instance.
take_copyFalse 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.