How to force UILabel to draw a text with upper case chars?
UILabel
Objective-C
NSString *text = @"Hello"; [myLabel setText:[text uppercaseString]];
Swift 3 & 4
let text = "Hello" myLabel.text = text.uppercased()
How do I set bold and italic on UILabel of iPhone/iPad? I searched the forum but nothing helped me. Could anyone help me?
I want to make UILabel's text bold infoLabel=[[UILabel alloc]initWithFrame:CGRectMake(90,150, 200, 30)]; [infoLabel setText:@"Drag 14 more Flavors"]; [infoLabel setBackgroundColor:[UIColor clearColor]]; [infoLabel setFont:[UIFont fontWithName:@"Arial" size:16]]; [infoLabel setTextColor:[UIColor colorWithRed:193.0/255 green:27.0/255 blue:23.0/255 alpha:1 ]];
I want to make a UIButton with type UIButtonTypeCustom (for the shape). I want to assign the title using button.titleLabel because I need to specify the font. The following code looks like it should work, but doesn't -- no …