nodelabel.h
Go to the documentation of this file.
1 /***************************************************************************
2  SocNetV: Social Network Visualizer
3  version: 2.2
4  Written in Qt
5 
6  nodelabel.h - description
7  -------------------
8  copyright : (C) 2005-2017 by Dimitris B. Kalamaras
9  project site : http://socnetv.org
10 
11  ***************************************************************************/
12 
13 /*******************************************************************************
14 * This program is free software: you can redistribute it and/or modify *
15 * it under the terms of the GNU General Public License as published by *
16 * the Free Software Foundation, either version 3 of the License, or *
17 * (at your option) any later version. *
18 * *
19 * This program is distributed in the hope that it will be useful, *
20 * but WITHOUT ANY WARRANTY; without even the implied warranty of *
21 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
22 * GNU General Public License for more details. *
23 * *
24 * You should have received a copy of the GNU General Public License *
25 * along with this program. If not, see <http://www.gnu.org/licenses/>. *
26 ********************************************************************************/
27 
28 #ifndef NODELABEL_H
29 #define NODELABEL_H
30 
31 #include <QGraphicsTextItem>
32 class Node;
33 
34 static const int TypeLabel = QGraphicsItem::UserType+4;
35 static const int ZValueNodeLabel = 80;
36 
37 class NodeLabel : public QGraphicsTextItem{
38 public:
39  NodeLabel(Node * , const QString &text, const int &size );
40 
41  void removeRefs();
42  enum { Type = UserType + 4 };
43  int type() const { return Type; }
44  void setSize(const int &size);
45  ~NodeLabel();
46  Node* node() { return source; }
47 private:
49 };
50 
51 #endif
~NodeLabel()
Definition: nodelabel.cpp:55
Definition: nodelabel.h:42
void removeRefs()
Definition: nodelabel.cpp:50
Definition: node.h:56
Node * source
Definition: nodelabel.h:48
static const int ZValueNodeLabel
Definition: nodelabel.h:35
Definition: nodelabel.h:37
int type() const
Definition: nodelabel.h:43
Node * node()
Definition: nodelabel.h:46
NodeLabel(Node *, const QString &text, const int &size)
Definition: nodelabel.cpp:33
static const int TypeLabel
Definition: nodelabel.h:34
void setSize(const int &size)
Definition: nodelabel.cpp:44