mirror of
https://github.com/Swiftgram/Telegram-iOS.git
synced 2025-12-20 13:19:16 +00:00
If trailing rect was set early return
This commit is contained in:
parent
91b6995987
commit
a9d0542d8f
@ -345,6 +345,11 @@ static const CGFloat ASTextKitRendererTextCapHeightPadding = 1.3;
|
||||
|
||||
textRange = NSMakeRange([textStorage length] - 1, 1);
|
||||
}];
|
||||
|
||||
// If trailing rect was set early return here
|
||||
if (!CGRectEqualToRect(trailingRect, CGRectNull)) {
|
||||
return trailingRect;
|
||||
}
|
||||
|
||||
// Take everything after our final character as trailing space.
|
||||
NSArray *finalRects = [self rectsForTextRange:textRange measureOption:ASTextKitRendererMeasureOptionLineHeight];
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user