Computer Assited Medical Intervention Tool Kit  version 4.0
AtomDCProperties.h
Go to the documentation of this file.
1 /*****************************************************************************
2  * $CAMITK_LICENCE_BEGIN$
3  *
4  * CamiTK - Computer Assisted Medical Intervention ToolKit
5  * (c) 2001-2016 Univ. Grenoble Alpes, CNRS, TIMC-IMAG UMR 5525 (GMCAO)
6  *
7  * Visit http://camitk.imag.fr for more information
8  *
9  * This file is part of CamiTK.
10  *
11  * CamiTK is free software: you can redistribute it and/or modify
12  * it under the terms of the GNU Lesser General Public License version 3
13  * only, as published by the Free Software Foundation.
14  *
15  * CamiTK is distributed in the hope that it will be useful,
16  * but WITHOUT ANY WARRANTY; without even the implied warranty of
17  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
18  * GNU Lesser General Public License version 3 for more details.
19  *
20  * You should have received a copy of the GNU Lesser General Public License
21  * version 3 along with CamiTK. If not, see <http://www.gnu.org/licenses/>.
22  *
23  * $CAMITK_LICENCE_END$
24  ****************************************************************************/
25 
26 
27 #ifndef AtomDCProperties_H
28 #define AtomDCProperties_H
29 
30 #include <QObject>
31 #include <QMap>
32 #include <QVector3D>
33 
34 class AtomDC;
47 class AtomDCProperties : public QObject {
48  Q_OBJECT
49 
51  Q_PROPERTY(int index READ getIndex WRITE setIndex )
52 
53 
54  Q_PROPERTY(QVector3D position READ getPosition WRITE setPosition)
55 
56 public:
57 
60 
63 
65  void updateProperties(AtomDC*);
66 
68  void setIndex( int );
70  int getIndex() const;
71 
73  void setPosition(QVector3D);
74 
76  QVector3D getPosition() const;
77 
80  virtual bool event(QEvent* e);
81 
82 private:
85 
86 };
87 
88 
89 #endif
int index
the index property that will be managed in the property dialog
Definition: AtomDCProperties.h:51
void setPosition(QVector3D)
change the atom&#39;s position from the property editor
Definition: AtomDCProperties.cpp:111
QVector3D getPosition() const
get the atom&#39;s position in a form the property editor understands
Definition: AtomDCProperties.cpp:124
virtual bool event(QEvent *e)
intercept signal for dynamic property changed.
Definition: AtomDCProperties.cpp:132
The class AtomDCProperties defines an object that allows interaction of some properties of an atom...
Definition: AtomDCProperties.h:47
The manager of the Atom data.
Definition: AtomDC.h:74
void updateProperties(AtomDC *)
change the currently managed AtomDC and update the value of the properties
Definition: AtomDCProperties.cpp:46
AtomDC * myDC
the currently selected atom&#39;s AtomDC
Definition: AtomDCProperties.h:84
void setIndex(int)
change the atom&#39;s index from the property editor
Definition: AtomDCProperties.cpp:96
int getIndex() const
get the atom&#39;s index in a form the property editor understands
Definition: AtomDCProperties.cpp:103
QVector3D position
the 3D position property
Definition: AtomDCProperties.h:54