qpushbutton Questions

3

Solved

Can anyone plz help me, how to save my QtableView as a Excel File. I have a QTableView and a QPushButton (Save Button). If i enter the values in my QtableView and if i click the Save Buttton the QT...
Inimical asked 27/9, 2012 at 5:45

2

Solved

I am writing newbie Qt5 code on OSX Mavericks and would like to override just one property:value pair of the StyleSheet for a given widget. If I run the following self-contained demonstration cod...
Trig asked 3/3, 2015 at 19:5

2

Solved

I have an Android application written in C++ using Qt Creator. After the Qt version upgrade (from 4.8 to 5.4) I observed a strange behaviour: all QPushButton got duplicated text label, one is at ...
Fireguard asked 27/4, 2015 at 11:24

1

Solved

I want to build a dropdown list control with QPushButton and QMenu like below: QPushButton* menuBt = new QPushButton("Please select"); menuBt->setFlat(true); QMenu* menu = new QMenu(); menuBt-&...
Peg asked 14/7, 2015 at 6:49

4

Solved

I want to make my app laptop friendly. I can tab to everywhere, but if I tab to a QPushButton I can't press it with Enter, only with space. What's the problem? How to make it pressable for Enter?
Schnitzler asked 9/8, 2012 at 16:33

1

Solved

I have got a weird problem. I need to have some buttons in my QTableView. I used to use QAbstractItemView::setIndexWidget() method, but it is not very responsible when working with larger models. ...
Friction asked 2/3, 2014 at 15:49

1

Solved

After begining the program I set icons on all pushbuttons. Code is like this: QImage img; img.load(pictureName); ui->pushButton_1->setIcon(QPixmap::fromImage(img)); ui->pushButton_1->...
Shekinah asked 24/11, 2014 at 15:19

3

Solved

I need a QPushButton with two colors in the text. I found a solution with a html code in QTextDocument and it's working. But I need center align and the html code isn't working. QTextDocument Tex...
Almost asked 10/11, 2014 at 20:21

4

The documentation on assigning a shortcut to a QPushButton is as follows: A shortcut key can be specified by preceding the preferred character with an ampersand in the text. For example: QPushB...
Nicky asked 22/9, 2014 at 15:3

2

Solved

When a QPushButton is clicked, I want it to remain pressed down until clicked again. void MainWindow::itemClicked(){ QPushButton *clickedItem = qobject_cast<QPushButton *>(sender()); qD...
Scrapple asked 14/8, 2014 at 7:8

1

Solved

I am using Qt 5.3.0. When I apply some background-color on the QPushButton's checked state, the button will be filled with grey dots (over the background color I wanted) when it is checked. Here i...
Sachet asked 13/7, 2014 at 1:13

1

Solved

I made an own GridPushButton class to store the buttons position in gridlayout. The parent is QPushButton. I have a problem with asking it's x and y coordinates in window (like x:654, y:768). I tho...
Roping asked 12/6, 2014 at 16:15

1

Solved

I want to have a function in main class which has parameters not only self. class Ui_Form(object): def clearTextEdit(self, x): self.plainTextEdit.setPlainText(" ") print("Script in Textbox is C...
Marcellusmarcelo asked 24/5, 2014 at 15:20

2

This seems like such a simple thing, but I can't seem to figure it out. How do I make the button the minimum width. It keeps expanding to the width of the layout I put it in. In the following examp...
Fuddle asked 19/1, 2013 at 20:10

1

Solved

I have a Qt application on C++ and I want to assign a slot to a QPushButton. But I want to pass some arguments because I have more than one QPushButton doing similar thing so I want one function bu...
Cabstand asked 16/1, 2014 at 0:3

1

Base on the groupbox example of PySide-Example, I add a clicked slot to the pushButton, such as: def createPushButtonGroup(self): ... pushButton = QtGui.QPushButton("&Normal Button") ...
Thrust asked 2/12, 2013 at 5:25

1

Solved

I know, thats a beginners question but I have to tried to solve it with goolge / stackoverflow, but I haven't found a good answer. The problem is, I want to add a icon to a qpushbutton. But it does...
Twiggy asked 3/11, 2013 at 23:15

4

Solved

I have two custom-styled QPushButton buttons. Here is the stylesheet for the Ok button: QPushButton { background-color:#9dce2c; border-radius:7px; border:1px solid #83c41a; color:#ffffff; fo...
Fraud asked 31/7, 2012 at 6:35

2

Solved

I want to stack some QPushButton objects on the other side of my QMenuBar. This is how my window looks now: And this is how I want it to look like (I've photoshopped the image): I know that in...
Rourke asked 1/2, 2013 at 11:45

1

Solved

I can change the font and font-color of a QPushButton using the StyleSheets. The Problem is that under the old Windows Theme the disabled Buttons shows a shaded font, but i dont know how to get rid...
Vincennes asked 31/10, 2012 at 12:33

© 2022 - 2024 — McMap. All rights reserved.