动态计算_shortLabel的文字宽度

 // 动态计算_shortLabel的文字宽度

    CGSize size = [_shortLabel.text sizeWithAttributes:[NSDictionary dictionaryWithObjectsAndKeys:_shortLabel.font,NSFontAttributeName, nil]];

    NSLog(@"%f  %f",size.width,size.height);


发布了40 篇原创文章 · 获赞 10 · 访问量 3万+

猜你喜欢

转载自blog.csdn.net/ai_pple/article/details/50973963
今日推荐