graph_tool.draw.GraphWindow#

class graph_tool.draw.GraphWindow(g, pos, geometry, vprops=None, eprops=None, vorder=None, eorder=None, nodesfirst=False, update_layout=False, **kwargs)[source]#

Interactive GTK+ window containing a GraphWidget.

Parameters:
gGraph

Graph to be drawn.

posVertexPropertyMap

Vector-valued vertex property map containing the x and y coordinates of the vertices.

geometrytuple

Widget geometry.

vpropsdict (optional, default: None)

Dictionary with the vertex properties. Individual properties may also be given via the vertex_<prop-name> parameters, where <prop-name> is the name of the property.

epropsdict (optional, default: None)

Dictionary with the edge properties. Individual properties may also be given via the edge_<prop-name> parameters, where <prop-name> is the name of the property.

vorderVertexPropertyMap (optional, default: None)

If provided, defines the relative order in which the vertices are drawn.

eorderEdgePropertyMap (optional, default: None)

If provided, defines the relative order in which the edges are drawn.

nodesfirstbool (optional, default: False)

If True, the vertices are drawn first, otherwise the edges are.

update_layoutbool (optional, default: True)

If True, the layout will be updated dynamically.

**kwargs

Any extra parameters are passed to GraphWidget and cairo_draw().