# HG changeset patch # User ladanyi # Date 1136558644 0 # Node ID 05b0e8d057a6ce2ef3af8fcca0a16b57d5aee84c # Parent 2c3f6c7e01b443eee02d5a37872415700bdd7155 Set arrow coordinates when creating a new edge. diff -r 2c3f6c7e01b4 -r 05b0e8d057a6 gui/graph_displayer_canvas-event.cc --- a/gui/graph_displayer_canvas-event.cc Fri Jan 06 14:36:46 2006 +0000 +++ b/gui/graph_displayer_canvas-event.cc Fri Jan 06 14:44:04 2006 +0000 @@ -453,6 +453,12 @@ target_item->get_bounds(x1, y1, x2, y2); coos.push_back(Gnome::Art::Point((x1+x2)/2,(y1+y2)/2)); + // set the coordinates of the arrow on the new edge + MapStorage& ms = mytab.mapstorage; + ms.arrow_pos.set(active_edge, + (ms.coords[ms.graph.source(active_edge)] + + ms.coords[ms.graph.target(active_edge)])/ 2.0); + //drawing new edge edgesmap[active_edge]=new BrokenEdge(displayed_graph, active_edge, *this);