QStackedWidget主要用于页面切换,如下:

QListWidget主要用于显示列表信息,如下:

QStackedWidget具体使用:
TableDemo6::TableDemo6(QWidget *parent)
:MainWindow(parent)
{
ui.setupli(this);
QPushButtom*b1 =new OPushButton("b1",this);
stack =new QStackedWidget(this);//创建页面切换窗口
stack->resize(300,300);
stack->move(30,30);
QLabel*FirstPage =new QLabel(this);
QLabel*SecondPage =new QLabel(this);
QLabel

文章介绍了QStackedWidget在页面切换中的应用,以及如何在QListWidget中添加和显示列表信息,同时提到了信号槽机制在这些控件中的运用。
最低0.47元/天 解锁文章
460

被折叠的 条评论
为什么被折叠?



