Setting column width for QTreeWidget

Is there a way to set the column width for a QTreeWidget from code? I want to change the default column width. I am using PySide.

+3


source to share


1 answer


QHeaderView :: resizeSection () should do the trick, in C ++ it would look like this:



myTreeWidget->headerView()->resizeSection(0 /*column index*/, 100 /*width*/);

      

+4


source







All Articles