Show basic information on selected object. More...
#include <SMESHGUI_MeshInfo.h>
Public Member Functions | |
SMESHGUI_BaseInfo (QWidget *=0) | |
Constructor. More... | |
~SMESHGUI_BaseInfo () | |
Destructor. More... | |
void | showInfo (const SMESH::SelectionProxy &) |
Show information on given object. More... | |
void | clear () |
Reset panel (clear all data). More... | |
void | saveInfo (QTextStream &) |
Write information from panel to output stream. More... | |
Private Types | |
enum | { iStart , iObjectStart = iStart , iName = iObjectStart , iObject , iObjectEnd , iNodesStart = iObjectEnd , iNodes , iNodesEnd , iElementsStart = iNodesEnd , iElementsTitleStart = iElementsStart , iElementsTitle , iElementsTitleEnd , iElementsTotalStart = iElementsTitleEnd , iElementsTotal , iElementsTotalEnd , i0DStart = iElementsTotalEnd , i0D , i0DEnd , iBallsStart = i0DEnd , iBalls , iBallsEnd , i1DStart = iBallsEnd , i1D , i1DEnd , i2DStart = i1DEnd , i2D , i2DTriangles , i2DQuadrangles , i2DPolygons , i2DEnd , i3DStart = i2DEnd , i3D , i3DTetrahedrons , i3DHexahedrons , i3DPyramids , i3DPrisms , i3DHexaPrisms , i3DPolyhedrons , i3DEnd , iElementsEnd = i3DEnd , iEnd , iOther = iEnd } |
enum | { iLabel , iSingle , iTotal = iSingle , iLinear , iQuadratic , iBiQuadratic , iNbColumns } |
typedef QMap< int, QWidget * > | wlist |
typedef QMap< int, wlist > | iwlist |
Private Slots | |
void | updateInfo () |
Update information in panel. More... | |
void | loadMesh () |
Load mesh from a study file. More... | |
Private Member Functions | |
QWidget * | addWidget (QWidget *, int, int, int=1) |
Register widget in a grid. More... | |
QWidget * | widget (int, int) const |
Get registered widget. More... | |
QString | value (int, int) const |
Get text value from registered widget. More... | |
void | setFieldsVisible (int, int, bool) |
Show/hide group(s) of widgets. More... | |
Private Attributes | |
iwlist | myWidgets |
SMESH::SelectionProxy | myProxy |
Show basic information on selected object.
Displays the base information about selected object: mesh, sub-mesh, group or arbitrary ID source.
|
private |
|
private |
|
private |
SMESHGUI_BaseInfo::SMESHGUI_BaseInfo | ( | QWidget * | parent = 0 | ) |
Constructor.
parent | Parent widget. Defaults to 0. |
References addWidget(), clear(), i0D, i0DEnd, i1D, i1DEnd, i2D, i2DEnd, i2DPolygons, i2DQuadrangles, i2DTriangles, i3D, i3DHexahedrons, i3DHexaPrisms, i3DPolyhedrons, i3DPrisms, i3DPyramids, i3DTetrahedrons, iBalls, iBallsEnd, iBiQuadratic, iElementsEnd, iElementsTitle, iElementsTitleEnd, iElementsTotal, iElementsTotalEnd, iEnd, iLabel, iLinear, iName, iNodes, iNodesEnd, iObject, iObjectEnd, iQuadratic, iSingle, iTotal, loadMesh(), MARGIN, and SPACING.
SMESHGUI_BaseInfo::~SMESHGUI_BaseInfo | ( | ) |
Destructor.
|
private |
Register widget in a grid.
w | Widget being added. |
row | Row index in a grid. |
column | Column index in a grid. |
colspan | Number of columns to span in a grid. Defaults to 1. |
References myWidgets.
Referenced by SMESHGUI_BaseInfo().
void SMESHGUI_BaseInfo::clear | ( | ) |
Reset panel (clear all data).
References iElementsEnd, iElementsTotal, iEnd, iName, iNbColumns, iNodes, iObject, iSingle, iTotal, and widget().
Referenced by showInfo(), and SMESHGUI_BaseInfo().
|
privateslot |
Load mesh from a study file.
References SMESH::SelectionProxy::load(), myProxy, and updateInfo().
Referenced by SMESHGUI_BaseInfo().
|
virtual |
Write information from panel to output stream.
out | Text stream output. |
Implements SMESHGUI_Info.
References i0D, i1D, i2D, i2DPolygons, i2DQuadrangles, i2DTriangles, i3D, i3DHexahedrons, i3DHexaPrisms, i3DPolyhedrons, i3DPrisms, i3DPyramids, i3DTetrahedrons, iBalls, iBiQuadratic, iElementsTotal, iLinear, iName, iNodes, iObject, iQuadratic, iSingle, iTotal, and value().
Referenced by SMESHGUI_MeshInfoDlg::dump().
|
private |
void SMESHGUI_BaseInfo::showInfo | ( | const SMESH::SelectionProxy & | proxy | ) |
Show information on given object.
proxy | Object to show information on (mesh, sub-mesh, group, ID source). |
References SMESH::BALL, clear(), SMESH::MeshInfo::count(), SMESH::EDGE, SMESH::ELEM0D, SMESH::FACE, SMESH::SelectionProxy::Group, SMESH::SelectionProxy::groupElementType(), SMESH::SelectionProxy::GroupFilter, SMESH::SelectionProxy::GroupGeom, SMESH::SelectionProxy::GroupStd, i0D, i1D, i2D, i2DEnd, i2DPolygons, i2DQuadrangles, i2DTriangles, i3D, i3DEnd, i3DHexahedrons, i3DHexaPrisms, i3DPolyhedrons, i3DPrisms, i3DPyramids, i3DTetrahedrons, iBalls, iBiQuadratic, iElementsEnd, iElementsTotal, iEnd, iLinear, iName, iNbColumns, iNodes, iObject, iQuadratic, iSingle, SMESH::SelectionProxy::isValid(), iTotal, SMESH::SelectionProxy::Mesh, SMESH::SelectionProxy::meshInfo(), myProxy, SMESH::SelectionProxy::name(), SMESH::NODE, SMDSEntity_0D, SMDSEntity_Ball, SMDSEntity_BiQuad_Penta, SMDSEntity_BiQuad_Quadrangle, SMDSEntity_BiQuad_Triangle, SMDSEntity_Edge, SMDSEntity_Hexa, SMDSEntity_Hexagonal_Prism, SMDSEntity_Last, SMDSEntity_Node, SMDSEntity_Penta, SMDSEntity_Polygon, SMDSEntity_Polyhedra, SMDSEntity_Pyramid, SMDSEntity_Quad_Edge, SMDSEntity_Quad_Hexa, SMDSEntity_Quad_Penta, SMDSEntity_Quad_Polygon, SMDSEntity_Quad_Pyramid, SMDSEntity_Quad_Quadrangle, SMDSEntity_Quad_Tetra, SMDSEntity_Quad_Triangle, SMDSEntity_Quadrangle, SMDSEntity_Tetra, SMDSEntity_Triangle, SMDSEntity_TriQuad_Hexa, SMESH::SelectionProxy::Submesh, SMESH::SelectionProxy::type(), SMESH::VOLUME, and widget().
Referenced by SMESHGUI_MeshInfoDlg::showInfo(), and updateInfo().
|
privateslot |
|
private |
Get text value from registered widget.
row | Row index in a grid. |
column | Column index in a grid. |
References widget().
Referenced by saveInfo().
|
private |
Get registered widget.
row | Row index in a grid. |
column | Column index in a grid. |
References myWidgets.
Referenced by clear(), showInfo(), and value().
|
private |
Referenced by loadMesh(), showInfo(), and updateInfo().
|
private |
Referenced by addWidget(), setFieldsVisible(), and widget().