Commit b2f3b5a6 authored by Egmont Koblinger's avatar Egmont Koblinger

build: Clean up gdk keysym names

parent 663cb180
......@@ -37,8 +37,6 @@
#include <gtk/gtk.h>
#define GDK_KEY(symbol) GDK_KEY_##symbol
/* Maps which jive with XTerm's ESC ()*+ ? sequences, RFC 1468. Add the
* PC437 map because despite knowing that XTerm doesn't support it, certain
* applications try to use it anyway. */
......@@ -118,7 +116,7 @@ static const struct _vte_iso2022_map16 _vte_iso2022_map_0[] = {
};
/* United Kingdom. VT100 and higher (per XTerm docs). */
static const struct _vte_iso2022_map16 _vte_iso2022_map_A[] = {
{'$', GDK_KEY (sterling)},
{'$', GDK_KEY_sterling},
};
/* US-ASCII (no conversions). VT100 and higher (per XTerm docs). */
static const struct _vte_iso2022_map16 _vte_iso2022_map_B[] = {
......@@ -126,128 +124,128 @@ static const struct _vte_iso2022_map16 _vte_iso2022_map_B[] = {
};
/* Dutch. VT220 and higher (per XTerm docs). */
static const struct _vte_iso2022_map16 _vte_iso2022_map_4[] = {
{'#', GDK_KEY (sterling)},
{'@', GDK_KEY (threequarters)},
{'[', GDK_KEY (ydiaeresis)},
{'\\', GDK_KEY (onehalf)},
{']', GDK_KEY (bar)}, /* FIXME? not in XTerm 170 */
{'{', GDK_KEY (diaeresis)},
{'#', GDK_KEY_sterling},
{'@', GDK_KEY_threequarters},
{'[', GDK_KEY_ydiaeresis},
{'\\', GDK_KEY_onehalf},
{']', GDK_KEY_bar}, /* FIXME? not in XTerm 170 */
{'{', GDK_KEY_diaeresis},
{'|', 0x192}, /* f with hook (florin) */ /* FIXME? not in XTerm 170 */
{'}', GDK_KEY (onequarter)},
{'~', GDK_KEY (acute)}
{'}', GDK_KEY_onequarter},
{'~', GDK_KEY_acute},
};
/* Finnish. VT220 and higher (per XTerm docs). */
static const struct _vte_iso2022_map16 _vte_iso2022_map_C[] = {
{'[', GDK_KEY (Adiaeresis)},
{'\\', GDK_KEY (Odiaeresis)},
{']', GDK_KEY (Aring)},
{'^', GDK_KEY (Udiaeresis)},
{'`', GDK_KEY (eacute)},
{'{', GDK_KEY (adiaeresis)},
{'|', GDK_KEY (odiaeresis)},
{'}', GDK_KEY (aring)},
{'~', GDK_KEY (udiaeresis)},
{'[', GDK_KEY_Adiaeresis},
{'\\', GDK_KEY_Odiaeresis},
{']', GDK_KEY_Aring},
{'^', GDK_KEY_Udiaeresis},
{'`', GDK_KEY_eacute},
{'{', GDK_KEY_adiaeresis},
{'|', GDK_KEY_odiaeresis},
{'}', GDK_KEY_aring},
{'~', GDK_KEY_udiaeresis},
};
/* French. VT220 and higher (per XTerm docs). */
static const struct _vte_iso2022_map16 _vte_iso2022_map_R[] = {
{'#', GDK_KEY (sterling)},
{'@', GDK_KEY (agrave)},
{'[', GDK_KEY (degree)},
{'\\', GDK_KEY (ccedilla)},
{']', GDK_KEY (section)},
{'{', GDK_KEY (eacute)},
{'|', GDK_KEY (ugrave)},
{'}', GDK_KEY (egrave)},
{'~', GDK_KEY (diaeresis)},
{'#', GDK_KEY_sterling},
{'@', GDK_KEY_agrave},
{'[', GDK_KEY_degree},
{'\\', GDK_KEY_ccedilla},
{']', GDK_KEY_section},
{'{', GDK_KEY_eacute},
{'|', GDK_KEY_ugrave},
{'}', GDK_KEY_egrave},
{'~', GDK_KEY_diaeresis},
};
/* French Canadian. VT220 and higher (per XTerm docs). */
static const struct _vte_iso2022_map16 _vte_iso2022_map_Q[] = {
{'@', GDK_KEY (agrave)},
{'[', GDK_KEY (acircumflex)},
{'\\', GDK_KEY (ccedilla)},
{']', GDK_KEY (ecircumflex)},
{'^', GDK_KEY (icircumflex)},
{'`', GDK_KEY (ocircumflex)},
{'{', GDK_KEY (eacute)},
{'|', GDK_KEY (ugrave)},
{'}', GDK_KEY (egrave)},
{'~', GDK_KEY (ucircumflex)},
{'@', GDK_KEY_agrave},
{'[', GDK_KEY_acircumflex},
{'\\', GDK_KEY_ccedilla},
{']', GDK_KEY_ecircumflex},
{'^', GDK_KEY_icircumflex},
{'`', GDK_KEY_ocircumflex},
{'{', GDK_KEY_eacute},
{'|', GDK_KEY_ugrave},
{'}', GDK_KEY_egrave},
{'~', GDK_KEY_ucircumflex},
};
/* German. VT220 and higher (per XTerm docs). */
static const struct _vte_iso2022_map16 _vte_iso2022_map_K[] = {
{'@', GDK_KEY (section)},
{'[', GDK_KEY (Adiaeresis)},
{'\\', GDK_KEY (Odiaeresis)},
{']', GDK_KEY (Udiaeresis)},
{'{', GDK_KEY (adiaeresis)},
{'|', GDK_KEY (odiaeresis)},
{'}', GDK_KEY (udiaeresis)},
{'~', GDK_KEY (ssharp)},
{'@', GDK_KEY_section},
{'[', GDK_KEY_Adiaeresis},
{'\\', GDK_KEY_Odiaeresis},
{']', GDK_KEY_Udiaeresis},
{'{', GDK_KEY_adiaeresis},
{'|', GDK_KEY_odiaeresis},
{'}', GDK_KEY_udiaeresis},
{'~', GDK_KEY_ssharp},
};
/* Italian. VT220 and higher (per XTerm docs). */
static const struct _vte_iso2022_map16 _vte_iso2022_map_Y[] = {
{'#', GDK_KEY (sterling)},
{'@', GDK_KEY (section)},
{'[', GDK_KEY (degree)},
{'\\', GDK_KEY (ccedilla)},
{']', GDK_KEY (eacute)},
{'`', GDK_KEY (ugrave)},
{'{', GDK_KEY (agrave)},
{'|', GDK_KEY (ograve)},
{'}', GDK_KEY (egrave)},
{'~', GDK_KEY (igrave)},
{'#', GDK_KEY_sterling},
{'@', GDK_KEY_section},
{'[', GDK_KEY_degree},
{'\\', GDK_KEY_ccedilla},
{']', GDK_KEY_eacute},
{'`', GDK_KEY_ugrave},
{'{', GDK_KEY_agrave},
{'|', GDK_KEY_ograve},
{'}', GDK_KEY_egrave},
{'~', GDK_KEY_igrave},
};
/* Norwegian and Danish. VT220 and higher (per XTerm docs). */
static const struct _vte_iso2022_map16 _vte_iso2022_map_E[] = {
{'@', GDK_KEY (Adiaeresis)},
{'[', GDK_KEY (AE)},
{'\\', GDK_KEY (Ooblique)},
{']', GDK_KEY (Aring)},
{'^', GDK_KEY (Udiaeresis)},
{'`', GDK_KEY (adiaeresis)},
{'{', GDK_KEY (ae)},
{'|', GDK_KEY (oslash)},
{'}', GDK_KEY (aring)},
{'~', GDK_KEY (udiaeresis)},
{'@', GDK_KEY_Adiaeresis},
{'[', GDK_KEY_AE},
{'\\', GDK_KEY_Ooblique},
{']', GDK_KEY_Aring},
{'^', GDK_KEY_Udiaeresis},
{'`', GDK_KEY_adiaeresis},
{'{', GDK_KEY_ae},
{'|', GDK_KEY_oslash},
{'}', GDK_KEY_aring},
{'~', GDK_KEY_udiaeresis},
};
/* Spanish. VT220 and higher (per XTerm docs). */
static const struct _vte_iso2022_map16 _vte_iso2022_map_Z[] = {
{'#', GDK_KEY (sterling)},
{'@', GDK_KEY (section)},
{'[', GDK_KEY (exclamdown)},
{'\\', GDK_KEY (Ntilde)},
{']', GDK_KEY (questiondown)},
{'{', GDK_KEY (degree)},
{'|', GDK_KEY (ntilde)},
{'}', GDK_KEY (ccedilla)},
{'#', GDK_KEY_sterling},
{'@', GDK_KEY_section},
{'[', GDK_KEY_exclamdown},
{'\\', GDK_KEY_Ntilde},
{']', GDK_KEY_questiondown},
{'{', GDK_KEY_degree},
{'|', GDK_KEY_ntilde},
{'}', GDK_KEY_ccedilla},
};
/* Swedish. VT220 and higher (per XTerm docs). */
static const struct _vte_iso2022_map16 _vte_iso2022_map_H[] = {
{'@', GDK_KEY (Eacute)},
{'[', GDK_KEY (Adiaeresis)},
{'\\', GDK_KEY (Odiaeresis)},
{']', GDK_KEY (Aring)},
{'^', GDK_KEY (Udiaeresis)},
{'`', GDK_KEY (eacute)},
{'{', GDK_KEY (adiaeresis)},
{'|', GDK_KEY (odiaeresis)},
{'}', GDK_KEY (aring)},
{'~', GDK_KEY (udiaeresis)},
{'@', GDK_KEY_Eacute},
{'[', GDK_KEY_Adiaeresis},
{'\\', GDK_KEY_Odiaeresis},
{']', GDK_KEY_Aring},
{'^', GDK_KEY_Udiaeresis},
{'`', GDK_KEY_eacute},
{'{', GDK_KEY_adiaeresis},
{'|', GDK_KEY_odiaeresis},
{'}', GDK_KEY_aring},
{'~', GDK_KEY_udiaeresis},
};
/* Swiss. VT220 and higher (per XTerm docs). */
static const struct _vte_iso2022_map16 _vte_iso2022_map_equal[] = {
{'#', GDK_KEY (ugrave)},
{'@', GDK_KEY (agrave)},
{'[', GDK_KEY (eacute)},
{'\\', GDK_KEY (ccedilla)},
{']', GDK_KEY (ecircumflex)},
{'^', GDK_KEY (icircumflex)},
{'_', GDK_KEY (egrave)},
{'`', GDK_KEY (ocircumflex)},
{'{', GDK_KEY (adiaeresis)},
{'|', GDK_KEY (odiaeresis)},
{'}', GDK_KEY (udiaeresis)},
{'~', GDK_KEY (ucircumflex)},
{'#', GDK_KEY_ugrave},
{'@', GDK_KEY_agrave},
{'[', GDK_KEY_eacute},
{'\\', GDK_KEY_ccedilla},
{']', GDK_KEY_ecircumflex},
{'^', GDK_KEY_icircumflex},
{'_', GDK_KEY_egrave},
{'`', GDK_KEY_ocircumflex},
{'{', GDK_KEY_adiaeresis},
{'|', GDK_KEY_odiaeresis},
{'}', GDK_KEY_udiaeresis},
{'~', GDK_KEY_ucircumflex},
};
/* Codepage 437. */
static const struct _vte_iso2022_map16 _vte_iso2022_map_U[] = {
......
......@@ -29,8 +29,6 @@
#include "keymap.h"
#include "vtetc.h"
#define GDK_KEY(symbol) GDK_KEY_##symbol
#if defined(HAVE_NCURSES_H) && defined(HAVE_TERM_H)
#include <ncurses.h>
#include <term.h>
......@@ -905,104 +903,104 @@ static const struct _vte_keymap_group {
guint keyval;
const struct _vte_keymap_entry *entries;
} _vte_keymap[] = {
{GDK_KEY (space), _vte_keymap_GDK_space},
{GDK_KEY (Return), _vte_keymap_GDK_Return},
{GDK_KEY (Escape), _vte_keymap_GDK_Escape},
{GDK_KEY (Tab), _vte_keymap_GDK_Tab},
{GDK_KEY (ISO_Left_Tab), _vte_keymap_GDK_ISO_Left_Tab},
{GDK_KEY (Home), _vte_keymap_GDK_Home},
{GDK_KEY (End), _vte_keymap_GDK_End},
{GDK_KEY (Insert), _vte_keymap_GDK_Insert},
{GDK_KEY (slash), _vte_keymap_GDK_slash},
{GDK_KEY (question), _vte_keymap_GDK_question},
/* GDK_KEY (Delete is all handled in code), due to funkiness. */
{GDK_KEY (Page_Up), _vte_keymap_GDK_Page_Up},
{GDK_KEY (Page_Down), _vte_keymap_GDK_Page_Down},
{GDK_KEY (2), _vte_keymap_GDK_2},
{GDK_KEY (3), _vte_keymap_GDK_3},
{GDK_KEY (4), _vte_keymap_GDK_4},
{GDK_KEY (5), _vte_keymap_GDK_5},
{GDK_KEY (6), _vte_keymap_GDK_6},
{GDK_KEY (7), _vte_keymap_GDK_7},
{GDK_KEY (8), _vte_keymap_GDK_8},
{GDK_KEY (minus), _vte_keymap_GDK_Minus},
{GDK_KEY (Up), _vte_keymap_GDK_Up},
{GDK_KEY (Down), _vte_keymap_GDK_Down},
{GDK_KEY (Right), _vte_keymap_GDK_Right},
{GDK_KEY (Left), _vte_keymap_GDK_Left},
{GDK_KEY (KP_Space), _vte_keymap_GDK_KP_Space},
{GDK_KEY (KP_Tab), _vte_keymap_GDK_KP_Tab},
{GDK_KEY (KP_Enter), _vte_keymap_GDK_KP_Enter},
{GDK_KEY (KP_F1), _vte_keymap_GDK_KP_F1},
{GDK_KEY (KP_F2), _vte_keymap_GDK_KP_F2},
{GDK_KEY (KP_F3), _vte_keymap_GDK_KP_F3},
{GDK_KEY (KP_F4), _vte_keymap_GDK_KP_F4},
{GDK_KEY (KP_Multiply), _vte_keymap_GDK_KP_Multiply},
{GDK_KEY (KP_Add), _vte_keymap_GDK_KP_Add},
{GDK_KEY (KP_Separator), _vte_keymap_GDK_KP_Separator},
{GDK_KEY (KP_Subtract), _vte_keymap_GDK_KP_Subtract},
{GDK_KEY (KP_Decimal), _vte_keymap_GDK_KP_Decimal_Delete},
{GDK_KEY (KP_Delete), _vte_keymap_GDK_KP_Decimal_Delete},
{GDK_KEY (KP_Divide), _vte_keymap_GDK_KP_Divide},
{GDK_KEY (KP_0), _vte_keymap_GDK_KP_0},
{GDK_KEY (KP_Insert), _vte_keymap_GDK_KP_Insert},
{GDK_KEY (KP_1), _vte_keymap_GDK_KP_1},
{GDK_KEY (KP_End), _vte_keymap_GDK_KP_End},
{GDK_KEY (KP_2), _vte_keymap_GDK_KP_2},
{GDK_KEY (KP_Down), _vte_keymap_GDK_KP_Down},
{GDK_KEY (KP_3), _vte_keymap_GDK_KP_3},
{GDK_KEY (KP_Page_Down), _vte_keymap_GDK_KP_Page_Down},
{GDK_KEY (KP_4), _vte_keymap_GDK_KP_4},
{GDK_KEY (KP_Left), _vte_keymap_GDK_KP_Left},
{GDK_KEY (KP_5), _vte_keymap_GDK_KP_5},
{GDK_KEY (KP_Begin), _vte_keymap_GDK_KP_Begin},
{GDK_KEY (KP_6), _vte_keymap_GDK_KP_6},
{GDK_KEY (KP_Right), _vte_keymap_GDK_KP_Right},
{GDK_KEY (KP_7), _vte_keymap_GDK_KP_7},
{GDK_KEY (KP_Home), _vte_keymap_GDK_KP_Home},
{GDK_KEY (KP_8), _vte_keymap_GDK_KP_8},
{GDK_KEY (KP_Up), _vte_keymap_GDK_KP_Up},
{GDK_KEY (KP_9), _vte_keymap_GDK_KP_9},
{GDK_KEY (KP_Page_Up), _vte_keymap_GDK_KP_Page_Up},
{GDK_KEY (F1), _vte_keymap_GDK_F1},
{GDK_KEY (F2), _vte_keymap_GDK_F2},
{GDK_KEY (F3), _vte_keymap_GDK_F3},
{GDK_KEY (F4), _vte_keymap_GDK_F4},
{GDK_KEY (F5), _vte_keymap_GDK_F5},
{GDK_KEY (F6), _vte_keymap_GDK_F6},
{GDK_KEY (F7), _vte_keymap_GDK_F7},
{GDK_KEY (F8), _vte_keymap_GDK_F8},
{GDK_KEY (F9), _vte_keymap_GDK_F9},
{GDK_KEY (F10), _vte_keymap_GDK_F10},
{GDK_KEY (F11), _vte_keymap_GDK_F11},
{GDK_KEY (F12), _vte_keymap_GDK_F12},
{GDK_KEY (F13), _vte_keymap_GDK_F13},
{GDK_KEY (F14), _vte_keymap_GDK_F14},
{GDK_KEY (F15), _vte_keymap_GDK_F15},
{GDK_KEY (F16), _vte_keymap_GDK_F16},
{GDK_KEY (F17), _vte_keymap_GDK_F17},
{GDK_KEY (F18), _vte_keymap_GDK_F18},
{GDK_KEY (F19), _vte_keymap_GDK_F19},
{GDK_KEY (F20), _vte_keymap_GDK_F20},
{GDK_KEY (F21), _vte_keymap_GDK_F21},
{GDK_KEY (F22), _vte_keymap_GDK_F22},
{GDK_KEY (F23), _vte_keymap_GDK_F23},
{GDK_KEY (F24), _vte_keymap_GDK_F24},
{GDK_KEY (F25), _vte_keymap_GDK_F25},
{GDK_KEY (F26), _vte_keymap_GDK_F26},
{GDK_KEY (F27), _vte_keymap_GDK_F27},
{GDK_KEY (F28), _vte_keymap_GDK_F28},
{GDK_KEY (F29), _vte_keymap_GDK_F29},
{GDK_KEY (F30), _vte_keymap_GDK_F30},
{GDK_KEY (F31), _vte_keymap_GDK_F31},
{GDK_KEY (F32), _vte_keymap_GDK_F32},
{GDK_KEY (F33), _vte_keymap_GDK_F33},
{GDK_KEY (F34), _vte_keymap_GDK_F34},
{GDK_KEY (F35), _vte_keymap_GDK_F35},
{GDK_KEY_space, _vte_keymap_GDK_space},
{GDK_KEY_Return, _vte_keymap_GDK_Return},
{GDK_KEY_Escape, _vte_keymap_GDK_Escape},
{GDK_KEY_Tab, _vte_keymap_GDK_Tab},
{GDK_KEY_ISO_Left_Tab, _vte_keymap_GDK_ISO_Left_Tab},
{GDK_KEY_Home, _vte_keymap_GDK_Home},
{GDK_KEY_End, _vte_keymap_GDK_End},
{GDK_KEY_Insert, _vte_keymap_GDK_Insert},
{GDK_KEY_slash, _vte_keymap_GDK_slash},
{GDK_KEY_question, _vte_keymap_GDK_question},
/* GDK_Delete is all handled in code, due to funkiness. */
{GDK_KEY_Page_Up, _vte_keymap_GDK_Page_Up},
{GDK_KEY_Page_Down, _vte_keymap_GDK_Page_Down},
{GDK_KEY_2, _vte_keymap_GDK_2},
{GDK_KEY_3, _vte_keymap_GDK_3},
{GDK_KEY_4, _vte_keymap_GDK_4},
{GDK_KEY_5, _vte_keymap_GDK_5},
{GDK_KEY_6, _vte_keymap_GDK_6},
{GDK_KEY_7, _vte_keymap_GDK_7},
{GDK_KEY_8, _vte_keymap_GDK_8},
{GDK_KEY_minus, _vte_keymap_GDK_Minus},
{GDK_KEY_Up, _vte_keymap_GDK_Up},
{GDK_KEY_Down, _vte_keymap_GDK_Down},
{GDK_KEY_Right, _vte_keymap_GDK_Right},
{GDK_KEY_Left, _vte_keymap_GDK_Left},
{GDK_KEY_KP_Space, _vte_keymap_GDK_KP_Space},
{GDK_KEY_KP_Tab, _vte_keymap_GDK_KP_Tab},
{GDK_KEY_KP_Enter, _vte_keymap_GDK_KP_Enter},
{GDK_KEY_KP_F1, _vte_keymap_GDK_KP_F1},
{GDK_KEY_KP_F2, _vte_keymap_GDK_KP_F2},
{GDK_KEY_KP_F3, _vte_keymap_GDK_KP_F3},
{GDK_KEY_KP_F4, _vte_keymap_GDK_KP_F4},
{GDK_KEY_KP_Multiply, _vte_keymap_GDK_KP_Multiply},
{GDK_KEY_KP_Add, _vte_keymap_GDK_KP_Add},
{GDK_KEY_KP_Separator, _vte_keymap_GDK_KP_Separator},
{GDK_KEY_KP_Subtract, _vte_keymap_GDK_KP_Subtract},
{GDK_KEY_KP_Decimal, _vte_keymap_GDK_KP_Decimal_Delete},
{GDK_KEY_KP_Delete, _vte_keymap_GDK_KP_Decimal_Delete},
{GDK_KEY_KP_Divide, _vte_keymap_GDK_KP_Divide},
{GDK_KEY_KP_0, _vte_keymap_GDK_KP_0},
{GDK_KEY_KP_Insert, _vte_keymap_GDK_KP_Insert},
{GDK_KEY_KP_1, _vte_keymap_GDK_KP_1},
{GDK_KEY_KP_End, _vte_keymap_GDK_KP_End},
{GDK_KEY_KP_2, _vte_keymap_GDK_KP_2},
{GDK_KEY_KP_Down, _vte_keymap_GDK_KP_Down},
{GDK_KEY_KP_3, _vte_keymap_GDK_KP_3},
{GDK_KEY_KP_Page_Down, _vte_keymap_GDK_KP_Page_Down},
{GDK_KEY_KP_4, _vte_keymap_GDK_KP_4},
{GDK_KEY_KP_Left, _vte_keymap_GDK_KP_Left},
{GDK_KEY_KP_5, _vte_keymap_GDK_KP_5},
{GDK_KEY_KP_Begin, _vte_keymap_GDK_KP_Begin},
{GDK_KEY_KP_6, _vte_keymap_GDK_KP_6},
{GDK_KEY_KP_Right, _vte_keymap_GDK_KP_Right},
{GDK_KEY_KP_7, _vte_keymap_GDK_KP_7},
{GDK_KEY_KP_Home, _vte_keymap_GDK_KP_Home},
{GDK_KEY_KP_8, _vte_keymap_GDK_KP_8},
{GDK_KEY_KP_Up, _vte_keymap_GDK_KP_Up},
{GDK_KEY_KP_9, _vte_keymap_GDK_KP_9},
{GDK_KEY_KP_Page_Up, _vte_keymap_GDK_KP_Page_Up},
{GDK_KEY_F1, _vte_keymap_GDK_F1},
{GDK_KEY_F2, _vte_keymap_GDK_F2},
{GDK_KEY_F3, _vte_keymap_GDK_F3},
{GDK_KEY_F4, _vte_keymap_GDK_F4},
{GDK_KEY_F5, _vte_keymap_GDK_F5},
{GDK_KEY_F6, _vte_keymap_GDK_F6},
{GDK_KEY_F7, _vte_keymap_GDK_F7},
{GDK_KEY_F8, _vte_keymap_GDK_F8},
{GDK_KEY_F9, _vte_keymap_GDK_F9},
{GDK_KEY_F10, _vte_keymap_GDK_F10},
{GDK_KEY_F11, _vte_keymap_GDK_F11},
{GDK_KEY_F12, _vte_keymap_GDK_F12},
{GDK_KEY_F13, _vte_keymap_GDK_F13},
{GDK_KEY_F14, _vte_keymap_GDK_F14},
{GDK_KEY_F15, _vte_keymap_GDK_F15},
{GDK_KEY_F16, _vte_keymap_GDK_F16},
{GDK_KEY_F17, _vte_keymap_GDK_F17},
{GDK_KEY_F18, _vte_keymap_GDK_F18},
{GDK_KEY_F19, _vte_keymap_GDK_F19},
{GDK_KEY_F20, _vte_keymap_GDK_F20},
{GDK_KEY_F21, _vte_keymap_GDK_F21},
{GDK_KEY_F22, _vte_keymap_GDK_F22},
{GDK_KEY_F23, _vte_keymap_GDK_F23},
{GDK_KEY_F24, _vte_keymap_GDK_F24},
{GDK_KEY_F25, _vte_keymap_GDK_F25},
{GDK_KEY_F26, _vte_keymap_GDK_F26},
{GDK_KEY_F27, _vte_keymap_GDK_F27},
{GDK_KEY_F28, _vte_keymap_GDK_F28},
{GDK_KEY_F29, _vte_keymap_GDK_F29},
{GDK_KEY_F30, _vte_keymap_GDK_F30},
{GDK_KEY_F31, _vte_keymap_GDK_F31},
{GDK_KEY_F32, _vte_keymap_GDK_F32},
{GDK_KEY_F33, _vte_keymap_GDK_F33},
{GDK_KEY_F34, _vte_keymap_GDK_F34},
{GDK_KEY_F35, _vte_keymap_GDK_F35},
};
/* Map the specified keyval/modifier setup, dependent on the mode, to either
......@@ -1074,13 +1072,13 @@ _vte_keymap_map(guint keyval,
mods &= entries[j].mod_mask;
}
switch (_vte_keymap[i].keyval) {
case GDK_KEY (2):
case GDK_KEY (3):
case GDK_KEY (4):
case GDK_KEY (5):
case GDK_KEY (6):
case GDK_KEY (7):
case GDK_KEY (8):
case GDK_KEY_2:
case GDK_KEY_3:
case GDK_KEY_4:
case GDK_KEY_5:
case GDK_KEY_6:
case GDK_KEY_7:
case GDK_KEY_8:
/* Known non-full-coverage cases. */
break;
default:
......@@ -1235,34 +1233,34 @@ _vte_keymap_key_is_modifier(guint keyval)
gboolean modifier = FALSE;
/* Determine if this is just a modifier key. */
switch (keyval) {
case GDK_KEY (Alt_L):
case GDK_KEY (Alt_R):
case GDK_KEY (Caps_Lock):
case GDK_KEY (Control_L):
case GDK_KEY (Control_R):
case GDK_KEY (Eisu_Shift):
case GDK_KEY (Hyper_L):
case GDK_KEY (Hyper_R):
case GDK_KEY (ISO_First_Group_Lock):
case GDK_KEY (ISO_Group_Lock):
case GDK_KEY (ISO_Group_Shift):
case GDK_KEY (ISO_Last_Group_Lock):
case GDK_KEY (ISO_Level3_Lock):
case GDK_KEY (ISO_Level3_Shift):
case GDK_KEY (ISO_Lock):
case GDK_KEY (ISO_Next_Group_Lock):
case GDK_KEY (ISO_Prev_Group_Lock):
case GDK_KEY (Kana_Lock):
case GDK_KEY (Kana_Shift):
case GDK_KEY (Meta_L):
case GDK_KEY (Meta_R):
case GDK_KEY (Num_Lock):
case GDK_KEY (Scroll_Lock):
case GDK_KEY (Shift_L):
case GDK_KEY (Shift_Lock):
case GDK_KEY (Shift_R):
case GDK_KEY (Super_L):
case GDK_KEY (Super_R):
case GDK_KEY_Alt_L:
case GDK_KEY_Alt_R:
case GDK_KEY_Caps_Lock:
case GDK_KEY_Control_L:
case GDK_KEY_Control_R:
case GDK_KEY_Eisu_Shift:
case GDK_KEY_Hyper_L:
case GDK_KEY_Hyper_R:
case GDK_KEY_ISO_First_Group_Lock:
case GDK_KEY_ISO_Group_Lock:
case GDK_KEY_ISO_Group_Shift:
case GDK_KEY_ISO_Last_Group_Lock:
case GDK_KEY_ISO_Level3_Lock:
case GDK_KEY_ISO_Level3_Shift:
case GDK_KEY_ISO_Lock:
case GDK_KEY_ISO_Next_Group_Lock:
case GDK_KEY_ISO_Prev_Group_Lock:
case GDK_KEY_Kana_Lock:
case GDK_KEY_Kana_Shift:
case GDK_KEY_Meta_L:
case GDK_KEY_Meta_R:
case GDK_KEY_Num_Lock:
case GDK_KEY_Scroll_Lock:
case GDK_KEY_Shift_L:
case GDK_KEY_Shift_Lock:
case GDK_KEY_Shift_R:
case GDK_KEY_Super_L:
case GDK_KEY_Super_R:
modifier = TRUE;
break;
default:
......@@ -1278,68 +1276,68 @@ _vte_keymap_key_get_modifier_encoding_method(guint keyval)
enum _vte_modifier_encoding_method method = MODIFIER_ENCODING_NONE;
/* Determine if this key gets modifiers. */
switch (keyval) {
case GDK_KEY (Up):
case GDK_KEY (Down):
case GDK_KEY (Left):
case GDK_KEY (Right):
case GDK_KEY (Insert):
case GDK_KEY (Delete):
case GDK_KEY (Home):
case GDK_KEY (End):
case GDK_KEY (Page_Up):
case GDK_KEY (Page_Down):
case GDK_KEY (KP_Up):
case GDK_KEY (KP_Down):
case GDK_KEY (KP_Left):
case GDK_KEY (KP_Right):
case GDK_KEY (KP_Insert):
case GDK_KEY (KP_Delete):
case GDK_KEY (KP_Home):
case GDK_KEY (KP_End):
case GDK_KEY (KP_Page_Up):
case GDK_KEY (KP_Page_Down):
case GDK_KEY (KP_Begin):
case GDK_KEY (F1):
case GDK_KEY (F2):
case GDK_KEY (F3):
case GDK_KEY (F4):
case GDK_KEY (F5):
case GDK_KEY (F6):
case GDK_KEY (F7):
case GDK_KEY (F8):
case GDK_KEY (F9):
case GDK_KEY (F10):
case GDK_KEY (F11):
case GDK_KEY (F12):
case GDK_KEY (F13):
case GDK_KEY (F14):
case GDK_KEY (F15):
case GDK_KEY (F16):
case GDK_KEY (F17):
case GDK_KEY (F18):
case GDK_KEY (F19):
case GDK_KEY (F20):
case GDK_KEY (F21):
case GDK_KEY (F22):
case GDK_KEY (F23):
case GDK_KEY (F24):
case GDK_KEY (F25):
case GDK_KEY (F26):
case GDK_KEY (F27):
case GDK_KEY (F28):
case GDK_KEY (F29):
case GDK_KEY (F30):
case GDK_KEY (F31):
case GDK_KEY (F32):
case GDK_KEY (F33):
case GDK_KEY (F34):
case GDK_KEY (F35):
case GDK_KEY_Up:
case GDK_KEY_Down:
case GDK_KEY_Left:
case GDK_KEY_Right:
case GDK_KEY_Insert:
case GDK_KEY_Delete:
case GDK_KEY_Home:
case GDK_KEY_End:
case GDK_KEY_Page_Up:
case GDK_KEY_Page_Down:
case GDK_KEY_KP_Up:
case GDK_KEY_KP_Down:
case GDK_KEY_KP_Left:
case GDK_KEY_KP_Right:
case GDK_KEY_KP_Insert:
case GDK_KEY_KP_Delete:
case GDK_KEY_KP_Home:
case GDK_KEY_KP_End:
case GDK_KEY_KP_Page_Up:
case GDK_KEY_KP_Page_Down:
case GDK_KEY_KP_Begin:
case GDK_KEY_F1:
case GDK_KEY_F2:
case GDK_KEY_F3:
case GDK_KEY_F4:
case GDK_KEY_F5:
case GDK_KEY_F6:
case GDK_KEY_F7:
case GDK_KEY_F8:
case GDK_KEY_F9:
case GDK_KEY_F10:
case GDK_KEY_F11:
case GDK_KEY_F12:
case GDK_KEY_F13:
case GDK_KEY_F14:
case GDK_KEY_F15:
case GDK_KEY_F16:
case GDK_KEY_F17:
case GDK_KEY_F18:
case GDK_KEY_F19:
case GDK_KEY_F20:
case GDK_KEY_F21:
case GDK_KEY_F22:
case GDK_KEY_F23:
case GDK_KEY_F24:
case GDK_KEY_F25:
case GDK_KEY_F26:
case GDK_KEY_F27:
case GDK_KEY_F28:
case GDK_KEY_F29:
case GDK_KEY_F30:
case GDK_KEY_F31:
case GDK_KEY_F32:
case GDK_KEY_F33:
case GDK_KEY_F34:
case GDK_KEY_F35:
method = MODIFIER_ENCODING_LONG;
break;
case GDK_KEY (KP_Divide):
case GDK_KEY (KP_Multiply):
case GDK_KEY (KP_Subtract):
case GDK_KEY (KP_Add):
case GDK_KEY_KP_Divide:
case GDK_KEY_KP_Multiply:
case GDK_KEY_KP_Subtract:
case GDK_KEY_KP_Add:
method = MODIFIER_ENCODING_SHORT;
break;
default:
......@@ -1354,20 +1352,20 @@ static gboolean
is_cursor_key(guint keyval)
{
switch (keyval) {
case GDK_KEY (Home):
case GDK_KEY (Left):
case GDK_KEY (Up):
case GDK_KEY (Right):
case GDK_KEY (Down):
case GDK_KEY (End):
case GDK_KEY (KP_Home):
case GDK_KEY (KP_Left):
case GDK_KEY (KP_Up):
case GDK_KEY (KP_Right):
case GDK_KEY (KP_Down):
case GDK_KEY (KP_End):
case GDK_KEY (KP_Begin):
case GDK_KEY_Home:
case GDK_KEY_Left:
case GDK_KEY_Up:
case GDK_KEY_Right:
case GDK_KEY_Down:
case GDK_KEY_End:
case GDK_KEY_KP_Home:
case GDK_KEY_KP_Left:
case GDK_KEY_KP_Up:
case GDK_KEY_KP_Right:
case GDK_KEY_KP_Down:
case GDK_KEY_KP_End:
case GDK_KEY_KP_Begin:
return TRUE;
default:
return FALSE;
......
......@@ -74,8 +74,6 @@ static inline double round(double x) {
}
#endif
#define GDK_KEY(symbol) GDK_KEY_##symbol