Version: 9.16.0
Plot2d_ViewModel.h
Go to the documentation of this file.
1// Copyright (C) 2007-2026 CEA, EDF, OPEN CASCADE
2//
3// Copyright (C) 2003-2007 OPEN CASCADE, EADS/CCR, LIP6, CEA/DEN,
4// CEDRAT, EDF R&D, LEG, PRINCIPIA R&D, BUREAU VERITAS
5//
6// This library is free software; you can redistribute it and/or
7// modify it under the terms of the GNU Lesser General Public
8// License as published by the Free Software Foundation; either
9// version 2.1 of the License, or (at your option) any later version.
10//
11// This library is distributed in the hope that it will be useful,
12// but WITHOUT ANY WARRANTY; without even the implied warranty of
13// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
14// Lesser General Public License for more details.
15//
16// You should have received a copy of the GNU Lesser General Public
17// License along with this library; if not, write to the Free Software
18// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
19//
20// See http://www.salome-platform.org/ or email : webmaster.salome@opencascade.com
21//
22
23#if !defined(_PLOT2D_VIEWMODEL_H)
24#define _PLOT2D_VIEWMODEL_H
25
26#include "Plot2d.h"
27#include "SUIT_ViewModel.h"
28#include <qwt_plot_item.h>
29
30class SUIT_ViewWindow;
31class SUIT_Desktop;
33class Plot2d_Prs;
34class QString;
35class QMenu;
36
38{
39 Q_OBJECT
40
41public:
42 static QString Type() { return "Plot2d"; }
43
44 Plot2d_Viewer(bool theAutoDel = false);
46
47 virtual void setViewManager( SUIT_ViewManager* );
48 virtual SUIT_ViewWindow* createView(SUIT_Desktop* theDesktop);
49 virtual QString getType() const { return Type(); }
50 virtual void contextMenuPopup(QMenu*);
51 Plot2d_Prs* getPrs() const { return myPrs; };
52 void setPrs(Plot2d_Prs* thePrs);
53 void update();
54 void clearPrs();
55 void setAutoDel(bool theDel);
56
57signals:
59
60protected slots:
61 void onChangeBgColor();
62 void onDumpView();
63 void onShowToolbar();
64 virtual void onCloneView( Plot2d_ViewFrame*, Plot2d_ViewFrame* );
65 virtual void onClicked( const QVariant&, int );
66
67private:
70};
71
72#endif // !defined(_PLOT2D_VIEWMODEL_H)
73
#define PLOT2D_EXPORT
Definition: Plot2d.h:36
Definition: Plot2d_Prs.h:30
Definition: Plot2d_ViewFrame.h:67
Definition: Plot2d_ViewModel.h:38
bool myAutoDel
Definition: Plot2d_ViewModel.h:69
void viewCloned(SUIT_ViewWindow *)
static QString Type()
Definition: Plot2d_ViewModel.h:42
Plot2d_Prs * getPrs() const
Definition: Plot2d_ViewModel.h:51
virtual QString getType() const
Definition: Plot2d_ViewModel.h:49
Plot2d_Prs * myPrs
Definition: Plot2d_ViewModel.h:68
Definition: SUIT_Desktop.h:47
Definition: SUIT_ViewManager.h:50
Definition: SUIT_ViewModel.h:47
virtual void contextMenuPopup(QMenu *)
Definition: SUIT_ViewModel.h:69
virtual SUIT_ViewWindow * createView(SUIT_Desktop *theDesktop)
Definition: SUIT_ViewModel.cxx:77
virtual void setViewManager(SUIT_ViewManager *theViewManager)
Definition: SUIT_ViewModel.cxx:85
Definition: SUIT_ViewWindow.h:42
int Type
Definition: VTKViewer_Actor.h:62