]> git.lizzy.rs Git - micro.git/blobdiff - internal/action/command.go
Support for highlighting all search matches (hlsearch) (#1762)
[micro.git] / internal / action / command.go
index 6abc30b33fd2da232b83925c6cb6d33cb25fc466..6e0c795cc3011c3c03781a9fb344fd107b5f3c39 100644 (file)
@@ -835,6 +835,9 @@ func (h *BufPane) ReplaceCmd(args []string) {
                        h.Cursor.SetSelectionStart(locs[0])
                        h.Cursor.SetSelectionEnd(locs[1])
                        h.Cursor.GotoLoc(locs[0])
+                       h.Buf.LastSearch = search
+                       h.Buf.LastSearchRegex = true
+                       h.Buf.HighlightSearch = h.Buf.Settings["hlsearch"].(bool)
 
                        h.Relocate()