S
S
Saharman2018-11-16 21:11:33
Qt
Saharman, 2018-11-16 21:11:33

How to make QT cells responsive?

How can I make the size of a cell in height calculated from the size of the text in it?

Answer the question

In order to leave comments, you need to log in

2 answer(s)
T
Tesla4o, 2018-11-30
@Saharman

Of course, an example of your code would be better.

QTableView *tabl = new QTableView();
tabl->resizeColumnsToContents();
tabl->resizeRowToContents();

P
Pavel K, 2018-11-17
@PavelK

I think that this is what doc.qt.io/qt-5/qheaderview.html#ResizeMode-enum is about. If not, then read the documentation there.

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question