<?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="GtkShortcutAction">
<refmeta>
<refentrytitle role="top_of_page" id="GtkShortcutAction.top_of_page">GtkShortcutAction</refentrytitle>
<manvolnum>3</manvolnum>
<refmiscinfo>GTK4 Library</refmiscinfo>
</refmeta>
<refnamediv>
<refname>GtkShortcutAction</refname>
<refpurpose>Tracking if shortcuts should be activated</refpurpose>
</refnamediv>

<refsect1 id="GtkShortcutAction.functions" role="functions_proto">
<title role="functions_proto.title">Functions</title>
<informaltable pgwide="1" frame="none">
<tgroup cols="2">
<colspec colname="functions_proto_type" colwidth="150px"/>
<colspec colname="functions_proto_name"/>
<tbody>
<row><entry role="function_type"><link linkend="gboolean"><returnvalue>gboolean</returnvalue></link>
</entry><entry role="function_name"><phrase role="c_punctuation">(</phrase><link linkend="GtkShortcutFunc">*GtkShortcutFunc</link><phrase role="c_punctuation">)</phrase>&#160;<phrase role="c_punctuation">()</phrase></entry></row>
<row><entry role="function_type"><link linkend="char"><returnvalue>char</returnvalue></link>&#160;*
</entry><entry role="function_name"><link linkend="gtk-shortcut-action-to-string">gtk_shortcut_action_to_string</link>&#160;<phrase role="c_punctuation">()</phrase></entry></row>
<row><entry role="function_type"><link linkend="void"><returnvalue>void</returnvalue></link>
</entry><entry role="function_name"><link linkend="gtk-shortcut-action-print">gtk_shortcut_action_print</link>&#160;<phrase role="c_punctuation">()</phrase></entry></row>
<row><entry role="function_type"><link linkend="GtkShortcutAction"><returnvalue>GtkShortcutAction</returnvalue></link>&#160;*
</entry><entry role="function_name"><link linkend="gtk-shortcut-action-parse-string">gtk_shortcut_action_parse_string</link>&#160;<phrase role="c_punctuation">()</phrase></entry></row>
<row><entry role="function_type"><link linkend="gboolean"><returnvalue>gboolean</returnvalue></link>
</entry><entry role="function_name"><link linkend="gtk-shortcut-action-activate">gtk_shortcut_action_activate</link>&#160;<phrase role="c_punctuation">()</phrase></entry></row>

<row><entry role="function_type"><link linkend="GtkShortcutAction"><returnvalue>GtkShortcutAction</returnvalue></link>&#160;*
</entry><entry role="function_name"><link linkend="gtk-nothing-action-get">gtk_nothing_action_get</link>&#160;<phrase role="c_punctuation">()</phrase></entry></row>

<row><entry role="function_type"><link linkend="GtkShortcutAction"><returnvalue>GtkShortcutAction</returnvalue></link>&#160;*
</entry><entry role="function_name"><link linkend="gtk-callback-action-new">gtk_callback_action_new</link>&#160;<phrase role="c_punctuation">()</phrase></entry></row>

<row><entry role="function_type"><link linkend="GtkShortcutAction"><returnvalue>GtkShortcutAction</returnvalue></link>&#160;*
</entry><entry role="function_name"><link linkend="gtk-mnemonic-action-get">gtk_mnemonic_action_get</link>&#160;<phrase role="c_punctuation">()</phrase></entry></row>

<row><entry role="function_type"><link linkend="GtkShortcutAction"><returnvalue>GtkShortcutAction</returnvalue></link>&#160;*
</entry><entry role="function_name"><link linkend="gtk-activate-action-get">gtk_activate_action_get</link>&#160;<phrase role="c_punctuation">()</phrase></entry></row>

<row><entry role="function_type"><link linkend="GtkShortcutAction"><returnvalue>GtkShortcutAction</returnvalue></link>&#160;*
</entry><entry role="function_name"><link linkend="gtk-signal-action-new">gtk_signal_action_new</link>&#160;<phrase role="c_punctuation">()</phrase></entry></row>
<row><entry role="function_type">const <link linkend="char"><returnvalue>char</returnvalue></link>&#160;*
</entry><entry role="function_name"><link linkend="gtk-signal-action-get-signal-name">gtk_signal_action_get_signal_name</link>&#160;<phrase role="c_punctuation">()</phrase></entry></row>

<row><entry role="function_type"><link linkend="GtkShortcutAction"><returnvalue>GtkShortcutAction</returnvalue></link>&#160;*
</entry><entry role="function_name"><link linkend="gtk-named-action-new">gtk_named_action_new</link>&#160;<phrase role="c_punctuation">()</phrase></entry></row>
<row><entry role="function_type">const <link linkend="char"><returnvalue>char</returnvalue></link>&#160;*
</entry><entry role="function_name"><link linkend="gtk-named-action-get-action-name">gtk_named_action_get_action_name</link>&#160;<phrase role="c_punctuation">()</phrase></entry></row>

</tbody>
</tgroup>
</informaltable>
</refsect1>
<anchor id="GtkNothingAction"/><anchor id="GtkCallbackAction"/><anchor id="GtkSignalAction"/><anchor id="GtkNamedAction"/><refsect1 id="GtkShortcutAction.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="GtkShortcutAction-struct">GtkShortcutAction</link></entry></row>
<row><entry role="datatype_keyword">enum</entry><entry role="function_name"><link linkend="GtkShortcutActionFlags">GtkShortcutActionFlags</link></entry></row>

<row><entry role="datatype_keyword"></entry><entry role="function_name"><link linkend="GtkNothingAction-struct">GtkNothingAction</link></entry></row>

<row><entry role="datatype_keyword"></entry><entry role="function_name"><link linkend="GtkCallbackAction-struct">GtkCallbackAction</link></entry></row>

<row><entry role="datatype_keyword"></entry><entry role="function_name"><link linkend="GtkMnemonicAction">GtkMnemonicAction</link></entry></row>

<row><entry role="datatype_keyword"></entry><entry role="function_name"><link linkend="GtkActivateAction">GtkActivateAction</link></entry></row>

<row><entry role="datatype_keyword"></entry><entry role="function_name"><link linkend="GtkSignalAction-struct">GtkSignalAction</link></entry></row>

<row><entry role="datatype_keyword"></entry><entry role="function_name"><link linkend="GtkNamedAction-struct">GtkNamedAction</link></entry></row>

</tbody>
</tgroup>
</informaltable>
</refsect1>
<refsect1 id="GtkShortcutAction.object-hierarchy" role="object_hierarchy">
<title role="object_hierarchy.title">Object Hierarchy</title>
<screen>    <link linkend="GObject">GObject</link>
    <phrase role="lineart">&#9584;&#9472;&#9472;</phrase> GtkShortcutAction
        <phrase role="lineart">&#9500;&#9472;&#9472;</phrase> GtkSignalAction
        <phrase role="lineart">&#9500;&#9472;&#9472;</phrase> GtkNothingAction
        <phrase role="lineart">&#9500;&#9472;&#9472;</phrase> GtkNamedAction
        <phrase role="lineart">&#9584;&#9472;&#9472;</phrase> GtkCallbackAction
</screen>
</refsect1>

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

<refsect1 id="GtkShortcutAction.description" role="desc">
<title role="desc.title">Description</title>
<para><link linkend="GtkShortcutAction"><type>GtkShortcutAction</type></link> is the object used to describe what a <link linkend="GtkShortcut"><type>GtkShortcut</type></link> should
do when triggered. To activate a <link linkend="GtkShortcutAction"><type>GtkShortcutAction</type></link> manually,
<link linkend="gtk-shortcut-action-activate"><function>gtk_shortcut_action_activate()</function></link> can be called.</para>
<para><link linkend="GtkShortcutActions"><type>GtkShortcutActions</type></link> contain functions that allow easy presentation to end
users as well as being printed for debugging.</para>
<para>All <link linkend="GtkShortcutActions"><type>GtkShortcutActions</type></link> are immutable, you can only specify their properties
during construction. If you want to change a action, you have to replace it
with a new one. If you need to pass arguments to an action, these are specified
by the higher-level <link linkend="GtkShortcut"><type>GtkShortcut</type></link> object.</para>
<para>GTK provides various actions:</para>
<itemizedlist>
<listitem><para><link linkend="GtkMnemonicAction"><type>GtkMnemonicAction</type></link>: a shortcut action that calls <link linkend="gtk-widget-mnemonic-activate"><function>gtk_widget_mnemonic_activate()</function></link></para></listitem>
<listitem><para><link linkend="GtkCallbackAction"><type>GtkCallbackAction</type></link>: a shortcut action that invokes a given callback</para></listitem>
<listitem><para><link linkend="GtkSignalAction"><type>GtkSignalAction</type></link>: a shortcut action that emits a given signal</para></listitem>
<listitem><para><link linkend="GtkActivateAction"><type>GtkActivateAction</type></link>: a shortcut action that calls <link linkend="gtk-widget-activate"><function>gtk_widget_activate()</function></link></para></listitem>
<listitem><para><link linkend="GtkNamedAction"><type>GtkNamedAction</type></link>: a shortcut action that calls <link linkend="gtk-widget-activate-action"><function>gtk_widget_activate_action()</function></link></para></listitem>
<listitem>
<para><link linkend="GtkNothingAction"><type>GtkNothingAction</type></link>: a shortcut action that does nothing</para>
</listitem>
</itemizedlist>
<refsect2><title>GtkShortcutAction as GtkBuildable</title><para>GtkShortcut</para>
</refsect2>

</refsect1>
<refsect1 id="GtkShortcutAction.functions_details" role="details">
<title role="details.title">Functions</title>
<refsect2 id="GtkShortcutFunc" role="function">
<title>GtkShortcutFunc&#160;()</title>
<indexterm zone="GtkShortcutFunc"><primary>GtkShortcutFunc</primary></indexterm>
<programlisting language="C"><link linkend="gboolean"><returnvalue>gboolean</returnvalue></link>
<phrase role="c_punctuation">(</phrase>*GtkShortcutFunc<phrase role="c_punctuation">)</phrase> (<parameter><link linkend="GtkWidget"><type>GtkWidget</type></link> *widget</parameter>,
                    <parameter><link linkend="GVariant"><type>GVariant</type></link> *args</parameter>,
                    <parameter><link linkend="gpointer"><type>gpointer</type></link> user_data</parameter>);</programlisting>
<para>Prototype for shortcuts based on user callbacks.</para>
<refsect3 id="GtkShortcutFunc.parameters" role="parameters">
<title>Parameters</title>
<informaltable role="parameters_table" pgwide="1" frame="none">
<tgroup cols="3">
<colspec colname="parameters_name" colwidth="150px"/>
<colspec colname="parameters_description"/>
<colspec colname="parameters_annotations" colwidth="200px"/>
<tbody>
<row><entry role="parameter_name"><para>widget</para></entry>
<entry role="parameter_description"><para>The widget passed to the activation</para></entry>
<entry role="parameter_annotations"></entry></row>
<row><entry role="parameter_name"><para>args</para></entry>
<entry role="parameter_description"><para>The arguments passed to the activation</para></entry>
<entry role="parameter_annotations"></entry></row>
<row><entry role="parameter_name"><para>user_data</para></entry>
<entry role="parameter_description"><para>The user data provided when activating the action</para></entry>
<entry role="parameter_annotations"></entry></row>
</tbody></tgroup></informaltable>
</refsect3></refsect2>
<refsect2 id="gtk-shortcut-action-to-string" role="function">
<title>gtk_shortcut_action_to_string&#160;()</title>
<indexterm zone="gtk-shortcut-action-to-string"><primary>gtk_shortcut_action_to_string</primary></indexterm>
<programlisting language="C"><link linkend="char"><returnvalue>char</returnvalue></link>&#160;*
gtk_shortcut_action_to_string (<parameter><link linkend="GtkShortcutAction"><type>GtkShortcutAction</type></link> *self</parameter>);</programlisting>
<para>Prints the given action into a human-readable string.
This is a small wrapper around <link linkend="gtk-shortcut-action-print"><function>gtk_shortcut_action_print()</function></link> to help
when debugging.</para>
<refsect3 id="gtk-shortcut-action-to-string.parameters" role="parameters">
<title>Parameters</title>
<informaltable role="parameters_table" pgwide="1" frame="none">
<tgroup cols="3">
<colspec colname="parameters_name" colwidth="150px"/>
<colspec colname="parameters_description"/>
<colspec colname="parameters_annotations" colwidth="200px"/>
<tbody>
<row><entry role="parameter_name"><para>self</para></entry>
<entry role="parameter_description"><para>a <link linkend="GtkShortcutAction"><type>GtkShortcutAction</type></link></para></entry>
<entry role="parameter_annotations"></entry></row>
</tbody></tgroup></informaltable>
</refsect3><refsect3 id="gtk-shortcut-action-to-string.returns" role="returns">
<title>Returns</title>
<para>a new string. </para>
<para><emphasis role="annotation">[<acronym>transfer full</acronym>]</emphasis></para>
</refsect3></refsect2>
<refsect2 id="gtk-shortcut-action-print" role="function">
<title>gtk_shortcut_action_print&#160;()</title>
<indexterm zone="gtk-shortcut-action-print"><primary>gtk_shortcut_action_print</primary></indexterm>
<programlisting language="C"><link linkend="void"><returnvalue>void</returnvalue></link>
gtk_shortcut_action_print (<parameter><link linkend="GtkShortcutAction"><type>GtkShortcutAction</type></link> *self</parameter>,
                           <parameter><link linkend="GString"><type>GString</type></link> *string</parameter>);</programlisting>
<para>Prints the given action into a string for the developer.
This is meant for debugging and logging.</para>
<para>The form of the representation may change at any time and is
not guaranteed to stay identical.</para>
<refsect3 id="gtk-shortcut-action-print.parameters" role="parameters">
<title>Parameters</title>
<informaltable role="parameters_table" pgwide="1" frame="none">
<tgroup cols="3">
<colspec colname="parameters_name" colwidth="150px"/>
<colspec colname="parameters_description"/>
<colspec colname="parameters_annotations" colwidth="200px"/>
<tbody>
<row><entry role="parameter_name"><para>self</para></entry>
<entry role="parameter_description"><para>a <link linkend="GtkShortcutAction"><type>GtkShortcutAction</type></link></para></entry>
<entry role="parameter_annotations"></entry></row>
<row><entry role="parameter_name"><para>string</para></entry>
<entry role="parameter_description"><para>a <link linkend="GString"><type>GString</type></link> to print into</para></entry>
<entry role="parameter_annotations"></entry></row>
</tbody></tgroup></informaltable>
</refsect3></refsect2>
<refsect2 id="gtk-shortcut-action-parse-string" role="function">
<title>gtk_shortcut_action_parse_string&#160;()</title>
<indexterm zone="gtk-shortcut-action-parse-string"><primary>gtk_shortcut_action_parse_string</primary></indexterm>
<programlisting language="C"><link linkend="GtkShortcutAction"><returnvalue>GtkShortcutAction</returnvalue></link>&#160;*
gtk_shortcut_action_parse_string (<parameter>const <link linkend="char"><type>char</type></link> *string</parameter>);</programlisting>
<para>Tries to parse the given string into an action. On
success, the parsed action is returned. When parsing
failed, <link linkend="NULL:CAPS"><literal>NULL</literal></link> is returned.</para>
<para>The accepted strings are:</para>
<itemizedlist>
<listitem><para><literal>nothing</literal>, for <link linkend="GtkNothingAction"><type>GtkNothingAction</type></link></para></listitem>
<listitem><para><literal>activate</literal>, for <link linkend="GtkActivateAction"><type>GtkActivateAction</type></link></para></listitem>
<listitem><para><literal>mnemonic-activate</literal>, for <link linkend="GtkMnemonicAction"><type>GtkMnemonicAction</type></link></para></listitem>
<listitem><para><literal>action(NAME)</literal>, for a <link linkend="GtkNamedAction"><type>GtkNamedAction</type></link> for the action named <literal>NAME</literal></para></listitem>
<listitem><para><literal>signal(NAME)</literal>, for a <link linkend="GtkSignalAction"><type>GtkSignalAction</type></link> for the signal <literal>NAME</literal></para></listitem>
</itemizedlist>

<para><emphasis role="annotation">[<acronym>constructor</acronym>]</emphasis></para><refsect3 id="gtk-shortcut-action-parse-string.parameters" role="parameters">
<title>Parameters</title>
<informaltable role="parameters_table" pgwide="1" frame="none">
<tgroup cols="3">
<colspec colname="parameters_name" colwidth="150px"/>
<colspec colname="parameters_description"/>
<colspec colname="parameters_annotations" colwidth="200px"/>
<tbody>
<row><entry role="parameter_name"><para>string</para></entry>
<entry role="parameter_description"><para>the string to parse</para></entry>
<entry role="parameter_annotations"></entry></row>
</tbody></tgroup></informaltable>
</refsect3><refsect3 id="gtk-shortcut-action-parse-string.returns" role="returns">
<title>Returns</title>
<para>a new <link linkend="GtkShortcutAction"><type>GtkShortcutAction</type></link>
or <link linkend="NULL:CAPS"><literal>NULL</literal></link> on error. </para>
<para><emphasis role="annotation">[<acronym>nullable</acronym>][<acronym>transfer full</acronym>]</emphasis></para>
</refsect3></refsect2>
<refsect2 id="gtk-shortcut-action-activate" role="function">
<title>gtk_shortcut_action_activate&#160;()</title>
<indexterm zone="gtk-shortcut-action-activate"><primary>gtk_shortcut_action_activate</primary></indexterm>
<programlisting language="C"><link linkend="gboolean"><returnvalue>gboolean</returnvalue></link>
gtk_shortcut_action_activate (<parameter><link linkend="GtkShortcutAction"><type>GtkShortcutAction</type></link> *self</parameter>,
                              <parameter><link linkend="GtkShortcutActionFlags"><type>GtkShortcutActionFlags</type></link> flags</parameter>,
                              <parameter><link linkend="GtkWidget"><type>GtkWidget</type></link> *widget</parameter>,
                              <parameter><link linkend="GVariant"><type>GVariant</type></link> *args</parameter>);</programlisting>
<para>Activates the action on the <parameter>widget</parameter>
 with the given <parameter>args</parameter>
. </para>
<para>Note that some actions ignore the passed in <parameter>flags</parameter>
, <parameter>widget</parameter>
 or <parameter>args</parameter>
.</para>
<para>Activation of an action can fail for various reasons. If the action
is not supported by the <parameter>widget</parameter>
, if the <parameter>args</parameter>
 don't match the action
or if the activation otherwise had no effect, <link linkend="FALSE:CAPS"><literal>FALSE</literal></link> will be returned.</para>
<refsect3 id="gtk-shortcut-action-activate.parameters" role="parameters">
<title>Parameters</title>
<informaltable role="parameters_table" pgwide="1" frame="none">
<tgroup cols="3">
<colspec colname="parameters_name" colwidth="150px"/>
<colspec colname="parameters_description"/>
<colspec colname="parameters_annotations" colwidth="200px"/>
<tbody>
<row><entry role="parameter_name"><para>self</para></entry>
<entry role="parameter_description"><para>a <link linkend="GtkShortcutAction"><type>GtkShortcutAction</type></link></para></entry>
<entry role="parameter_annotations"></entry></row>
<row><entry role="parameter_name"><para>flags</para></entry>
<entry role="parameter_description"><para>flags to activate with</para></entry>
<entry role="parameter_annotations"></entry></row>
<row><entry role="parameter_name"><para>widget</para></entry>
<entry role="parameter_description"><para>Target of the activation</para></entry>
<entry role="parameter_annotations"></entry></row>
<row><entry role="parameter_name"><para>args</para></entry>
<entry role="parameter_description"><para>arguments to pass. </para></entry>
<entry role="parameter_annotations"><emphasis role="annotation">[<acronym>allow-none</acronym>]</emphasis></entry></row>
</tbody></tgroup></informaltable>
</refsect3><refsect3 id="gtk-shortcut-action-activate.returns" role="returns">
<title>Returns</title>
<para> <link linkend="TRUE:CAPS"><literal>TRUE</literal></link> if this action was activated successfully</para>
</refsect3></refsect2>
<refsect2 id="gtk-nothing-action-get" role="function">
<title>gtk_nothing_action_get&#160;()</title>
<indexterm zone="gtk-nothing-action-get"><primary>gtk_nothing_action_get</primary></indexterm>
<programlisting language="C"><link linkend="GtkShortcutAction"><returnvalue>GtkShortcutAction</returnvalue></link>&#160;*
gtk_nothing_action_get (<parameter><type>void</type></parameter>);</programlisting>
<para>Gets the nothing action. This is an action that does nothing and where
activating it always fails.</para>
<refsect3 id="gtk-nothing-action-get.returns" role="returns">
<title>Returns</title>
<para>The nothing action. </para>
<para><emphasis role="annotation">[<acronym>transfer none</acronym>]</emphasis></para>
</refsect3></refsect2>
<refsect2 id="gtk-callback-action-new" role="function">
<title>gtk_callback_action_new&#160;()</title>
<indexterm zone="gtk-callback-action-new"><primary>gtk_callback_action_new</primary></indexterm>
<programlisting language="C"><link linkend="GtkShortcutAction"><returnvalue>GtkShortcutAction</returnvalue></link>&#160;*
gtk_callback_action_new (<parameter><link linkend="GtkShortcutFunc"><type>GtkShortcutFunc</type></link> callback</parameter>,
                         <parameter><link linkend="gpointer"><type>gpointer</type></link> data</parameter>,
                         <parameter><link linkend="GDestroyNotify"><type>GDestroyNotify</type></link> destroy</parameter>);</programlisting>
<para>Create a custom action that calls the given <parameter>callback</parameter>
 when
activated.</para>
<refsect3 id="gtk-callback-action-new.parameters" role="parameters">
<title>Parameters</title>
<informaltable role="parameters_table" pgwide="1" frame="none">
<tgroup cols="3">
<colspec colname="parameters_name" colwidth="150px"/>
<colspec colname="parameters_description"/>
<colspec colname="parameters_annotations" colwidth="200px"/>
<tbody>
<row><entry role="parameter_name"><para>callback</para></entry>
<entry role="parameter_description"><para>the callback to call. </para></entry>
<entry role="parameter_annotations"><emphasis role="annotation">[<acronym>scope notified</acronym>]</emphasis></entry></row>
<row><entry role="parameter_name"><para>data</para></entry>
<entry role="parameter_description"><para>the data to be passed to <parameter>callback</parameter>
. </para></entry>
<entry role="parameter_annotations"><emphasis role="annotation">[<acronym>closure</acronym> callback]</emphasis></entry></row>
<row><entry role="parameter_name"><para>destroy</para></entry>
<entry role="parameter_description"><para>the function to be called when the
callback action is finalized. </para></entry>
<entry role="parameter_annotations"><emphasis role="annotation">[<acronym>destroy</acronym> data]</emphasis></entry></row>
</tbody></tgroup></informaltable>
</refsect3><refsect3 id="gtk-callback-action-new.returns" role="returns">
<title>Returns</title>
<para>A new shortcut action. </para>
<para><emphasis role="annotation">[<acronym>transfer full</acronym>]</emphasis></para>
</refsect3></refsect2>
<refsect2 id="gtk-mnemonic-action-get" role="function">
<title>gtk_mnemonic_action_get&#160;()</title>
<indexterm zone="gtk-mnemonic-action-get"><primary>gtk_mnemonic_action_get</primary></indexterm>
<programlisting language="C"><link linkend="GtkShortcutAction"><returnvalue>GtkShortcutAction</returnvalue></link>&#160;*
gtk_mnemonic_action_get (<parameter><type>void</type></parameter>);</programlisting>
<para>Gets the mnemonic action. This is an action that calls
<link linkend="gtk-widget-mnemonic-activate"><function>gtk_widget_mnemonic_activate()</function></link> on the given widget upon activation.</para>
<refsect3 id="gtk-mnemonic-action-get.returns" role="returns">
<title>Returns</title>
<para>The mnemonic action. </para>
<para><emphasis role="annotation">[<acronym>transfer none</acronym>]</emphasis></para>
</refsect3></refsect2>
<refsect2 id="gtk-activate-action-get" role="function">
<title>gtk_activate_action_get&#160;()</title>
<indexterm zone="gtk-activate-action-get"><primary>gtk_activate_action_get</primary></indexterm>
<programlisting language="C"><link linkend="GtkShortcutAction"><returnvalue>GtkShortcutAction</returnvalue></link>&#160;*
gtk_activate_action_get (<parameter><type>void</type></parameter>);</programlisting>
<para>Gets the activate action. This is an action that calls <link linkend="gtk-widget-activate"><function>gtk_widget_activate()</function></link>
on the given widget upon activation.</para>
<refsect3 id="gtk-activate-action-get.returns" role="returns">
<title>Returns</title>
<para>The activate action. </para>
<para><emphasis role="annotation">[<acronym>transfer none</acronym>]</emphasis></para>
</refsect3></refsect2>
<refsect2 id="gtk-signal-action-new" role="function">
<title>gtk_signal_action_new&#160;()</title>
<indexterm zone="gtk-signal-action-new"><primary>gtk_signal_action_new</primary></indexterm>
<programlisting language="C"><link linkend="GtkShortcutAction"><returnvalue>GtkShortcutAction</returnvalue></link>&#160;*
gtk_signal_action_new (<parameter>const <link linkend="char"><type>char</type></link> *signal_name</parameter>);</programlisting>
<para>Creates an action that when activated, emits the given action signal
on the provided widget unpacking the given args into arguments passed
to the signal.</para>
<refsect3 id="gtk-signal-action-new.parameters" role="parameters">
<title>Parameters</title>
<informaltable role="parameters_table" pgwide="1" frame="none">
<tgroup cols="3">
<colspec colname="parameters_name" colwidth="150px"/>
<colspec colname="parameters_description"/>
<colspec colname="parameters_annotations" colwidth="200px"/>
<tbody>
<row><entry role="parameter_name"><para>signal_name</para></entry>
<entry role="parameter_description"><para>name of the signal to emit</para></entry>
<entry role="parameter_annotations"></entry></row>
</tbody></tgroup></informaltable>
</refsect3><refsect3 id="gtk-signal-action-new.returns" role="returns">
<title>Returns</title>
<para>a new <link linkend="GtkShortcutAction"><type>GtkShortcutAction</type></link>. </para>
<para><emphasis role="annotation">[<acronym>transfer full</acronym>][<acronym>type</acronym> GtkSignalAction]</emphasis></para>
</refsect3></refsect2>
<refsect2 id="gtk-signal-action-get-signal-name" role="function">
<title>gtk_signal_action_get_signal_name&#160;()</title>
<indexterm zone="gtk-signal-action-get-signal-name"><primary>gtk_signal_action_get_signal_name</primary></indexterm>
<programlisting language="C">const <link linkend="char"><returnvalue>char</returnvalue></link>&#160;*
gtk_signal_action_get_signal_name (<parameter><link linkend="GtkSignalAction"><type>GtkSignalAction</type></link> *self</parameter>);</programlisting>
<para>Returns the name of the signal that will be emitted.</para>
<refsect3 id="gtk-signal-action-get-signal-name.parameters" role="parameters">
<title>Parameters</title>
<informaltable role="parameters_table" pgwide="1" frame="none">
<tgroup cols="3">
<colspec colname="parameters_name" colwidth="150px"/>
<colspec colname="parameters_description"/>
<colspec colname="parameters_annotations" colwidth="200px"/>
<tbody>
<row><entry role="parameter_name"><para>self</para></entry>
<entry role="parameter_description"><para>a signal action</para></entry>
<entry role="parameter_annotations"></entry></row>
</tbody></tgroup></informaltable>
</refsect3><refsect3 id="gtk-signal-action-get-signal-name.returns" role="returns">
<title>Returns</title>
<para>the name of the signal to emit. </para>
<para><emphasis role="annotation">[<acronym>transfer none</acronym>]</emphasis></para>
</refsect3></refsect2>
<refsect2 id="gtk-named-action-new" role="function">
<title>gtk_named_action_new&#160;()</title>
<indexterm zone="gtk-named-action-new"><primary>gtk_named_action_new</primary></indexterm>
<programlisting language="C"><link linkend="GtkShortcutAction"><returnvalue>GtkShortcutAction</returnvalue></link>&#160;*
gtk_named_action_new (<parameter>const <link linkend="char"><type>char</type></link> *name</parameter>);</programlisting>
<para>Creates an action that when activated, activates the action given by
the detailed <parameter>name</parameter>
 on the widget passing the given arguments to it.</para>
<para>See <link linkend="gtk-widget-insert-action-group"><function>gtk_widget_insert_action_group()</function></link> for how to add actions to widgets.</para>
<refsect3 id="gtk-named-action-new.parameters" role="parameters">
<title>Parameters</title>
<informaltable role="parameters_table" pgwide="1" frame="none">
<tgroup cols="3">
<colspec colname="parameters_name" colwidth="150px"/>
<colspec colname="parameters_description"/>
<colspec colname="parameters_annotations" colwidth="200px"/>
<tbody>
<row><entry role="parameter_name"><para>name</para></entry>
<entry role="parameter_description"><para>the detailed name of the action</para></entry>
<entry role="parameter_annotations"></entry></row>
</tbody></tgroup></informaltable>
</refsect3><refsect3 id="gtk-named-action-new.returns" role="returns">
<title>Returns</title>
<para>a new <link linkend="GtkShortcutAction"><type>GtkShortcutAction</type></link>. </para>
<para><emphasis role="annotation">[<acronym>transfer full</acronym>][<acronym>type</acronym> GtkNamedAction]</emphasis></para>
</refsect3></refsect2>
<refsect2 id="gtk-named-action-get-action-name" role="function">
<title>gtk_named_action_get_action_name&#160;()</title>
<indexterm zone="gtk-named-action-get-action-name"><primary>gtk_named_action_get_action_name</primary></indexterm>
<programlisting language="C">const <link linkend="char"><returnvalue>char</returnvalue></link>&#160;*
gtk_named_action_get_action_name (<parameter><link linkend="GtkNamedAction"><type>GtkNamedAction</type></link> *self</parameter>);</programlisting>
<para>Returns the name of the action that will be activated.</para>
<refsect3 id="gtk-named-action-get-action-name.parameters" role="parameters">
<title>Parameters</title>
<informaltable role="parameters_table" pgwide="1" frame="none">
<tgroup cols="3">
<colspec colname="parameters_name" colwidth="150px"/>
<colspec colname="parameters_description"/>
<colspec colname="parameters_annotations" colwidth="200px"/>
<tbody>
<row><entry role="parameter_name"><para>self</para></entry>
<entry role="parameter_description"><para>a named action</para></entry>
<entry role="parameter_annotations"></entry></row>
</tbody></tgroup></informaltable>
</refsect3><refsect3 id="gtk-named-action-get-action-name.returns" role="returns">
<title>Returns</title>
<para> the name of the action to activate</para>
</refsect3></refsect2>

</refsect1>
<refsect1 id="GtkShortcutAction.other_details" role="details">
<title role="details.title">Types and Values</title>
<refsect2 id="GtkShortcutAction-struct" role="struct">
<title>GtkShortcutAction</title>
<indexterm zone="GtkShortcutAction-struct"><primary>GtkShortcutAction</primary></indexterm>
<programlisting language="C">typedef struct _GtkShortcutAction GtkShortcutAction;</programlisting>
</refsect2>
<refsect2 id="GtkShortcutActionFlags" role="enum">
<title>enum GtkShortcutActionFlags</title>
<indexterm zone="GtkShortcutActionFlags"><primary>GtkShortcutActionFlags</primary></indexterm>
<para>List of flags that can be passed to action activation.
More flags may be added in the future.</para>
<refsect3 id="GtkShortcutActionFlags.members" role="enum_members">
<title>Members</title>
<informaltable role="enum_members_table" pgwide="1" frame="none">
<tgroup cols="3">
<colspec colname="enum_members_name" colwidth="300px"/>
<colspec colname="enum_members_description"/>
<colspec colname="enum_members_annotations" colwidth="200px"/>
<tbody>
<row role="constant"><entry role="enum_member_name"><para id="GTK-SHORTCUT-ACTION-EXCLUSIVE:CAPS">GTK_SHORTCUT_ACTION_EXCLUSIVE</para></entry>
<entry role="enum_member_description"><para>The action is the only
action that can be activated. If this flag is not set,
a future activation may select a different action.</para>
</entry>
<entry role="enum_member_annotations"></entry>
</row>
</tbody></tgroup></informaltable>
</refsect3></refsect2>
<refsect2 id="GtkNothingAction-struct" role="struct">
<title>GtkNothingAction</title>
<indexterm zone="GtkNothingAction-struct"><primary>GtkNothingAction</primary></indexterm>
<programlisting language="C">typedef struct _GtkNothingAction GtkNothingAction;</programlisting>
<para>A <link linkend="GtkShortcutAction"><type>GtkShortcutAction</type></link> that does nothing.</para>
</refsect2>
<refsect2 id="GtkCallbackAction-struct" role="struct">
<title>GtkCallbackAction</title>
<indexterm zone="GtkCallbackAction-struct"><primary>GtkCallbackAction</primary></indexterm>
<programlisting language="C">typedef struct _GtkCallbackAction GtkCallbackAction;</programlisting>
<para>A <link linkend="GtkShortcutAction"><type>GtkShortcutAction</type></link> that invokes a callback.</para>
</refsect2>
<refsect2 id="GtkMnemonicAction" role="struct">
<title>GtkMnemonicAction</title>
<indexterm zone="GtkMnemonicAction"><primary>GtkMnemonicAction</primary></indexterm>
<programlisting language="C">typedef struct _GtkMnemonicAction GtkMnemonicAction;</programlisting>
<para>A <link linkend="GtkShortcutAction"><type>GtkShortcutAction</type></link> that calls <link linkend="gtk-widget-mnemonic-activate"><function>gtk_widget_mnemonic_activate()</function></link>.</para>
</refsect2>
<refsect2 id="GtkActivateAction" role="struct">
<title>GtkActivateAction</title>
<indexterm zone="GtkActivateAction"><primary>GtkActivateAction</primary></indexterm>
<programlisting language="C">typedef struct _GtkActivateAction GtkActivateAction;</programlisting>
<para>A <link linkend="GtkShortcutAction"><type>GtkShortcutAction</type></link> that calls <link linkend="gtk-widget-activate"><function>gtk_widget_activate()</function></link>.</para>
</refsect2>
<refsect2 id="GtkSignalAction-struct" role="struct">
<title>GtkSignalAction</title>
<indexterm zone="GtkSignalAction-struct"><primary>GtkSignalAction</primary></indexterm>
<programlisting language="C">typedef struct _GtkSignalAction GtkSignalAction;</programlisting>
<para>A <link linkend="GtkShortcutAction"><type>GtkShortcutAction</type></link> that emits a signal.</para>
</refsect2>
<refsect2 id="GtkNamedAction-struct" role="struct">
<title>GtkNamedAction</title>
<indexterm zone="GtkNamedAction-struct"><primary>GtkNamedAction</primary></indexterm>
<programlisting language="C">typedef struct _GtkNamedAction GtkNamedAction;</programlisting>
<para>A <link linkend="GtkShortcutAction"><type>GtkShortcutAction</type></link> that activates an action by name.</para>
</refsect2>

</refsect1>
<refsect1 id="GtkShortcutAction.see-also">
<title>See Also</title>
<para><link linkend="GtkShortcut"><type>GtkShortcut</type></link></para>

</refsect1>

</refentry>
