Fix find bound with regex

This commit is contained in:
1024jp 2017-01-31 18:51:44 +09:00
parent 93281f94b0
commit add85a6d5d
2 changed files with 6 additions and 1 deletions

View File

@ -10,6 +10,11 @@ develop
- Now, AppleScript's script bundles can specify execution mode to enable running the script inside the application Sandbox (thanks to Kaito Udagawa!).
### Fixes
- Fix an issue on the regular expression search where the look-after did not match the word just behind the selection.
3.1.3 (180)
--------------------------

View File

@ -801,7 +801,7 @@ final class TextFinder: NSResponder, TextFinderSettingsProvider {
guard let string = string, !string.isEmpty else { return }
let regex = self.regex()!
let options: NSRegularExpression.MatchingOptions = [.withoutAnchoringBounds]
let options: NSRegularExpression.MatchingOptions = [.withTransparentBounds, .withoutAnchoringBounds]
for scopeRange in ranges {
regex.enumerateMatches(in: string, options: options, range: scopeRange, using: { (result, flags, stop) in