2 #ifndef SMESHGUI_FUNCTION_PREVIEW_HEADER
3 #define SMESHGUI_FUNCTION_PREVIEW_HEADER
6 #include <SALOMEconfig.h>
7 #include CORBA_SERVER_HEADER(SMESH_Mesh)
8 #include <ExprIntrp_GenExp.hxx>
9 #include <Expr_Array1OfNamedUnknown.hxx>
10 #include <TColStd_Array1OfReal.hxx>
12 class SMESHGUI_FunctionPreview : public QwtPlot
17 SMESHGUI_FunctionPreview( QWidget* );
18 virtual ~SMESHGUI_FunctionPreview();
20 QString function() const;
21 bool isTableFunc() const;
22 void tableFunc( SMESH::double_array& ) const;
23 void interval( double&, double& ) const;
24 int pointsCount() const;
27 bool setParams( const QString&, const double = 0.0, const double = 1.0, const int = 50, const bool = true );
28 bool setParams( const SMESH::double_array&, const double = 0.0, const double = 1.0, const bool = true );
29 void setIsExp( const bool, const bool = true );
32 virtual bool init( const QString& );
33 virtual double funcValue( const double, bool& );
34 virtual bool createTable( SMESH::double_array& );
35 virtual void drawContents( QPainter* );
42 double myXmin, myXmax;
46 SMESH::double_array myTableFunc;
48 Handle(ExprIntrp_GenExp) myExpr;
49 Expr_Array1OfNamedUnknown myVars;
50 TColStd_Array1OfReal myValues;