iCoder86
iCoder86

Reputation: 1895

Adjusting font size for UILabel according to device screen iPhone4/5 and iPhone6/Plus

I am using Autoresizing for UILabel on the xib.

And when i launch app on iPhone4/5 UILabel font looks perfect but for iPhone6/Plus font looks very small.

I referred so many link including Adjusting font size according to device screen and Category for UILabel

Also the adjustsFontSizeToFitWidth is not working for me somehow.

yourLabel.adjustsFontSizeToFitWidth=YES;
yourLabel.minimumScaleFactor=0.5;

So, i want to know if there is any other way around to have UILabel font size different for iPhone4/5 and iPhone6/Plus using Autoresizing in xib.

Upvotes: 1

Views: 2651

Answers (1)

Wain
Wain

Reputation: 119031

adjustsFontSizeToFitWidth only scales the font down, not up. So, if you want a bigger font you need to set one, either specifically for the iPhone 6 or always and allow iOS to scale the font down for the iPhone 4 / 5.

Upvotes: 1

Related Questions