Interface

GioActionMap

Description [src]

interface Gio.ActionMap : GObject.Object

The GActionMap interface is implemented by GActionGroup implementations that operate by containing a number of named GAction instances, such as GSimpleActionGroup.

One useful application of this interface is to map the names of actions from various action groups to unique, prefixed names (e.g. by prepending “app.” or “win.”). This is the motivation for the ‘Map’ part of the interface name.

Available since:2.32

Prerequisite

In order to implement ActionMap, your type must inherit from GObject.

Instance methods

g_action_map_add_action

Adds an action to the action_map.

Available since: 2.32

g_action_map_add_action_entries

A convenience function for creating multiple GSimpleAction instances and adding them to a GActionMap.

Available since: 2.32

g_action_map_lookup_action

Looks up the action with the name action_name in action_map.

Available since: 2.32

g_action_map_remove_action

Removes the named action from the action map.

Available since: 2.32

Interface structure

struct GioActionMapInterface {
  GTypeInterface g_iface;
  GAction* (* lookup_action) (
    GActionMap* action_map,
    const gchar* action_name
  );
  void (* add_action) (
    GActionMap* action_map,
    GAction* action
  );
  void (* remove_action) (
    GActionMap* action_map,
    const gchar* action_name
  );
  
}
Interface members
g_iface
GTypeInterface
 No description available.
lookup_action
GAction* (* lookup_action) (
    GActionMap* action_map,
    const gchar* action_name
  )
 No description available.
add_action
void (* add_action) (
    GActionMap* action_map,
    GAction* action
  )
 No description available.
remove_action
void (* remove_action) (
    GActionMap* action_map,
    const gchar* action_name
  )
 No description available.

Virtual methods

Gio.ActionMap.add_action

Adds an action to the action_map.

Gio.ActionMap.lookup_action

Looks up the action with the name action_name in action_map.

Gio.ActionMap.remove_action

Removes the named action from the action map.