面板按钮 tpPanelSwitchButton
2025-07-17
介绍
tpPanelSwitchButton 类 tpPanelSwitchButton 侧重于面板样式显示的按钮。
使用示例
tpPanelSwitchButton* wifiBtn = new tpPanelSwitchButton(this);
wifiBtn->setCheckable(true);
wifiBtn->setText("WIFI");
wifiBtn->setIcon("/res/WIFI.png");
connect(wifiBtn_, onClicked, [=](bool)
{
std::cout << "WIFI开关!" << std::endl;
});
效果演示
未选中
选中