[go: up one dir, main page]

Feature request: neato -n3

For this problem (when edge trajectory is set but we want graphviz make clip_and_install) I want propose new Nop mode.

For implement this we just need here replace useless commands that do nothing

		add_pointf(ND_coord(n), ED_tail_port(e).p);
		add_pointf(ND_coord(head), ED_head_port(e).p);

with

		if(Nop==3 && ED_spl(e)->size>0) { 
			// use first bezier, start point and end point will lost
			if(ED_spl(e)->size>1) 
				fprintf(stderr,
					"edge %s -> %s : setted more than one spline. First used, other dropped.",
					agnameof(n),agnameof(head));
			bezier * bez = ED_spl(e)->list;
			size_t sz = bez->size;
			bez->size = 0;
			pointf * pb = bez->list;
			bez->list = NULL;
			gv_free_splines(e);
			clip_and_install(e, head, pb, sz, &sinfo);
			free(pb);
		}

and here replace

	if (posEdges != AllEdges)

with

	if (posEdges != AllEdges || Nop==3)