[Gui] Add command and task for unified measurement facility
This commit is contained in:
@@ -76,6 +76,7 @@
|
||||
#include "SelectionObject.h"
|
||||
#include "SoAxisCrossKit.h"
|
||||
#include "SoFCOffscreenRenderer.h"
|
||||
#include "TaskMeasure.h"
|
||||
#include "TextureMapping.h"
|
||||
#include "Tools.h"
|
||||
#include "Tree.h"
|
||||
@@ -3189,6 +3190,38 @@ bool StdCmdMeasureDistance::isActive()
|
||||
return false;
|
||||
}
|
||||
|
||||
//===========================================================================
|
||||
// Std_Measure
|
||||
// this is the Unified Measurement Facility Measure command
|
||||
//===========================================================================
|
||||
|
||||
|
||||
DEF_STD_CMD_A(StdCmdMeasure)
|
||||
|
||||
StdCmdMeasure::StdCmdMeasure()
|
||||
:Command("Std_Measure")
|
||||
{
|
||||
sGroup = "Measure";
|
||||
sMenuText = QT_TR_NOOP("&Measure");
|
||||
sToolTipText = QT_TR_NOOP("Measure a feature");
|
||||
sWhatsThis = "Std_Measure";
|
||||
sStatusTip = QT_TR_NOOP("Measure a feature");
|
||||
sPixmap = "umf-measurement";
|
||||
}
|
||||
|
||||
void StdCmdMeasure::activated(int iMsg)
|
||||
{
|
||||
Q_UNUSED(iMsg);
|
||||
|
||||
TaskMeasure *task = new TaskMeasure();
|
||||
Gui::Control().showDialog(task);
|
||||
}
|
||||
|
||||
|
||||
bool StdCmdMeasure::isActive(){
|
||||
return true;
|
||||
}
|
||||
|
||||
//===========================================================================
|
||||
// Std_SceneInspector
|
||||
//===========================================================================
|
||||
@@ -4117,6 +4150,7 @@ void CreateViewStdCommands()
|
||||
rcCmdMgr.addCommand(new StdCmdTreeCollapse());
|
||||
rcCmdMgr.addCommand(new StdCmdTreeSelectAllInstances());
|
||||
rcCmdMgr.addCommand(new StdCmdMeasureDistance());
|
||||
rcCmdMgr.addCommand(new StdCmdMeasure());
|
||||
rcCmdMgr.addCommand(new StdCmdSceneInspector());
|
||||
rcCmdMgr.addCommand(new StdCmdTextureMapping());
|
||||
rcCmdMgr.addCommand(new StdCmdDemoMode());
|
||||
|
||||
Reference in New Issue
Block a user