Salome HOME
Fix for using Gmsh 4.10
authorAfeef <afeef.badri@gmail.com>
Fri, 24 Jun 2022 13:07:02 +0000 (15:07 +0200)
committerAfeef <afeef.badri@gmail.com>
Wed, 28 Sep 2022 08:10:28 +0000 (10:10 +0200)
Two algorithms from Gmsh 4.10 for generating quad mesh, Packing of Parallelograms and Quasi Structured Quad,
depend on frame/cross-field computations in Gmsh. As such when using these algorithms a class Field is used
(see Field.h in gmsh source). As the class Field also exists in src/SMESHGUI/SMESHGUI_MeshInfo.cxx this cr-
eates an error for displaying the mesh Info.

Hence the Field has been renamed as FieldInfo in src/SMESHGUI/SMESHGUI_MeshInfo.cxx.

src/SMESHGUI/SMESHGUI_MeshInfo.cxx

index 8fe998131bfcfcc2f4288046b8100f88fd935060..cef3451ca362b71173715c1440e942e02bb37f03 100644 (file)
 #include <QVBoxLayout>
 
 ////////////////////////////////////////////////////////////////////////////////
-/// \class Field
-/// \brief Field widget.
+/// \class FieldInfo
+/// \brief FieldInfo widget.
 /// \internal
 ////////////////////////////////////////////////////////////////////////////////
 
-class Field : public QLabel
+class FieldInfo : public QLabel
 {
 public:
-  Field( QWidget*, const QString& = QString() );
+  FieldInfo( QWidget*, const QString& = QString() );
   bool event( QEvent* );
 };
 
 /*!
   \brief Constructor.
   \param parent Parent widget.
-  \param name Field name. Defaults to null string.
+  \param name FieldInfo name. Defaults to null string.
 */
-Field::Field( QWidget* parent, const QString& name ): QLabel( parent )
+FieldInfo::FieldInfo( QWidget* parent, const QString& name ): QLabel( parent )
 {
   setFrameStyle( QLabel::StyledPanel | QLabel::Sunken );
   setAlignment( Qt::AlignCenter );
@@ -100,7 +100,7 @@ Field::Field( QWidget* parent, const QString& name ): QLabel( parent )
 /*!
   \brief Event handler. Redefined from QLabel.
 */
-bool Field::event( QEvent* e )
+bool FieldInfo::event( QEvent* e )
 {
   if ( e->type() == QEvent::DynamicPropertyChange )
   {
@@ -332,12 +332,12 @@ namespace
   /*!
     \brief Create information field.
     \param parent Parent widget.
-    \param name Field's object. Default to null string.
-    \return New field.
+    \param name FieldInfo's object. Default to null string.
+    \return New FieldInfo.
   */
   QLabel* createField( QWidget* parent, const QString& name = QString() )
   {
-    return new Field( parent, name );
+    return new FieldInfo( parent, name );
   }
 
   /*!