PDA

View Full Version : How can QTreeWidget force window to resize.



Malutek
3rd May 2012, 03:24
Hello,

I'm working on a simple music player, and I can't deal with resizing. Namely, I have main window, in which I have QTreeWidget. Now, once I load some kind of data into that tree, it grows both horizontally and vertically. The problem is, that I want to force main window to resize itself each time I load data, so the window can present whole data horizontally (vertically not necessary). I just don't want to scroll on sides, just up and down.
I've been googling for this for quite some time now, and didn't find solution to my problem. Thanks in advance for help ; )

mentalmushroom
4th May 2012, 06:15
you may try to manually resize main window when loading data.

zgulser
4th May 2012, 08:36
Hi,

I got a bit confused about your question. I mean you mentioned about resizing the main window but then said something about scroll bars.

I assume you don't want to resize the widget. If so you don't want to scroll the widget on sides? But if so, your one raw data may shrink to 2nd line?

Added after 12 minutes:

By the way, I suppose you need to use QTableWidget?