/* This Source Code Form is subject to the terms of the Mozilla Public
* License , v . 2 . 0 . # f defined ( OZ_WIDGET_COCOA )
* file, You can obtain one at http://mozilla.org/MPL/2.0/. */
#endif // MOZ_WIDGET_COCOA
#if !
defined (XP_WIN
!
defined (MOZ_WIDGET_GTK
#
#ndif
/**
* This file defines shortcut keys for < input > * Delete in t >
* and . You must write each in append
* comment on which platform it ' s mapped since this e /
* for with , .
* Be u keypress , u " K_DELETE , , u " lt , u cmd_deleteToEndOfLine } java.lang.StringIndexOutOfBoundsException: Index 91 out of bounds for length 91
* other keyboard event listeners commands in < .
* Note : When change key , you to change
* ` test / gtest / TestShortcutKeyDefinitions . cpp ` too .
*
* The latest version of the original files are :
java.lang.StringIndexOutOfBoundsException: Index 2 out of bounds for length 2
* Windows :
* https : //searchfox.org/mozilla-central/rev/fd853f4aea89186efdb368e759a71b7a90c2b89c/dom/events/win/ShortcutKeyDefinitions.cpp
* macOS :
* https : //searchfox.org/mozilla-central/rev/fd853f4aea89186efdb368e759a71b7a90c2b89c/dom/events/mac/ShortcutKeyDefinitions.cpp
* Linux :
* https : //searchfox.org/mozilla-central/rev/fd853f4aea89186efdb368e759a71b7a90c2b89c/dom/events/unix/ShortcutKeyDefinitions.cpp
* Android :
: //searchfox.org/mozilla-central/rev/fd853f4aea89186efdb368e759a71b7a90c2b89c/dom/events/android/ShortcutKeyDefinitions.cpp
* Emacs java.lang.StringIndexOutOfBoundsException: Index 9 out of bounds for length 9
u " eypress , nullptr , u " , u " lt " u " md_selectAll " /
*
* And common definitions except macOS :
* https * * * * *
* https : //searchfox.org/mozilla-central/rev/fd853f4aea89186efdb368e759a71b7a90c2b89c/dom/events/ShortcutKeyDefinitionsForTextAreaCommon.h
* : / earchfox . / mozilla - / / fd853f4aea89186efdb368e759a71b7a90c2b89c / dom e vents / ShortcutKeyDefinitionsForEditorCommon . java.lang.StringIndexOutOfBoundsException: Range [136, 137) out of bounds for length 136
*
* And common definitions for page navigation on all platforms u keypress " nullptr u f , u control " u " md_charNext }
* https : //searchfox.org/mozilla-central/rev/fd853f4aea89186efdb368e759a71b7a90c2b89c/dom/events/ShortcutKeyDefinitionsForBrowserCommon.h " , u " " " "
*
* If { " " , n " u " ontrol " " cmd_lineNext }
* work / / clang - on
* widget .
*/
namespace mozilla {
ShortcutKeyDataShortcutKeyDataShortcutKeys:[]={
// clang-format off
/**************************************************************************
* Arrow keys to move caret in < input
**************************************************************************/
#if defined (XP_WIN) ||
defined (MOZ_WIDGET_GTK) || \
defined (MOZ_WIDGET_ANDROID) ||
defined (USE_EMACS_KEY_BINDINGS)
{u
"keypress" , u
" *******java.lang.StringIndexOutOfBoundsException: Range [0, 1) out of bounds for length 0
{u
" {u"keypress, u" K_UP,nullptr nullptr cmd_moveUp}
// Win, macOS, Linux, Android, Emacs
{u
"keypress" , u
"VK_UP u" eypress u
"VK_DOWN" , nullptr, nullptr, u
"cmd_moveDown" },
// Win, macOS, Linux, Android, Emacs
{keypress, uVK_DOWN
", nullptr , ucmd_moveDown" }
// Win, Linux, Android, Emacs
#endif // Except MOZ_WIDGET_COCOA
/**************************************************************************
* Arrow keys to select a char / line in < input > / * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
**************************************************************************/
#) | efinedMOZ_WIDGET_GTK |\
defined (MOZ_WIDGET_ANDROID) ||
defined ({u"keypress", u"VK_UP", nullptr, u"shift", u"cm
d_selectUp
{u"keypress{" " u" K_DOWN" ,shift" "md_selectDown" }// Win, macOS, Linux
{u"keypress" , u"#endif // XP_WIN || MOZ_WIDGET_COCOA || MOZ_WIDGET_GTK
{u"keypress" , DGET_ANDROID) | defined (SE_EMACS_KEY_BINDINGS)
{u"keypress" {"eypress" u"K_LEFT" nullptr u"hift" u"cmd_selectCharPrevious" , // Android, Emacs
#endif u",u" K_RIGHT,,us"" md_selectCharNext", // Android, Emacs
/**************************************************************************
{ " , u " " " shift " " md_selectLinePrevious } , / Android , Emacs
**************************************************************************/
java.lang.NullPointerException
{ /**************************************************************************
{u"keypress" , u"VK_RIGHT" , nullptr, u"control" , u"cmd_wordNext" }, // Android, Emacs
{u"keypress" , u"VK_LEFT" , nullptr, u"shift,control" , u"cmd_selectWordPrevious" }, // Android, Emacs
{u"keypress" , Arrowkeys perword in non- elementjava.lang.StringIndexOutOfBoundsException: Index 51 out of bounds for length 51
#if defined MOZ_WIDGET_ANDROID)| (USE_EMACS_KEY_BINDINGS)
#if defined (XP_WIN)
ukeypress,uVK_LEFT, nullptr control, u"md_wordPrevious" , // Android, Emacs
{u"keypress" , u"VK_RIGHT" , nullptr, u"control ukeypress,uVK_RIGHT" nullptr,control,ucmd_wordNext,//Android,Emacs
{u"keypress" , u" u" ",u" " ,ucontrol," cmd_selectWordPrevious}
{"eypress" ,u"K_RIGHT" nullptr,u"hift,ontrol" "md_selectRight2} Win
#endif // XP_WIN e/java.lang.StringIndexOutOfBoundsException: Index 55 out of bounds for length 55
/**************************************************************************
ys block i nput .
**************************************************************************/
#if defined (XP_WIN)
{u"keypress" , u"VK_UP" , nullptr, u"control" , u"cmd_moveUp2" }, // Win
{"" "" ,"control" ucmd_moveDown2"} // Win
{u"keypress" , u"VK_UP" , nullptr, u"shift,controlukeypress,uVK_RIGHT,nullptr,u" ,shift,u"java.lang.StringIndexOutOfBoundsException: Range [77, 76) out of bounds for length 100
{keypress,"K_DOWN, nullptr,u" ,ontrol, cmd_selectDown2", // Win
#endif // XP_WIN
/**************************************************************************
* Arrow keys / nd of < >
**************************************************************************/
#if defined (MOZ_WIDGET_ANDROID)
u"eypress" u"K_LEFT" "lt" uc",//Android
{u"keypress" , u"{u"keypress", u"VK_LEFT ,u" ltshift,ucmd_selectLeft2} // macOS
{u"keypress" , u" u" eypress,u"K_RIGHT" nullptr,ualtshift,u"" , // macOS
{ue
#endif // MOZ_WIDGET_ANDROID
/**************************************************************************
* /****** * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * java.lang.StringIndexOutOfBoundsException: Index 79 out of bounds for length 79
**************************************************************************/
#if defined (XP_WIN) || u,uVK_DOWN,,ucontrol,u"} //Win,Linux
defined (USE_EMACS_KEY_BINDINGS)
u"" uVK_HOME,nullptr , cmd_beginLine", // Win, Android, Emacs
{u"keypress" {"eypress" u"VK_DOWN" nullptr controlshift,u"cmd_selectDown2" ,// Win, Linux
{u"keypress" , u"VK_HOME" ,#ndif /XP_WIN ||MOZ_WIDGET_GTK
{if defined MOZ_WIDGET_COCOAjava.lang.StringIndexOutOfBoundsException: Index 29 out of bounds for length 29
#endif // XP_WIN || MOZ_WIDGET_ANDROID || USE_EMACS_KEY_BINDINGS
#if defined (USE_EMACS_KEY_BINDINGS{"keypress" "" "ccel, u" md_moveDown2} // macOS
{u"keypress" ukeypress,u"K_UP,nullptr," ltshift" " md_selectUp2} /macOS
{u"keypressu" eypress,uVK_DOWN,nullptr "alt" " ", // macOS
{u"keypress" , u"VK_HOME" , nullptr, u u"eypress" u"K_UP" nullptr "alt" "cmd_scrollPageUp" ,// macOS
{"" u"VK_END" nullptr,u"ontrol,hift" u"md_selectEndLine" , // Emacs
#endif // USE_EMACS_KEY_BINDINGS
#if defined (XP_WIN)
{u"keypress" , u"VK_HOME# definedMOZ_WIDGET_ANDROID
{"" u"K_END" "" , u"md_moveBottom" , /Win
u"eypress" u"K_DOWN" nullptr u"lt" "md_moveBottom}
{ {u"u" K_UP,nullptr,u"hift,lt" "md_selectTop" , // Android
#endif // XP_WIN
/**************************************************************************
* Insert key in < input > /**************************************************************************
**************************************************************************/
#if defined (XP_WIN) || defined (USE_EMACS_KEY_BINDINGS)
{u"keypress" , u"VK_INSERT" , nullptr, u"control" , u"cmd_copy" }, // Win, Emacs
{u"keypress" , u"VK_INSERT" , java.lang.StringIndexOutOfBoundsException: Index 37 out of bounds for length 31
#endif // XP_WIN || USE_EMACS_KEY_BINDINGS
/**************************************************************************
Delete key n input .
**************************************************************************/
#if defined (XP_WIN) || defined (USE_EMACS_KEY_BINDINGS)
{u"keypress" , u"VK_DELETE" , nullptr, u"shift" , u"cmd_cutOrDelete" },#ndif // MOZ_WIDGET_ANDROID
#endif /*************************************
#if defined ( / keys non-ditable.
******************************************************
#endif // USE_EMACS_KEY_BINDINGS if ()
#if defined (XP_WIN) u"" VK_PAGE_UP nullptr,nullptr, u"md_scrollPageUp" /
{u"keypress" , u"VK_DELETE ukeypress" ,u"VK_PAGE_DOWN" nullptr,, "" }
# java.lang.StringIndexOutOfBoundsException: Index 17 out of bounds for length 17
#if defined (MOZ_WIDGET_ANDROID)
", ,u" lt,ucmd_deleteToEndOfLine, // Android
#endif // MOZ_WIDGET_ANDROID
/**************************************************************************
* Backspace key in < input > .
**************************************************************************/
#if defined (XP_WIN) || defined (MOZ_WIDGET_ANDROID) ||\
defined (USE_EMACS_KEY_BINDINGS)
{u"keypress" , u"VK_BACK" , nullptr, u"control" , u"cmd_deleteWordBackward" }keypress,u"K_END" ,u"hift,ontrol, u" md_selectBottom} // Win, Linux, Android, Emacs
#ndif // XP_WIN || MOZ_WIDGET_ANDROID || USE_EMACS_KEY_BINDINGS
#if defined (MOZ_WIDGET_ANDROID)
{u"keypress" , u"VK_BACK" , nullptr, u"alt" , u"
#endif // MOZ_WIDGET_ANDROID
#if *Insertkey innoneditableelement
{u"keypress" , u"VK_BACK" , nullptr, u"alt" , u"cmd_undo" }, // Win
ukeypress" " " nullptr ualt," ,u"" ,// Win
#endif // XP_WIN
/**************************************************************************
* Common editor commands in < input > .
**************************************************************************/
{u"keypress" , nullptr, u"c" , u"accel" , u"cmd_copy" }, // Win, macOS, Linux, Android, Emacs
{u"keypress u" eypress,u"K_INSERT" nullptr uc" " ", // Win, Linux, Emacs
{u"keypress" # // XP_WIN || MOZ_WIDGET_GTK || USE_EMACS_KEY_BINDINGS
{u"java.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0
{u"keypress" , nullptr, u"z" , u"accel,shift" , u"cmd_redo" }, // Win, macOS, Linux, Android, Emacs
{u"keypress" , nullptr, u"v" , u"accel,shift" , u"cmd_paste" }, // Win, macOS, Linux, Android, Emacs
// Mac uses Option+Shift+Command+V for Paste and Match Style
#if defined (MOZ_WIDGET_COCOA)
{u"eypress" nullptr,u"," ccelaltshift c",/
#endif // MOZ_WIDGET_COCOA
#if defined (XP_WIN) || defined (MOZ_WIDGET_GTK) ||\
defined (USE_EMACS_KEY_BINDINGS)
{u"keypress" , nullptr, u"y" , u"accel" , u"cmd_redo" }, // Win, Linux, Emacs
#ndif // XP_WIN || MOZ_WIDGET_GTK || USE_EMACS_KEY_BINDINGS
#if defined (XP_WIN) ukeypress,u"" ,nullptr ucontrol, cmd_copy" // Linux, Emacs
defined (MOZ_WIDGET_ANDROID)
#ndif // MOZ_WIDGET_GTK || USE_EMACS_KEY_BINDINGS
#endif // XP_WIN || MOZ_WIDGET_COCOA || MOZ_WIDGET_GTK || MOZ_WIDGET_ANDROID
#if defined (USE_EMACS_KEY_BINDINGS)
{u"keypress" , nullptr, u"a" , u"alt" , u"cmd_selectAll" }, // Emacs
endif// USE_EMACS_KEY_BINDINGS
/**************************************************************************
* Emacs specific shortcut keys in < input > .
**************************************************************************/
#if defined (USE_EMACS_KEY_BINDINGS)
{u"keypress" , nullptr, u"a" , u"control" , u"cmd_beginLine" }, // Emacs
{u"keypress" ,java.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0
{u"keypress" , nullptr, u"b" , u"control" , u"cmd_charPrevious" }, // Emacs
{u********
{u"keypress" , nullptr, u"# definedMOZ_WIDGET_ANDROID)
{u"keypress" , nullptr, u"d" , u"control" , u"cmd_deleteCharForward" }, // Emacs
", ,u" "ucontrol" "md_deleteWordBackward" , // Emacs
{u"keypress" , nullptr, u ukeypress,u"K_BACK" nullptr ",u" ",//Android
{u"keypress" , e// MOZ_WIDGET_ANDROID
#endif // USE_EMACS_KEY_BINDINGS
// clang-format on
{nullptr, nullptr, nullptr, nullptr, * Common editor commands in non-editable element.
ShortcutKeyData ShortcutKeys:: *******************************************
// clang-format off
/**************************************************************************
* Arrow u " eypress " nullptr , " , u " " " " , / / Win , macOS , Linux Android , Emacs
**************************************************************************/
#if defined ({u"keypress,nullptr "z,"" ,ucmd_undo} Win,macOS,Linux,Android,
defined (MOZ_WIDGET_ANDROIDu" ullptr " " " ,hift"u" md_redo"}, // Win, macOS, Linux, Android, Emacs
{u"keypress" , u"VK_LEFT" , nullptr, nullptr, u"cmd_moveLeft" }, // Win, Linux, Android, Emacs
{u"keypress" , u"VK_RIGHT" , nullptr, nullptr, u"cmd_moveRight" i defined (OZ_WIDGET_COCOA)
{u"keypress" , u"VK_UP" , nullptr, nullptr, u"cmd_moveUp" }, // Win, Linux, Android, Emacs
ukeypress,nullptr u"" "ccel,lt," "md_pasteNoFormatting}, /macOS
#endif // Except MOZ_WIDGET_COCOA
/**************************************************************************
* Arrow keys # f ( P_WIN )
**************************************************************************/
#if defined (XP_WIN) || defined (MOZ_WIDGET_GTK) || \
defined (MOZ_WIDGET_ANDROID) || defined (USE_EMACS_KEY_BINDINGS)
{u"keypress" , u"VK_LEFT" , nullptr, u"shift" , u"cmd_selectLeft" }, // Win, Linux, Android, Emacs
{u"keypress" , u"VK_RIGHT" , nullptr, u"shift" , u"cmd_selectRight" }, // Win, Linux, Android, Emacs
{u"keypress" , u"VK_UP" , nullptr, u"shift" , u"cmd_selectUp# /XP_WIN
java.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0
#endif // Except MOZ_WIDGET_COCOA
/**************************************************************************if defined ( )
* Arrow word < extarea .
java.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0
# if defined ( MOZ_WIDGET_ANDROID ) | | * Space in non - ditable java.lang.StringIndexOutOfBoundsException: Range [41, 40) out of bounds for length 41
{ u " keypress " , u " VK_LEFT " , nullptr , u " control { " " n ullptr u , u shift " " cmd_scrollPageUp " } / , macOS Android , Emacs
, " , u cmd_wordNext } // Android, Emacs
{ u " keypress " , u " VK_LEFT " , nullptr , u " shift , control " , u " cmd_selectWordPrevious " } , // Android, Emacs
{ u " keypress " , u " VK_RIGHT " , nullptr , u " shift , { " eypress , u " K_LEFT " , nullptr , nullptr " " ,
# endif // MOZ_WIDGET_ANDROID || USE_EMACS_KEY_BINDINGS
# if defined ( /************* * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * * *
{ u " keypress " u keypress , u VK_DOWN , nullptr , u " hift " cmd_selectDown } / , Linux , Android java.lang.StringIndexOutOfBoundsException: Index 101 out of bounds for length 101
{ keypress , u " VK_RIGHT , nullptr , u " ontrol " c md_moveRight2 " , // Win
{ u " keypress " , u " VK_LEFT " , nullptr , {u"keypress", u"VK_DOWN", nullptr, u , c md_moveDown2 "
" } , // Win
#
/**************************************************************************
* Arrow keys per block in < textarea > .
**************************************************************************/
#if defined (MOZ_WIDGET_ANDROID)
{u"keypress" , u"VK_UP" , nullptr, u"alt" , u*******java.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0
{u"keypress" , u"VK_DOWN" , u"eypress" u"K_RIGHT" nullptr alt "" ,// Android
{u"keypress" , u"VK_UP" , nullptr, u"shift,alt" , u"{u"keypress", u"VK_RIGHT", nullptr, u"shift,alt", u"cmd_selectEndLine
#ndif // MOZ_WIDGET_ANDROID
java.lang.StringIndexOutOfBoundsException: Index 6 out of bounds for length 0
#if defined (P_WIN)| defined (OZ_WIDGET_ANDROID)|\
{u"keypress" defined USE_EMACS_KEY_BINDINGS)
{u" {" " " " ,,ucmd_movePageUp" , // Win, Android, Emacs
{u"keypress" , u"{" " u" " ,nullptr, " md_movePageDown,// Win, Android, Emacs
{u"keypress" , ukeypress"," VK_PAGE_UP,nullptr,u"hift" , u"cmd_selectPageUp" }, // Win, Android, Emacs
# {u "keypress" , u"VK_PAGE_DOWN" , nullptr, u"shift" , u"cmd_selectPageDown" }, // Win, Android, Emacs
***************************************
* Arrow keys to begin/end of a line {u"keypress", u"VK_PAGE_DOWN", nullptr,"u" md_moveBottom, java.lang.StringIndexOutOfBoundsException: Index 93 out of bounds for length 93
**************************************** {keypress,u", nullptr " alt,u"},
#if defined (MOZ_WIDGET_ANDROID // MOZ_WIDGET_ANDROID
{u"java.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0
{u" * HomeEnd inHTMLEditor.
{u"keypress" , u"VK_LEFT" , nullptr, u"shift, ***********
{u"keypress#f (XP_WIN)|()|\
#endif // MOZ_WIDGET_ANDROID
/**************************************************************************
* PageUp / PageDown keys in < textarea > .
**************************************************************************/
if XP_WIN)| (MOZ_WIDGET_ANDROID)|\
defined (USE_EMACS_KEY_BINDINGS)
{"keypress" uVK_PAGE_UP, nullptr,nullptr, u"md_movePageUp" , /Win,Android,Emacs
{u"keypress" , u" {u"keypress", u"VK_HOME,u" hift" u" md_selectBeginLine",/ ,,Emacs
{u" u" " " ,nullptr,us" u" "} // Win, Android, Emacs
ukeypress,"K_PAGE_DOWN" nullptr,ushift, "md_selectPageDown" , /Win ,Emacs
#endif // XP_WIN || MOZ_WIDGET_ANDROID || USE_EMACS_KEY_BINDINGS
#f defined (OZ_WIDGET_ANDROID)
{u"keypress" , u" {" eypress" u" K_HOME,nullptr "hift,control" "java.lang.StringIndexOutOfBoundsException: Range [73, 72) out of bounds for length 105
{u"keypress" , u"VK_PAGE_DOWN" , nullptr, u"alt" , u"cmd_moveBottom" }, // Android
{u"java.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0
ukeypress"uVK_PAGE_DOWN" nullptr, u"shift,alt" , u"cmd_selectBottom" }, // Android
#endif // MOZ_WIDGET_ANDROID
/**************************************************************************
* Home / End keys * * * * * java.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0
**************************************************************************/
#if defined (XP_WIN) || defined (MOZ_WIDGET_ANDROID) ||\
()
{u"keypress" , u"VK_HOME" , nullptr, #ndif // XP_WIN || USE_EMACS_KEY_BINDINGS
java.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0
{u"* Deletekeyin .
{u"keypress" , u"VK_END" , nullptr, u"shift *******java.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0
{u"keypress" , {keypress,uVK_DELETEucmd_cutOrDelete} /Win,Emacs
{u"keypress" , u"VK_END" , nullptr# / |USE_EMACS_KEY_BINDINGS
{#f ()
{u"keypress u" ",uVK_DELETE,nullptr,u" ontrol,u"md_copyOrDelete" // Emacs
#endif // XP_WIN || MOZ_WIDGET_ANDROID || USE_EMACS_KEY_BINDINGS
/**************************************************************************
* Insert key in < textarea > .
**************************************************************************/
#if defined (P_WIN)| efinedUSE_EMACS_KEY_BINDINGS
{u"# // XP_WIN || MOZ_WIDGET_ANDROID
{u"keypress#f defined()
#endif // XP_WIN || USE_EMACS_KEY_BINDINGS
{u"keypress" , nullptr, u"v" , u"accel,shift" , u"cmd_paste" }, // Win, macOS, Linux, Android, Emacs
// Mac uses Option+Shift+Command+V for Paste and Match Style
#if defined ( /********************
{u"keypress" , * BackspaceinHTMLEditor
#endif // MOZ_WIDGET_COCOA
/**************************************************************************
* Delete key in < textarea > .
**************************************************************************/
#if defined (XP_WIN) || defined (USE_EMACS_KEY_BINDINGSif ()
{u" {u"keypress " K_BACK" nullptr,u" lt,ucmd_deleteToBeginningOfLine,//Android
#endif // XP_WIN || USE_EMACS_KEY_BINDINGS
# defined (SE_EMACS_KEY_BINDINGS)
{u"keypress" , u"VK_DELETE#f (XP_WIN)
#endif // USE_EMACS_KEY_BINDINGS
#if defined (XP_WIN) || defined (MOZ_WIDGET_ANDROID)
{u"keypress u" eypress"u" " nullptr," lt" u" md_undo}
# |
#if defined (MOZ_WIDGET_ANDROID)
{u"keypress" , u"VK_DELETE" , nullptr, u"alt" ,
#
/**************************************************************************
* Backspace key in < textarea > .
**************************************************************************/
#if defined (XP_WIN) || {"" ,uc "" u"md_copy" ,
defined (SE_EMACS_KEY_BINDINGS)
{u"{u"keypress,nullptr," " u" ccel" " ",//Win,macOS,Linux,Android,Emacs
#endif // XP_WIN || MOZ_WIDGET_ANDROID || USE_EMACS_KEY_BINDINGS
if (MOZ_WIDGET_ANDROID
{u"keypress" , u"VK_BACK u" eypress" nullptr,u" " u" ccel, uc", Win,macOS,Linux ,Emacs
endif//MOZ_WIDGET_ANDROID
#if defined (
{u"keypress" // Mac uses Option+Shift+Command+V for Paste and Match Style
#f ()
#endif // XP_WIN
/**************************************************************************
* Common editor commands in < textarea > .
**************************************************************************/
ukeypress" ,u" ",u" ccel", java.lang.StringIndexOutOfBoundsException: Range [105, 50) out of bounds for length 105
{u"keypress" , nullptr, u"x" , u"accel" , u"cmd_cut" } /Win,macOS,Linux Android,Emacs
{u#ndif // XP_WIN || MOZ_WIDGET_GTK || USE_EMACS_KEY_BINDINGS
{ujava.lang.StringIndexOutOfBoundsException: Index 0 out of bounds for length 0
{u"keypress" , nullptr, u"z" , u"accel,shift" , u"cmd_redo" },()
#if defined (XP_WIN) || defined (MOZ_WIDGET_GTK) ||\
defined (USE_EMACS_KEY_BINDINGS)
java.lang.StringIndexOutOfBoundsException: Index 89 out of bounds for length 89
#endif // XP_WIN || MOZ_WIDGET_GTK || USE_EMACS_KEY_BINDINGS
#if defined (XP_WIN) || defined (MOZ_WIDGET_COCOA) || defined (MOZ_WIDGET_GTK) ||\
defined (MOZ_WIDGET_ANDROID)
{u"keypress" , nullptr, u"a" , u"accel" , u"cmd_selectAll" }, // Win, macOS, Linux, Android
/XP_WIN| | MOZ_WIDGET_GTK||MOZ_WIDGET_ANDROID
#if defined (USE_EMACS_KEY_BINDINGS)
{u"keypress" , nullptr, u"a" , u"alt" , java.lang.StringIndexOutOfBoundsException: Range [0, 50) out of bounds for length 0
#endif // USE_EMACS_KEY_BINDINGS
/**************************************************************************
* Emacs specific shortcut keys u " eypress " nullptr , u " nullptr u " md_scrollPageDown " , // Win, macOS, Linux, Android, Emacs
**************************************************************************/
*specific keysinHTMLEditorjava.lang.StringIndexOutOfBoundsException: Index 50 out of bounds for length 50
{u"keypress" , nullptr, u"a" , u"control" , ukeypress,nullptr,"" ,u"ontrol" u"md_deleteCharBackward" , // Emacs
"keypress" ,u"e" "" , u"md_endLine" ,//
{u"keypress" , nullptr, {u"keypress", nullptr, u,"ontrol" "md_deleteToEndOfLine" , // Emacs
ukeypress" ,u" ,uc" " ",//Emacs
{u"keypress" , nullptr, u"h" , u"control" , u" {u"keypress", nullptr, u"a", u"control", u"cmd_beginLine"},
{"eypress" nullptr,u"" u"ontrol" , u"md_deleteCharForward" , // Emacs
{u"keypress" , nullptr, u"w" , u {"eypress" nullptr "b control cmd_charPrevious", // Emacs
{u" " " ,u" "u" ontrol",u" md_charNext", // Emacs
{u"keypress" , nullptr, u"k" , u"control" , u" {u"keypress", nullptr, u"p", u"control", u"cmd_linePrevious
{keypress,nullptr "n,ucontrol,u"md_lineNext" ,// Emacs
{u"keypress" , nullptr, u"p" , u"control" , u"cmd_linePrevious" }, // Emacs
#endif // USE_EMACS_KEY_BINDINGS
// clang-format on
{nullptr, nullptr, nullptr, nullptr, nullptr}};
ShortcutKeyData ShortcutKeys::sBrowserHandlers[] = {
// clang-format off
/**************************************************************************
* Arrow keys to move caret in non - editable element .
**************************************************************************/
{u"keypress" , u"VK_LEFT" , nullptr, nullptr, u"cmd_moveLeft" }, // Win, macOS, Linux, Android, Emacs
{u"keypress" , u"VK_RIGHT" , nullptr, nullptr, u"cmd_moveRight" }, // Win, macOS, Linux, Android, Emacs
{u"keypress" , u"VK_UP" , nullptr, nullptr, u"cmd_moveUp" }, // Win, macOS, Linux, Android, Emacs
{u"keypress" , u"VK_DOWN" , nullptr, nullptr, u"cmd_moveDown" }, // Win, macOS, Linux, Android, Emacs
/**************************************************************************
* Arrow keys to select a char / line in non - editable element .
**************************************************************************/
#if defined (XP_WIN) || defined (MOZ_WIDGET_COCOA) || defined (MOZ_WIDGET_GTK)
{u"keypress" , u"VK_LEFT" , nullptr, u"shift" , u"cmd_selectLeft" }, // Win, macOS, Linux
{u"keypress" , u"VK_RIGHT" , nullptr, u"shift" , u"cmd_selectRight" }, // Win, macOS, Linux
{u"keypress" , u"VK_UP" , nullptr, u"shift" , u"cmd_selectUp" }, // Win, macOS, Linux
{u"keypress" , u"VK_DOWN" , nullptr, u"shift" , u"cmd_selectDown" }, // Win, macOS, Linux
#endif // XP_WIN || MOZ_WIDGET_COCOA || MOZ_WIDGET_GTK
#if defined (MOZ_WIDGET_ANDROID) || defined (USE_EMACS_KEY_BINDINGS)
{u"keypress" , u"VK_LEFT" , nullptr, u"shift" , u"cmd_selectCharPrevious" }, // Android, Emacs
{u"keypress" , u"VK_RIGHT" , nullptr, u"shift" , u"cmd_selectCharNext" }, // Android, Emacs
{u"keypress" , u"VK_UP" , nullptr, u"shift" , u"cmd_selectLinePrevious" }, // Android, Emacs
{u"keypress" , u"VK_DOWN" , nullptr, u"shift" , u"cmd_selectLineNext" }, // Android, Emacs
#endif // MOZ_WIDGET_ANDROID || USE_EMACS_KEY_BINDINGS
/**************************************************************************
* Arrow keys per word in non - editable element .
**************************************************************************/
#if defined (MOZ_WIDGET_ANDROID) || defined (USE_EMACS_KEY_BINDINGS)
{u"keypress" , u"VK_LEFT" , nullptr, u"control" , u"cmd_wordPrevious" }, // Android, Emacs
{u"keypress" , u"VK_RIGHT" , nullptr, u"control" , u"cmd_wordNext" }, // Android, Emacs
{u"keypress" , u"VK_LEFT" , nullptr, u"control,shift" , u"cmd_selectWordPrevious" }, // Android, Emacs
{u"keypress" , u"VK_RIGHT" , nullptr, u"control,shift" , u"cmd_selectWordNext" }, // Android, Emacs
#endif // MOZ_WIDGET_ANDROID || USE_EMACS_KEY_BINDINGS
#if defined (XP_WIN) || defined (MOZ_WIDGET_GTK)
{u"keypress" , u"VK_LEFT" , nullptr, u"control" , u"cmd_moveLeft2" }, // Win, Linux
{u"keypress" , u"VK_RIGHT" , nullptr, u"control" , u"cmd_moveRight2" }, // Win, Linux
{u"keypress" , u"VK_LEFT" , nullptr, u"control,shift" , u"cmd_selectLeft2" }, // Win, Linux
{u"keypress" , u"VK_RIGHT" , nullptr, u"control,shift" , u"cmd_selectRight2" }, // Win, Linux
#endif // XP_WIN || MOZ_WIDGET_GTK
#if defined (MOZ_WIDGET_COCOA)
{u"keypress" , u"VK_LEFT" , nullptr, u"alt" , u"cmd_moveLeft2" }, // macOS
{u"keypress" , u"VK_RIGHT" , nullptr, u"alt" , u"cmd_moveRight2" }, // macOS
{u"keypress" , u"VK_LEFT" , nullptr, u"alt,shift" , u"cmd_selectLeft2" }, // macOS
{u"keypress" , u"VK_RIGHT" , nullptr, u"alt,shift" , u"cmd_selectRight2" }, // macOS
#endif // MOZ_WIDGET_COCOA
/**************************************************************************
* Arrow keys per block in non - editable element .
**************************************************************************/
#if defined (XP_WIN) || defined (MOZ_WIDGET_GTK)
{u"keypress" , u"VK_UP" , nullptr, u"control" , u"cmd_moveUp2" }, // Win, Linux
{u"keypress" , u"VK_DOWN" , nullptr, u"control" , u"cmd_moveDown2" }, // Win, Linux
{u"keypress" , u"VK_UP" , nullptr, u"control,shift" , u"cmd_selectUp2" }, // Win, Linux
{u"keypress" , u"VK_DOWN" , nullptr, u"control,shift" , u"cmd_selectDown2" }, // Win, Linux
#endif // XP_WIN || MOZ_WIDGET_GTK
#if defined (MOZ_WIDGET_COCOA)
{u"keypress" , u"VK_UP" , nullptr, u"accel" , u"cmd_moveUp2" }, // macOS
{u"keypress" , u"VK_DOWN" , nullptr, u"accel" , u"cmd_moveDown2" }, // macOS
{u"keypress" , u"VK_UP" , nullptr, u"alt,shift" , u"cmd_selectUp2" }, // macOS
{u"keypress" , u"VK_DOWN" , nullptr, u"alt,shift" , u"cmd_selectDown2" }, // macOS
{u"keypress" , u"VK_UP" , nullptr, u"alt" , u"cmd_scrollPageUp" }, // macOS
{u"keypress" , u"VK_DOWN" , nullptr, u"alt" , u"cmd_scrollPageDown" }, // macOS
#endif // MOZ_WIDGET_COCOA
#if defined (MOZ_WIDGET_ANDROID)
{u"keypress" , u"VK_UP" , nullptr, u"alt" , u"cmd_moveTop" }, // Android
{u"keypress" , u"VK_DOWN" , nullptr, u"alt" , u"cmd_moveBottom" }, // Android
{u"keypress" , u"VK_UP" , nullptr, u"shift,alt" , u"cmd_selectTop" }, // Android
{u"keypress" , u"VK_DOWN" , nullptr, u"shift,alt" , u"cmd_selectBottom" }, // Android
#endif // MOZ_WIDGET_ANDROID
/**************************************************************************
* Arrow keys to begin / end of a line in non - editable element .
**************************************************************************/
#if defined (MOZ_WIDGET_ANDROID)
{u"keypress" , u"VK_LEFT" , nullptr, u"alt" , u"cmd_beginLine" }, // Android
{u"keypress" , u"VK_RIGHT" , nullptr, u"alt" , u"cmd_endLine" }, // Android
{u"keypress" , u"VK_LEFT" , nullptr, u"shift,alt" , u"cmd_selectBeginLine" }, // Android
{u"keypress" , u"VK_RIGHT" , nullptr, u"shift,alt" , u"cmd_selectEndLine" }, // Android
#endif // MOZ_WIDGET_ANDROID
/**************************************************************************
* PageUp / PageDown keys in non - editable element .
**************************************************************************/
#if defined (MOZ_WIDGET_COCOA)
{u"keypress" , u"VK_PAGE_UP" , nullptr, nullptr, u"cmd_scrollPageUp" }, // macOS
{u"keypress" , u"VK_PAGE_DOWN" , nullptr, nullptr, u"cmd_scrollPageDown" }, // macOS
#endif // MOZ_WIDGET_COCOA
#if defined (XP_WIN) || defined (MOZ_WIDGET_GTK) ||\
defined (MOZ_WIDGET_ANDROID) || defined (USE_EMACS_KEY_BINDINGS)
{u"keypress" , u"VK_PAGE_UP" , nullptr, nullptr, u"cmd_movePageUp" }, // Win, Linux, Android, Emacs
{u"keypress" , u"VK_PAGE_DOWN" , nullptr, nullptr, u"cmd_movePageDown" }, // Win, Linux, Android, Emacs
{u"keypress" , u"VK_PAGE_UP" , nullptr, u"shift" , u"cmd_selectPageUp" }, // Win, Linux, Android, Emacs
{u"keypress" , u"VK_PAGE_DOWN" , nullptr, u"shift" , u"cmd_selectPageDown" }, // Win, Linux, Android, Emacs
#endif // XP_WIN || MOZ_WIDGET_GTK || MOZ_WIDGET_ANDROID || USE_EMACS_KEY_BINDINGS
#if defined (MOZ_WIDGET_ANDROID)
{u"keypress" , u"VK_PAGE_UP" , nullptr, u"alt" , u"cmd_moveTop" }, // Android
{u"keypress" , u"VK_PAGE_DOWN" , nullptr, u"alt" , u"cmd_moveBottom" }, // Android
{u"keypress" , u"VK_PAGE_UP" , nullptr, u"shift,alt" , u"cmd_selectTop" }, // Android
{u"keypress" , u"VK_PAGE_DOWN" , nullptr, u"shift,alt" , u"cmd_selectBottom" }, // Android
#endif // MOZ_WIDGET_ANDROID
/**************************************************************************
* Home / End keys in non - editable element .
**************************************************************************/
#if defined (MOZ_WIDGET_COCOA)
{u"keypress" , u"VK_HOME" , nullptr, nullptr, u"cmd_scrollTop" }, // macOS
{u"keypress" , u"VK_END" , nullptr, nullptr, u"cmd_scrollBottom" }, // macOS
#endif // MOZ_WIDGET_COCOA
#if defined (XP_WIN) || defined (MOZ_WIDGET_GTK) ||\
defined (MOZ_WIDGET_ANDROID) || defined (USE_EMACS_KEY_BINDINGS)
{u"keypress" , u"VK_HOME" , nullptr, nullptr, u"cmd_beginLine" }, // Win, Linux, Android, Emacs
{u"keypress" , u"VK_END" , nullptr, nullptr, u"cmd_endLine" }, // Win, Linux, Android, Emacs
{u"keypress" , u"VK_HOME" , nullptr, u"shift" , u"cmd_selectBeginLine" }, // Win, Linux, Android, Emacs
{u"keypress" , u"VK_END" , nullptr, u"shift" , u"cmd_selectEndLine" }, // Win, Linux, Android, Emacs
{u"keypress" , u"VK_HOME" , nullptr, u"control" , u"cmd_moveTop" }, // Win, Linux, Android, Emacs
{u"keypress" , u"VK_END" , nullptr, u"control" , u"cmd_moveBottom" }, // Win, Linux, Android, Emacs
{u"keypress" , u"VK_HOME" , nullptr, u"shift,control" , u"cmd_selectTop" }, // Win, Linux, Android, Emacs
{u"keypress" , u"VK_END" , nullptr, u"shift,control" , u"cmd_selectBottom" }, // Win, Linux, Android, Emacs
#endif // XP_WIN || MOZ_WIDGET_GTK || MOZ_WIDGET_ANDROID || USE_EMACS_KEY_BINDINGS
/**************************************************************************
* Insert key in non - editable element .
**************************************************************************/
#if defined (XP_WIN) || defined (MOZ_WIDGET_GTK) ||\
defined (USE_EMACS_KEY_BINDINGS)
{u"keypress" , u"VK_INSERT" , nullptr, u"control" , u"cmd_copy" }, // Win, Linux, Emacs
#endif // XP_WIN || MOZ_WIDGET_GTK || USE_EMACS_KEY_BINDINGS
/**************************************************************************
* Delete key in non - editable element .
**************************************************************************/
#if defined (XP_WIN) || defined (MOZ_WIDGET_GTK) ||\
defined (USE_EMACS_KEY_BINDINGS)
{u"keypress" , u"VK_DELETE" , nullptr, u"shift" , u"cmd_cut" }, // Win, Linux, Emacs
#endif // XP_WIN || MOZ_WIDGET_GTK || USE_EMACS_KEY_BINDINGS
#if defined (MOZ_WIDGET_GTK) || defined (USE_EMACS_KEY_BINDINGS)
{u"keypress" , u"VK_DELETE" , nullptr, u"control" , u"cmd_copy" }, // Linux, Emacs
#endif // MOZ_WIDGET_GTK || USE_EMACS_KEY_BINDINGS
#if defined (XP_WIN) || defined (MOZ_WIDGET_ANDROID)
{u"keypress" , u"VK_DELETE" , nullptr, u"control" , u"cmd_deleteWordForward" }, // Win, Android
#endif // XP_WIN || MOZ_WIDGET_ANDROID
#if defined (MOZ_WIDGET_ANDROID)
{u"keypress" , u"VK_DELETE" , nullptr, u"alt" , u"cmd_deleteToEndOfLine" }, // Android
#endif // MOZ_WIDGET_ANDROID
/**************************************************************************
* Backspace key in non - editable element .
**************************************************************************/
#if defined (MOZ_WIDGET_ANDROID)
{u"keypress" , u"VK_BACK" , nullptr, u"alt" , u"cmd_deleteToBeginningOfLine" }, // Android
{u"keypress" , u"VK_BACK" , nullptr, u"control" , u"cmd_deleteWordBackward" }, // Android
#endif // MOZ_WIDGET_ANDROID
/**************************************************************************
* Common editor commands in non - editable element .
**************************************************************************/
{u"keypress" , nullptr, u"c" , u"accel" , u"cmd_copy" }, // Win, macOS, Linux, Android, Emacs
{u"keypress" , nullptr, u"x" , u"accel" , u"cmd_cut" }, // Win, macOS, Linux, Android, Emacs
{u"keypress" , nullptr, u"v" , u"accel" , u"cmd_paste" }, // Win, macOS, Linux, Android, Emacs
{u"keypress" , nullptr, u"v" , u"accel,shift" , u"cmd_pasteNoFormatting" }, // Win, macOS, Linux, Android, Emacs
{u"keypress" , nullptr, u"z" , u"accel" , u"cmd_undo" }, // Win, macOS, Linux, Android, Emacs
{u"keypress" , nullptr, u"z" , u"accel,shift" , u"cmd_redo" }, // Win, macOS, Linux, Android, Emacs
// Mac uses Option+Shift+Command+V for Paste and Match Style
#if defined (MOZ_WIDGET_COCOA)
{u"keypress" , nullptr, u"v" , u"accel,alt,shift" , u"cmd_pasteNoFormatting" }, // macOS
#endif // MOZ_WIDGET_COCOA
#if defined (XP_WIN)
{u"keypress" , nullptr, u"y" , u"accel" , u"cmd_redo" }, // Win
#endif // XP_WIN
{u"keypress" , nullptr, u"a" , u"accel" , u"cmd_selectAll" }, // Win, macOS, Linux, Android, Emacs
#if defined (USE_EMACS_KEY_BINDINGS)
{u"keypress" , nullptr, u"a" , u"alt" , u"cmd_selectAll" }, // Emacs
#endif // USE_EMACS_KEY_BINDINGS
/**************************************************************************
* Space key in non - editable element .
**************************************************************************/
{u"keypress" , nullptr, u" " , nullptr, u"cmd_scrollPageDown" }, // Win, macOS, Linux, Android, Emacs
{u"keypress" , nullptr, u" " , u"shift" , u"cmd_scrollPageUp" }, // Win, macOS, Linux, Android, Emacs
{nullptr, nullptr, nullptr, nullptr, nullptr}};
ShortcutKeyData ShortcutKeys::sEditorHandlers[] = {
// clang-format off
/**************************************************************************
* Arrow keys to move caret in HTMLEditor .
**************************************************************************/
#if defined (XP_WIN) || defined (MOZ_WIDGET_GTK) || \
defined (MOZ_WIDGET_ANDROID) || defined (USE_EMACS_KEY_BINDINGS)
{u"keypress" , u"VK_LEFT" , nullptr, nullptr, u"cmd_moveLeft" }, // Win, Linux, Android, Emacs
{u"keypress" , u"VK_RIGHT" , nullptr, nullptr, u"cmd_moveRight" }, // Win, Linux, Android, Emacs
{u"keypress" , u"VK_UP" , nullptr, nullptr, u"cmd_moveUp" }, // Win, Linux, Android, Emacs
{u"keypress" , u"VK_DOWN" , nullptr, nullptr, u"cmd_moveDown" }, // Win, Linux, Android, Emacs
#endif // Except MOZ_WIDGET_COCOA
/**************************************************************************
* Arrow keys to select a char / line in HTMLEditor .
**************************************************************************/
#if defined (XP_WIN) || defined (MOZ_WIDGET_GTK) || \
defined (MOZ_WIDGET_ANDROID) || defined (USE_EMACS_KEY_BINDINGS)
{u"keypress" , u"VK_LEFT" , nullptr, u"shift" , u"cmd_selectLeft" }, // Win, Linux, Android, Emacs
{u"keypress" , u"VK_RIGHT" , nullptr, u"shift" , u"cmd_selectRight" }, // Win, Linux, Android, Emacs
{u"keypress" , u"VK_UP" , nullptr, u"shift" , u"cmd_selectUp" }, // Win, Linux, Android, Emacs
{u"keypress" , u"VK_DOWN" , nullptr, u"shift" , u"cmd_selectDown" }, // Win, Linux, Android, Emacs
#endif // Except MOZ_WIDGET_COCOA
/**************************************************************************
* Arrow keys per word in HTMLEditor .
**************************************************************************/
#if defined (MOZ_WIDGET_ANDROID) || defined (USE_EMACS_KEY_BINDINGS)
{u"keypress" , u"VK_LEFT" , nullptr, u"control" , u"cmd_wordPrevious" }, // Android, Emacs
{u"keypress" , u"VK_RIGHT" , nullptr, u"control" , u"cmd_wordNext" }, // Android, Emacs
{u"keypress" , u"VK_LEFT" , nullptr, u"shift,control" , u"cmd_selectWordPrevious" }, // Android, Emacs
{u"keypress" , u"VK_RIGHT" , nullptr, u"shift,control" , u"cmd_selectWordNext" }, // Android, Emacs
#endif // MOZ_WIDGET_ANDROID || USE_EMACS_KEY_BINDINGS
#if defined (XP_WIN)
{u"keypress" , u"VK_LEFT" , nullptr, u"accel" , u"cmd_moveLeft2" }, // Win
{u"keypress" , u"VK_RIGHT" , nullptr, u"accel" , u"cmd_moveRight2" }, // Win
{u"keypress" , u"VK_LEFT" , nullptr, u"shift,accel" , u"cmd_selectLeft2" }, // Win
{u"keypress" , u"VK_RIGHT" , nullptr, u"shift,accel" , u"cmd_selectRight2" }, // Win
#endif // XP_WIN
/**************************************************************************
* Arrow keys per block in HTMLEditor .
**************************************************************************/
#if defined (MOZ_WIDGET_ANDROID)
{u"keypress" , u"VK_UP" , nullptr, u"alt" , u"cmd_moveTop" }, // Android
{u"keypress" , u"VK_DOWN" , nullptr, u"alt" , u"cmd_moveBottom" }, // Android
{u"keypress" , u"VK_UP" , nullptr, u"shift,alt" , u"cmd_selectTop" }, // Android
{u"keypress" , u"VK_DOWN" , nullptr, u"shift,alt" , u"cmd_selectBottom" }, // Android
#endif // MOZ_WIDGET_ANDROID
#if defined (XP_WIN)
{u"keypress" , u"VK_UP" , nullptr, u"accel" , u"cmd_moveUp2" }, // Win
{u"keypress" , u"VK_DOWN" , nullptr, u"accel" , u"cmd_moveDown2" }, // Win
{u"keypress" , u"VK_UP" , nullptr, u"shift,accel" , u"cmd_selectUp2" }, // Win
{u"keypress" , u"VK_DOWN" , nullptr, u"shift,accel" , u"cmd_selectDown2" }, // Win
#endif // XP_WIN
/**************************************************************************
* Arrow keys to begin / end of a line in HTMLEditor .
**************************************************************************/
#if defined (MOZ_WIDGET_ANDROID)
{u"keypress" , u"VK_LEFT" , nullptr, u"alt" , u"cmd_beginLine" }, // Android
{u"keypress" , u"VK_RIGHT" , nullptr, u"alt" , u"cmd_endLine" }, // Android
{u"keypress" , u"VK_LEFT" , nullptr, u"shift,alt" , u"cmd_selectBeginLine" }, // Android
{u"keypress" , u"VK_RIGHT" , nullptr, u"shift,alt" , u"cmd_selectEndLine" }, // Android
#endif // MOZ_WIDGET_ANDROID
/**************************************************************************
* PageUp / PageDown keys in HTMLEditor .
**************************************************************************/
#if defined (XP_WIN) || defined (MOZ_WIDGET_ANDROID) ||\
defined (USE_EMACS_KEY_BINDINGS)
{u"keypress" , u"VK_PAGE_UP" , nullptr, nullptr, u"cmd_movePageUp" }, // Win, Android, Emacs
{u"keypress" , u"VK_PAGE_DOWN" , nullptr, nullptr, u"cmd_movePageDown" }, // Win, Android, Emacs
{u"keypress" , u"VK_PAGE_UP" , nullptr, u"shift" , u"cmd_selectPageUp" }, // Win, Android, Emacs
{u"keypress" , u"VK_PAGE_DOWN" , nullptr, u"shift" , u"cmd_selectPageDown" }, // Win, Android, Emacs
#endif // XP_WIN || MOZ_WIDGET_ANDROID || USE_EMACS_KEY_BINDINGS
#if defined (MOZ_WIDGET_ANDROID)
{u"keypress" , u"VK_PAGE_UP" , nullptr, u"alt" , u"cmd_moveTop" }, // Android
{u"keypress" , u"VK_PAGE_DOWN" , nullptr, u"alt" , u"cmd_moveBottom" }, // Android
{u"keypress" , u"VK_PAGE_UP" , nullptr, u"shift,alt" , u"cmd_selectTop" }, // Android
{u"keypress" , u"VK_PAGE_DOWN" , nullptr, u"shift,alt" , u"cmd_selectBottom" }, // Android
#endif // MOZ_WIDGET_ANDROID
/**************************************************************************
* Home / End keys in HTMLEditor .
**************************************************************************/
#if defined (XP_WIN) || defined (MOZ_WIDGET_ANDROID) ||\
defined (USE_EMACS_KEY_BINDINGS)
{u"keypress" , u"VK_HOME" , nullptr, nullptr, u"cmd_beginLine" }, // Win, Android, Emacs
{u"keypress" , u"VK_END" , nullptr, nullptr, u"cmd_endLine" }, // Win, Android, Emacs
{u"keypress" , u"VK_HOME" , nullptr, u"shift" , u"cmd_selectBeginLine" }, // Win, Android, Emacs
{u"keypress" , u"VK_END" , nullptr, u"shift" , u"cmd_selectEndLine" }, // Win, Android, Emacs
{u"keypress" , u"VK_HOME" , nullptr, u"control" , u"cmd_moveTop" }, // Win, Android, Emacs
{u"keypress" , u"VK_END" , nullptr, u"control" , u"cmd_moveBottom" }, // Win, Android, Emacs
{u"keypress" , u"VK_HOME" , nullptr, u"shift,control" , u"cmd_selectTop" }, // Win, Android, Emacs
{u"keypress" , u"VK_END" , nullptr, u"shift,control" , u"cmd_selectBottom" }, // Win, Android, Emacs
#endif // XP_WIN || MOZ_WIDGET_ANDROID || USE_EMACS_KEY_BINDINGS
/**************************************************************************
* Insert key in HTMLEditor .
**************************************************************************/
#if defined (XP_WIN) || defined (USE_EMACS_KEY_BINDINGS)
{u"keypress" , u"VK_INSERT" , nullptr, u"control" , u"cmd_copy" }, // Win, Emacs
{u"keypress" , u"VK_INSERT" , nullptr, u"shift" , u"cmd_paste" }, // Win, Emacs
#endif // XP_WIN || USE_EMACS_KEY_BINDINGS
/**************************************************************************
* Delete key in HTMLEditor .
**************************************************************************/
#if defined (XP_WIN) || defined (USE_EMACS_KEY_BINDINGS)
{u"keypress" , u"VK_DELETE" , nullptr, u"shift" , u"cmd_cutOrDelete" }, // Win, Emacs
#endif // XP_WIN || USE_EMACS_KEY_BINDINGS
#if defined (USE_EMACS_KEY_BINDINGS)
{u"keypress" , u"VK_DELETE" , nullptr, u"control" , u"cmd_copyOrDelete" }, // Emacs
#endif // USE_EMACS_KEY_BINDINGS
#if defined (XP_WIN) || defined (MOZ_WIDGET_ANDROID)
{u"keypress" , u"VK_DELETE" , nullptr, u"control" , u"cmd_deleteWordForward" }, // Win, Android
#endif // XP_WIN || MOZ_WIDGET_ANDROID
#if defined (MOZ_WIDGET_ANDROID)
{u"keypress" , u"VK_DELETE" , nullptr, u"alt" , u"cmd_deleteToEndOfLine" }, // Android
#endif // MOZ_WIDGET_ANDROID
/**************************************************************************
* Backspace key in HTMLEditor .
**************************************************************************/
#if defined (XP_WIN) || defined (MOZ_WIDGET_ANDROID) || defined (USE_EMACS_KEY_BINDINGS)
{u"keypress" , u"VK_BACK" , nullptr, u"control" , u"cmd_deleteWordBackward" }, // Win, Android, Emacs
#endif // XP_WIN || MOZ_WIDGET_ANDROID || USE_EMACS_KEY_BINDINGS
#if defined (MOZ_WIDGET_ANDROID)
{u"keypress" , u"VK_BACK" , nullptr, u"alt" , u"cmd_deleteToBeginningOfLine" }, // Android
#endif // MOZ_WIDGET_ANDROID
#if defined (XP_WIN)
{u"keypress" , u"VK_BACK" , nullptr, u"alt" , u"cmd_undo" }, // Win
{u"keypress" , u"VK_BACK" , nullptr, u"alt,shift" , u"cmd_redo" }, // Win
#endif // XP_WIN
/**************************************************************************
* Common editor commands in HTMLEditor .
**************************************************************************/
{u"keypress" , nullptr, u"c" , u"accel" , u"cmd_copy" }, // Win, macOS, Linux, Android, Emacs
{u"keypress" , nullptr, u"x" , u"accel" , u"cmd_cut" }, // Win, macOS, Linux, Android, Emacs
{u"keypress" , nullptr, u"v" , u"accel" , u"cmd_paste" }, // Win, macOS, Linux, Android, Emacs
{u"keypress" , nullptr, u"v" , u"accel,shift" , u"cmd_pasteNoFormatting" }, // Win, macOS, Linux, Android, Emacs
{u"keypress" , nullptr, u"z" , u"accel" , u"cmd_undo" }, // Win, macOS, Linux, Android, Emacs
{u"keypress" , nullptr, u"z" , u"accel,shift" , u"cmd_redo" }, // Win, macOS, Linux, Android, Emacs
// Mac uses Option+Shift+Command+V for Paste and Match Style
#if defined (MOZ_WIDGET_COCOA)
{u"keypress" , nullptr, u"v" , u"accel,alt,shift" , u"cmd_pasteNoFormatting" }, // macOS
#endif // MOZ_WIDGET_COCOA
#if defined (XP_WIN) || defined (MOZ_WIDGET_GTK) ||\
defined (USE_EMACS_KEY_BINDINGS)
{u"keypress" , nullptr, u"y" , u"accel" , u"cmd_redo" }, // Emacs
#endif // XP_WIN || MOZ_WIDGET_GTK || USE_EMACS_KEY_BINDINGS
#if defined (XP_WIN) || defined (MOZ_WIDGET_COCOA) || defined (MOZ_WIDGET_GTK) ||\
defined (MOZ_WIDGET_ANDROID)
{u"keypress" , nullptr, u"a" , u"accel" , u"cmd_selectAll" }, // Win, macOS, Linux, Android
#endif // XP_WIN || MOZ_WIDGET_COCOA || MOZ_WIDGET_GTK || MOZ_WIDGET_ANDROID
#if defined (USE_EMACS_KEY_BINDINGS)
{u"keypress" , nullptr, u"a" , u"alt" , u"cmd_selectAll" }, // Emacs
#endif // USE_EMACS_KEY_BINDINGS
/**************************************************************************
* Space key in HTMLEditor .
**************************************************************************/
{u"keypress" , nullptr, u" " , nullptr, u"cmd_scrollPageDown" }, // Win, macOS, Linux, Android, Emacs
{u"keypress" , nullptr, u" " , u"shift" , u"cmd_scrollPageUp" }, // Win, macOS, Linux, Android, Emacs
/**************************************************************************
* Emacs specific shortcut keys in HTMLEditor .
**************************************************************************/
#if defined (USE_EMACS_KEY_BINDINGS)
{u"keypress" , nullptr, u"h" , u"control" , u"cmd_deleteCharBackward" }, // Emacs
{u"keypress" , nullptr, u"d" , u"control" , u"cmd_deleteCharForward" }, // Emacs
{u"keypress" , nullptr, u"k" , u"control" , u"cmd_deleteToEndOfLine" }, // Emacs
{u"keypress" , nullptr, u"u" , u"control" , u"cmd_deleteToBeginningOfLine" }, // Emacs
{u"keypress" , nullptr, u"a" , u"control" , u"cmd_beginLine" }, // Emacs
{u"keypress" , nullptr, u"e" , u"control" , u"cmd_endLine" }, // Emacs
{u"keypress" , nullptr, u"b" , u"control" , u"cmd_charPrevious" }, // Emacs
{u"keypress" , nullptr, u"f" , u"control" , u"cmd_charNext" }, // Emacs
{u"keypress" , nullptr, u"p" , u"control" , u"cmd_linePrevious" }, // Emacs
{u"keypress" , nullptr, u"n" , u"control" , u"cmd_lineNext" }, // Emacs
#endif // USE_EMACS_KEY_BINDINGS
// clang-format on
{nullptr, nullptr, nullptr, nullptr, nullptr}};
} // namespace mozilla
#undef USE_EMACS_KEY_BINDINGS
Messung V0.5 in Prozent C=53 H=100 G=80
¤ Dauer der Verarbeitung: 0.34 Sekunden
(vorverarbeitet am 2026-08-25)
¤
*© Formatika GbR, Deutschland