#include <StdMeshersGUI_SubShapeSelectorWdg.h>
StdMeshersGUI_SubShapeSelectorWdg::StdMeshersGUI_SubShapeSelectorWdg |
( |
QWidget * |
parent = 0 , |
|
|
TopAbs_ShapeEnum |
subShType = TopAbs_EDGE , |
|
|
const bool |
toShowList = true , |
|
|
const bool |
toShowActivateBtn = false |
|
) |
| |
StdMeshersGUI_SubShapeSelectorWdg::~StdMeshersGUI_SubShapeSelectorWdg |
( |
| ) |
|
Destructor.
References SMESH::GetViewWindow(), myEntry, myFilter, myGeomFilters, myMainShape, myParamValue, myPreviewActor, myRenderer, mySelectionMgr, mySMESHGUI, and SMESH_PreviewActorsCollection::RemoveFromRender().
void StdMeshersGUI_SubShapeSelectorWdg::ActivateSelection |
( |
bool |
toActivate | ) |
|
|
slot |
void StdMeshersGUI_SubShapeSelectorWdg::ClearSelected |
( |
| ) |
|
GEOM::GEOM_Object_var StdMeshersGUI_SubShapeSelectorWdg::GetGeomObjectByEntry |
( |
const QString & |
theEntry | ) |
|
|
static |
TopoDS_Shape StdMeshersGUI_SubShapeSelectorWdg::GetGeomShape |
( |
| ) |
|
SMESH::long_array_var StdMeshersGUI_SubShapeSelectorWdg::GetListOfIDs |
( |
| ) |
|
int StdMeshersGUI_SubShapeSelectorWdg::GetListSize |
( |
| ) |
|
TopoDS_Shape StdMeshersGUI_SubShapeSelectorWdg::GetMainShape |
( |
| ) |
|
const char * StdMeshersGUI_SubShapeSelectorWdg::GetMainShapeEntry |
( |
| ) |
|
vtkRenderer* StdMeshersGUI_SubShapeSelectorWdg::GetRenderer |
( |
| ) |
|
const QList<int>& StdMeshersGUI_SubShapeSelectorWdg::GetSelectedIDs |
( |
| ) |
const |
TopoDS_Shape StdMeshersGUI_SubShapeSelectorWdg::GetTopoDSByEntry |
( |
const QString & |
theEntry | ) |
|
|
static |
QString StdMeshersGUI_SubShapeSelectorWdg::GetValue |
( |
| ) |
const |
void StdMeshersGUI_SubShapeSelectorWdg::init |
( |
| ) |
|
|
private |
Create a layout, initialize fields.
References ActivateSelection(), SMESH::GetSelectionMgr(), SMESH::GetSelector(), SMESHGUI::GetSMESHGUI(), SMESH::GetViewWindow(), myActivateButton, myAddButton, myFilter, myListOfIDs, myListWidget, myNextButton, myParamValue, myPrevButton, myRemoveButton, mySelectedIDs, mySelectionMgr, mySelector, mySMESHGUI, onAdd(), onListSelectionChanged(), onNext(), onPrevious(), onRemove(), selectionIntoArgument(), and updateState().
void StdMeshersGUI_SubShapeSelectorWdg::onAdd |
( |
| ) |
|
|
privateslot |
void StdMeshersGUI_SubShapeSelectorWdg::onListSelectionChanged |
( |
| ) |
|
|
privateslot |
void StdMeshersGUI_SubShapeSelectorWdg::onNext |
( |
| ) |
|
|
privateslot |
void StdMeshersGUI_SubShapeSelectorWdg::onPrevious |
( |
| ) |
|
|
privateslot |
void StdMeshersGUI_SubShapeSelectorWdg::onRemove |
( |
| ) |
|
|
privateslot |
void StdMeshersGUI_SubShapeSelectorWdg::selectionChanged |
( |
| ) |
|
|
signal |
void StdMeshersGUI_SubShapeSelectorWdg::selectionIntoArgument |
( |
| ) |
|
|
privateslot |
References GetGeomObjectByEntry(), SMESH_PreviewActorsCollection::GetIndexByShape(), Handle(), SMESH_PreviewActorsCollection::HighlightID(), myAddButton, myEntry, myListWidget, myMaxSize, myPreviewActor, myRemoveButton, mySelectedIDs, mySelectionMgr, mySubShType, and shapeSelected().
Referenced by ActivateSelection(), ClearSelected(), and init().
void StdMeshersGUI_SubShapeSelectorWdg::setFilter |
( |
| ) |
|
|
private |
Install filters to select sub-shapes of mySubShType or their groups.
void StdMeshersGUI_SubShapeSelectorWdg::SetGeomShapeEntry |
( |
const QString & |
theEntry, |
|
|
const QString & |
theMainShapeEntry |
|
) |
| |
bool StdMeshersGUI_SubShapeSelectorWdg::SetListOfIDs |
( |
SMESH::long_array_var |
theIds | ) |
|
References SMESH_PreviewActorsCollection::IsValidIndex(), myListOfIDs, myListWidget, myMainShape, myPreviewActor, mySelectedIDs, and onAdd().
Referenced by StdMeshersGUI_NbSegmentsCreator::buildFrame(), StdMeshersGUI_StdHypothesisCreator::makeReverseEdgesWdg(), StdMeshersGUI_PropagationHelperWdg::onAdd(), StdMeshersGUI_QuadrangleParamCreator::retrieveParams(), and StdMeshersGUI_StdHypothesisCreator::stdParams().
void StdMeshersGUI_SubShapeSelectorWdg::SetMaxSize |
( |
int |
aMaxSize | ) |
|
void StdMeshersGUI_SubShapeSelectorWdg::shapeSelected |
( |
| ) |
|
|
signal |
void StdMeshersGUI_SubShapeSelectorWdg::ShowPreview |
( |
bool |
visible | ) |
|
void StdMeshersGUI_SubShapeSelectorWdg::updateButtons |
( |
| ) |
|
|
private |
References SMESH_PreviewActorsCollection::chunkSize(), SMESH_PreviewActorsCollection::count(), SMESH_PreviewActorsCollection::currentChunk(), SMESH_PreviewActorsCollection::hasNext(), SMESH_PreviewActorsCollection::hasPrevious(), myInfoLabel, myNextButton, myPrevButton, and myPreviewActor.
Referenced by onNext(), onPrevious(), and updateState().
void StdMeshersGUI_SubShapeSelectorWdg::updateState |
( |
| ) |
|
|
private |
References SMESH_PreviewActorsCollection::AddToRender(), SMESH::GetViewWindow(), SMESH_PreviewActorsCollection::Init(), myAddButton, myEntry, myGeomShape, myInfoLabel, myIsShown, myListWidget, myMainShape, myNextButton, myPrevButton, myPreviewActor, myRenderer, mySelectedIDs, mySelector, mySMESHGUI, mySubShType, SMESH_PreviewActorsCollection::SetSelector(), SMESH_PreviewActorsCollection::SetShown(), and updateButtons().
Referenced by init(), and SetGeomShapeEntry().
QPushButton* StdMeshersGUI_SubShapeSelectorWdg::myActivateButton |
|
private |
QPushButton* StdMeshersGUI_SubShapeSelectorWdg::myAddButton |
|
private |
std::string StdMeshersGUI_SubShapeSelectorWdg::myEntry |
|
private |
TopoDS_Shape StdMeshersGUI_SubShapeSelectorWdg::myGeomShape |
|
private |
QLabel* StdMeshersGUI_SubShapeSelectorWdg::myInfoLabel |
|
private |
bool StdMeshersGUI_SubShapeSelectorWdg::myIsShown |
|
private |
QList<int> StdMeshersGUI_SubShapeSelectorWdg::myListOfIDs |
|
private |
QListWidget* StdMeshersGUI_SubShapeSelectorWdg::myListWidget |
|
private |
std::string StdMeshersGUI_SubShapeSelectorWdg::myMainEntry |
|
private |
TopoDS_Shape StdMeshersGUI_SubShapeSelectorWdg::myMainShape |
|
private |
int StdMeshersGUI_SubShapeSelectorWdg::myMaxSize |
|
private |
SMESH::SMESH_Mesh_var StdMeshersGUI_SubShapeSelectorWdg::myMesh |
|
private |
QPushButton* StdMeshersGUI_SubShapeSelectorWdg::myNextButton |
|
private |
QString StdMeshersGUI_SubShapeSelectorWdg::myParamValue |
|
private |
QPushButton* StdMeshersGUI_SubShapeSelectorWdg::myPrevButton |
|
private |
QPushButton* StdMeshersGUI_SubShapeSelectorWdg::myRemoveButton |
|
private |
vtkRenderer* StdMeshersGUI_SubShapeSelectorWdg::myRenderer |
|
private |
QList<int> StdMeshersGUI_SubShapeSelectorWdg::mySelectedIDs |
|
private |
LightApp_SelectionMgr* StdMeshersGUI_SubShapeSelectorWdg::mySelectionMgr |
|
private |
SVTK_Selector* StdMeshersGUI_SubShapeSelectorWdg::mySelector |
|
private |
SMESHGUI* StdMeshersGUI_SubShapeSelectorWdg::mySMESHGUI |
|
private |
TopAbs_ShapeEnum StdMeshersGUI_SubShapeSelectorWdg::mySubShType |
|
private |