Salome HOME
Mantis issues 0021432 and 0021404: MakeFace[Wires] should generate exception on attem...
[modules/geom.git] / src / OBJECT / GEOM_Actor.cxx
index 3e2d7a1b1a4e7cf3c07015d25b992aaa6b78cc33..bc9c5c9f19dee6f0d1792b8d58a7d30acb3cac60 100644 (file)
@@ -497,6 +497,12 @@ void GEOM_Actor::SetWireframeProperty(vtkProperty* Prop)
   myWireframeFaceActor->SetProperty(Prop);
 }
 
+
+vtkProperty* GEOM_Actor::GetWireframeProperty()
+{
+  return myWireframeFaceActor->GetProperty();
+}
+
 void GEOM_Actor::SetShadingProperty(vtkProperty* Prop)
 {
 #ifdef MYDEBUG
@@ -506,6 +512,12 @@ void GEOM_Actor::SetShadingProperty(vtkProperty* Prop)
 }
 
 
+vtkProperty* GEOM_Actor::GetShadingProperty()
+{
+  return myShadingFaceProp;
+}
+
+
 void GEOM_Actor::Render(vtkRenderer *ren, vtkMapper *theMapper)
 {
 #ifdef MYDEBUG
@@ -687,6 +699,8 @@ void GEOM_Actor::SetColor(vtkFloatingPointType r,vtkFloatingPointType g,vtkFloat
     myOneFaceEdgeActor->GetProperty()->SetColor(r,g,b);          // standalone face edge color (Wireframe)
     mySharedEdgeActor->GetProperty()->SetColor(r,g,b);           // share edge color (Wireframe)
   }
+
+  StoreBoundaryColors();
 }
 
 void GEOM_Actor::GetColor(vtkFloatingPointType& r,vtkFloatingPointType& g,vtkFloatingPointType& b)
@@ -993,6 +1007,27 @@ void GEOM_Actor::StoreIsoNumbers()
   myWireframeFaceSource->GetNbIso(myNbIsos[0], myNbIsos[1]);
 }
 
+void GEOM_Actor::SetIsosWidth(const int width) {
+  myWireframeFaceActor->GetProperty()->SetLineWidth(width);
+}
+
+int GEOM_Actor::GetIsosWidth() const {
+  return (int)myWireframeFaceActor->GetProperty()->GetLineWidth();
+}
+
+void GEOM_Actor::SetWidth(const int width) {
+  myIsolatedEdgeActor->GetProperty()->SetLineWidth(width);
+  myOneFaceEdgeActor->GetProperty()->SetLineWidth(width);
+  mySharedEdgeActor->GetProperty()->SetLineWidth(width);
+  myHighlightProp->SetLineWidth(width);
+  myPreHighlightProp->SetLineWidth(width+1);
+
+}
+
+int GEOM_Actor::GetWidth() const {
+  return (int)myIsolatedEdgeActor->GetProperty()->GetLineWidth();
+}
+    
 void GEOM_Actor::RestoreIsoNumbers()
 {
   if ( myNbIsos[0] > 0 || myNbIsos[1] > 0 )
@@ -1008,7 +1043,8 @@ void GEOM_Actor::ResetIsoNumbers()
 
 void GEOM_Actor::StoreBoundaryColors()
 {
-  mySharedEdgeActor->GetProperty()->GetColor(myEdgesInWireframeColor);
+  myShadingFaceProp->GetColor(myEdgesInWireframeColor);
+
 }
  
 void GEOM_Actor::RestoreBoundaryColors()