Reasonable text layout in Android?

Is it possible to make a block of text in an excuse layout?

+3
source share
1 answer

Android does not support full justification.

you can try android: gravity = "fill_horizontal", but from what I read, it also doesn't work properly.

As an alternative method, you can use:

android:layout_gravity="center_vertical|right"

and

android:gravity="right"

The gravity attribute indicates how to align text inside a TextView. Layout_gravity indicates how to align the TextView element itself.

I'm sorry that I could not provide further assistance.

0
source

Source: https://habr.com/ru/post/1756827/


All Articles