1
0
mirror of https://git.dev.opencascade.org/repos/occt.git synced 2025-08-09 13:22:24 +03:00

0029988: AIS_Shape - SetWidth() and SetColor() has no effect for FaceBoundary

AIS_Shape SetWidth and SetColor methods now propagate modifications to FaceBoundary aspect.
This commit is contained in:
kgv
2018-09-10 18:44:17 +03:00
committed by bugmaster
parent c60ec7f521
commit 7604a15365
6 changed files with 102 additions and 68 deletions

View File

@@ -77,6 +77,7 @@ AIS_ColoredShape::AIS_ColoredShape (const TopoDS_Shape& theShape)
myDrawer->SetFreeBoundaryAspect (myDrawer->LineAspect());
myDrawer->SetUnFreeBoundaryAspect(myDrawer->LineAspect());
myDrawer->SetSeenLineAspect (myDrawer->LineAspect());
myDrawer->SetFaceBoundaryAspect (myDrawer->LineAspect());
}
//=======================================================================
@@ -90,6 +91,7 @@ AIS_ColoredShape::AIS_ColoredShape (const Handle(AIS_Shape)& theShape)
myDrawer->SetFreeBoundaryAspect (myDrawer->LineAspect());
myDrawer->SetUnFreeBoundaryAspect(myDrawer->LineAspect());
myDrawer->SetSeenLineAspect (myDrawer->LineAspect());
myDrawer->SetFaceBoundaryAspect (myDrawer->LineAspect());
if (theShape->HasMaterial())
{
SetMaterial (theShape->Material());
@@ -236,6 +238,10 @@ void AIS_ColoredShape::SetColor (const Quantity_Color& theColor)
{
aDrawer->WireAspect()->SetColor (theColor);
}
if (aDrawer->HasOwnFaceBoundaryAspect())
{
aDrawer->FaceBoundaryAspect()->SetColor (theColor);
}
}
}
@@ -266,6 +272,10 @@ void AIS_ColoredShape::SetWidth (const Standard_Real theLineWidth)
{
aDrawer->WireAspect()->SetWidth (theLineWidth);
}
if (aDrawer->HasOwnFaceBoundaryAspect())
{
aDrawer->FaceBoundaryAspect()->SetWidth (theLineWidth);
}
}
}