From cb17aef2be5efbfd94b55b8843b3c91333f940d6 Mon Sep 17 00:00:00 2001 From: Erwan Jahier <erwan.jahier@univ-grenoble-alpes.fr> Date: Fri, 17 Dec 2021 13:36:26 +0100 Subject: [PATCH] fix: Add arrow back in dot visu for directed graphs --- tools/rdbg4sasa/dot4sasa.ml | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/tools/rdbg4sasa/dot4sasa.ml b/tools/rdbg4sasa/dot4sasa.ml index d7fcc3db..25d147b9 100644 --- a/tools/rdbg4sasa/dot4sasa.ml +++ b/tools/rdbg4sasa/dot4sasa.ml @@ -160,9 +160,11 @@ let to_pdf engine par_var only_parent rn g f e = (fun n -> let l = g.succ n.id in List.mapi (fun i t -> - if is_parent "par" n.id i e then + if g.directed then + Printf.sprintf "%s -> %s" t n.id + else if is_parent "par" n.id i e then Printf.sprintf "%s -> %s" n.id t - else if n.id < t then + else if n.id < t then (* to avoid duplication in undir graphs *) Printf.sprintf "%s -- %s" n.id t else Printf.sprintf "%s -- %s" t n.id -- GitLab