+/**
+ * gtk_action_set_always_show_image:
+ * @action: a #GtkAction
+ * @always_show: %TRUE if menuitem proxies should always show their image
+ *
+ * Sets whether @action<!-- -->'s menu item proxies will ignore the
+ * #GtkSettings:gtk-menu-images setting and always show their image, if available.
+ *
+ * Use this if the menu item would be useless or hard to use
+ * without their image.
+ *
+ * Since: 2.20
+ */
+void
+gtk_action_set_always_show_image (GtkAction *action,
+ gboolean always_show)
+{
+ GtkActionPrivate *priv;
+
+ g_return_if_fail (GTK_IS_ACTION (action));
+
+ priv = action->private_data;
+
+ always_show = always_show != FALSE;
+
+ if (priv->always_show_image != always_show)
+ {
+ priv->always_show_image = always_show;
+
+ g_object_notify (G_OBJECT (action), "always-show-image");
+ }
+}
+
+/**
+ * gtk_action_get_always_show_image:
+ * @action: a #GtkAction
+ *
+ * Returns whether @action<!-- -->'s menu item proxies will ignore the
+ * #GtkSettings:gtk-menu-images setting and always show their image,
+ * if available.
+ *
+ * Returns: %TRUE if the menu item proxies will always show their image
+ *
+ * Since: 2.20
+ */
+gboolean
+gtk_action_get_always_show_image (GtkAction *action)
+{
+ g_return_val_if_fail (GTK_IS_ACTION (action), FALSE);
+
+ return action->private_data->always_show_image;
+}
+
+/**
+ * gtk_action_set_label:
+ * @action: a #GtkAction
+ * @label: the label text to set
+ *
+ * Sets the label of @action.
+ *
+ * Since: 2.16
+ */
+void
+gtk_action_set_label (GtkAction *action,
+ const gchar *label)
+{
+ gchar *tmp;
+
+ g_return_if_fail (GTK_IS_ACTION (action));
+
+ tmp = action->private_data->label;
+ action->private_data->label = g_strdup (label);
+ g_free (tmp);
+ action->private_data->label_set = (action->private_data->label != NULL);
+ /* if label is unset, then use the label from the stock item */
+ if (!action->private_data->label_set && action->private_data->stock_id)
+ {
+ GtkStockItem stock_item;
+
+ if (gtk_stock_lookup (action->private_data->stock_id, &stock_item))
+ action->private_data->label = g_strdup (stock_item.label);
+ }
+
+ g_object_notify (G_OBJECT (action), "label");
+
+ /* if short_label is unset, set short_label=label */
+ if (!action->private_data->short_label_set)
+ {
+ gtk_action_set_short_label (action, action->private_data->label);
+ action->private_data->short_label_set = FALSE;
+ }
+}
+
+/**
+ * gtk_action_get_label:
+ * @action: a #GtkAction
+ *
+ * Gets the label text of @action.
+ *
+ * Returns: the label text
+ *
+ * Since: 2.16
+ */
+const gchar *
+gtk_action_get_label (GtkAction *action)
+{
+ g_return_val_if_fail (GTK_IS_ACTION (action), NULL);
+
+ return action->private_data->label;
+}
+
+/**
+ * gtk_action_set_short_label:
+ * @action: a #GtkAction
+ * @short_label: the label text to set
+ *
+ * Sets a shorter label text on @action.
+ *
+ * Since: 2.16
+ */
+void
+gtk_action_set_short_label (GtkAction *action,
+ const gchar *short_label)
+{
+ gchar *tmp;
+
+ g_return_if_fail (GTK_IS_ACTION (action));
+
+ tmp = action->private_data->short_label;
+ action->private_data->short_label = g_strdup (short_label);
+ g_free (tmp);
+ action->private_data->short_label_set = (action->private_data->short_label != NULL);
+ /* if short_label is unset, then use the value of label */
+ if (!action->private_data->short_label_set)
+ action->private_data->short_label = g_strdup (action->private_data->label);
+
+ g_object_notify (G_OBJECT (action), "short-label");
+}
+
+/**
+ * gtk_action_get_short_label:
+ * @action: a #GtkAction
+ *
+ * Gets the short label text of @action.
+ *
+ * Returns: the short label text.
+ *
+ * Since: 2.16
+ */
+const gchar *
+gtk_action_get_short_label (GtkAction *action)
+{
+ g_return_val_if_fail (GTK_IS_ACTION (action), NULL);
+
+ return action->private_data->short_label;
+}
+
+/**
+ * gtk_action_set_visible_horizontal:
+ * @action: a #GtkAction
+ * @visible_horizontal: whether the action is visible horizontally
+ *
+ * Sets whether @action is visible when horizontal
+ *
+ * Since: 2.16
+ */
+void
+gtk_action_set_visible_horizontal (GtkAction *action,
+ gboolean visible_horizontal)
+{
+ g_return_if_fail (GTK_IS_ACTION (action));
+
+ g_return_if_fail (GTK_IS_ACTION (action));
+
+ visible_horizontal = visible_horizontal != FALSE;
+
+ if (action->private_data->visible_horizontal != visible_horizontal)
+ {
+ action->private_data->visible_horizontal = visible_horizontal;
+
+ g_object_notify (G_OBJECT (action), "visible-horizontal");
+ }
+}
+
+/**
+ * gtk_action_get_visible_horizontal:
+ * @action: a #GtkAction
+ *
+ * Checks whether @action is visible when horizontal
+ *
+ * Returns: whether @action is visible when horizontal
+ *
+ * Since: 2.16
+ */
+gboolean
+gtk_action_get_visible_horizontal (GtkAction *action)
+{
+ g_return_val_if_fail (GTK_IS_ACTION (action), FALSE);
+
+ return action->private_data->visible_horizontal;
+}
+
+/**
+ * gtk_action_set_visible_vertical:
+ * @action: a #GtkAction
+ * @visible_vertical: whether the action is visible vertically
+ *
+ * Sets whether @action is visible when vertical
+ *
+ * Since: 2.16
+ */
+void
+gtk_action_set_visible_vertical (GtkAction *action,
+ gboolean visible_vertical)
+{
+ g_return_if_fail (GTK_IS_ACTION (action));
+
+ g_return_if_fail (GTK_IS_ACTION (action));
+
+ visible_vertical = visible_vertical != FALSE;
+
+ if (action->private_data->visible_vertical != visible_vertical)
+ {
+ action->private_data->visible_vertical = visible_vertical;
+
+ g_object_notify (G_OBJECT (action), "visible-vertical");
+ }
+}
+
+/**
+ * gtk_action_get_visible_vertical:
+ * @action: a #GtkAction
+ *
+ * Checks whether @action is visible when horizontal
+ *
+ * Returns: whether @action is visible when horizontal
+ *
+ * Since: 2.16
+ */
+gboolean
+gtk_action_get_visible_vertical (GtkAction *action)
+{
+ g_return_val_if_fail (GTK_IS_ACTION (action), FALSE);
+
+ return action->private_data->visible_vertical;
+}
+
+/**
+ * gtk_action_set_tooltip:
+ * @action: a #GtkAction
+ * @tooltip: the tooltip text
+ *
+ * Sets the tooltip text on @action
+ *
+ * Since: 2.16
+ */
+void
+gtk_action_set_tooltip (GtkAction *action,
+ const gchar *tooltip)
+{
+ gchar *tmp;
+
+ g_return_if_fail (GTK_IS_ACTION (action));
+
+ tmp = action->private_data->tooltip;
+ action->private_data->tooltip = g_strdup (tooltip);
+ g_free (tmp);
+
+ g_object_notify (G_OBJECT (action), "tooltip");
+}
+
+/**
+ * gtk_action_get_tooltip:
+ * @action: a #GtkAction
+ *
+ * Gets the tooltip text of @action.
+ *
+ * Returns: the tooltip text
+ *
+ * Since: 2.16
+ */
+const gchar *
+gtk_action_get_tooltip (GtkAction *action)
+{
+ g_return_val_if_fail (GTK_IS_ACTION (action), NULL);
+
+ return action->private_data->tooltip;
+}
+
+/**
+ * gtk_action_set_stock_id:
+ * @action: a #GtkAction
+ * @stock_id: the stock id
+ *
+ * Sets the stock id on @action
+ *
+ * Since: 2.16
+ */
+void
+gtk_action_set_stock_id (GtkAction *action,
+ const gchar *stock_id)
+{
+ gchar *tmp;
+
+ g_return_if_fail (GTK_IS_ACTION (action));
+
+ g_return_if_fail (GTK_IS_ACTION (action));
+
+ tmp = action->private_data->stock_id;
+ action->private_data->stock_id = g_strdup (stock_id);
+ g_free (tmp);
+
+ g_object_notify (G_OBJECT (action), "stock-id");
+
+ /* update label and short_label if appropriate */
+ if (!action->private_data->label_set)
+ {
+ GtkStockItem stock_item;
+
+ if (action->private_data->stock_id &&
+ gtk_stock_lookup (action->private_data->stock_id, &stock_item))
+ gtk_action_set_label (action, stock_item.label);
+ else
+ gtk_action_set_label (action, NULL);
+
+ action->private_data->label_set = FALSE;
+ }
+}
+
+/**
+ * gtk_action_get_stock_id:
+ * @action: a #GtkAction
+ *
+ * Gets the stock id of @action.
+ *
+ * Returns: the stock id
+ *
+ * Since: 2.16
+ */
+const gchar *
+gtk_action_get_stock_id (GtkAction *action)
+{
+ g_return_val_if_fail (GTK_IS_ACTION (action), NULL);
+
+ return action->private_data->stock_id;
+}
+
+/**
+ * gtk_action_set_icon_name:
+ * @action: a #GtkAction
+ * @icon_name: the icon name to set
+ *
+ * Sets the icon name on @action
+ *
+ * Since: 2.16
+ */
+void
+gtk_action_set_icon_name (GtkAction *action,
+ const gchar *icon_name)
+{
+ gchar *tmp;
+
+ g_return_if_fail (GTK_IS_ACTION (action));
+
+ tmp = action->private_data->icon_name;
+ action->private_data->icon_name = g_strdup (icon_name);
+ g_free (tmp);
+
+ g_object_notify (G_OBJECT (action), "icon-name");
+}
+
+/**
+ * gtk_action_get_icon_name:
+ * @action: a #GtkAction
+ *
+ * Gets the icon name of @action.
+ *
+ * Returns: the icon name
+ *
+ * Since: 2.16
+ */
+const gchar *
+gtk_action_get_icon_name (GtkAction *action)
+{
+ g_return_val_if_fail (GTK_IS_ACTION (action), NULL);
+
+ return action->private_data->icon_name;
+}
+
+/**
+ * gtk_action_set_gicon:
+ * @action: a #GtkAction
+ * @icon: the #GIcon to set
+ *
+ * Sets the icon of @action.
+ *
+ * Since: 2.16
+ */
+void
+gtk_action_set_gicon (GtkAction *action,
+ GIcon *icon)
+{
+ g_return_if_fail (GTK_IS_ACTION (action));
+
+ if (action->private_data->gicon)
+ g_object_unref (action->private_data->gicon);
+
+ action->private_data->gicon = icon;
+
+ if (action->private_data->gicon)
+ g_object_ref (action->private_data->gicon);
+
+ g_object_notify (G_OBJECT (action), "gicon");
+}
+
+/**
+ * gtk_action_get_gicon:
+ * @action: a #GtkAction
+ *
+ * Gets the gicon of @action.
+ *
+ * Returns: (transfer none): The action's #GIcon if one is set.
+ *
+ * Since: 2.16
+ */
+GIcon *
+gtk_action_get_gicon (GtkAction *action)
+{
+ g_return_val_if_fail (GTK_IS_ACTION (action), NULL);
+
+ return action->private_data->gicon;
+}
+
+static void
+closure_accel_activate (GClosure *closure,
+ GValue *return_value,
+ guint n_param_values,
+ const GValue *param_values,
+ gpointer invocation_hint,