PDA

View Full Version : How to place QSlider inside and QPushButton above the widget area



Cucumber
6th December 2010, 20:06
Hello there,

The default position of QSlider is to the right of the widget.
I would like to to place my slider inside the widget and
to make the groove transparent.Below given an example:
http://cl.ly/1f2I0V0y241g43343234/content


The second question is pretty much the same. I would like to place QPushButton (and some other widgets like QLabel and QCheckBox) above the QTextEdit. Below is an example:
http://cl.ly/283H3w2U401R113n3z0f/content

How can I make it?
I would really appreciate any help on those questions. Thanks in advance!

tbscope
7th December 2010, 04:18
Why do you want to hide part of the text?

Cucumber
8th December 2010, 01:53
Why do you want to hide part of the text?
Just because of design.
So, any clues? Thanks in advance.

tbscope
8th December 2010, 05:42
You can stack widgets by not using layouts and setting the right coordinates.
You can make parts of the slider transparent by creating a custom style.

You can also use a graphicsview as the parent widget and put all the child widgets in a scene. Then you can even do nice effects without a lot of effort. Or use QML directly.

But, I would never use such a program. It's unbelievably annoying.