QTableWidget: how to stretch columns?
General and Desktop
7
Posts
3
Posters
9.5k
Views
1
Watching
-
Hi, I'd like to know how to stretch a QTableWidget's columns from the designer? thanks.
-
please help.
-
[quote author="zeljko" date="1398791061"]QListWidget doesn't have columns afaik (TextMode). Are you talking about IconMode ? What exactly you want to resize ?[/quote]
Sorry, I was wrong about the QListWidget: it's in reality about QTableWidget.
so how to do that? -
Hi kaisbs,
There is way to stretch the column in QTableWidget in Designer also.
Steps as,- Open the Qt designer.
- Select QTableWidget item which you already placed on your form.
- See the property box at right hand side.
- Scroll down to QTable Widget
- Under Header section you will find options to resize it as,
- horizontalHeaderDefaultSectionSize increase as you want & try it out
- horizontalHeaderStretchLastSection make it true so your empty space after last column will be filled by stretched last column.
Do your own tryouts on that there are plenty of option to do.
Thanks
Prashant Moglaikar