-
Notifications
You must be signed in to change notification settings - Fork 11
NodeTypes: NodeValue
Akash Bora edited this page Jun 4, 2023
·
11 revisions
Node Value is a node which contains a variable as the value on it, it has one output socket which can connect to multiple inputs of other nodes.
node = NodeValue(canvas, value=1, text="Value 1")
Parameter | Description |
---|---|
canvas | parent canvas where the node will be spawn |
height | height of the node |
width | width of the node |
value | variable which contains the value |
fg_color | foreground color of the node |
text | change the text of the node |
text_color | change the text color |
font | change the font of text |
justify | change the text anchor |
highlightcolor | hover color of the node |
border_width | adds an additional border to the nodes |
border_color | border color of the node if border_width>0 |
hover | disable/enable the hover effect |
socket_color | change the color of the sockets |
socket_hover_color | change the hover color of the sockets |
socket_hover | enable/disable the socket hover |
socket_radius | change the size of the sockets |
corner_radius | change the roundness of the node frame |
side | change the side of the socket (left or right) |
x | specify the x spawn location |
y | specify the y spawn location |
fixed | removes the delete key binding, makes the node non-removable |
click_command | add a command when the node is clicked |
- .configure(args...): change some attributes of the node including the value.
- .destroy(): deletes the node from the canvas.
- .exists(): check if node exist in the canvas.
- .get(): get the current output value.