PDA

View Full Version : MDI with resizable sections



Cruz
26th December 2011, 04:26
Hello!

I want to write a program with a GUI that is divided into four tiles. The tiles should be resizable with a "cross" in the middle. For example, ftp clients have typically two tiles, one on the left and one on the right, with a bar in the middle that can be used to shrink the left half and grow the right half.

Is the QMdiArea the right thing to start from? I definately don't need any cascading though. It will always be four tiles and this cross like resizing is an important feature.

Lykurg
26th December 2011, 08:07
I would go for three QSplitter's which you have to synchronize to emulate the "cross" behavior.

Cruz
26th December 2011, 15:38
If this was Facebook, I would press the like button now.

Cruz
28th December 2011, 06:19
It works just like I wanted, but there is one problem. The splitters are only one pixel wide and very hard to grab with the mouse. I'm unable to make the splitters bigger with either using setHandleWidth() or using style sheets



QSplitter::handle {
background-color: rgb(150,150,150);
width: 10px;
}

QSplitter::handle:horizontal {
background-color: rgb(150,150,150);
width: 10px;
}

QSplitter::handle:vertical {
background-color: rgb(150,150,150);
height: 10px;
}


Any ideas?