diff options
Diffstat (limited to 'script.ml')
-rwxr-xr-x | script.ml | 16 |
1 files changed, 4 insertions, 12 deletions
@@ -197,12 +197,9 @@ let on_change canva mouse_position state = end in - let path = Paths.CanvaRepr.get - @@ Paths.Path_Builder.repr - current - (module Paths.CanvaRepr) - (Paths.CanvaRepr.create_path (fun p -> fill context p)) in - stroke context path; + let repr = `Wire in + + Paths.to_canva (module Paths.Path_Builder) current context repr; List.iter state.paths ~f:(fun path -> @@ -221,12 +218,7 @@ let on_change canva mouse_position state = | _ -> () in - let path = Paths.CanvaRepr.get - @@ Paths.Fixed.repr - path - (module Paths.CanvaRepr) - (Paths.CanvaRepr.create_path (fun p -> fill context p)) in - stroke context path; + Paths.to_canva (module Paths.Fixed) path context repr ); () |