fix(ui): 调整 PEBI 网格预览工具栏分组和图标

feature/nmNum-postprocessing-view-20260910
lh 3 hours ago
parent 369d67aa77
commit 3eef7f3c82

Binary file not shown.

After

Width:  |  Height:  |  Size: 415 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 979 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 365 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 485 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 400 B

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.1 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.0 KiB

@ -34,14 +34,14 @@ nmVTKViewCommandController::nmVTKViewCommandController(
}
// QAction 只在构造阶段创建一次,后续所有菜单和工具栏复用这些实例。
createAction(ViewCommand_ZoomIn, tr("Zoom In"), "ZoomIn.png",
SLOT(zoomIn()));
createAction(ViewCommand_ZoomOut, tr("Zoom Out"), "ZoomOut.png",
SLOT(zoomOut()));
createAction(ViewCommand_ZoomIn, tr("Zoom In"), "NmZoomIn.png",
SLOT(zoomIn()));
createAction(ViewCommand_ZoomOut, tr("Zoom Out"), "NmZoomOut.png",
SLOT(zoomOut()));
createAction(ViewCommand_Fit, tr("Fit to Window"),
"ZoomSelfAdaptation.png", SLOT(fitView()));
createAction(ViewCommand_Top, tr("Top View"), "Map2D.png",
SLOT(setTopView()));
"NmZoomReset.png", SLOT(fitView()));
createAction(ViewCommand_Top, tr("Top View"), "NmTopView.png",
SLOT(setTopView()));
createAction(ViewCommand_Front, tr("Front View"), QString(),
SLOT(setFrontView()));
createAction(ViewCommand_Right, tr("Right View"), QString(),
@ -53,8 +53,9 @@ nmVTKViewCommandController::nmVTKViewCommandController(
SLOT(resetRotationCenter()));
createAction(ViewCommand_SaveImage, tr("Save as Image"), "SaveImg.png",
SLOT(saveImage()));
createAction(ViewCommand_CopyImage, tr("Copy Image"), "Copy.png",
SLOT(copyImage()));
createAction(ViewCommand_CopyImage, tr("Copy Image"),
"NmCopyGraphic.png",
SLOT(copyImage()));
createAction(ViewCommand_Print, tr("Print"), "Print.png",
SLOT(printImage()));
createAction(ViewCommand_PrintPreview, tr("Print Preview"),

@ -87,7 +87,7 @@ void nmWxPebiGridViewWidget::createUi()
m_pToolBar->setOrientation(Qt::Vertical);
m_pToolBar->setMovable(false);
m_pToolBar->setFloatable(false);
m_pToolBar->setIconSize(QSize(20, 20));
m_pToolBar->setIconSize(QSize(24, 24));
m_pToolBar->setToolButtonStyle(Qt::ToolButtonIconOnly);
m_pToolBar->setSizePolicy(QSizePolicy::Fixed, QSizePolicy::Expanding);
@ -101,12 +101,12 @@ void nmWxPebiGridViewWidget::createUi()
m_pGridLinesAction->setToolTip(tr("Show Grid Lines"));
m_pGridLinesAction->setCheckable(true);
m_pScalarBarAction = new QAction(
QIcon(gridViewIconPath("Eyes.png")),
QIcon(gridViewIconPath("NmColorScale.png")),
tr("Show Scalar Bar"), this);
m_pScalarBarAction->setToolTip(tr("Show Scalar Bar"));
m_pScalarBarAction->setCheckable(true);
m_pBoundsGridAction = new QAction(
QIcon(gridViewIconPath("CalGrid.png")),
QIcon(gridViewIconPath("NmScaleGrid.png")),
tr("Scale Grid"), this);
m_pBoundsGridAction->setToolTip(tr("Scale Grid"));
m_pBoundsGridAction->setCheckable(true);
@ -123,24 +123,34 @@ void nmWxPebiGridViewWidget::createUi()
nmVTKViewCommandController::ViewCommand_Top);
QAction* pCopyAction = pCommandController->getAction(
nmVTKViewCommandController::ViewCommand_CopyImage);
bool bHasPreviousGroup = false;
if(pZoomOutAction != nullptr) {
m_pToolBar->addAction(pZoomOutAction);
bHasPreviousGroup = true;
}
if(pFitAction != nullptr) {
m_pToolBar->addAction(pFitAction);
bHasPreviousGroup = true;
}
if(pZoomInAction != nullptr) {
m_pToolBar->addAction(pZoomInAction);
bHasPreviousGroup = true;
}
if(pTopAction != nullptr) {
if(bHasPreviousGroup) {
m_pToolBar->addSeparator();
}
m_pToolBar->addAction(pTopAction);
bHasPreviousGroup = true;
}
if(bHasPreviousGroup) {
m_pToolBar->addSeparator();
}
m_pToolBar->addSeparator();
m_pToolBar->addAction(m_pGridLinesAction);
m_pToolBar->addAction(m_pScalarBarAction);
m_pToolBar->addAction(m_pBoundsGridAction);
m_pToolBar->addSeparator();
if(pCopyAction != nullptr) {
m_pToolBar->addSeparator();
m_pToolBar->addAction(pCopyAction);
}
} else {

Loading…
Cancel
Save