MCPcopy Create free account
hub / github.com/czyt1988/SARibbon / createRightButtonGroup

Method createRightButtonGroup

example/UseNativeFrameExample/mainwindow.cpp:612–627  ·  view source on GitHub ↗

* @brief 创建RightButtonGroup * * RightButtonGroup实在ribbonbar右边的工具栏,可以放置一些快捷图标 * @param rightBar */

Source from the content-addressed store, hash-verified

610 * @param rightBar
611 */
612void MainWindow::createRightButtonGroup()
613{
614 SARibbonBar* ribbon = ribbonBar();
615 if (!ribbon) {
616 return;
617 }
618 SARibbonButtonGroupWidget* rightBar = ribbon->rightButtonGroup();
619 QAction* actionHelp = createAction(tr("help"), ":/icon/icon/help.svg");
620 mActionVisibleAll = createAction(tr("Visible"), ":/icon/icon/visible-true.svg");
621 mActionVisibleAll->setCheckable(true);
622 mActionVisibleAll->setChecked(true);
623 connect(actionHelp, &QAction::triggered, this, &MainWindow::onActionHelpTriggered);
624 connect(mActionVisibleAll, &QAction::triggered, this, &MainWindow::onActionVisibleAllTriggered);
625 rightBar->addAction(actionHelp);
626 rightBar->addAction(mActionVisibleAll);
627}
628
629/**
630 * @brief 创建右上角系统最大、最小化按钮栏的图标工具

Callers

nothing calls this directly

Calls 2

rightButtonGroupMethod · 0.45
addActionMethod · 0.45

Tested by

no test coverage detected