mirror of
https://github.com/Swiftgram/Telegram-iOS.git
synced 2025-06-16 05:55:20 +00:00
Fix more
This commit is contained in:
parent
1adee04eae
commit
63edb12edf
@ -1260,7 +1260,12 @@ open class TextNode: ASDisplayNode {
|
|||||||
var effectiveLineRange = brokenLineRange
|
var effectiveLineRange = brokenLineRange
|
||||||
var additionalTrailingLine: (CTLine, Double)?
|
var additionalTrailingLine: (CTLine, Double)?
|
||||||
|
|
||||||
if lineRange.length == 0 || (CTLineGetTypographicBounds(originalLine, nil, nil, nil) - CTLineGetTrailingWhitespaceWidth(originalLine) + truncationTokenWidth) < Double(lineConstrainedSize.width) {
|
var measureFitWidth = CTLineGetTypographicBounds(originalLine, nil, nil, nil) - CTLineGetTrailingWhitespaceWidth(originalLine)
|
||||||
|
if customTruncationToken != nil {
|
||||||
|
measureFitWidth += truncationTokenWidth
|
||||||
|
}
|
||||||
|
|
||||||
|
if lineRange.length == 0 || measureFitWidth < Double(lineConstrainedSize.width) {
|
||||||
if didClipLinebreak {
|
if didClipLinebreak {
|
||||||
if lineRange.length == 0 {
|
if lineRange.length == 0 {
|
||||||
coreTextLine = CTLineCreateWithAttributedString(NSAttributedString())
|
coreTextLine = CTLineCreateWithAttributedString(NSAttributedString())
|
||||||
|
Loading…
x
Reference in New Issue
Block a user