Add main window menu for auto colorize
parent
db9d8c04c0
commit
29f988aa7b
|
@ -370,6 +370,18 @@ Tips:
|
|||
<source>Toggle rotation</source>
|
||||
<translation>旋转视角</translation>
|
||||
</message>
|
||||
<message>
|
||||
<source>Colorize</source>
|
||||
<translation>着色</translation>
|
||||
</message>
|
||||
<message>
|
||||
<source>Blank</source>
|
||||
<translation>空白</translation>
|
||||
</message>
|
||||
<message>
|
||||
<source>Auto Color</source>
|
||||
<translation>自动着色</translation>
|
||||
</message>
|
||||
</context>
|
||||
<context>
|
||||
<name>ExportPreviewWidget</name>
|
||||
|
|
|
@ -624,6 +624,22 @@ DocumentWindow::DocumentWindow() :
|
|||
|
||||
m_editMenu->addMenu(m_markAsMenu);
|
||||
|
||||
m_colorizeAsMenu = new QMenu(tr("Colorize"));
|
||||
|
||||
m_colorizeAsBlankAction = new QAction(tr("Blank"), this);
|
||||
connect(m_colorizeAsBlankAction, &QAction::triggered, [=]() {
|
||||
m_graphicsWidget->fadeSelected();
|
||||
});
|
||||
m_colorizeAsMenu->addAction(m_colorizeAsBlankAction);
|
||||
|
||||
m_colorizeAsAutoAction = new QAction(tr("Auto Color"), this);
|
||||
connect(m_colorizeAsAutoAction, &QAction::triggered, [=]() {
|
||||
m_graphicsWidget->colorizeSelected();
|
||||
});
|
||||
m_colorizeAsMenu->addAction(m_colorizeAsAutoAction);
|
||||
|
||||
m_editMenu->addMenu(m_colorizeAsMenu);
|
||||
|
||||
m_selectAllAction = new QAction(tr("Select All"), this);
|
||||
connect(m_selectAllAction, &QAction::triggered, m_graphicsWidget, &SkeletonGraphicsWidget::selectAll);
|
||||
m_editMenu->addAction(m_selectAllAction);
|
||||
|
@ -652,6 +668,8 @@ DocumentWindow::DocumentWindow() :
|
|||
m_switchXzAction->setEnabled(m_graphicsWidget->hasSelection());
|
||||
m_setCutFaceAction->setEnabled(m_graphicsWidget->hasSelection());
|
||||
m_clearCutFaceAction->setEnabled(m_graphicsWidget->hasCutFaceAdjustedNodesSelection());
|
||||
m_colorizeAsBlankAction->setEnabled(m_graphicsWidget->hasSelection());
|
||||
m_colorizeAsAutoAction->setEnabled(m_graphicsWidget->hasSelection());
|
||||
m_alignToGlobalCenterAction->setEnabled(m_graphicsWidget->hasSelection() && m_document->originSettled());
|
||||
m_alignToGlobalVerticalCenterAction->setEnabled(m_graphicsWidget->hasSelection() && m_document->originSettled());
|
||||
m_alignToGlobalHorizontalCenterAction->setEnabled(m_graphicsWidget->hasSelection() && m_document->originSettled());
|
||||
|
|
|
@ -153,6 +153,10 @@ private:
|
|||
QAction *m_markAsNoneAction;
|
||||
QAction *m_markAsActions[(int)BoneMark::Count - 1];
|
||||
|
||||
QMenu *m_colorizeAsMenu;
|
||||
QAction *m_colorizeAsBlankAction;
|
||||
QAction *m_colorizeAsAutoAction;
|
||||
|
||||
QMenu *m_viewMenu;
|
||||
QAction *m_resetModelWidgetPosAction;
|
||||
QAction *m_toggleWireframeAction;
|
||||
|
|
Loading…
Reference in New Issue