diff --git a/common/content/dactyl.js b/common/content/dactyl.js index c9c06eae..15d511ac 100644 --- a/common/content/dactyl.js +++ b/common/content/dactyl.js @@ -686,7 +686,7 @@ const Dactyl = Module("dactyl", { let res =
{link(obj.name)}
{obj.description ? obj.description.replace(/\.$/, "") : ""}
- {template.map(obj.names.reverse, tag, " ")} + {template.map(obj.names.slice().reverse(), tag, " ")} {spec((obj.specs || obj.names)[0])}{ !obj.type ? "" : <> {obj.type} @@ -721,7 +721,7 @@ const Dactyl = Module("dactyl", { }) } ])); - return res.*.toXMLString().replace(/^ {12}/gm, "");; + return res.*.toXMLString().replace(/^ {12}|[ \t]+$/gm, ""); }, /** diff --git a/common/content/events.js b/common/content/events.js index db7d6762..6a89d7b0 100644 --- a/common/content/events.js +++ b/common/content/events.js @@ -969,11 +969,9 @@ const Events = Module("events", { this._input.motionCount = null; if (!isEscape(key)) { - stop = false; - if (mode.main === modes.TEXT_EDIT) { + stop = (mode.main === modes.TEXT_EDIT); + if (stop) dactyl.beep(); - stop = true; - } if (mode.main === modes.COMMAND_LINE) if (!(mode.extended & modes.INPUT_MULTILINE)) diff --git a/common/content/finder.js b/common/content/finder.js index 356a99ac..d01486d2 100644 --- a/common/content/finder.js +++ b/common/content/finder.js @@ -28,7 +28,8 @@ const RangeFinder = Module("rangefinder", { let highlighted = this.rangeFind && this.rangeFind.highlighted; let selections = this.rangeFind && this.rangeFind.selections; let regexp = false; - let matchCase = options["smartcase"] && /[A-Z]/.test(str) || !options["ignorecase"]; + let matchCase = options["searchcase"] === "smart" ? /[A-Z]/.test(str) : + options["searchcase"] === "ignore" ? false : true; let linksOnly = options["linksearch"]; str = str.replace(/\\(.|$)/g, function (m, n1) { @@ -218,9 +219,16 @@ const RangeFinder = Module("rangefinder", { } }); - options.add(["ignorecase", "ic"], - "Ignore case in search patterns", - "boolean", true); + options.add(["searchcase", "sc"], + "Search case matching mode", + "string", "smart", + { + completer: function () [ + ["smart", "Case is significant when capital letters are typed"], + ["match", "Case is always significant"], + ["ignore", "Case is never significant"] + ] + }); options.add(["incsearch", "is"], "Show where the search pattern matches as it is typed", @@ -230,9 +238,6 @@ const RangeFinder = Module("rangefinder", { "Limit the search to hyperlink text", "boolean", false); - options.add(["smartcase", "scs"], - "Override the 'ignorecase' option if the pattern contains uppercase characters", - "boolean", true); } }); diff --git a/common/locale/en-US/index.xml b/common/locale/en-US/index.xml index 61714744..97f32508 100644 --- a/common/locale/en-US/index.xml +++ b/common/locale/en-US/index.xml @@ -392,7 +392,6 @@ This file contains a list of all available commands, mappings and options.
hinttimeout
Timeout before automatically following a non-unique numerical hint
history
Number of Ex commands and search patterns to store in the command-line history
hlsearch
Highlight previous search pattern matches
-
ignorecase
Ignore case in search patterns
incsearch
Show where the search pattern matches as it is typed
insertmode
Use Insert mode as the default for text areas
jsdebugger
Use the JavaScript debugger service for JavaScript completion
@@ -416,12 +415,12 @@ This file contains a list of all available commands, mappings and options.
sanitizeshutdown
The items to sanitize automatically at shutdown
sanitizetimespan
The default sanitizer time span
scroll
Number of lines to scroll with and commands
+
searchcase
Search case matching mode
shell
Shell to use for executing :! and :run commands
shellcmdflag
Flag passed to shell when executing :! and :run commands
showmode
Show the current mode in the command line
showstatuslinks
Show the destination of the link under the cursor in the status bar
showtabline
Control when to show the tab bar of opened web pages
-
smartcase
Override the ignorecase option if the pattern contains uppercase characters
strictfocus
Prevent scripts from focusing input elements without user intervention
suggestengines
Engine Alias which has a feature of suggest
titlestring
Change the title of the window
diff --git a/common/locale/en-US/options.xml b/common/locale/en-US/options.xml index d21369cb..215bbd5e 100644 --- a/common/locale/en-US/options.xml +++ b/common/locale/en-US/options.xml @@ -869,17 +869,6 @@
- - 'noic' 'noignorecase' - 'ic' 'ignorecase' - 'ignorecase' 'ic' - boolean - on - -

Ignore case in search patterns.

-
-
- 'nois' 'noincsearch' 'is' 'incsearch' @@ -1282,6 +1271,22 @@ + + 'sc' 'searchcase' + 'searchcase' + string + smart + +

Search case matching mode.

+ +
+
ignore
Case is never significant
+
match
Case is always significant
+
smart
Case is significant when capital letters are typed
+
+
+
+ 'shell' 'sh' 'shell' 'sh' @@ -1354,21 +1359,6 @@ - - 'noscs' 'nosmartcase' - 'scs' 'smartcase' - 'smartcase' 'scs' - boolean - on - -

- Override the ignorecase option if the pattern contains - uppercase characters. This is only used if the ignorecase - option is set. -

-
-
- 'nosf' 'nostrictfocus' 'sf' 'strictfocus' diff --git a/pentadactyl/NEWS b/pentadactyl/NEWS index 42884192..b92327bc 100644 --- a/pentadactyl/NEWS +++ b/pentadactyl/NEWS @@ -52,6 +52,7 @@ * IMPORTANT: 'laststatus' has been replaced with the "s" flag in 'guioptions'. * IMPORTANT: 'showstatuslinks' is now a string option. + * IMPORTANT: 'ignorecase' and 'smartcase' have been replaced with 'searchcase' * IMPORTANT: Command script files now use the *.penta file extension. * IMPORTANT: Plugins are now loaded from the 'plugins/' directory in 'runtimepath' rather than 'plugin/'. diff --git a/pentadactyl/TODO b/pentadactyl/TODO index a763fcac..318fac2d 100644 --- a/pentadactyl/TODO +++ b/pentadactyl/TODO @@ -39,7 +39,6 @@ FEATURES: 8 / should work as in Vim (i.e., save page positions as well as locations in the history list). 8 jump to the next heading with ]h, next image ]i, previous textbox [t and so on -7 add source location links to the output of certain commands (e.g. :viusage! or describe-key) 7 add search capability to MOW 7 describe-key command (prompt for a key and display its binding with documentation) 7 Specify all INSERT mode mappings rather than falling through to the host apps