0

I am making an app where I need text to display directly above a UIImage. When the text is too wide to fit, I need it to display on 2 rows of text, with the bottom one being at the same position vertically as if it only had one row. If the text cannot fit in two rows, I want it to get smaller so that it will just fit in the two rows. Below is an image showing what I mean.

Image

1 Answers1

0

Label constraints : top to superview , leading & trailing & bottom to imageView ,,, with .lines = 2 , textAlignment = .center

ImageView constraints : centerX , width , height

Sh_Khan
  • 93,445
  • 7
  • 57
  • 76