Links
EControl Syntax Editor SDK
TSyntKeyMapping Class

Contains redefined keystrokes for registered commands of Syntax Memo.

TSyntKeyMapping = class(TComponent);

ecKeyMap

Use TSyntKeyMapping to centralize the response to user commands. 

Use Items property to access a specific item. Use Add method to add item to the list. 

If TSyntKeyMapping is empty only default command descriptions are used to associate keystroke with the particular command. User may assign new keystroke for any command. All this changes are stored in the overwritten keystrokes in the TSyntKeyMapping. 

 

About keystrokes. 

For a single command it is possible to use more than one keystroke. Each keystroke may be a sequence of any amount of shortcuts. 

UseFirstCOntrolKeys property defines whether control keys in keystrokes are considered. For example, if UseFirstControlKeys is set to true "Ctrl+O+Ctrl+K" and "Ctrl+O+K" keystrokes are treated as identical. Otherwise these keystrokes are treated as non-identical. 

Customize method calls the Key Mapping dialog for customizing commands. At run-time only commands with customize property set to true are customizable. 

Use IsHandled and IsHandledCmd methods to determine the longest keystroke in the queue and its ID number correspondingly. 

Use Validate method to detect duplicate keystrokes.

Topic 
Description 
The methods of the TSyntKeyMapping class are listed here. 
The properties of the TSyntKeyMapping class are listed here. 
The events of the TSyntKeyMapping class are listed here. 
 
Method 
 
virtual 
 
Property 
 
Event 
TSyntKeyMapping Events 
Description 
Occurs when the command is executed. 
TSyntKeyMapping Methods 
Description 
Add 
Adds new object to the array. 
Returns item with Command equal to Cmd. 
Creates and initializes a TSyntKeyMapping instance. 
Displays "Key Mapping" dialog. 
Destroys an instance of TSyntKeyMapping. 
Returns an item containing a keystroke which matches KeyQueue and contains maximum amount of shortcuts. 
Returns command ID of a command containing a keystroke which matches KeyQueue and contains maximum amount of shortcuts. 
Checks whether Items property contains duplicate keystrokes. 
TSyntKeyMapping Properties 
Description 
Represents contents of TSyntKeyMapping as a hex string. 
Lists the TecCommandItem object references. 
Defines whether first control keys are considered. 
Copyright (c) 2004-2011. All rights reserved.
What do you think about this topic? Send feedback!