Qt keyboard event commonly used button key value sorting

There are hundreds of keys in the Qt document, which is too many, so here are some keys commonly used in keyboard events in Qt. If you can’t find the key you are looking for here, you can check it in the Qt document by yourself.

key name hexadecimal value button
Qt::Key_Escape 0x01000000 Esc 
Qt::Key_Tab 0x01000001 Tab 
Qt::Key_Backtab 0x01000002 Tab 
Qt::Key_Backspace 0x01000003 backspace
Qt::Key_Return 0x01000004 carriage return (letter)
Qt::Key_Enter 0x01000005 Enter (keypad)
Qt::Key_Insert 0x01000006 insert
Qt::Key_Delete 0x01000007 delete
Qt::Key_Pause 0x01000008 Pause/Break 
Qt::Key_Print 0x01000009 print key
Qt::Key_Home 0x01000010 home button
Qt::Key_End 0x01000011 end key
Qt::Key_Left 0x01000012 ← 
Qt::Key_Up 0x01000013 ↑ 
Qt::Key_Right 0x01000014 → 
Qt::Key_Down 0x01000015 ↓ 
Qt::Key_PageUp 0x01000016 Turn the page (on)
Qt::Key_PageDown 0x01000017 Turn the page (below)
Qt::Key_Shift 0x01000020 Shift 
Qt::Key_Control 0x01000021 Ctrl 
Qt::Key_Alt 0x01000023 Alt (left)
Qt::Key_AltGr 0x01001103  Alt (right)
Qt::Key_CapsLock 0x01000024 caps Lock
Qt::Key_NumLock 0x01000025 number lock
Qt::Key_ScrollLock 0x01000026 scroll lock
Qt::Key_F1 to Qt::Key_F35 0x01000030 to 0x01000052 F1 to F35 
Qt::Key_Menu 0x01000055 menu
Qt::Key_Space 0x20 space
Qt::Key_Exclam 0x21 ! exclamation point
Qt::Key_QuoteDbl 0x22 Double quotes
Qt::Key_NumberSign 0x23 # Number
Qt::Key_Dollar 0x24 $ dollar sign
Qt::Key_Percent 0x25 % percent sign
Qt::Key_Ampersand 0x26 & get address
Qt::Key_Apostrophe 0x27 ' apostrophe
Qt::Key_ParenLeft 0x28 ( Left parenthesis
Qt::Key_ParenRight 0x29 ) closing parenthesis
Qt::Key_Asterisk 0x2a * Asterisk
Qt::Key_Plus 0x2b + plus sign
Qt::Key_Comma 0x2c , comma
Qt::Key_Minus 0x2d - minus sign
Qt::Key_Period 0x2e . decimal point
Qt::Key_Slash 0x2f / slash
Qt::Key_0 to Qt::Key_9 0x30 to 0x39 0 to 9 digits
Qt::Key_Colon 0x3a : colon
Qt::Key_Semicolon 0x3b ; semicolon
Qt::Key_Less 0x3c < less than sign
Qt::Key_Equal 0x3d = equal sign
Qt::Key_Greater 0x3e > greater than sign
Qt::Key_Question 0x3f ? question mark
Qt::Key_At 0x40
Qt::Key_A 到 Qt::Key_Z 0x41 to 0x5a a to z letters
Qt::Key_BracketLeft 0x5b [ left square bracket
Qt::Key_Backslash 0x5c \ backslash
Qt::Key_BracketRight 0x5d ] closing square bracket
Qt::Key_AsciiCircum 0x5e ^ caret
Qt::Key_Underscore 0x5f _ underscore
Qt::Key_QuoteLeft 0x60 " left double quote
Qt::Key_BraceLeft 0x7b { left curly brace
Qt::Key_Bar 0x7c |
Qt::Key_BraceRight 0x7d } 右花括号
Qt::Key_AsciiTilde 0x7e ~ 波浪号
Qt::Key_nobreakspace 0x0a0 不换行空格
Qt::Key_exclamdown 0x0a1 ! 惊叹号
Qt::Key_cent 0x0a2 美分键
Qt::Key_sterling 0x0a3 英镑键
Qt::Key_currency 0x0a4 货币键
Qt::Key_yen 0x0a5 日元键
Qt::Key_Back 0x01000061 后退键
Qt::Key_Forward 0x01000062 前进键
Qt::Key_Stop 0x01000063 停止键
Qt::Key_Refresh 0x01000064 刷新键
Qt::Key_VolumeDown 0x01000070 降低音量键
Qt::Key_VolumeMute 0x01000071 音量静音键
Qt::Key_VolumeUp 0x01000072 提高音量键
Qt::Key_HomePage 0x01000090 首页键
Qt::Key_Favorites 0x01000091 收藏键
Qt::Key_Search 0x01000092 搜索键

Guess you like

Origin blog.csdn.net/m0_71741835/article/details/128036598