"Hidden faces transparency",
Config_Prop::DblSpin,
"0.8");
+
std::ostringstream aStream;
aStream << SketcherPrs_Tools::getDefaultArrowSize();
Config_PropManager::registerProp("Visualization", "dimension_arrow_size",
"Feature items in Object Browser",
Config_Prop::Color, FEATURE_ITEM_COLOR);
+ Config_PropManager::registerProp("Visualization", "zoom_trihedron_arrows",
+ "Zoom trihedron arrows", Config_Prop::Boolean, "false");
+
+ Config_PropManager::registerProp("Visualization", "axis_arrow_size",
+ "Axis arrow size", Config_Prop::IntSpin, "10");
+
Config_PropManager::registerProp("Shortcuts", "add_parameter_shortcut",
"Add parameter in parameters manager dialog",
Config_Prop::Shortcut, "Ctrl+A");
return;
bool isModified = false;
+ double aLen = aView->Convert(SketcherPrs_Tools::getConfigArrowSize());
ModuleBase_Operation* aCurrentOperation = myWorkshop->currentOperation();
if (aCurrentOperation &&
(PartSet_SketcherMgr::isSketchOperation(aCurrentOperation) ||
sketchMgr()->isNestedSketchOperation(aCurrentOperation) ||
(aCurrentOperation->id() == "Measurement")))
{
- double aLen = aView->Convert(SketcherPrs_Tools::getConfigArrowSize());
double aPrevLen = SketcherPrs_Tools::getArrowSize();
SketcherPrs_Tools::setArrowSize(aLen);
isModified = true;
}
}
- if (isModified)
- aDisplayer->updateViewer();
}
+ // Manage trihedron arrows
+ if (Config_PropManager::boolean("Visualization", "zoom_trihedron_arrows")) {
+ Handle(AIS_Trihedron) aTrihedron = aViewer->trihedron();
+ if (!aTrihedron.IsNull()) {
+ double aAxLen =
+ aView->Convert(Config_PropManager::integer("Visualization", "axis_arrow_size"));
+ Handle(Prs3d_DatumAspect) aDatumAspect = aTrihedron->Attributes()->DatumAspect();
+ double aAxisLen = aDatumAspect->AxisLength(Prs3d_DP_XAxis);
+ aDatumAspect->SetAttribute(Prs3d_DP_ShadingConeLengthPercent, aAxLen / aAxisLen);
+ aTrihedron->Attributes()->SetDatumAspect(aDatumAspect);
+ aContext->Redisplay(aTrihedron, false);
+ isModified = true;
+ }
+ }
+ if (isModified)
+ aDisplayer->updateViewer();
}
//******************************************************