Reputation: 585
We have label with text in 2 lines. In second line the text is not aligning exactly to the left as in the first line. we had set property for the label as number of lines = 0.
for Ex: label.text = @"This is the text for the label."
In Result We are getting this as
This is the text
for the label.
But we want this as
This is the text
for the label.
Upvotes: 0
Views: 614
Reputation: 4710
try setting the word wrap of button:
[label setNumberOfLines:0]
Edit: just realised there's linebreak property of label, that should help
label.lineBreakMode = UILineBreakModeWordWrap;
Upvotes: 1