QFrame is a class from the Qt Toolkit which provides the base class for widgets that can have a frame.
Questions tagged [qframe]
75 questions
10
votes
3 answers
QLineEdit with custom button
I need to implement LineEdit widget with possibility to add tool buttons at the right end of text area. I know two ways of doing that but both solutions seems ugly.
1) add tool buttons as child widgets of QLineEdit and handle resizeEvent to position…

ArmanHunanyan
- 905
- 3
- 11
- 24
9
votes
1 answer
QScrollArea not working as expected with QWidget and QVBoxLayout
So I have this QFrame which is the parent widget (represented by this in the code). In this widget, I want to place a QWidget at 10 px from top (and 10 px from bottom, as a result of which it will have a height of 140px, whereas parent is 160px).…

SexyBeast
- 7,913
- 28
- 108
- 196
6
votes
1 answer
Border color of Qt components
I want to change border color of QFrame component. Also tried with style sheet but no effect at run time. In my project there are various Dialog UI are there which are basically QFrame and i want to change the border color of selected dialog i.e.…

foxt7ot
- 2,465
- 1
- 19
- 30
5
votes
3 answers
Qt - Draw a fully transparent window in Windows without using WA_TranslucentBackground
I need to draw transparent window (either QLabel or QFrame or QWidget), but without using WA_TranslucentBackground. The reason for that is that the windows will contain other child widgets rendered through OpenGL, and using that property makes those…

SexyBeast
- 7,913
- 28
- 108
- 196
4
votes
1 answer
QFrame Background Color overlapped with other Widgets like QLineEdit, QListBoxWidget, etc. How to avoid it?
In my Programme,
QLineEdit and QListWidget Placed in QVBoxLayout. And then QVBoxLayout put in a QFrame with Stylesheet of background-color:orange.
QLineEdit and QListWidget also get the same background-color of QFrame. How to avoid the background …

Kumar
- 592
- 6
- 18
4
votes
1 answer
How to set border to widget, inherited from QFrame?
I created widget of led light with radial gradient,(found example in internet). It was inheritated from qwidget and all type of borders that I could use in there are presented By QPaint. But I need more difficult shape for this LED, I saw this kind…

Albert
- 81
- 2
- 8
3
votes
1 answer
Popup widget in qt
How to create it in qt?
When you click on button - should be shown popup widget and its width should be = button width.
And if main window (main form) drag to another place on the screen - popup widget should continuously follow the button (must be…

igorotvertka
- 87
- 1
- 7
3
votes
1 answer
PyQt5 actual size of a QFrame
Is there a way to get an actual size of the QFrame in PyQt5? My monitor resolution is 1920x1080. After I add QFrame to layout it fills the whole window in my case about 1200px. However the width() command returns 640. It seems that default size…

goryef
- 1,337
- 3
- 22
- 37
3
votes
5 answers
Changing the color of a QFrame in QT
I have set the color of my main window in QT to be grey.
ui(new Ui ::MainWindow)
ui-> setupUi(this)
this->setStyleSheet("background-color: grey;");
I have tried multiple ways to set the color of the QFrame, however it takes on the default grey…

Gage Haas
- 51
- 1
- 2
- 8
3
votes
2 answers
How to remove horizontal borders from QHeaderView
I Have QTableView object with horizontal headerView, (vertical I have hidden).
I set setShowGrid(false) to remove grid from qtableView, but how can I remove separator borders between QTableView and its horizontal header.
I…

tokafr
- 109
- 2
- 12
3
votes
1 answer
QFrame's stylesheet affecting QLabel
I am using QFrame just to have colored border, since I couldn't find
the a way to change color of the QDialog. So because of tampering with
QFrame's border, it is also affecting the QLabel's look, is there any
way to avoid this?
Edit:
Here is the…

jxgn
- 741
- 2
- 15
- 36
2
votes
1 answer
How to call a frame in Qt
I have included a frame in my ui and i'm trying to call it in my source code, and I'm guessing it should be something like this ui->frame; but while I'm typing it, it doesn't come along the suggestions...
user12991669
2
votes
1 answer
Adding a QVBoxLayout to a QFrame?
I am trying to figure out how to add a populated QVBoxLayout into a QFrame.
In the image you see 4 sliders, each with two labels, and a pushbutton. I've been messing around with QIcon and stylesheets which is why they look a bit odd at the moment.…

Welshhobo
- 115
- 11
2
votes
1 answer
QFrame With Title
I need to implement a QFrame that has a title (see image). However, after reading QFrame's documentation and trying to re-implement the paintEvent(QPaintEvent*) method, I failed to find any solution.
I was wondering if any of you could provide a…

mathlizee
- 185
- 2
- 12
2
votes
1 answer
Can I change custom dynamic properties from a stylesheet (qss)?
I have a custom QFramelike this
//! Widget which displays a audio level meter, indicating the
//! level and peak levels of the window of audio samples most recently analyzed
class BLACKGUI_EXPORT CLevelMeter : public QFrame
{
Q_OBJECT
…

Horst Walter
- 13,663
- 32
- 126
- 228