QLabel Anywhere wordwrap or char -wrap?

qlabel's word-wrap mode only works with spaces, but if one word is long enough, it is truncated.
To overcome this we can use QTextEdit, which gives wordwrap functionality anywhere, but there is no vertical alignment in QTextEdit. So, is there any third good option, or any way I can use word wrap anywhere (fixed size) in QLabel, or vertical alignment in QTextEdit?

Or finally I need to manually break the word in the qlabel.

+3


source to share


1 answer


Read the documentation. QLabel::setWordWrap( bool )

is exactly what you are looking for.



0


source







All Articles