File tree Expand file tree Collapse file tree 2 files changed +3
-2
lines changed Expand file tree Collapse file tree 2 files changed +3
-2
lines changed Original file line number Diff line number Diff line change 12
12
static NSString *TEST_STRINGS[] = {
13
13
@" ABCDEFGHIJKLM\n NOPQRSTUVWXYZ" ,
14
14
@" abcdefghijklm\n nopqrstuvwxyz" ,
15
+ @" first line\u2028 second line" ,
15
16
@" ,.?!;:'\" " ,
16
17
@" ()[]{}<>\\ |/\n " ,
17
18
@" @#$%^&*+-=_" ,
Original file line number Diff line number Diff line change @@ -762,7 +762,7 @@ -(void) createFontChars
762
762
// since the Y position needs to be calcualted before hand
763
763
for (NSUInteger i=0 ; i < stringLen-1 ;i++) {
764
764
unichar c = [_string characterAtIndex: i];
765
- if ( c== ' \n ' )
765
+ if ([[ NSCharacterSet newlineCharacterSet ] characterIsMember: c] )
766
766
quantityOfLines++;
767
767
}
768
768
@@ -776,7 +776,7 @@ -(void) createFontChars
776
776
for (NSUInteger i = 0 ; i<stringLen; i++) {
777
777
unichar c = [_string characterAtIndex: i];
778
778
779
- if (c == ' \n ' ) {
779
+ if ([[ NSCharacterSet newlineCharacterSet ] characterIsMember: c] ) {
780
780
nextFontPositionX = 0 ;
781
781
nextFontPositionY -= _configuration->_commonHeight ;
782
782
continue ;
You can’t perform that action at this time.
0 commit comments