1
0
mirror of https://github.com/gryf/pentadactyl-pm.git synced 2025-12-20 18:37:58 +01:00

Change (\S+) to (\w+) in abbreviation matching so that "VIMP<space> expands (to match Vim behavior).

This commit is contained in:
Ted Pavlic
2009-01-16 13:34:05 -05:00
parent a0fcde5b4a
commit 1019daa5ca

View File

@@ -1010,7 +1010,7 @@ function Editor() //{{{
let text = textbox.value; let text = textbox.value;
let currStart = textbox.selectionStart; let currStart = textbox.selectionStart;
let currEnd = textbox.selectionEnd; let currEnd = textbox.selectionEnd;
let foundWord = text.substring(0, currStart).replace(/^(.|\n)*?(\S+)$/m, "$2"); // get last word \b word boundary let foundWord = text.substring(0, currStart).replace(/^(.|\n)*?(\w+)$/m, "$2"); // get last word \b word boundary
if (!foundWord) if (!foundWord)
return true; return true;