最終更新:2019-04-02 (火) 18:20:40 (463d)  

Linux/キーコード
Top / Linux / キーコード

一覧

ヘッダファイル

Linux 4.4

Linux 3.7

Linux 3.6

マッピング

HID/キーコードとの対応表

Android/Key Layout Files

構造体

X/キーコード

evdevからの入力

xmodmap

キーコード (keycode)

  • キーコードはキーやマウスボタンが押された時にカーネルによって生成される番号のことです。

キーシム (keysym)

  • キーシムはキーコードに割り当てられている値です。例えば、A を押すと keycode? 73 が生成されますが、このキーコードは keysym? 0×61 にマッピングされており、このキーシムは ASCII 表の A に対応しています。
  • キーシムはキーコード-キーシムの対応関係を示すキーコードの表で Xorg によって管理されており、この表はキーマップテーブルと呼ばれます。キーマップテーブルは xmodmap を実行することで確認できます。

一覧

Keys and buttons

  • 名前
    KEY_RESERVED?0
    KEY_ESC1
    KEY_1?2
    KEY_2?3
    KEY_3?4
    KEY_4?5
    KEY_5?6
    KEY_6?7
    KEY_7?8
    KEY_8?9
    KEY_9?10
    KEY_0?11
    KEY_MINUS?12
    KEY_EQUAL?13
    KEY_BACKSPACE14
    KEY_TAB?15
    KEY_Q?16
    KEY_W?17
    KEY_E?18
    KEY_R?19
    KEY_T?20
    KEY_Y?21
    KEY_U?22
    KEY_I?23
    KEY_O?24
    KEY_P?25
    KEY_LEFTBRACE?26
    KEY_RIGHTBRACE?27
    KEY_ENTER28
    KEY_LEFTCTRL29
    KEY_A?30
    KEY_S?31
    KEY_D?32
    KEY_F?33
    KEY_G?34
    KEY_H?35
    KEY_J?36
    KEY_K?37
    KEY_L?38
    KEY_SEMICOLON?39
    KEY_APOSTROPHE?40
    KEY_GRAVE?41
    KEY_LEFTSHIFT42
    KEY_BACKSLASH?43
    KEY_Z?44
    KEY_X?45
    KEY_C?46
    KEY_V?47
    KEY_B?48
    KEY_N?49
    KEY_M?50
    KEY_COMMA?51
    KEY_DOT?52
    KEY_SLASH?53
    KEY_RIGHTSHIFT?54
    KEY_KPASTERISK?55
    KEY_LEFTALT?56
    KEY_SPACE?57
    KEY_CAPSLOCK?58
    KEY_F1?59
    KEY_F2?60
    KEY_F3?61
    KEY_F4?62
    KEY_F5?63
    KEY_F6?64
    KEY_F7?65
    KEY_F8?66
    KEY_F9?67
    KEY_F10?68
    KEY_NUMLOCK?69
    KEY_SCROLLLOCK?70
    KEY_KP7?71
    KEY_KP8?72
    KEY_KP9?73
    KEY_KPMINUS?74
    KEY_KP4?75
    KEY_KP5?76
    KEY_KP6?77
    KEY_KPPLUS?78
    KEY_KP1?79
    KEY_KP2?80
    KEY_KP3?81
    KEY_KP0?82
    KEY_KPDOT?83
    KEY_ZENKAKUHANKAKU?85
    KEY_102ND?86
    KEY_F11?87
    KEY_F12?88
    KEY_RO?89
    KEY_KATAKANA?90
    KEY_HIRAGANA?91
    KEY_HENKAN92
    KEY_KATAKANAHIRAGANA?93
    KEY_MUHENKAN94
    KEY_KPJPCOMMA?95
    KEY_KPENTER?96
    KEY_RIGHTCTRL?97
    KEY_KPSLASH?98
    KEY_SYSRQ?99
    KEY_RIGHTALT?100
    KEY_LINEFEED?101
    KEY_HOME?102
    KEY_UP?103
    KEY_PAGEUP?104
    KEY_LEFT105
    KEY_RIGHT?106
    KEY_END?107
    KEY_DOWN108
    KEY_PAGEDOWN?109
    KEY_INSERT?110
    KEY_DELETE?111
    KEY_MACRO?112
    KEY_MUTE?113
    KEY_VOLUMEDOWN114
    KEY_VOLUMEUP?115
    KEY_POWER?116SC System Power Down
    KEY_KPEQUAL?117
    KEY_KPPLUSMINUS?118
    KEY_PAUSE?119
    KEY_SCALE?120AL Compiz Scale (Expose)
    KEY_KPCOMMA?121
    KEY_HANGEUL?122
    KEY_HANGUEL?KEY_HANGEUL?
    KEY_HANJA?123
    KEY_YEN?124
    KEY_LEFTMETA?125
    KEY_RIGHTMETA?126
    KEY_COMPOSE?127
    KEY_STOP?128AC Stop
    KEY_AGAIN?129
    KEY_PROPS?130AC Properties
    KEY_UNDO?131AC Undo
    KEY_FRONT?132
    KEY_COPY?133AC Copy
    KEY_OPEN?134AC Open
    KEY_PASTE?135AC Paste
    KEY_FIND?136AC Search
    KEY_CUT?137AC Cut
    KEY_HELP?138AL Integrated Help Center
    KEY_MENU?139Menu (show menu)
    KEY_CALC?140AL Calculator
    KEY_SETUP?141
    KEY_SLEEP?142SC System Sleep
    KEY_WAKEUP?143System Wake Up
    KEY_FILE?144AL Local Machine Browser
    KEY_SENDFILE?145
    KEY_DELETEFILE?146
    KEY_XFER?147
    KEY_PROG1?148
    KEY_PROG2?149
    KEY_WWW?150AL Internet Browser
    KEY_MSDOS?151
    KEY_COFFEE?152AL Terminal Lock/Screensaver
    KEY_SCREENLOCK?KEY_COFFEE?
    KEY_ROTATE_DISPLAY?153Display orientation for e.g. tablets
    KEY_DIRECTION?KEY_ROTATE_DISPLAY?
    KEY_CYCLEWINDOWS?154
    KEY_MAIL?155
    KEY_BOOKMARKS?156AC Bookmarks
    KEY_COMPUTER?157
    KEY_BACK158AC Back
    KEY_FORWARD159AC Forward
    KEY_CLOSECD?160
    KEY_EJECTCD?161
    KEY_EJECTCLOSECD?162
    KEY_NEXTSONG?163
    KEY_PLAYPAUSE164
    KEY_PREVIOUSSONG?165
    KEY_STOPCD?166
    KEY_RECORD?167
    KEY_REWIND?168
    KEY_PHONE?169Media Select Telephone
    KEY_ISO?170
    KEY_CONFIG?171AL Consumer Control Configuration
    KEY_HOMEPAGE?172AC Home
    KEY_REFRESH?173AC Refresh
    KEY_EXIT?174AC Exit
    KEY_MOVE?175
    KEY_EDIT?176
    KEY_SCROLLUP?177
    KEY_SCROLLDOWN?178
    KEY_KPLEFTPAREN?179
    KEY_KPRIGHTPAREN?180
    KEY_NEW?181AC New
    KEY_REDO?182AC Redo/Repeat
    KEY_F13?183
    KEY_F14?184
    KEY_F15?185
    KEY_F16?186
    KEY_F17?187
    KEY_F18?188
    KEY_F19?189
    KEY_F20?190
    KEY_F21?191
    KEY_F22?192
    KEY_F23?193
    KEY_F24?194
    KEY_PLAYCD?200
    KEY_PAUSECD?201
    KEY_PROG3?202
    KEY_PROG4?203
    KEY_DASHBOARD?204AL Dashboard
    KEY_SUSPEND?205
    KEY_CLOSE?206AC Close
    KEY_PLAY?207
    KEY_FASTFORWARD?208
    KEY_BASSBOOST?209
    KEY_PRINT?210AC Print
    KEY_HP?211
    KEY_CAMERA?212
    KEY_SOUND?213
    KEY_QUESTION?214
    KEY_EMAIL?215
    KEY_CHAT?216
    KEY_SEARCH?217
    KEY_CONNECT?218
    KEY_FINANCE?219AL Checkbook/Finance
    KEY_SPORT?220
    KEY_SHOP?221
    KEY_ALTERASE?222
    KEY_CANCEL?223AC Cancel
    KEY_BRIGHTNESSDOWN?224
    KEY_BRIGHTNESSUP?225
    KEY_MEDIA?226
    KEY_SWITCHVIDEOMODE?227Cycle between available video outputs (Monitor/LCD/TV-out/etc)
    KEY_KBDILLUMTOGGLE?228
    KEY_KBDILLUMDOWN?229
    KEY_KBDILLUMUP?230
    KEY_SEND?231AC Send
    KEY_REPLY?232AC Reply
    KEY_FORWARDMAIL?233AC Forward Msg
    KEY_SAVE?234AC Save
    KEY_DOCUMENTS?235
    KEY_BATTERY?236
    KEY_BLUETOOTH?237
    KEY_WLAN?238
    KEY_UWB?239
    KEY_UNKNOWN?240
    KEY_VIDEO_NEXT?241drive next video source
    KEY_VIDEO_PREV?242drive previous video source
    KEY_BRIGHTNESS_CYCLE?243brightness up, after max is min
    KEY_BRIGHTNESS_AUTO?244Set Auto Brightness: manual brightness control is off,rely on ambient
    KEY_BRIGHTNESS_ZERO?KEY_BRIGHTNESS_AUTO?
    KEY_DISPLAY_OFF?245display device to off state
    KEY_WWAN?246Wireless WAN (LTE, UMTS, GSM, etc.)
    KEY_WIMAX?KEY_WWAN?
    KEY_RFKILL?247Key that controls all radios
    KEY_MICMUTE?248Mute / unmute the microphone
    KEY_OK0x160
    KEY_SELECT?0x161
    KEY_GOTO?0x162
    KEY_CLEAR?0x163
    KEY_POWER2?0x164
    KEY_OPTION?0x165
    KEY_INFO?0x166AL OEM Features/Tips/Tutorial
    KEY_TIME?0x167
    KEY_VENDOR?0x168
    KEY_ARCHIVE?0x169
    KEY_PROGRAM?0x16aMedia Select Program Guide
    KEY_CHANNEL?0x16b
    KEY_FAVORITES?0x16c
    KEY_EPG?0x16d
    KEY_PVR?0x16eMedia Select Home
    KEY_MHP?0x16f
    KEY_LANGUAGE?0x170
    KEY_TITLE?0x171
    KEY_SUBTITLE?0x172
    KEY_ANGLE?0x173
    KEY_ZOOM?0x174
    KEY_MODE?0x175
    KEY_KEYBOARD?0x176
    KEY_SCREEN?0x177
    KEY_PC?0x178Media Select Computer
    KEY_TV?0x179Media Select TV
    KEY_TV2?0x17aMedia Select Cable
    KEY_VCR?0x17bMedia Select VCR
    KEY_VCR2?0x17cVCR Plus
    KEY_SAT?0x17dMedia Select Satellite
    KEY_SAT2?0x17e
    KEY_CD?0x17fMedia Select CD
    KEY_TAPE?0x180Media Select Tape
    KEY_RADIO?0x181
    KEY_TUNER?0x182Media Select Tuner
    KEY_PLAYER?0x183
    KEY_TEXT?0x184
    KEY_DVD?0x185Media Select DVD
    KEY_AUX?0x186
    KEY_MP3?0x187
    KEY_AUDIO?0x188AL Audio Browser
    KEY_VIDEO?0x189AL Movie Browser
    KEY_DIRECTORY?0x18a
    KEY_LIST?0x18b
    KEY_MEMO?0x18cMedia Select Messages
    KEY_CALENDAR?0x18d
    KEY_RED?0x18e
    KEY_GREEN?0x18f
    KEY_YELLOW?0x190
    KEY_BLUE?0x191
    KEY_CHANNELUP?0x192Channel Increment
    KEY_CHANNELDOWN?0x193Channel Decrement
    KEY_FIRST?0x194
    KEY_LAST?0x195Recall Last
    KEY_AB?0x196
    KEY_NEXT?0x197
    KEY_RESTART?0x198
    KEY_SLOW?0x199
    KEY_SHUFFLE?0x19a
    KEY_BREAK?0x19b
    KEY_PREVIOUS?0x19c
    KEY_DIGITS?0x19d
    KEY_TEEN?0x19e
    KEY_TWEN?0x19f
    KEY_VIDEOPHONE0x1a0Media Select Video Phone
    KEY_GAMES?0x1a1Media Select Games
    KEY_ZOOMIN?0x1a2AC Zoom In
    KEY_ZOOMOUT?0x1a3AC Zoom Out
    KEY_ZOOMRESET?0x1a4AC Zoom
    KEY_WORDPROCESSOR?0x1a5AL Word Processor
    KEY_EDITOR?0x1a6AL Text Editor
    KEY_SPREADSHEET?0x1a7AL Spreadsheet
    KEY_GRAPHICSEDITOR?0x1a8AL Graphics Editor
    KEY_PRESENTATION?0x1a9AL Presentation App
    KEY_DATABASE?0x1aaAL Database App
    KEY_NEWS?0x1abAL Newsreader
    KEY_VOICEMAIL?0x1acAL Voicemail
    KEY_ADDRESSBOOK?0x1adAL Contacts/Address Book
    KEY_MESSENGER?0x1aeAL Instant Messaging
    KEY_DISPLAYTOGGLE0x1afTurn display (LCD) on and off
    KEY_BRIGHTNESS_TOGGLE?KEY_DISPLAYTOGGLE
    KEY_SPELLCHECK?0x1b0AL Spell Check
    KEY_LOGOFF?0x1b1AL Logoff
    KEY_DOLLAR?0x1b2
    KEY_EURO?0x1b3
    KEY_FRAMEBACK?0x1b4Consumer - transport controls
    KEY_FRAMEFORWARD?0x1b5
    KEY_CONTEXT_MENU?0x1b6GenDesc? - system context menu
    KEY_MEDIA_REPEAT?0x1b7Consumer - transport control
    KEY_10CHANNELSUP?0x1b810 channels up (10+)
    KEY_10CHANNELSDOWN?0x1b910 channels down (10-)
    KEY_IMAGES?0x1baAL Image Browser
    KEY_DEL_EOL?0x1c0
    KEY_DEL_EOS?0x1c1
    KEY_INS_LINE?0x1c2
    KEY_DEL_LINE?0x1c3
    KEY_FN?0x1d0
    KEY_FN_ESC?0x1d1
    KEY_FN_F1?0x1d2
    KEY_FN_F2?0x1d3
    KEY_FN_F3?0x1d4
    KEY_FN_F4?0x1d5
    KEY_FN_F5?0x1d6
    KEY_FN_F6?0x1d7
    KEY_FN_F7?0x1d8
    KEY_FN_F8?0x1d9
    KEY_FN_F9?0x1da
    KEY_FN_F10?0x1db
    KEY_FN_F11?0x1dc
    KEY_FN_F12?0x1dd
    KEY_FN_1?0x1de
    KEY_FN_2?0x1df
    KEY_FN_D?0x1e0
    KEY_FN_E?0x1e1
    KEY_FN_F?0x1e2
    KEY_FN_S?0x1e3
    KEY_FN_B?0x1e4
    KEY_BRL_DOT1?0x1f1
    KEY_BRL_DOT2?0x1f2
    KEY_BRL_DOT3?0x1f3
    KEY_BRL_DOT4?0x1f4
    KEY_BRL_DOT5?0x1f5
    KEY_BRL_DOT6?0x1f6
    KEY_BRL_DOT7?0x1f7
    KEY_BRL_DOT8?0x1f8
    KEY_BRL_DOT90x1f9
    KEY_BRL_DOT10?0x1fa
    KEY_NUMERIC_0?0x200used by phones, remote controls,
    KEY_NUMERIC_1?0x201and other keypads
    KEY_NUMERIC_2?0x202
    KEY_NUMERIC_3?0x203
    KEY_NUMERIC_4?0x204
    KEY_NUMERIC_5?0x205
    KEY_NUMERIC_6?0x206
    KEY_NUMERIC_7?0x207
    KEY_NUMERIC_8?0x208
    KEY_NUMERIC_9?0x209
    KEY_NUMERIC_STAR?0x20a
    KEY_NUMERIC_POUND?0x20b
    KEY_NUMERIC_A?0x20cPhone key A - HUT Telephony 0xb9
    KEY_NUMERIC_B?0x20d
    KEY_NUMERIC_C?0x20e
    KEY_NUMERIC_D?0x20f
    KEY_CAMERA_FOCUS?0x210
    KEY_WPS_BUTTON?0x211WiFi? Protected Setup key
    KEY_TOUCHPAD_TOGGLE?0x212Request switch touchpad on or off
    KEY_TOUCHPAD_ON?0x213
    KEY_TOUCHPAD_OFF?0x214
    KEY_CAMERA_ZOOMIN?0x215
    KEY_CAMERA_ZOOMOUT?0x216
    KEY_CAMERA_UP?0x217
    KEY_CAMERA_DOWN?0x218
    KEY_CAMERA_LEFT?0x219
    KEY_CAMERA_RIGHT?0x21a
    KEY_ATTENDANT_ON?0x21b
    KEY_ATTENDANT_OFF?0x21c
    KEY_ATTENDANT_TOGGLE?0x21dAttendant call on or off
    KEY_LIGHTS_TOGGLE?0x21eReading light on or off
    KEY_ALS_TOGGLE?0x230Ambient light sensor
    KEY_BUTTONCONFIG?0x240AL Button Configuration
    KEY_TASKMANAGER?0x241AL Task/Project Manager
    KEY_JOURNAL?0x242AL Log/Journal/Timecard
    KEY_CONTROLPANEL?0x243AL Control Panel
    KEY_APPSELECT?0x244AL Select Task/Application
    KEY_SCREENSAVER?0x245AL Screen Saver
    KEY_VOICECOMMAND?0x246Listening Voice Command
    KEY_BRIGHTNESS_MIN?0x250Set Brightness to Minimum
    KEY_BRIGHTNESS_MAX?0x251Set Brightness to Maximum
    KEY_KBDINPUTASSIST_PREV?0x260
    KEY_KBDINPUTASSIST_NEXT?0x261
    KEY_KBDINPUTASSIST_PREVGROUP?0x262
    KEY_KBDINPUTASSIST_NEXTGROUP?0x263
    KEY_KBDINPUTASSIST_ACCEPT?0x264
    KEY_KBDINPUTASSIST_CANCEL?0x265

Diagonal movement keys

  • KEY_RIGHT_UP?0x266
    KEY_RIGHT_DOWN?0x267
    KEY_LEFT_UP?0x268
    KEY_LEFT_DOWN?0x269
    KEY_ROOT_MENU?0x26aShow Device's Root Menu

Show Top Menu of the Media (e.g. DVD)

  • KEY_MEDIA_TOP_MENU?0x26b
    KEY_NUMERIC_11?0x26c
    KEY_NUMERIC_12?0x26d

Toggle Audio Description:

  • refers to an audio service that helps blind and visually impaired consumers understand the action in a program. Note: in some countries this is referred to as "Video Description".|
    KEY_AUDIO_DESC?0x26e
    KEY_3D_MODE?0x26f
    KEY_NEXT_FAVORITE?0x270
    KEY_STOP_RECORD?0x271
    KEY_PAUSE_RECORD?0x272
    KEY_VOD?0x273Video on Demand
    KEY_UNMUTE?0x274
    KEY_FASTREVERSE?0x275
    KEY_SLOWREVERSE?0x276

Control a data application associated with the currently viewed channel,

  • e.g. teletext or data broadcast application (MHEG, MHP, HbbTV, etc.)
    KEY_DATA?0x277

関連