Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Merge branch 'master' of github.com:victorhge/iedit

  • Loading branch information...
commit b95c35107a429d63b99f888b52eb0f74105d0da0 2 parents a55fcae + dbe9e44
@victorhge authored
Showing with 7 additions and 3 deletions.
  1. +7 −3 iedit-lib.el
View
10 iedit-lib.el
@@ -582,16 +582,20 @@ value of `iedit-occurrence-context-lines' is used for this time."
(iedit-barf-if-buffering)
(iedit-apply-on-occurrences 'downcase-region))
-(defun iedit-replace-occurrences(to-string)
+(defun iedit-replace-occurrences()
"Replace occurrences with STRING.
This function preserves case."
- (interactive "*sReplace with: ")
+ (interactive "*")
(iedit-barf-if-buffering)
(let* ((ov (iedit-find-current-occurrence-overlay))
(offset (- (point) (overlay-start ov)))
(from-string (downcase (buffer-substring-no-properties
(overlay-start ov)
- (overlay-end ov)))))
+ (overlay-end ov))))
+ (to-string (read-string "Replace with: "
+ nil nil
+ from-string
+ nil)))
(iedit-apply-on-occurrences
(lambda (beg end from-string to-string)
(goto-char beg)
Please sign in to comment.
Something went wrong with that request. Please try again.