1 /*
2  * Copyright (C) 2002 Red Hat, Inc.
3  *
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.1 of the License, or (at your option) any later version.
8  *
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.
13  *
14  * You should have received a copy of the GNU Lesser General Public
15  * License along with this library; if not, write to the Free Software
16  * Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301  USA
17  */
18 
19 /* The interfaces in this file are subject to change at any time. */
20 
21 #ifndef vte_keymap_h_included
22 #define vte_keymap_h_included
23 
24 #include <glib.h>
25 #include <gdk/gdk.h>
26 
27 G_BEGIN_DECLS
28 
29 #define VTE_META_MASK		GDK_META_MASK
30 #define VTE_NUMLOCK_MASK	GDK_MOD2_MASK
31 
32 /* Map the specified keyval/modifier setup, dependent on the mode, to either
33  * a literal string or a capability name. */
34 void _vte_keymap_map(guint keyval,
35 		     GdkModifierType modifiers,
36 		     gboolean app_cursor_keys,
37 		     gboolean app_keypad_keys,
38 		     char **normal,
39 		     gssize *normal_length);
40 
41 /* Return TRUE if a keyval is just a modifier key. */
42 gboolean _vte_keymap_key_is_modifier(guint keyval);
43 
44 /* Add modifiers to the sequence if they're needed. */
45 void _vte_keymap_key_add_key_modifiers(guint keyval,
46 				       GdkModifierType modifiers,
47 				       gboolean app_cursor_keys,
48 				       char **normal,
49 				       gssize *normal_length);
50 
51 G_END_DECLS
52 
53 #endif
54