Commit e07f74c6 authored by Malte R's avatar Malte R
Browse files

Fix GraphWidget.update() crashing when called without vprops or eprops argument.

This fixes interactive_window() crashing when called with window argument but without vprops or eprops.
parent 4e66070a
Pipeline #746 passed with stage
in 119 minutes and 26 seconds
...@@ -20,6 +20,8 @@ ...@@ -20,6 +20,8 @@
import numpy import numpy
import copy
from .. import GraphView, PropertyMap, ungroup_vector_property, \ from .. import GraphView, PropertyMap, ungroup_vector_property, \
group_vector_property, infect_vertex_property, edge_endpoint_property, _prop group_vector_property, infect_vertex_property, edge_endpoint_property, _prop
from .cairo_draw import * from .cairo_draw import *
...@@ -381,6 +383,9 @@ class GraphWidget(Gtk.DrawingArea): ...@@ -381,6 +383,9 @@ class GraphWidget(Gtk.DrawingArea):
nodesfirst=None, display_props=None, nodesfirst=None, display_props=None,
fit_view=True, bg_color=None, **kwargs): fit_view=True, bg_color=None, **kwargs):
vprops = {} if vprops is None else copy.copy(vprops)
eprops = {} if eprops is None else copy.copy(eprops)
props, kwargs = parse_props("vertex", kwargs) props, kwargs = parse_props("vertex", kwargs)
vprops.update(props) vprops.update(props)
props, kwargs = parse_props("edge", kwargs) props, kwargs = parse_props("edge", kwargs)
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment