Keyboard Support

Contact and Search Homepage

Header bottom

Other versions
Version 17.0 (current version)Version 16.0Version 15.0Version 14.0Version 13.0Version 12.0Version 11.0Version 10.0Version 2.0 (home page)Version 1.0 (home page)

On this page

deadkeyMatch (KDM) (Deprecated)


(Deprecated)Deadkey matching: Seeks to match the deadkey state dk at the relative caret position n.


keyman.interface.deadkeyMatch(n, Pelem, dk);


KeymanWeb.KDM(n, Pelem, dk); // Shorthand


Type: number
The position to match, relative to the caret's present position.
Type: Element
The HTML element receiving input.
Type: number
The deadkey id.

Return Value

true if the specified deadkey exists at the specified input location, otherwise false.


Deadkeys are useful for tracking hidden state information used to modify future keystrokes. For example, rather than using

"`" + "a" = "à"

to combine two visible characters, certain applications may desire to keep the "`" character hidden with a rule such as

+ '`' > dk(backquote)


dk(backquote) + "a" > "à"

The Developer compiler then generates a unique id for the deadkey state - say, 0, and in order to detect the deadkey associated with the '`' character, compiles the dk(backquote) check to

keyman.interface.deadkeyMatch(0, Pelem, 0)

which detects the existing deadkey (the second zero above) at the caret's present position (the first zero above).

For versions 10.0 and later, please consider use of fullContextMatch() instead.

See also


Wikipedia article on deadkeys