keyAction parameter

Use the keyAction parameter to set or query the editor action assignment for a specified key or series of keys.

Availability

query command
set command

Scope

The current view.

Syntax

query keyAction.[modifier-][...]key[,[modifier-][...]key][...][.context][...][.secondary]
set keyAction.[modifier-][...]key[,[modifier-][...]key][...][.context][...][.secondary] [action] 

Parameters

modifier The modifier parameter can be any of c, s, or a c is used to indicate the primary keyboard modifier for the platform (for example, the Ctrl key on Windows).  s is used to indicate the secondary keyboard modifier for the platform (for example, the Shift key on Windows).  a is used to indicate the tertiary keyboard modifier for the platform (for example, the Alt key on Windows).  For example if you want to set a key for Ctrl+Alt+A you specify "c-a-a".
key The key parameter can be any of the following: 
  • a through z
  • 0 through 9
  • f1 through f15
  • numpad0 through numpad9
  • add
  • ampersand
  • asterisk
  • atSign
  • backQuote
  • backSlash
  • backSpace
  • cancel
  • capsLock
  • closeBrace
  • closeBracket
  • closeParenthesis
  • colon
  • comma
  • decimal
  • delete
  • divide
  • dollarSign
  • doubleQuote
  • down
  • end
  • enter
  • equals
  • escape
  • exclamationMark
  • greaterThanSign
  • help
  • home
  • insert
  • karat
  • left
  • lessThanSign
  • minus
  • multiply
  • numLock
  • numberSign
  • numpadEnter
  • openBrace
  • openBracket
  • openParenthesis
  • pageDown
  • pageUp
  • pause
  • percent
  • period
  • plus
  • printScreen
  • questionMark
  • quote
  • right
  • scrollLock
  • semicolon
  • slash
  • space
  • subtract
  • tab
  • tilde
  • underscore
  • up
  • verticalBar
context The context parameter can be any of t, p, or ct is used to indicate that the key should be available when the cursor is in the text area.  p is used to indicate that the key should be available when the cursor is in the prefix area.  c is used to indicate that the key should be available when the cursor is on the command line.  If you do not specify a context, the context is assumed to be t.
secondary Use the secondary parameter if you wish to assign an additional key to an editor action.  Only one primary key can be assigned to an action at a time but you can assign as many secondary keys to the same action as you want.  The primary key that is assigned to an action is the one that is returned by the actionKey parameter.
action Use the action parameter to specify the editor action that you want to assign to the specified key.  If you do not specify an action or specify null, the key will not have an editor action assigned to it.

Description

To assign an editor action to a series of keys, specify additional keys separated by commas.  All of the specified keys must be issued in the correct order before the action will be invoked.

When the vi base profile is active, the editor does not use the keyAction parameter for key assignments in the text area.  Instead, the editor's vi key handler is activated.

The actual keys received by the editor depend on the environment (workstation configuration, operating system, Java support, enclosing editor application, etc.) in which the editor is running.  Certain key actions may not be activated in some environments.

Examples

query keyAction.c-f
set keyAction.a-backSpace.t.p.secondary undo
set keyAction.c-x,c-x.t findQuickMark 

Related reference
query command
set command
actionKey parameter
actionKeyText parameter
keys parameter
updateProfile.userKeyActions parameter
vi base profile