aboutsummaryrefslogtreecommitdiffstats
path: root/Source/SPTextViewAdditions.m
diff options
context:
space:
mode:
Diffstat (limited to 'Source/SPTextViewAdditions.m')
-rw-r--r--Source/SPTextViewAdditions.m6
1 files changed, 5 insertions, 1 deletions
diff --git a/Source/SPTextViewAdditions.m b/Source/SPTextViewAdditions.m
index 6723fa7f..9cefa758 100644
--- a/Source/SPTextViewAdditions.m
+++ b/Source/SPTextViewAdditions.m
@@ -63,7 +63,11 @@
end++;
}
- return(NSMakeRange(start, end-start));
+ NSRange wordRange = NSMakeRange(start, end-start);
+ if(wordRange.length && [[self string] characterAtIndex:NSMaxRange(wordRange)-1] == '.')
+ wordRange.length--;
+
+ return(wordRange);
}