How do you add an image in the beginning of a multiline iPhone UILabel so that it starts the first line of text but doesn’t disrupt the flow of the second/third/etc line of text?
Share
Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.
Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.
Lost your password? Please enter your email address. You will receive a link and will create a new password via email.
Please briefly explain why you feel this question should be reported.
Please briefly explain why you feel this answer should be reported.
Please briefly explain why you feel this user should be reported.
This cannot be done with a
UILabel. To accomplish this, you’re going to have to have the image with a UILabel to the right of it, and anotherUILabelbelow those that spans the full width. And you’ll have to calculate how much of the text can be shown in the firstUILabel, so that you know what text to put in the bottom label. UILabel visible part of text should give you an idea of what you’ll need to do to calculate how much of the text is visible in the first label.Not an easy task, but it’s doable.