package tree_layout

  1. Overview
  2. Docs

Module Tree_layout.CommonSource

Common types

Common set of types and functions for all other modules.

Sourcetype pos = {
  1. x : float;
  2. y : float;
}
Sourcetype rectangle = {
  1. p : pos;
  2. w : float;
  3. h : float;
}
Sourceval boundaries : ?margins:pos -> pos Iter.t -> rectangle

boundaries ~margins positions returns a pair (pos, size) defining a rectangle containing the positions in positions.

The option argument margins add a margin around the rectangle.

OCaml

Innovation. Community. Security.