summaryrefslogtreecommitdiff
path: root/cocoa
diff options
context:
space:
mode:
Diffstat (limited to 'cocoa')
-rw-r--r--cocoa/font.m2
1 files changed, 1 insertions, 1 deletions
diff --git a/cocoa/font.m b/cocoa/font.m
index 5241a7a1c..1b06d3dc7 100644
--- a/cocoa/font.m
+++ b/cocoa/font.m
@@ -85,7 +85,7 @@ static bool nsfont_split(const plot_font_style_t *style,
}
- chars = [[cocoa_text_storage string] rangeOfString: @" " options: NSBackwardsSearch range: NSMakeRange( 0, chars )].location;
+ chars = [[cocoa_text_storage string] rangeOfString: @" " options: NSBackwardsSearch range: NSMakeRange( 0, chars + 1 )].location;
if (chars == NSNotFound) {
*char_offset = 0;
*actual_x = 0;