diff --git a/content/buffer.js b/content/buffer.js index 06476cf8..921e0a14 100644 --- a/content/buffer.js +++ b/content/buffer.js @@ -1082,9 +1082,7 @@ liberator.Buffer = function () //{{{ highlight: function (key, style) { -liberator.log("key: " + key + ", style: " + style); let [, class, selectors] = key.match(/^([a-zA-Z_-]+)(.*)/); -liberator.log("class: " + class + ", selectors: " + selectors); if (highlightClasses.indexOf(class) == -1) { diff --git a/content/events.js b/content/events.js index d78c1653..6ab58ed2 100644 --- a/content/events.js +++ b/content/events.js @@ -677,9 +677,15 @@ liberator.Events = function () //{{{ liberator.commands.add(["delmac[ros]"], "Delete macros", - function (args) { liberator.events.deleteMacros(args); }, + function (args, special) { - argCount: "+", // pattern might contain whitespace + if (special) + args = ".*"; // XXX + + liberator.events.deleteMacros(args); + }, + { + bang: true, completer: function (filter) liberator.completion.macro(filter) }); diff --git a/locale/en-US/repeat.txt b/locale/en-US/repeat.txt index b48d6480..2fc0fb99 100644 --- a/locale/en-US/repeat.txt +++ b/locale/en-US/repeat.txt @@ -25,8 +25,10 @@ ________________________________________________________________________________ |:delmac| |:delmacros| ||:delmac[ros] {args}|| + +||:delmac[ros]!|| ________________________________________________________________________________ -Delete recorded macros matching the regular expression [args]. +Delete recorded macros matching the regular expression [args]. If [!] is given +all macros are deleted. ________________________________________________________________________________