diff --git a/common/content/events.js b/common/content/events.js index cdc5f7c3..7bd715ae 100644 --- a/common/content/events.js +++ b/common/content/events.js @@ -1409,12 +1409,12 @@ var Events = Module("events", { "Prevent scripts from focusing input elements without user intervention", "boolean", true); - options.add(["timeout", "to"], + options.add(["timeout", "tmo"], "Whether to execute a shorter key command after a timeout when a longer command exists", "boolean", true); - options.add(["timeoutlen", "tm"], - "Maximum time to wait for a longer key command when a shorter command exists", + options.add(["timeoutlen", "tmol"], + "Maximum time (milliseconds) to wait for a longer key command when a shorter one exists", "number", 1000); }, sanitizer: function () { diff --git a/common/locale/en-US/map.xml b/common/locale/en-US/map.xml index 24ff91ba..2a0bfd21 100644 --- a/common/locale/en-US/map.xml +++ b/common/locale/en-US/map.xml @@ -217,6 +217,14 @@ +

Mapping timeout

+

+ When &dactyl.appName; receives a key event that has a separate binding and + at the same time is part of a key chain, values of the timeout and + timeoutlen options are used to decide what to do. See the + documentation of those options for more information. +

+

Special arguments

:map-<silent> diff --git a/common/locale/en-US/options.xml b/common/locale/en-US/options.xml index 5016950d..c11a047a 100644 --- a/common/locale/en-US/options.xml +++ b/common/locale/en-US/options.xml @@ -1391,6 +1391,34 @@ + + 'tmo' 'timeout' + 'timeout' 'tmo' + boolean + true + +

+ When this option is set and a key sequence interpretable both as a + complete command and as a start of a longer command is typed, + execute the shorter command after timeoutlen milliseconds. +

+
+
+ + + 'tmol' 'timeoutlen' + 'timeoutlen' 'tmol' + number + 1000 + +

+ Maximum number of milliseconds to wait for a longer key command + when a shorter one exists. Only effective when timeout is + set. +

+
+
+ 'titlestring' 'titlestring' diff --git a/pentadactyl/NEWS b/pentadactyl/NEWS index 070d5dcd..7895a01a 100644 --- a/pentadactyl/NEWS +++ b/pentadactyl/NEWS @@ -62,6 +62,7 @@ Hint, Multi-line Output, and Menu. [b4] - Added site-specific mapping groups and related command changes. [b6] + - Added 'timeout' and 'timeoutlen' options. [b6] - Added l and s to aid in the construction of macros. [b6] - Removed the implicit page load delays during macro playback. [b6]