There is a TextView, you need to display the formatted text, as in the example that I attached below.

I make the first lines with the help of NSMutableAttributedString , NSMutableParagraphStyle , NSTextTab . Everything works as it should.

The problem is the last line "About the direction ...". How to make so that from a certain distance the line is cut off and the output continues on a new line, but at the same time another line goes to the right side?

Example

  • Show on the picture how it should be - Maxim Bogdanov
  • @MaximBogdanov I will not show, because I came to the conclusion that such a layout in UITextView cannot be done (without some hard crutches). I'm talking about what goes below the "Related documents", everything above works fine. - Tikhonov Alexander
  • Most likely, because NSAttributedString - Maxim Bogdanov is located inside the UITextView
  • Yes, it is there, it is a string with attributes, we can shove a picture, but we can’t split one line into different lines and arrange them as shown above. - Tikhonov Alexander
  • one
    In general, the following meaning - you find a place in which you need to make a transfer. On the first line you put some attributes (alignment to the left), on the rest - other attributes (alignment to the right). But since you didn’t tell you more about what you need, you’re not sure what you want - Maxim Bogdanov

0