diff options
Diffstat (limited to 'modules')
-rw-r--r-- | modules/textadept/editing.lua | 4 | ||||
-rw-r--r-- | modules/textadept/find.lua | 2 |
2 files changed, 4 insertions, 2 deletions
diff --git a/modules/textadept/editing.lua b/modules/textadept/editing.lua index 1830e047..5b39c1bc 100644 --- a/modules/textadept/editing.lua +++ b/modules/textadept/editing.lua @@ -165,7 +165,7 @@ end, 1) -- need index of 1 because default key handler halts propagation -- Highlights matching braces. events.connect(events.UPDATE_UI, function(updated) - if updated and updated & 3 == 0 then return end -- ignore scrolling + if updated & 3 == 0 then return end -- ignore scrolling local pos = buffer.selection_n_caret[buffer.main_selection] if M.brace_matches[buffer.char_at[pos]] then local match = buffer:brace_match(pos, 0) @@ -187,7 +187,7 @@ end, 1) -- Highlight all instances of the current or selected word. events.connect(events.UPDATE_UI, function(updated) - if not updated or updated & buffer.UPDATE_SELECTION == 0 then return end + if updated & buffer.UPDATE_SELECTION == 0 or ui.find.active then return end local word if M.highlight_words == M.HIGHLIGHT_CURRENT then clear_highlighted_words() diff --git a/modules/textadept/find.lua b/modules/textadept/find.lua index 520b977e..d5e34ca9 100644 --- a/modules/textadept/find.lua +++ b/modules/textadept/find.lua @@ -57,6 +57,8 @@ local M = ui.find -- @field in_files_label_text (string, Write-only) -- The text of the "In files" label. -- This is primarily used for localization. +-- @field active (boolean) +-- Whether or not the Find & Replace pane is active. -- @field highlight_all_matches (boolean) -- Whether or not to highlight all occurrences of found text in the current -- buffer. |