Strictly limit find/replace commands to `core.docview` (#1108)

Without this, find/replace commands applied to the `CommandView` too,
with buggy results.
This commit is contained in:
Guldoman 2022-09-14 04:29:52 +02:00 committed by GitHub
parent bead59a898
commit a19cfb4f80
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
1 changed files with 1 additions and 1 deletions

View File

@ -200,7 +200,7 @@ command.add(has_unique_selection, {
["find-replace:select-add-all"] = function() select_add_next(true) end
})
command.add("core.docview", {
command.add("core.docview!", {
["find-replace:find"] = function()
find("Find Text", function(doc, line, col, text, case_sensitive, find_regex, find_reverse)
local opt = { wrap = true, no_case = not case_sensitive, regex = find_regex, reverse = find_reverse }