Questions tagged [qcheckbox]

A QCheckBox is a GUI class from the Qt toolkit which provides a checkbox with a text label.

A QCheckBox is an option button that can be switched on (checked) or off (unchecked). Checkboxes are typically used to represent features in an application that can be enabled or disabled without affecting others.

The official documentation for this Qt class can be found here

175 questions
0
votes
0 answers

Editing Qt style sheet of QCheckBox

I'm using style sheets to edit some checkboxes to my liking. I can change the color of the text with color: rgb(255,0,0); // Red text and I can change the look of the checkbox itself with QCheckBox::indicator { background-color:…
Churchbus
  • 53
  • 5
0
votes
1 answer

QCombobox of Checkboxes

I have a problem and I hope that you can help me. I want to create a Combobox of Checkboxes on Qt Creator. This is my code mod = new QStandardItemModel(1,0); QStandardItem *item; item = new…
TorneiTP
  • 1
  • 2
0
votes
1 answer

How to search for a specific kind of qt gui control

I have a QWidget that contains a QGroupBox, which contains QComboBox, QLineEdit and QCheckBox. I need to go around all the controls, and if the control is a QCheckBox, ask if it is checked or not. I need to know how all the QCheckBox are checked -…
GSandro_Strongs
  • 773
  • 3
  • 11
  • 24
0
votes
0 answers

QChecbkBox events into QGraphicsScene

I have a problem on the behavior of QCheckBox. I am under Qt5.3.2/MinGW I create a QGraphicsScene where i add severals QCheckBox via QGraphicsProxyWidget. To be able to do drag and drop, zoom in / out, I reimplemented the virtual method…
Gamso
  • 73
  • 2
  • 7
0
votes
0 answers

PyQt QTreeWidget - odd delay when setting all checkboxes to unchecked

I am building an application with PyQt4 and Python3 that is using a QTreeWidget to give users a way to select what portions of their data that they want interact with after it has been loaded into the application. The tree usually has 3 levels.…
dan_g
  • 2,712
  • 5
  • 25
  • 44
0
votes
2 answers

Lock a choice in PyQt4 QComboBox using a QCheckBox

I am beginning to write a GUI using PyQt4. This is my first experience with GUIs (and also oo-programming is somewhat new to me). Part of that GUI will be like 4 to 5 instances of QComboBox. As many choices are to be made, I want the user to be able…
Nras
  • 4,251
  • 3
  • 25
  • 37
0
votes
1 answer

Pyside - delegate readonly checkbox

I want to delegate a readonly Checkbox into a QTableWidget I have the following class for the a checkbox which is shown enabled (editable) from PySide import QtCore, QtGui class CheckBoxDelegate(QtGui.QStyledItemDelegate): """ A delegate…
Elteroooo
  • 2,913
  • 3
  • 33
  • 40
0
votes
2 answers

Synchronize QTableWidget cell with widget in the center of the cell

I use QCheckBox in QTableWidgetCell QWidget *widget = new QWidget(); QCheckBox *checkBox = new QCheckBox(); QHBoxLayout *layout = new…
Ufx
  • 2,595
  • 12
  • 44
  • 83
0
votes
1 answer

QTableWidget with checkbox

I need to use QTableWidget with checkboxes instead of text in items. Checkbox must be in the center of item. Examples which I tried work while checkbox is checked. If I uncheck checkbox it disapeares.
Ufx
  • 2,595
  • 12
  • 44
  • 83
0
votes
3 answers

Python2 PyQt4 Connect a bool Variable to a QCheckBox item

I have a problem with QCheckBox. I am trying to connect a boolean variable to a QCheckBox so that when I change the boolean variable, the QCheckBox will be automatically checked or unchecked. My Question is similar to the Question below but in…
0
votes
0 answers

Checkboxes in PySide using for loop connects unexpected on stateChanged

What I'm trying to do is to create checkboxes using for loop and connect a function to them ,which is called with different argument for every checkbox. Here is some code: for video in videos: video_cb = QtGui.QCheckBox(video['title']) …
dragonator
  • 137
  • 5
  • 14
0
votes
1 answer

How to add checkbox in the bottom left corner of QGraphicsView?

I want to add a checkbox in the left corner of QGraphicsView . I tried painting it directly in painEvent of my view . void BhGraphicsView::paintEvent(QPaintEvent* event) { QGraphicsView::paintEvent(event); QStyleOptionButton opt; …
uchar
  • 2,552
  • 4
  • 29
  • 50
0
votes
0 answers

check QCheckBox in QVboxLayout of QStackedWidget

i have a QstackedWidget and i add QHboxLayout and QVBoxLayout to it, in my vertical layout i add 3 QCheckBox, and i add this layout with two spacer for left and right side to it, then i push this new layout with two spacer for top and bottom in…
mari
  • 417
  • 1
  • 6
  • 21
0
votes
1 answer

how i find out uset check and unchecked checkboxes?

My program have a set of checkbox, When user check a checkbox, i should call slot1() and user uncheck checkbox, i should call slot2(),But i can't understand when user checks and when unchecked. My questions is, How can i find out user check and…
PersianGulf
  • 2,845
  • 6
  • 47
  • 67
0
votes
1 answer

QT QTableView get checked items

I have a QTableView with check boxes was created by: QStandardItem* checkBox = new QStandardItem(true); checkBox->setCheckable(true); checkBox->setCheckState(Qt::Unchecked); model->setItem(row, 0, checkBox); ui->tableView->setModel(model); Now…
RRR
  • 3,937
  • 13
  • 51
  • 75
1 2 3
11
12