How can I see qDebug messages while debugging in QtCreator

前端 未结 7 1449
感动是毒
感动是毒 2021-02-04 06:38

I\'m making the transition from Eclipse CDT (with Qt integration plugin) to QtCreator 2.0 but there is still one thing that bother me with QtCreator :

When I debug in Qt

7条回答
  •  别那么骄傲
    2021-02-04 07:11

    None of these answers were right for me (Arch linux user). Rather than try to explain my troubles, here is a .pro file that worked. I'm not using the QT thread loop, purely just a simple main() that does stuff and exists. I'm using cout for my output:

    QT += core
    QT -= gui
    
    CONFIG += c++14
    
    TARGET = evo
    #CONFIG += console
    CONFIG -= app_bundle
    #CONFIG += qt
    
    #OUTPUT += console
    
    TEMPLATE = app
    
    SOURCES += main.cpp \
        individual.cpp \
        node.cpp \
        tree.cpp
    
    HEADERS += \
        individual.h \
        node.h \
        tree.h
    

提交回复
热议问题