1 /* GTK - The GIMP Toolkit
2 * Copyright (C) 1998, 2001 Tim Janik
4 * This library is free software; you can redistribute it and/or
5 * modify it under the terms of the GNU Lesser General Public
6 * License as published by the Free Software Foundation; either
7 * version 2 of the License, or (at your option) any later version.
9 * This library is distributed in the hope that it will be useful,
10 * but WITHOUT ANY WARRANTY; without even the implied warranty of
11 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
12 * Lesser General Public License for more details.
14 * You should have received a copy of the GNU Lesser General Public
15 * License along with this library; if not, write to the
16 * Free Software Foundation, Inc., 59 Temple Place - Suite 330,
17 * Boston, MA 02111-1307, USA.
19 #ifndef __GTK_ACCEL_MAP_H__
20 #define __GTK_ACCEL_MAP_H__
23 #include <gtk/gtkaccelgroup.h>
28 /* --- notifier --- */
29 typedef void (*GtkAccelMapForeach) (gpointer data,
30 const gchar *accel_path,
36 /* --- public API --- */
37 void gtk_accel_map_add_entry (const gchar *accel_path,
40 gboolean gtk_accel_map_lookup_entry (const gchar *accel_path,
42 gboolean gtk_accel_map_change_entry (const gchar *accel_path,
44 GdkModifierType accel_mods,
46 void gtk_accel_map_load (const gchar *file_name);
47 void gtk_accel_map_save (const gchar *file_name);
48 void gtk_accel_map_foreach (gpointer data,
49 GtkAccelMapForeach foreach_func);
50 void gtk_accel_map_load_fd (gint fd);
51 void gtk_accel_map_load_scanner (GScanner *scanner);
52 void gtk_accel_map_save_fd (gint fd);
55 /* --- filter functions --- */
56 void gtk_accel_map_add_filter (const gchar *filter_pattern);
57 void gtk_accel_map_foreach_unfilterd (gpointer data,
58 GtkAccelMapForeach foreach_func);
61 /* --- internal API --- */
62 void _gtk_accel_map_init (void);
64 void _gtk_accel_map_add_group (const gchar *accel_path,
65 GtkAccelGroup *accel_group);
66 void _gtk_accel_map_remove_group (const gchar *accel_path,
67 GtkAccelGroup *accel_group);
68 gboolean _gtk_accel_path_is_valid (const gchar *accel_path);
73 #endif /* __GTK_ACCEL_MAP_H__ */