<?xml version="1.0"?>
<!DOCTYPE refentry PUBLIC "-//OASIS//DTD DocBook XML V4.3//EN"
               "http://www.oasis-open.org/docbook/xml/4.3/docbookx.dtd" [
<!ENTITY % local.common.attrib "xmlns:xi  CDATA  #FIXED 'http://www.w3.org/2003/XInclude'">
<!ENTITY version SYSTEM "version.xml">
<!ENTITY pi "&#960;">
<!ENTITY solidus "&#8260;">
]>
<refentry id="GtkShortcutManager">
<refmeta>
<refentrytitle role="top_of_page" id="GtkShortcutManager.top_of_page">GtkShortcutManager</refentrytitle>
<manvolnum>3</manvolnum>
<refmiscinfo>GTK4 Library</refmiscinfo>
</refmeta>
<refnamediv>
<refname>GtkShortcutManager</refname>
<refpurpose>Interface for managing shortcuts</refpurpose>
</refnamediv>

<refsect1 id="GtkShortcutManager.other" role="other_proto">
<title role="other_proto.title">Types and Values</title>
<informaltable pgwide="1" frame="none">
<tgroup cols="2">
<colspec colname="other_proto_type" colwidth="150px"/>
<colspec colname="other_proto_name"/>
<tbody>
<row><entry role="datatype_keyword"></entry><entry role="function_name"><link linkend="GtkShortcutManager-struct">GtkShortcutManager</link></entry></row>
<row><entry role="datatype_keyword">struct</entry><entry role="function_name"><link linkend="GtkShortcutManagerInterface">GtkShortcutManagerInterface</link></entry></row>

</tbody>
</tgroup>
</informaltable>
</refsect1>
<refsect1 id="GtkShortcutManager.object-hierarchy" role="object_hierarchy">
<title role="object_hierarchy.title">Object Hierarchy</title>
<screen>    <link linkend="GInterface">GInterface</link>
    <phrase role="lineart">&#9584;&#9472;&#9472;</phrase> GtkShortcutManager
</screen>
</refsect1>
<refsect1 id="GtkShortcutManager.prerequisites" role="prerequisites">
<title role="prerequisites.title">Prerequisites</title>
<para>
GtkShortcutManager requires
 <link linkend="GObject">GObject</link>.</para>

</refsect1>
<refsect1 id="GtkShortcutManager.implementations" role="implementations">
<title role="implementations.title">Known Implementations</title>
<para>
GtkShortcutManager is implemented by
 <link linkend="GtkAboutDialog">GtkAboutDialog</link>,  <link linkend="GtkAppChooserDialog">GtkAppChooserDialog</link>,  <link linkend="GtkApplicationWindow">GtkApplicationWindow</link>,  <link linkend="GtkAssistant">GtkAssistant</link>,  <link linkend="GtkColorChooserDialog">GtkColorChooserDialog</link>,  <link linkend="GtkDialog">GtkDialog</link>,  <link linkend="GtkEmojiChooser">GtkEmojiChooser</link>,  <link linkend="GtkFileChooserDialog">GtkFileChooserDialog</link>,  <link linkend="GtkFontChooserDialog">GtkFontChooserDialog</link>,  <link linkend="GtkMessageDialog">GtkMessageDialog</link>,  <link linkend="GtkPageSetupUnixDialog">GtkPageSetupUnixDialog</link>,  <link linkend="GtkPopover">GtkPopover</link>,  <link linkend="GtkPopoverMenu">GtkPopoverMenu</link>,  <link linkend="GtkPrintUnixDialog">GtkPrintUnixDialog</link>,  <link linkend="GtkShortcutsWindow">GtkShortcutsWindow</link> and  <link linkend="GtkWindow">GtkWindow</link>.</para>

</refsect1>

<refsect1 id="GtkShortcutManager.includes"><title>Includes</title><synopsis>#include &lt;gtk/gtk.h&gt;
</synopsis></refsect1>

<refsect1 id="GtkShortcutManager.description" role="desc">
<title role="desc.title">Description</title>
<para>The GtkShortcutManager interface is used to implement
shortcut scopes.</para>
<para>This is important for <link linkend="GtkNative"><type>GtkNative</type></link> widgets that have their own surface,
since the event controllers that are used to implement managed and
global scopes are limited to the same native.</para>
<para>Examples for widgets implementing <link linkend="GtkShortcutManager"><type>GtkShortcutManager</type></link> are <link linkend="GtkWindow"><type>GtkWindow</type></link>
and <link linkend="GtkPopover"><type>GtkPopover</type></link>.</para>

</refsect1>
<refsect1 id="GtkShortcutManager.functions_details" role="details">
<title role="details.title">Functions</title>
<para />
</refsect1>
<refsect1 id="GtkShortcutManager.other_details" role="details">
<title role="details.title">Types and Values</title>
<refsect2 id="GtkShortcutManager-struct" role="struct">
<title>GtkShortcutManager</title>
<indexterm zone="GtkShortcutManager-struct"><primary>GtkShortcutManager</primary></indexterm>
<programlisting language="C">typedef struct _GtkShortcutManager GtkShortcutManager;</programlisting>
<para>This object is used to implement support for <link linkend="GtkShortcutScopes"><type>GtkShortcutScopes</type></link>. Every
widget that implements <link linkend="GtkShortcutManager"><type>GtkShortcutManager</type></link> will be used as a
<link linkend="GTK-SHORTCUT-SCOPE-MANAGED:CAPS"><literal>GTK_SHORTCUT_SCOPE_MANAGED</literal></link>.</para>
</refsect2>
<refsect2 id="GtkShortcutManagerInterface" role="struct">
<title>struct GtkShortcutManagerInterface</title>
<indexterm zone="GtkShortcutManagerInterface"><primary>GtkShortcutManagerInterface</primary></indexterm>
<programlisting language="C">struct GtkShortcutManagerInterface {
  void                  (* add_controller)              (GtkShortcutManager           *self,
                                                         GtkShortcutController        *controller);
  void                  (* remove_controller)           (GtkShortcutManager           *self,
                                                         GtkShortcutController        *controller);
};
</programlisting>
<para>The list of functions that can be implemented for the <link linkend="GtkShortcutManager"><type>GtkShortcutManager</type></link> interface.</para>
<para>Note that no function is mandatory to implement, the default implementation will work
fine.</para>
<refsect3 id="GtkShortcutManagerInterface.members" role="struct_members">
<title>Members</title>
<informaltable role="struct_members_table" pgwide="1" frame="none">
<tgroup cols="3">
<colspec colname="struct_members_name" colwidth="300px"/>
<colspec colname="struct_members_description"/>
<colspec colname="struct_members_annotations" colwidth="200px"/>
<tbody>
<row role="member"><entry role="struct_member_name"><para><structfield id="GtkShortcutManagerInterface.add-controller">add_controller</structfield>&#160;()</para></entry>
<entry role="struct_member_description"><para>Add a <link linkend="GtkShortcutController"><type>GtkShortcutController</type></link> to be managed.</para></entry>
<entry role="struct_member_annotations"></entry>
</row>
<row role="member"><entry role="struct_member_name"><para><structfield id="GtkShortcutManagerInterface.remove-controller">remove_controller</structfield>&#160;()</para></entry>
<entry role="struct_member_description"><para>Remove a <link linkend="GtkShortcutController"><type>GtkShortcutController</type></link> that had previously
been added.</para></entry>
<entry role="struct_member_annotations"></entry>
</row>
</tbody></tgroup></informaltable>
</refsect3>
</refsect2>

</refsect1>

</refentry>
