FazBrowse GitHub Viewer
|
Trending
|
URL:
|
Home
Tools:
[Download Repo ZIP]
[View Raw Code]
[Original HTTPS Page]
nodeeditor/src/NodeGraphicsObject.hpp at hahaton · DigitalPulseSoftware/nodeeditor · GitHub
Uh oh!
There was an error while loading.
Please reload this page
.
DigitalPulseSoftware
/
nodeeditor
Public
forked from
paceholder/nodeeditor
Notifications
You must be signed in to change notification settings
Fork
0
Star
1
Code
Pull requests
0
Actions
Projects
Security and quality
0
Insights
Additional navigation options
Code
Pull requests
Actions
Projects
Security and quality
Insights
Expand file tree
Breadcrumbs
nodeeditor
/
src
/
NodeGraphicsObject.hpp
Copy path
More file actions
More file actions
Latest commit
History
History
History
102 lines (70 loc) · 1.77 KB
Breadcrumbs
nodeeditor
/
src
/
NodeGraphicsObject.hpp
Copy path
File metadata and controls
102 lines (70 loc) · 1.77 KB
Raw
Copy raw file
Download raw file
Open symbols panel
Edit and raw actions
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
#
pragma
once
#
include
<
QtCore/QUuid
>
#
include
<
QtWidgets/QGraphicsObject
>
#
include
"
Connection.hpp
"
#
include
"
NodeGeometry.hpp
"
#
include
"
NodeState.hpp
"
class
QGraphicsProxyWidget
;
namespace
QtNodes
{
class
FlowScene
;
class
FlowItemEntry
;
//
/ Class reacts on GUI events, mouse clicks and
//
/ forwards painting operation.
class
NodeGraphicsObject
:
public
QGraphicsObject
{
Q_OBJECT
public:
NodeGraphicsObject
(FlowScene &scene,
Node& node);
virtual
~NodeGraphicsObject
();
Node&
node
();
Node
const
&
node
()
const
;
QRectF
boundingRect
()
const
override
;
void
setGeometryChanged
();
//
/ Visits all attached connections and corrects
//
/ their corresponding end points.
void
moveConnections
()
const
;
enum
{ Type = UserType +
1
};
int
type
()
const
override
{
return
Type; }
void
lock
(
bool
locked);
protected:
void
paint
(QPainter* painter,
QStyleOptionGraphicsItem
const
* option,
QWidget* widget =
0
)
override
;
QVariant
itemChange
(GraphicsItemChange change,
const
QVariant &value)
override
;
void
mousePressEvent
(QGraphicsSceneMouseEvent* event)
override
;
void
mouseMoveEvent
(QGraphicsSceneMouseEvent* event)
override
;
void
mouseReleaseEvent
(QGraphicsSceneMouseEvent* event)
override
;
void
hoverEnterEvent
(QGraphicsSceneHoverEvent* event)
override
;
void
hoverLeaveEvent
(QGraphicsSceneHoverEvent* event)
override
;
void
hoverMoveEvent
(QGraphicsSceneHoverEvent *)
override
;
void
mouseDoubleClickEvent
(QGraphicsSceneMouseEvent* event)
override
;
private:
void
embedQWidget
();
private:
FlowScene & _scene;
Node& _node;
bool
_locked;
//
either nullptr or owned by parent QGraphicsItem
QGraphicsProxyWidget * _proxyWidget;
};
}
Back
|
FazBrowse Home
|
New Git URL