No member named 'addAction' in 'QWidget'



  • I downloaded Qt package including Qt Creator from the official website and started to create a simple project with mainwindow.cpp, mainwindow.h and mainwindow.ui in. Then I hit the build button. It pops out the same errors:

    qmenu.h:86:20: error: no member named 'addAction' in 'QWidget'

    This error seems to point to the file below with the error line

    Qt/5.3/clang_64/lib/QtWidgets.framework/Versions/5/Headers/qmenubar.h:71:20: error: no member named 'addAction' in 'QWidget'
    using QWidget::addAction;

    Could somebody tell me what is going on here? I use the cmake to do the same process, the same error pops out, is it a bug or not?

    PLUS: I am using Qt Creator on MAC OS Mavericks.

    Cheers,

    Gauss


  • Lifetime Qt Champion

    Hi and welcome to devnet,

    Can you show your code related to QAction ?


Log in to reply
 

Looks like your connection to Qt Forum was lost, please wait while we try to reconnect.