diff options
author | 2019-11-22 09:31:50 -0500 | |
---|---|---|
committer | 2019-11-22 09:31:50 -0500 | |
commit | ea04a3c09a143fc5405556aa766423468e27fe57 (patch) | |
tree | 960a7b71653e5dfa4fea6526ce94712295859c1b /modules/textadept | |
parent | 7ba33bd25ebd4660859aaf68f87d377e94aba69c (diff) | |
download | textadept-ea04a3c09a143fc5405556aa766423468e27fe57.tar.gz textadept-ea04a3c09a143fc5405556aa766423468e27fe57.zip |
Fixed bug in "Replace All in selection" with a match at the end of a selection.
Diffstat (limited to 'modules/textadept')
-rw-r--r-- | modules/textadept/find.lua | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/modules/textadept/find.lua b/modules/textadept/find.lua index 120abae5..7a26296c 100644 --- a/modules/textadept/find.lua +++ b/modules/textadept/find.lua @@ -362,7 +362,7 @@ events.connect(events.REPLACE_ALL, function(ftext, rtext) buffer.search_flags = get_flags() buffer:set_target_range(not replace_in_sel and 0 or s, buffer.length) while buffer:search_in_target(ftext) ~= -1 and (not replace_in_sel or - buffer.target_end < buffer:indicator_end(INDIC_REPLACE, s) or EOF) do + buffer.target_end <= buffer:indicator_end(INDIC_REPLACE, s) or EOF) do if buffer.target_start == buffer.target_end then break end -- prevent loops buffer_replace_target(buffer, rtext) count = count + 1 |