From: vsv Date: Thu, 27 Aug 2015 13:38:30 +0000 (+0300) Subject: Issue #780: Make Arrow Tail size and extension line size adaptive to current viewer... X-Git-Tag: V_1.4.0_beta4~225 X-Git-Url: http://git.salome-platform.org/gitweb/?a=commitdiff_plain;h=ec4c89c20d9e981b527288ef230f527e025f4627;p=modules%2Fshaper.git Issue #780: Make Arrow Tail size and extension line size adaptive to current viewer scale --- diff --git a/src/SketcherPrs/SketcherPrs_Angle.cpp b/src/SketcherPrs/SketcherPrs_Angle.cpp index fbdb47391..8603dd444 100644 --- a/src/SketcherPrs/SketcherPrs_Angle.cpp +++ b/src/SketcherPrs/SketcherPrs_Angle.cpp @@ -106,6 +106,9 @@ void SketcherPrs_Angle::Compute(const Handle(PrsMgr_PresentationManager3d)& theP AttributeDoublePtr aVal = aData->real(SketchPlugin_Constraint::VALUE()); SetCustomValue(aVal->value() * PI / 180.0); + myAspect->SetExtensionSize(myAspect->ArrowAspect()->Length()); + myAspect->SetArrowTailSize(myAspect->ArrowAspect()->Length()); + AIS_AngleDimension::Compute(thePresentationManager, thePresentation, theMode); } diff --git a/src/SketcherPrs/SketcherPrs_LengthDimension.cpp b/src/SketcherPrs/SketcherPrs_LengthDimension.cpp index ea58e6515..347d8b12c 100644 --- a/src/SketcherPrs/SketcherPrs_LengthDimension.cpp +++ b/src/SketcherPrs/SketcherPrs_LengthDimension.cpp @@ -55,6 +55,9 @@ void SketcherPrs_LengthDimension::Compute(const Handle(PrsMgr_PresentationManage gp_Pnt aPnt1, aPnt2; if (!getPoints(aPnt1, aPnt2)) return; + myAspect->SetExtensionSize(myAspect->ArrowAspect()->Length()); + myAspect->SetArrowTailSize(myAspect->ArrowAspect()->Length()); + SetFlyout(SketcherPrs_Tools::getFlyoutDistance(myConstraint)); SetMeasuredGeometry(aPnt1, aPnt2, myPlane->impl()); AIS_LengthDimension::Compute(thePresentationManager, thePresentation, theMode); diff --git a/src/SketcherPrs/SketcherPrs_Radius.cpp b/src/SketcherPrs/SketcherPrs_Radius.cpp index a99bdc9af..6fc31d0d5 100644 --- a/src/SketcherPrs/SketcherPrs_Radius.cpp +++ b/src/SketcherPrs/SketcherPrs_Radius.cpp @@ -87,6 +87,9 @@ void SketcherPrs_Radius::Compute(const Handle(PrsMgr_PresentationManager3d)& the SetMeasuredGeometry(aCircle.impl(), anAnchor->impl()); SetCustomValue(aRadius); + myAspect->SetExtensionSize(myAspect->ArrowAspect()->Length()); + myAspect->SetArrowTailSize(myAspect->ArrowAspect()->Length()); + AIS_RadiusDimension::Compute(thePresentationManager, thePresentation, theMode); }