#include "XGUI_FacesPanel.h"
+#include <Config_PropManager.h>
#include <Events_Loop.h>
-#include "GeomAlgoAPI_CompoundBuilder.h"
+#include <GeomAlgoAPI_CompoundBuilder.h>
#include <ModelAPI_Events.h>
myHiddenOrTransparent = new QCheckBox(tr("Transparent"), aContent);
myListView = new ModuleBase_ListView(aContent, "", "Hidden/transparent faces in 3D view");
- connect(myListView->getControl(), SIGNAL(itemSelectionChanged()), SLOT(onListSelection()));
connect(myListView, SIGNAL(deleteActionClicked()), SLOT(onDeleteItem()));
aMainLayout->addWidget(myHiddenOrTransparent, 0, 0);
}
}
+//********************************************************************
+bool XGUI_FacesPanel::useTransparency() const
+{
+ return myHiddenOrTransparent->isChecked();
+}
+
//********************************************************************
void XGUI_FacesPanel::restoreObjects(const std::set<ObjectPtr>& theHiddenObjects)
{
aHiddenSubShapes.Append(aShape);
}
isModified = aResultPrs->setSubShapeHidden(aHiddenSubShapes);
+ double aTransparency = !useTransparency() ? 1
+ : Config_PropManager::real("Visualization", "hidden_face_transparency");
+ aResultPrs->setHiddenSubShapeTransparency(aTransparency);
return isModified;
}