gpt4 book ai didi

ios - 相邻的 "f"和 "l"字符

转载 作者:行者123 更新时间:2023-11-28 18:13:24 24 4
gpt4 key购买 nike

出于某种原因,当我显示单词“Butterfly”(或任何其他带有“fl”的单词)时,“f”和“l”连接在顶部(见下图)。字体为 Century Gothic Bold。这是我用来设置 UILabel 的代码。标签的字符串是从 plist 中检索的:

UILabel *label = [[UILabel alloc] init];
label.text = [self.flashcardDelegate.alphabetArr objectAtIndex:index];
label.textColor = [UIColor colorWithRed:.733 green:0 blue:.03137 alpha:1];
label.backgroundColor = [UIColor clearColor];
label.frame = CGRectMake(ipad ? 210.0f : 65.0f,
ipad ? 650.0f : 300.0f,
ipad ? 340.0f : 185.0f,
ipad ? 250.0f : 135.0f);
label.font = [UIFont fontWithName:@"CenturyGothic-Bold" size:ipad ? 200 : 100];
label.textAlignment = UITextAlignmentCenter;

知道为什么会这样吗?谢谢。

screenshot

最佳答案

这叫做连字,是有意为之的。您可以使用 kCTLigatureAttributeName 更改操作系统呈现连字的方式。如果你使用的是 Core Text 属性,或者你可以使用 NSLigatureAttributeName如果您使用的是 NSAttributedString

关于ios - 相邻的 "f"和 "l"字符,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/11423558/

24 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com