qpushbutton Questions
3
Solved
I used PyQt5 for a project and have the following snippet (button is a QPushButton)
def on_receive(self, query):
print("receiving", query)
datapackages = json.loads(query)
for button, datapack...
Hardboiled asked 14/10, 2017 at 17:21
10
I have a QDialog with a QDialogButtonBox. The OK and Cancel buttons are active. Occasionally I disable or hide the OK button based on the state of my dialog. It seems, no matter what I do, the Ente...
Ringler asked 6/4, 2013 at 0:5
2
Solved
I am trying to figure out how to create QPushButton by pressing another QPushbutton so that I can ultimately create buttons dynamically. It seems like the initial method for creating buttons doesn'...
Amice asked 20/4, 2018 at 19:44
2
Solved
I created QPushButton in Qt Designer with this stylesheet:
QPushButton#pushButton {
background-color: #ffffff;
}
QPushButton#pushButton:disabled {
background-color: yellow;
}
QPushButton#pushB...
Ravenous asked 7/1, 2016 at 11:56
4
Solved
I used this as my button pushButton's stylesheet:
QPushButton#pushButton {
background-color: yellow;
}
QPushButton#pushButton:pressed {
background-color: rgb(224, 0, 0);
}
QPushButton#pushButton...
Inkstand asked 3/10, 2013 at 13:54
7
I'm trying to change the background color of a QAbstractButton (either a QPushButton or QCheckBox) in Qt5 and having zero luck.
This does nothing:
pButton->setAutoFillBackground(true);
QPalett...
Ardell asked 10/2, 2014 at 18:46
4
Solved
I'm using Qt Creator to create a gui for a mineseeper game.
How can I know a QpushButton clicked with rightclick? for flag in the game.
In other word, which signal used for rightclick?
First asked 27/3, 2013 at 12:11
3
Solved
I am using this code to set a label on the pushbutton with size of 16
ui->pushButton->setText(tr("<font size=16>Tank 1 \n %1%2C</font>").arg(szTemp).arg(degree));
but I am gett...
Senhauser asked 21/12, 2012 at 5:37
4
Solved
Using Python 3.2x and PyQT 4.8x:
I initialized an action and assigned to a menu item:
self.__actionOpen = QtGui.QAction(self.__mw)
self.__actionOpen.setObjectName("actionOpen")
self.__actionOpen....
Exserviceman asked 22/5, 2013 at 23:10
2
Solved
QPushButton can have icon, but I need to set animated icon to it. How to do this?
I created new class implemented from QPushButton but how to replace icon from QIcon to QMovie?
Radio asked 12/3, 2013 at 23:22
0
Hi I have a GUI with 26 QPushButtons named A to Z, using uicload I load into my Main class
is there any way to loop over them to end up with something
self.A.clicked.connect(self.foo(A))
# ...
Worst asked 6/5, 2020 at 19:7
1
Solved
I am building a small interface where I subclassed RViz which is a visualizer from ROS. According to the official documentation it is possible to re-use and re-implement some of the functions prese...
Elamitic asked 15/6, 2019 at 16:8
3
Solved
In my project, I have some pushbuttons that change between visible and invisible using this:
ui->button->setVisible(true);
//or
ui->button->setVisible(false);
However, it seems that ...
Wellestablished asked 15/7, 2013 at 0:54
1
Solved
Can someone tell me what approach or what logic so the QPushbutton will be enable if all the fields are not empty. I'm making a simple form that you can only push the button if the fields are not e...
Smyth asked 11/3, 2019 at 21:24
2
Solved
Let's say I have an application with a number of QGroupBoxes like so:
import sys
from PyQt4 import QtGui, QtCore
class Main(QtGui.QWidget):
# pylint: disable=too-many-statements
def __init__...
Sciential asked 17/10, 2018 at 11:23
1
Solved
In Qt when we use the function addAction of a QToolBar:
_LastBar->addAction(QtExtensions::Action(name, icon, func));
How could we retrieve the QToolButton generated for that action?
Or, if t...
Rheinland asked 5/9, 2018 at 8:38
4
Solved
I am new to PySide. I want to get the QPushButton obj (such as use it to get its text) in its clicked slot.
button = QtGui.QPushButton("start go")
button.clicked.connect(self.buttonClick)
def but...
Undo asked 2/12, 2013 at 3:18
3
Solved
I am writing a popup menu for a Qt push button widget. Whenever the push button is clicked, a menu pops up (below the push button).
The popup menu is left-sided below by default.
Are there any w...
Skimp asked 28/7, 2015 at 6:14
1
Solved
I am currently learning qt. And I am trying to build a small GUI program with 81 QPushButton on it.
I want to set those buttons to 9 rows and 9 cols. The best way I can think to implement this lay...
Montero asked 10/11, 2017 at 15:24
1
Solved
I would like to get the list of all QPushButton in my MainWindow. Actually, I have a QRadioButton, and when I uncheck it, I would like to disable all the QPushButton of my window.
How can I do tha...
Subtlety asked 16/2, 2017 at 10:31
2
Solved
Can I add some widgets like QLabel and QPushButton into a QTabWidget?
Actually, I want to do something like this:
I'm using C++ and Qt.
Thanks
Mcreynolds asked 6/6, 2016 at 3:33
1
Solved
I want to write a if with a condition as the state of QPushButton. I would like to execute if if the button is enabled. So, how can i check the state of the Button.
Code:
self.pushButton = QtGui....
Mathew asked 28/12, 2016 at 22:11
5
Solved
I have a QPushButton and when it is on focus it has a rectangle on it that I want to remove. Here some screenshot:
Normal button:
Focused button:
I have tried to add something (backgroundcolor, t...
Contrecoup asked 24/6, 2013 at 16:10
3
Is it possible to set and change the icon on a QPushButton using stylesheets?
I need this for a Windows-based white-label Qt4.5 application that customers stylize using stylesheets.
Monoplegia asked 20/4, 2010 at 14:28
2
Solved
I'm new to Qt and the difference between QPushButton and QToolButton is not so clear to me.
I know that a QToolButton is usually used in a QToolBar and it usually shows only an icon, without text,...
Quarterhour asked 25/7, 2016 at 19:58
1 Next >
© 2022 - 2024 — McMap. All rights reserved.