License Public Domain
Lines 22
Keywords
flow charts (4) graphics (9) graphs (2) nodebox (8)
Included in this Library
Permissions
Owner: Theodore Test
Viewable by Everyone
Editable by All Siafoo Users
Hide
Free your code from a slow death on your hard drive Join Siafoo Now or Learn More

Nodebox Flow Chart Nodes Atom Feed 0

In Brief A few functions that draw simple nodes for use in a flow chart of differing bounding path shapes. Should eventually add a generic node class to enable complex node interactions and cut down on C/V code reuse/abuse.... more
# 's
 1from custom_primitives import diamond_path
2from utility_geometry import centered_text_path
3
4def named_rect_node(arg_x,arg_y,arg_width,arg_height,text_string='',round_edges=0.0,draw_it=True):
5 r = rect(arg_x,arg_y,arg_width,arg_height,roundness=round_edges,draw=draw_it)
6 tp = centered_text_path(text_string,r)
7 if draw_it:
8 drawpath(tp)
9 return r,tp
10
11
12def named_diamond_node(arg_x,arg_y,arg_width,arg_height,text_string='',draw_it=True):
13 d = diamond_path(arg_x,arg_y,arg_width,arg_height,draw=draw_it)
14 tp = centered_text_path(text_string,d)
15 if draw_it:
16 drawpath(tp)
17 return d,tp
18
19def named_oval_node(arg_x,arg_y,arg_width,arg_height,text_string='',draw_it=True):
20 o = oval(arg_x,arg_y,arg_width,arg_height,draw=draw_it)
21 tp = centered_text_path(text_string,o)
22 if draw_it:
23 drawpath(tp)
24 return o,tp

A few functions that draw simple nodes for use in a flow chart of differing bounding path shapes. Should eventually add a generic node class to enable complex node interactions and cut down on C/V code reuse/abuse.

Dependent on the Nodebox environment.

http://www.siafoo.net/image/68