qt-creator

How open Qt Creator project (itk-snap) using Cmake

[亡魂溺海] 提交于 2019-12-14 00:41:42
问题 I am interested to import Itk-snap source code in Qt5.4. Based on their help I could built the executable itksnap in my system using cmake(3.4.1). Then, I have imported the Cmakelist.txt in Qt creator and pressed "run camke". It is configured successfully, but I cannot see the project file ( no main.cpp or any file in left panel)! , cannot build it because it does not loaded in Qt creator. What do I do wrong? How can I have itksnap in my QT creator. I am using OSX, and unix generator for

QTCreator does not recognize the executable while debugging C++ program

流过昼夜 提交于 2019-12-13 17:21:53
问题 I have installed QTCreator in ubuntu 12.04 through sudo apt-get install. My problem is that QTcreator is not able to recognize the executable in debug mode, although it is running fine without debugging..when I simply run my program. The error which the QTCreator throws at me while debugging is: s/Prog": not in executable format: File format not recognized I can use gdb outside QtCreator. All my tool chain just shows me GCC(x86 64 bit)...is this setting fine. If not please recommend. 回答1: I

qtcreator customize getters and setters

狂风中的少年 提交于 2019-12-13 17:17:22
问题 I have lots of member variables in my file i.e. int m_member_var , when I hit alt+enter to auto generate the getters/setters, it give me the setter void setMember_var(...) . But I need set_member_var(...) . Is there a way to change the template? I'm using Qtcreator 3.0.1 来源: https://stackoverflow.com/questions/31162580/qtcreator-customize-getters-and-setters

Show Array's Content in a Range in Qt Debugger

旧城冷巷雨未停 提交于 2019-12-13 16:02:43
问题 I'm using QT Creator debugger. When I try to debug a large array (i.e. 1000,000 elements), it hangs for trying to retrieve the whole array's values, though I'm trying to see the first few elements only. In KDevelop the debugger shows the first 5 elements only, then I press click to show another 5 elements and so on. Is it possible to do the same in QT Creator? 回答1: The answer depends on the debugging backend you use, and the version of Qt Creator. With GDB as debugging backend you can use

eof(), bad(), good() functions aren't detected by autocomplete

ε祈祈猫儿з 提交于 2019-12-13 15:17:28
问题 This code block: #include <iostream> #include <fstream> #include <string> using namespace std; int main () { string line; ifstream myfile ("example.txt"); if (myfile.is_open()) { while ( myfile.good() ) { getline (myfile,line); cout << line << endl; } myfile.close(); } else cout << "Unable to open file"; return 0; } taken from here, compiles and runs well, but the good() function isn't recognized by my IDE (Qt) when I try to write it by hand and use autocomplete. Can anyone tell me why? Thank

Deploying a Qt application on Windows?

那年仲夏 提交于 2019-12-13 14:24:40
问题 I'm new to Qt and cannot figure out how to deploy a simple Qt application on Windows. It runs fine when run from inside Qt Creator, but it won't run when directly executed. I have the newest version of the Qt SDK installed and am using all of the default settings. I have read dozens of "how to" guides, all of which provided conflicting information, in addition to dozens upon dozens of forum threads, blog posts, and questions on here. I simply cannot find instructions that clearly explain how

Can QT Creator on linux create .exe files

有些话、适合烂在心里 提交于 2019-12-13 10:33:04
问题 I ve installed QT Creator in OpenSUSE Linux distro, Can i know if it is possible to create ".exe" of QT program which is perfectly executing in Linux. If so kindly mention the procedure to create .exe in Linux. Thank U 回答1: I understand that you have a Qt application, and you are able to compile it on OpenSuse using QtCreator, and you want to create a windows binary of the same application on OpenSuse. The most hassle free method of doing this is to install the Qt SDK (and QtCreator, if need

Issue trying to configure Qt Creator with OpenCV

会有一股神秘感。 提交于 2019-12-13 05:27:58
问题 I'm trying to configure Qt Creator (Qt 5.4.1) with OpenCV 2.4.10. I've followed the steps on this page: https://zahidhasan.wordpress.com/2014/08/19/qt-5-3-1-64-bit-mingw-windows/ I followed all steps to the letter except this: INCLUDEPATH += C:\opencv-mingw\install\include LIBS += -L”C:/opencv-mingw/install/x64/mingw/bin” LIBS += -lopencv_core249 -lopencv_highgui249 -lopencv_imgproc249 I changed it to INCLUDEPATH += C:\opencv-mingw\install\include LIBS += -L”C:/opencv-mingw/install/x64/mingw

c++, g2o (Graph-Framework), qcreator, undefined reference to methods

China☆狼群 提交于 2019-12-13 05:00:02
问题 I'm trying to use the g2o library in a c++ project. I installed the library in two systems OpenSuse - dependencies through zypper install, g2o by compiling according to directions Ubuntu - all dependencies through apt-get, g2o by compiling according to directions My .pro file includes these, in order to link to the .so libaries: INCLUDEPATH += /home/rhun/data/Coding/g2o/trunk/lib/ LIBS += -L/home/rhun/data/Coding/g2o/trunk/lib/ LIBS += -lg2o_calibration_odom_laser LIBS += -lg2o_cli LIBS +=

Inaccessible QPushButton mystery

萝らか妹 提交于 2019-12-13 04:31:35
问题 I have a QT application. It has functioning QPushButtons that are connected to slots in my program. I am now trying to add a new button myNewButton , but somewhere, somehow it is not being registered. For an existing, working button myExistingButton I have the line: connect(ui->myExistingButton, SIGNAL(clicked()), this, SLOT(Foo())); I cannot simply add the line: connect(ui->myNewButton, SIGNAL(clicked()), this, SLOT(Foo())); The compilation error is: class UI::Viewer has no member named