Problem with mainwindow (the buttons desapear)
-
Hello, i am new in Qt and i having a problem with the application that i am doing.
This application has the mainwindow and a second window that open with a button in the mainwindow. When i run the program it compiles, but when i pass the mouse over a button, the window become white and the buttons desapear.
I am using Qt creator 3.5.1.
Based on Qt 5.5.1(MSVC 2013, 32 bits)
My windows is 7 - 64 bitscode of the mainwindow (posicionador_de_antenas)
#include "posicionador_de_antenas.h"
#include "ui_posicionador_de_antenas.h"
#include "posicionador_manual_1.h"Posicionador_de_Antenas::Posicionador_de_Antenas(QWidget *parent) :
QMainWindow(parent),
ui(new Ui::Posicionador_de_Antenas)
{
ui->setupUi(this);
}Posicionador_de_Antenas::~Posicionador_de_Antenas()
{
delete ui;
}void Posicionador_de_Antenas::on_pushButton_clicked()
{
Posicionador_Manual_1 pos_man;
pos_man.setModal(true);
pos_man.exec();
}
Figure of the problem
errorThanks!!
-
Hi
what does Posicionador_Manual_1 window look like?
Its a qdialog type window?please show source for this class also.
-
Hi,
Posicionador_Manual_1 have two buttons, one label and one doublespin box. I am setting the valour read in the box to a variable float when i press the button ok. The other button close this window. Here is the code:
#include "posicionador_manual_1.h"
#include "ui_posicionador_manual_1.h"
#include "posicionador_de_antenas.h"Posicionador_Manual_1::Posicionador_Manual_1(QWidget *parent) :
QDialog(parent),
ui(new Ui::Posicionador_Manual_1)
{
ui->setupUi(this);
}Posicionador_Manual_1::~Posicionador_Manual_1()
{
delete ui;
}void Posicionador_Manual_1::on_pushButton_clicked()
{
float posicao = ui->doubleSpinBox->value();
}Thanks!
-
Hi
I don't see anything wrong with code.
The picture you shown.
Seems just to be Mainwindow.
Not the Posicionador_Manual_1 dialogSo the dialog do show?
-
That's the issue.
The mainwindow turns white even when i do not click in any button, just pass the mouse over it.
This is the two windows after the problem.
I am suspecting of a problem with compatibility in my windows or something like that. i don't know for sure. -
Hi,
i tried to do a simple window, with just one button to close this mainwindow and i am geting the same problem, the window turns white. I will reinstall my Qt with a an older version that have 64 bits version and see what happend.
thank you anyway!!
-
Hi,
i tried to do a simple window, with just one button to close this mainwindow and i am geting the same problem, the window turns white. I will reinstall my Qt with a an older version that have 64 bits version and see what happend.
thank you anyway!!
@BrunoVinicius
Ok it does seem a bit strange.
Just moving mouse over window should not make it white/non responsive.If you open any of the many examples. do they run?
-
I did not try exemples, but i followed some videos in youtube, and did just the same program the video shows, and give me the same error. Like you said, it does seem a bit strange.
when i reinstall the Qt, i will post the result.Thanks!
-
I did not try exemples, but i followed some videos in youtube, and did just the same program the video shows, and give me the same error. Like you said, it does seem a bit strange.
when i reinstall the Qt, i will post the result.Thanks!
@BrunoVinicius
ok before u reinstall,maybe try example just to see? -
hi again,
like you said i tried some exemples and the same error. I tried childwidget, most basic impossible!!!
I try to install some older version, but i had problem with the compiler.
i don't know what to do anymore. -
Hi,
What if you use the 64 bit version of Qt ?
-
Also, make sure to try to disable your virus scanner for a moment to test.
-
Hi,
SGaist, i downloaded a Qt 5.0.2-msvc2012_64-x64-offline, but i had some problems with the compiler, because its not integrate, i assume. Do i need to desinstall my current version to install this one? And how i can configure the compiler?
mrjj, i do not have a antivirus runing in the moment, so that's is not the problem.
thanks a lot guys!!
-
Because that's a version for Visual Studio 2012 and you have 2013. You can't mix and match compilers on Windows, they are not compatible one with the other.
Just download the 64 bit Qt 5.5.1 for Visual Studio 2013
-
Hello,
i know it is not the topic problem but,
i installed Qt 5.5.1 64 (MSVC2013) version, and know in Build and Run, Qt versions and Kits configurations have problem. In compilers, the program just detect Micrsoft Visual C++ Compiler 14.0. How i configure and do i have to install another program?Thanks
-
Hello again,
i reinstall Qt, using "qt-opensource-windows-x86-mingw491_opengl-5.4.0" and works properly.
Thanks anyaway guys. -
Out of curiosity, did you by any chance change from Visual Studio 2013 to Visual Studio 2015 ?
Also, why install an older version of Qt and not the current ?