FXLabel icon indicating copy to clipboard operation
FXLabel copied to clipboard

if set lineSpacing, sizeThatFits not support chinese characters

Open foxling opened this issue 11 years ago • 0 comments

self.titleLabel = [[FXLabel alloc] initWithFrame:CGRectMake(9, 7, 100, font.lineHeight)];
self.titleLabel.numberOfLines = 0;
self.titleLabel.font = font;
self.titleLabel.backgroundColor = [UIColor clearColor];
self.titleLabel.textColor = [UIColor whiteColor];
self.titleLabel.shadowColor = [[UIColor blackColor] colorWithAlphaComponent:0.2];
self.titleLabel.shadowOffset = CGSizeMake(0, 1);
self.titleLabel.shadowBlur = 1;
self.titleLabel.lineSpacing = 0.27;
self.titleLabel.text = @"如果是中文,就不会换行了";

foxling avatar May 15 '14 09:05 foxling