QT C++ 备查

输出调试信息

#include <iostream>
using namespace std;

cout << "msg" << endl;

按钮点击事件绑定Lambda表达式创建的匿名函数

#include <QPushButton>

connect(ui->btn1,
            &QPushButton::clicked,
            this,
            [](){cout << "btn1 clicked" << endl;}
    );
posted @ 2022-09-02 09:57  太晓  阅读(10)  评论(0编辑  收藏  举报