sig
  module rec Num :
    sig
      type t
      val bp : float -> Mlpost.Num.t
      val pt : float -> Mlpost.Num.t
      val cm : float -> Mlpost.Num.t
      val mm : float -> Mlpost.Num.t
      val inch : float -> Mlpost.Num.t
      val addn : Mlpost.Num.t -> Mlpost.Num.t -> Mlpost.Num.t
      val subn : Mlpost.Num.t -> Mlpost.Num.t -> Mlpost.Num.t
      val multn : Mlpost.Num.t -> Mlpost.Num.t -> Mlpost.Num.t
      val multf : float -> Mlpost.Num.t -> Mlpost.Num.t
      val divf : Mlpost.Num.t -> float -> Mlpost.Num.t
      val neg : Mlpost.Num.t -> Mlpost.Num.t
      val divn : Mlpost.Num.t -> Mlpost.Num.t -> Mlpost.Num.t
      val maxn : Mlpost.Num.t -> Mlpost.Num.t -> Mlpost.Num.t
      val minn : Mlpost.Num.t -> Mlpost.Num.t -> Mlpost.Num.t
      val gmean : Mlpost.Num.t -> Mlpost.Num.t -> Mlpost.Num.t
      module Infix :
        sig
          val ( +/ ) : Mlpost.Num.t -> Mlpost.Num.t -> Mlpost.Num.t
          val ( -/ ) : Mlpost.Num.t -> Mlpost.Num.t -> Mlpost.Num.t
          val ( */ ) : Mlpost.Num.t -> Mlpost.Num.t -> Mlpost.Num.t
          val ( // ) : Mlpost.Num.t -> Mlpost.Num.t -> Mlpost.Num.t
          val ( *./ ) : float -> Mlpost.Num.t -> Mlpost.Num.t
          val ( /./ ) : Mlpost.Num.t -> float -> Mlpost.Num.t
        end
      val zero : Mlpost.Num.t
      val one : Mlpost.Num.t
      val two : Mlpost.Num.t
      val pi : float
      val deg2rad : float -> float
      type scale = float -> Mlpost.Num.t
      module Scale :
        sig
          val bp : float -> Mlpost.Num.scale
          val pt : float -> Mlpost.Num.scale
          val cm : float -> Mlpost.Num.scale
          val mm : float -> Mlpost.Num.scale
          val inch : float -> Mlpost.Num.scale
        end
    end
  and Point :
    sig
      type t
      val pt : Mlpost.Num.t * Mlpost.Num.t -> Mlpost.Point.t
      val dir : float -> Mlpost.Point.t
      val up : Mlpost.Point.t
      val down : Mlpost.Point.t
      val left : Mlpost.Point.t
      val right : Mlpost.Point.t
      val origin : Mlpost.Point.t
      val length : Mlpost.Point.t -> Mlpost.Num.t
      val xpart : Mlpost.Point.t -> Mlpost.Num.t
      val ypart : Mlpost.Point.t -> Mlpost.Num.t
      val transform : Mlpost.Transform.t -> Mlpost.Point.t -> Mlpost.Point.t
      val segment :
        float -> Mlpost.Point.t -> Mlpost.Point.t -> Mlpost.Point.t
      val add : Mlpost.Point.t -> Mlpost.Point.t -> Mlpost.Point.t
      val shift : Mlpost.Point.t -> Mlpost.Point.t -> Mlpost.Point.t
      val sub : Mlpost.Point.t -> Mlpost.Point.t -> Mlpost.Point.t
      val mult : Mlpost.Num.t -> Mlpost.Point.t -> Mlpost.Point.t
      val scale : Mlpost.Num.t -> Mlpost.Point.t -> Mlpost.Point.t
      val rotate : float -> Mlpost.Point.t -> Mlpost.Point.t
      val rotate_around :
        Mlpost.Point.t -> float -> Mlpost.Point.t -> Mlpost.Point.t
      val xscale : Mlpost.Num.t -> Mlpost.Point.t -> Mlpost.Point.t
      val yscale : Mlpost.Num.t -> Mlpost.Point.t -> Mlpost.Point.t
      val bpp : float * float -> Mlpost.Point.t
      val inp : float * float -> Mlpost.Point.t
      val cmp : float * float -> Mlpost.Point.t
      val mmp : float * float -> Mlpost.Point.t
      val ptp : float * float -> Mlpost.Point.t
      val map_bp : (float * float) list -> Mlpost.Point.t list
      val map_in : (float * float) list -> Mlpost.Point.t list
      val map_cm : (float * float) list -> Mlpost.Point.t list
      val map_mm : (float * float) list -> Mlpost.Point.t list
      val map_pt : (float * float) list -> Mlpost.Point.t list
      val p :
        ?scale:(float -> Mlpost.Num.t) -> float * float -> Mlpost.Point.t
      val ptlist :
        ?scale:(float -> Mlpost.Num.t) ->
        (float * float) list -> Mlpost.Point.t list
    end
  and Path :
    sig
      type direction
      val vec : Mlpost.Point.t -> Mlpost.Path.direction
      val curl : float -> Mlpost.Path.direction
      val noDir : Mlpost.Path.direction
      type knot
      val knotp :
        ?l:Mlpost.Path.direction ->
        ?r:Mlpost.Path.direction -> Mlpost.Point.t -> Mlpost.Path.knot
      val knotlist :
        (Mlpost.Path.direction * Mlpost.Point.t * Mlpost.Path.direction) list ->
        Mlpost.Path.knot list
      type joint
      val jLine : Mlpost.Path.joint
      val jCurve : Mlpost.Path.joint
      val jCurveNoInflex : Mlpost.Path.joint
      val jTension : float -> float -> Mlpost.Path.joint
      val jControls : Mlpost.Point.t -> Mlpost.Point.t -> Mlpost.Path.joint
      type t
      val knot :
        ?l:Mlpost.Path.direction ->
        ?r:Mlpost.Path.direction ->
        ?scale:(float -> Mlpost.Num.t) -> float * float -> Mlpost.Path.knot
      val knotn :
        ?l:Mlpost.Path.direction ->
        ?r:Mlpost.Path.direction ->
        Mlpost.Num.t * Mlpost.Num.t -> Mlpost.Path.knot
      val path :
        ?style:Mlpost.Path.joint ->
        ?cycle:Mlpost.Path.joint ->
        ?scale:(float -> Mlpost.Num.t) ->
        (float * float) list -> Mlpost.Path.t
      val pathn :
        ?style:Mlpost.Path.joint ->
        ?cycle:Mlpost.Path.joint ->
        (Mlpost.Num.t * Mlpost.Num.t) list -> Mlpost.Path.t
      val pathk :
        ?style:Mlpost.Path.joint ->
        ?cycle:Mlpost.Path.joint -> Mlpost.Path.knot list -> Mlpost.Path.t
      val pathp :
        ?style:Mlpost.Path.joint ->
        ?cycle:Mlpost.Path.joint -> Mlpost.Point.t list -> Mlpost.Path.t
      val jointpathk :
        Mlpost.Path.knot list -> Mlpost.Path.joint list -> Mlpost.Path.t
      val jointpathp :
        Mlpost.Point.t list -> Mlpost.Path.joint list -> Mlpost.Path.t
      val jointpathn :
        (Mlpost.Num.t * Mlpost.Num.t) list ->
        Mlpost.Path.joint list -> Mlpost.Path.t
      val jointpath :
        ?scale:(float -> Mlpost.Num.t) ->
        (float * float) list -> Mlpost.Path.joint list -> Mlpost.Path.t
      val cycle :
        ?dir:Mlpost.Path.direction ->
        ?style:Mlpost.Path.joint -> Mlpost.Path.t -> Mlpost.Path.t
      val concat :
        ?style:Mlpost.Path.joint ->
        Mlpost.Path.t -> Mlpost.Path.knot -> Mlpost.Path.t
      val start : Mlpost.Path.knot -> Mlpost.Path.t
      val append :
        ?style:Mlpost.Path.joint ->
        Mlpost.Path.t -> Mlpost.Path.t -> Mlpost.Path.t
      val length : Mlpost.Path.t -> Mlpost.Num.t
      val point : float -> Mlpost.Path.t -> Mlpost.Point.t
      val pointn : Mlpost.Num.t -> Mlpost.Path.t -> Mlpost.Point.t
      val direction : float -> Mlpost.Path.t -> Mlpost.Point.t
      val directionn : Mlpost.Num.t -> Mlpost.Path.t -> Mlpost.Point.t
      val subpath : float -> float -> Mlpost.Path.t -> Mlpost.Path.t
      val subpathn :
        Mlpost.Num.t -> Mlpost.Num.t -> Mlpost.Path.t -> Mlpost.Path.t
      val transform : Mlpost.Transform.t -> Mlpost.Path.t -> Mlpost.Path.t
      val scale : Mlpost.Num.t -> Mlpost.Path.t -> Mlpost.Path.t
      val rotate : float -> Mlpost.Path.t -> Mlpost.Path.t
      val shift : Mlpost.Point.t -> Mlpost.Path.t -> Mlpost.Path.t
      val yscale : Mlpost.Num.t -> Mlpost.Path.t -> Mlpost.Path.t
      val xscale : Mlpost.Num.t -> Mlpost.Path.t -> Mlpost.Path.t
      val cut_after : Mlpost.Path.t -> Mlpost.Path.t -> Mlpost.Path.t
      val cut_before : Mlpost.Path.t -> Mlpost.Path.t -> Mlpost.Path.t
      val build_cycle : Mlpost.Path.t list -> Mlpost.Path.t
      val defaultjoint : Mlpost.Path.joint
      val fullcircle : Mlpost.Path.t
      val halfcircle : Mlpost.Path.t
      val quartercircle : Mlpost.Path.t
      val unitsquare : Mlpost.Path.t
    end
  and Pen :
    sig
      type t
      val transform : Mlpost.Transform.t -> Mlpost.Pen.t -> Mlpost.Pen.t
      val default : Mlpost.Pen.t
      val circle : Mlpost.Pen.t
      val square : Mlpost.Pen.t
      val from_path : Mlpost.Path.t -> Mlpost.Pen.t
      val scale : Mlpost.Num.t -> Mlpost.Pen.t -> Mlpost.Pen.t
      val rotate : float -> Mlpost.Pen.t -> Mlpost.Pen.t
      val shift : Mlpost.Point.t -> Mlpost.Pen.t -> Mlpost.Pen.t
      val yscale : Mlpost.Num.t -> Mlpost.Pen.t -> Mlpost.Pen.t
      val xscale : Mlpost.Num.t -> Mlpost.Pen.t -> Mlpost.Pen.t
    end
  and Dash :
    sig
      type t
      val evenly : Mlpost.Dash.t
      val withdots : Mlpost.Dash.t
      val scaled : float -> Mlpost.Dash.t -> Mlpost.Dash.t
      val shifted : Mlpost.Point.t -> Mlpost.Dash.t -> Mlpost.Dash.t
      type on_off
      val on : Mlpost.Num.t -> Mlpost.Dash.on_off
      val off : Mlpost.Num.t -> Mlpost.Dash.on_off
      val pattern : Mlpost.Dash.on_off list -> Mlpost.Dash.t
    end
  and Color :
    sig
      type t
      val default : Mlpost.Color.t
      val rgb : float -> float -> float -> Mlpost.Color.t
      val rgb8 : int -> int -> int -> Mlpost.Color.t
      val cmyk : float -> float -> float -> float -> Mlpost.Color.t
      val rgba : float -> float -> float -> float -> Mlpost.Color.t
      val rgb8a : int -> int -> int -> int -> Mlpost.Color.t
      val cmyka : float -> float -> float -> float -> float -> Mlpost.Color.t
      val is_opaque : Mlpost.Color.t -> bool
      val opaque : Mlpost.Color.t -> Mlpost.Color.t
      val transparent : float -> Mlpost.Color.t -> Mlpost.Color.t
      val white : Mlpost.Color.t
      val black : Mlpost.Color.t
      val red : Mlpost.Color.t
      val blue : Mlpost.Color.t
      val green : Mlpost.Color.t
      val cyan : Mlpost.Color.t
      val yellow : Mlpost.Color.t
      val magenta : Mlpost.Color.t
      val lightred : Mlpost.Color.t
      val lightblue : Mlpost.Color.t
      val lightgreen : Mlpost.Color.t
      val lightcyan : Mlpost.Color.t
      val lightyellow : Mlpost.Color.t
      val lightmagenta : Mlpost.Color.t
      val gray : float -> Mlpost.Color.t
      val lightgray : Mlpost.Color.t
      val mediumgray : Mlpost.Color.t
      val darkgray : Mlpost.Color.t
      val orange : Mlpost.Color.t
      val purple : Mlpost.Color.t
      val color : string -> Mlpost.Color.t
    end
  and Transform :
    sig
      type t'
      val scaled : Mlpost.Num.t -> Mlpost.Transform.t'
      val rotated : float -> Mlpost.Transform.t'
      val shifted : Mlpost.Point.t -> Mlpost.Transform.t'
      val slanted : Mlpost.Num.t -> Mlpost.Transform.t'
      val xscaled : Mlpost.Num.t -> Mlpost.Transform.t'
      val yscaled : Mlpost.Num.t -> Mlpost.Transform.t'
      val zscaled : Mlpost.Point.t -> Mlpost.Transform.t'
      val reflect : Mlpost.Point.t -> Mlpost.Point.t -> Mlpost.Transform.t'
      val rotate_around : Mlpost.Point.t -> float -> Mlpost.Transform.t'
      type t = Mlpost.Transform.t' list
      val id : Mlpost.Transform.t
    end
  and Picture :
    sig
      type t
      val make : Mlpost.Command.t -> Mlpost.Picture.t
      val tex : string -> Mlpost.Picture.t
      val transform :
        Mlpost.Transform.t -> Mlpost.Picture.t -> Mlpost.Picture.t
      val bbox : Mlpost.Picture.t -> Mlpost.Path.t
      val corner_bbox :
        ?dx:Mlpost.Num.t ->
        ?dy:Mlpost.Num.t -> Mlpost.Picture.t -> Mlpost.Path.t
      val center : Mlpost.Point.t -> Mlpost.Picture.t -> Mlpost.Picture.t
      val place_up_left :
        Mlpost.Point.t -> Mlpost.Picture.t -> Mlpost.Picture.t
      val place_up_right :
        Mlpost.Point.t -> Mlpost.Picture.t -> Mlpost.Picture.t
      val place_bot_left :
        Mlpost.Point.t -> Mlpost.Picture.t -> Mlpost.Picture.t
      val place_bot_right :
        Mlpost.Point.t -> Mlpost.Picture.t -> Mlpost.Picture.t
      val beside : Mlpost.Picture.t -> Mlpost.Picture.t -> Mlpost.Picture.t
      val below : Mlpost.Picture.t -> Mlpost.Picture.t -> Mlpost.Picture.t
      val ulcorner : Mlpost.Picture.t -> Mlpost.Point.t
      val llcorner : Mlpost.Picture.t -> Mlpost.Point.t
      val urcorner : Mlpost.Picture.t -> Mlpost.Point.t
      val lrcorner : Mlpost.Picture.t -> Mlpost.Point.t
      val ctr : Mlpost.Picture.t -> Mlpost.Point.t
      val clip : Mlpost.Picture.t -> Mlpost.Path.t -> Mlpost.Picture.t
      val width : Mlpost.Picture.t -> Mlpost.Num.t
      val height : Mlpost.Picture.t -> Mlpost.Num.t
      val scale : Mlpost.Num.t -> Mlpost.Picture.t -> Mlpost.Picture.t
      val rotate : float -> Mlpost.Picture.t -> Mlpost.Picture.t
      val shift : Mlpost.Point.t -> Mlpost.Picture.t -> Mlpost.Picture.t
      val yscale : Mlpost.Num.t -> Mlpost.Picture.t -> Mlpost.Picture.t
      val xscale : Mlpost.Num.t -> Mlpost.Picture.t -> Mlpost.Picture.t
      val spin : float -> Mlpost.Picture.t -> Mlpost.Picture.t
    end
  and Command :
    sig
      type t
      val draw :
        ?color:Mlpost.Color.t ->
        ?pen:Mlpost.Pen.t ->
        ?dashed:Mlpost.Dash.t -> Mlpost.Path.t -> Mlpost.Command.t
      val draw_arrow :
        ?color:Mlpost.Color.t ->
        ?pen:Mlpost.Pen.t ->
        ?dashed:Mlpost.Dash.t -> Mlpost.Path.t -> Mlpost.Command.t
      val fill : ?color:Mlpost.Color.t -> Mlpost.Path.t -> Mlpost.Command.t
      val draw_pic : Mlpost.Picture.t -> Mlpost.Command.t
      val externalimage :
        string ->
        [ `Exact of Mlpost.Num.t * Mlpost.Num.t
        | `Height of Mlpost.Num.t
        | `Inside of Mlpost.Num.t * Mlpost.Num.t
        | `None
        | `Width of Mlpost.Num.t ] -> Mlpost.Command.t
      val nop : Mlpost.Command.t
      val append : Mlpost.Command.t -> Mlpost.Command.t -> Mlpost.Command.t
      val ( ++ ) : Mlpost.Command.t -> Mlpost.Command.t -> Mlpost.Command.t
      val seq : Mlpost.Command.t list -> Mlpost.Command.t
      val iter : int -> int -> (int -> Mlpost.Command.t) -> Mlpost.Command.t
      val iterl : ('-> Mlpost.Command.t) -> 'a list -> Mlpost.Command.t
      type hposition = [ `Center | `Left | `Right ]
      type vposition = [ `Bot | `Center | `Top ]
      type position =
          [ `Bot
          | `Center
          | `Left
          | `Lowleft
          | `Lowright
          | `Right
          | `Top
          | `Upleft
          | `Upright ]
      val label :
        ?pos:Mlpost.Command.position ->
        Mlpost.Picture.t -> Mlpost.Point.t -> Mlpost.Command.t
      val dotlabel :
        ?pos:Mlpost.Command.position ->
        Mlpost.Picture.t -> Mlpost.Point.t -> Mlpost.Command.t
    end
  module rec Shapes :
    sig
      val round_rect :
        Mlpost.Num.t ->
        Mlpost.Num.t -> Mlpost.Num.t -> Mlpost.Num.t -> Mlpost.Path.t
      val rectangle : Mlpost.Num.t -> Mlpost.Num.t -> Mlpost.Path.t
      val ellipse : Mlpost.Num.t -> Mlpost.Num.t -> Mlpost.Path.t
      val circle : Mlpost.Num.t -> Mlpost.Path.t
      val patatoid : Mlpost.Num.t -> Mlpost.Num.t -> Mlpost.Path.t
    end
  and Box :
    sig
      type t
      val empty :
        ?name:string ->
        ?width:Mlpost.Num.t -> ?height:Mlpost.Num.t -> unit -> Mlpost.Box.t
      type style =
          Rect
        | Circle
        | RoundRect
        | Patatoid
        | Ellipse
        | Custom of
            (Mlpost.Num.t ->
             Mlpost.Num.t -> Mlpost.Num.t * Mlpost.Num.t * Mlpost.Path.t)
      type 'a box_creator =
          ?dx:Mlpost.Num.t ->
          ?dy:Mlpost.Num.t ->
          ?name:string ->
          ?stroke:Mlpost.Color.t option ->
          ?pen:Mlpost.Pen.t -> ?fill:Mlpost.Color.t -> '-> Mlpost.Box.t
      val pic :
        ?style:Mlpost.Box.style -> Mlpost.Picture.t Mlpost.Box.box_creator
      val path :
        ?style:Mlpost.Box.style -> Mlpost.Path.t Mlpost.Box.box_creator
      val tex : ?style:Mlpost.Box.style -> string Mlpost.Box.box_creator
      val box :
        ?style:Mlpost.Box.style -> Mlpost.Box.t Mlpost.Box.box_creator
      val circle : Mlpost.Box.t Mlpost.Box.box_creator
      val ellipse : Mlpost.Box.t Mlpost.Box.box_creator
      val rect : Mlpost.Box.t Mlpost.Box.box_creator
      val round_rect : Mlpost.Box.t Mlpost.Box.box_creator
      val patatoid : Mlpost.Box.t Mlpost.Box.box_creator
      val bpath : Mlpost.Box.t -> Mlpost.Path.t
      val ctr : t -> Point.t
      val north : Mlpost.Box.t -> Mlpost.Point.t
      val south : Mlpost.Box.t -> Mlpost.Point.t
      val west : Mlpost.Box.t -> Mlpost.Point.t
      val east : Mlpost.Box.t -> Mlpost.Point.t
      val north_west : Mlpost.Box.t -> Mlpost.Point.t
      val south_west : Mlpost.Box.t -> Mlpost.Point.t
      val north_east : Mlpost.Box.t -> Mlpost.Point.t
      val south_east : Mlpost.Box.t -> Mlpost.Point.t
      val ctr : Mlpost.Box.t -> Mlpost.Point.t
      val height : Mlpost.Box.t -> Mlpost.Num.t
      val width : Mlpost.Box.t -> Mlpost.Num.t
      val shift : Mlpost.Point.t -> Mlpost.Box.t -> Mlpost.Box.t
      val center : Mlpost.Point.t -> Mlpost.Box.t -> Mlpost.Box.t
      val draw : ?debug:bool -> Mlpost.Box.t -> Mlpost.Command.t
      val group :
        ?style:Mlpost.Box.style -> Mlpost.Box.t list Mlpost.Box.box_creator
      val hbox :
        ?padding:Mlpost.Num.t ->
        ?pos:Mlpost.Command.vposition ->
        ?style:Mlpost.Box.style -> Mlpost.Box.t list Mlpost.Box.box_creator
      val vbox :
        ?padding:Mlpost.Num.t ->
        ?pos:Mlpost.Command.hposition ->
        ?style:Mlpost.Box.style -> Mlpost.Box.t list Mlpost.Box.box_creator
      val tabular :
        ?hpadding:Mlpost.Num.t ->
        ?vpadding:Mlpost.Num.t ->
        ?pos:Mlpost.Command.position ->
        Mlpost.Box.t array array -> Mlpost.Box.t
      val tabularl :
        ?hpadding:Mlpost.Num.t ->
        ?vpadding:Mlpost.Num.t ->
        ?pos:Mlpost.Command.position ->
        Mlpost.Box.t list list -> Mlpost.Box.t
      val tabulari :
        ?hpadding:Mlpost.Num.t ->
        ?vpadding:Mlpost.Num.t ->
        ?pos:Mlpost.Command.position ->
        int -> int -> (int -> int -> Mlpost.Box.t) -> Mlpost.Box.t
      val hblock :
        ?pos:Mlpost.Command.vposition ->
        ?name:string ->
        ?min_width:Mlpost.Num.t ->
        ?same_width:bool -> Mlpost.Box.t list -> Mlpost.Box.t
      val vblock :
        ?pos:Mlpost.Command.hposition ->
        ?name:string ->
        ?min_height:Mlpost.Num.t ->
        ?same_height:bool -> Mlpost.Box.t list -> Mlpost.Box.t
      val grid :
        ?pos:Mlpost.Command.position ->
        Mlpost.Box.t array array -> Mlpost.Box.t
      val gridl :
        ?pos:Mlpost.Command.position ->
        Mlpost.Box.t list list -> Mlpost.Box.t
      val gridi :
        ?pos:Mlpost.Command.position ->
        int -> int -> (int -> int -> Mlpost.Box.t) -> Mlpost.Box.t
      val nth : int -> Mlpost.Box.t -> Mlpost.Box.t
      val get : string -> Mlpost.Box.t -> Mlpost.Box.t
      val elts : Mlpost.Box.t -> Mlpost.Box.t array
      val get_fill : Mlpost.Box.t -> Mlpost.Color.t option
      val set_fill : Mlpost.Color.t -> Mlpost.Box.t -> Mlpost.Box.t
      val get_stroke : Mlpost.Box.t -> Mlpost.Color.t option
      val set_stroke : Mlpost.Color.t -> Mlpost.Box.t -> Mlpost.Box.t
      val clear_stroke : Mlpost.Box.t -> Mlpost.Box.t
      val get_name : Mlpost.Box.t -> string option
      val set_name : string -> Mlpost.Box.t -> Mlpost.Box.t
      val get_pen : Mlpost.Box.t -> Mlpost.Pen.t option
      val set_pen : Mlpost.Pen.t -> Mlpost.Box.t -> Mlpost.Box.t
      val shadow : Mlpost.Box.t -> Mlpost.Box.t
      val cpath :
        ?style:Mlpost.Path.joint ->
        ?outd:Mlpost.Path.direction ->
        ?ind:Mlpost.Path.direction ->
        Mlpost.Box.t -> Mlpost.Box.t -> Mlpost.Path.t
    end
  module Arrow :
    sig
      type kind
      val draw :
        ?kind:Mlpost.Arrow.kind ->
        ?tex:string ->
        ?pos:Mlpost.Command.position -> Mlpost.Path.t -> Mlpost.Command.t
      val draw2 :
        ?kind:Mlpost.Arrow.kind ->
        ?tex:string ->
        ?pos:Mlpost.Command.position ->
        ?outd:Mlpost.Path.direction ->
        ?ind:Mlpost.Path.direction ->
        Mlpost.Point.t -> Mlpost.Point.t -> Mlpost.Command.t
      val classic : Mlpost.Arrow.kind
      val triangle : Mlpost.Arrow.kind
      val triangle_full : Mlpost.Arrow.kind
      type head =
          Mlpost.Point.t ->
          Mlpost.Point.t -> Mlpost.Command.t * Mlpost.Path.t
      val head_classic :
        ?color:Mlpost.Color.t ->
        ?pen:Mlpost.Pen.t ->
        ?dashed:Mlpost.Dash.t ->
        ?angle:float -> ?size:Mlpost.Num.t -> Mlpost.Arrow.head
      val head_triangle :
        ?color:Mlpost.Color.t ->
        ?pen:Mlpost.Pen.t ->
        ?dashed:Mlpost.Dash.t ->
        ?angle:float -> ?size:Mlpost.Num.t -> Mlpost.Arrow.head
      val head_triangle_full :
        ?color:Mlpost.Color.t ->
        ?angle:float -> ?size:Mlpost.Num.t -> Mlpost.Arrow.head
      val empty : Mlpost.Arrow.kind
      val add_line :
        ?dashed:Mlpost.Dash.t ->
        ?color:Mlpost.Color.t ->
        ?pen:Mlpost.Pen.t ->
        ?from_point:float ->
        ?to_point:float ->
        ?dist:Mlpost.Num.t -> Mlpost.Arrow.kind -> Mlpost.Arrow.kind
      val add_head :
        ?head:Mlpost.Arrow.head -> Mlpost.Arrow.kind -> Mlpost.Arrow.kind
      val add_foot :
        ?head:Mlpost.Arrow.head -> Mlpost.Arrow.kind -> Mlpost.Arrow.kind
      val add_belt :
        ?clip:bool ->
        ?rev:bool ->
        ?point:float ->
        ?head:Mlpost.Arrow.head -> Mlpost.Arrow.kind -> Mlpost.Arrow.kind
      val draw_thick :
        ?style:Mlpost.Path.joint ->
        ?boxed:bool ->
        ?line_color:Mlpost.Color.t ->
        ?fill_color:Mlpost.Color.t ->
        ?outd:Mlpost.Path.direction ->
        ?ind:Mlpost.Path.direction ->
        ?width:Mlpost.Num.t ->
        ?head_length:Mlpost.Num.t ->
        ?head_width:Mlpost.Num.t ->
        Mlpost.Point.t -> Mlpost.Point.t -> Mlpost.Command.t
    end
  module Helpers :
    sig
      val dotlabels :
        ?pos:Mlpost.Command.position ->
        string list -> Mlpost.Point.t list -> Mlpost.Command.t
      val draw_simple_arrow :
        ?color:Mlpost.Color.t ->
        ?pen:Mlpost.Pen.t ->
        ?dashed:Mlpost.Dash.t ->
        ?style:Mlpost.Path.joint ->
        ?outd:Mlpost.Path.direction ->
        ?ind:Mlpost.Path.direction ->
        Mlpost.Point.t -> Mlpost.Point.t -> Mlpost.Command.t
      val draw_label_arrow :
        ?color:Mlpost.Color.t ->
        ?pen:Mlpost.Pen.t ->
        ?dashed:Mlpost.Dash.t ->
        ?style:Mlpost.Path.joint ->
        ?outd:Mlpost.Path.direction ->
        ?ind:Mlpost.Path.direction ->
        ?pos:Mlpost.Command.position ->
        Mlpost.Picture.t ->
        Mlpost.Point.t -> Mlpost.Point.t -> Mlpost.Command.t
      val draw_labelbox_arrow :
        ?color:Mlpost.Color.t ->
        ?pen:Mlpost.Pen.t ->
        ?dashed:Mlpost.Dash.t ->
        ?style:Mlpost.Path.joint ->
        ?outd:Mlpost.Path.direction ->
        ?ind:Mlpost.Path.direction ->
        ?pos:Mlpost.Command.position ->
        Mlpost.Box.t -> Mlpost.Point.t -> Mlpost.Point.t -> Mlpost.Command.t
      val box_arrow :
        ?color:Mlpost.Color.t ->
        ?pen:Mlpost.Pen.t ->
        ?dashed:Mlpost.Dash.t ->
        ?style:Mlpost.Path.joint ->
        ?outd:Mlpost.Path.direction ->
        ?ind:Mlpost.Path.direction ->
        Mlpost.Box.t -> Mlpost.Box.t -> Mlpost.Command.t
      val box_line :
        ?color:Mlpost.Color.t ->
        ?pen:Mlpost.Pen.t ->
        ?dashed:Mlpost.Dash.t ->
        ?style:Mlpost.Path.joint ->
        ?outd:Mlpost.Path.direction ->
        ?ind:Mlpost.Path.direction ->
        Mlpost.Box.t -> Mlpost.Box.t -> Mlpost.Command.t
      val box_label_arrow :
        ?color:Mlpost.Color.t ->
        ?pen:Mlpost.Pen.t ->
        ?dashed:Mlpost.Dash.t ->
        ?style:Mlpost.Path.joint ->
        ?outd:Mlpost.Path.direction ->
        ?ind:Mlpost.Path.direction ->
        ?pos:Mlpost.Command.position ->
        Mlpost.Picture.t -> Mlpost.Box.t -> Mlpost.Box.t -> Mlpost.Command.t
      val box_label_line :
        ?color:Mlpost.Color.t ->
        ?pen:Mlpost.Pen.t ->
        ?dashed:Mlpost.Dash.t ->
        ?style:Mlpost.Path.joint ->
        ?outd:Mlpost.Path.direction ->
        ?ind:Mlpost.Path.direction ->
        ?pos:Mlpost.Command.position ->
        Mlpost.Picture.t -> Mlpost.Box.t -> Mlpost.Box.t -> Mlpost.Command.t
      val box_labelbox_arrow :
        ?color:Mlpost.Color.t ->
        ?pen:Mlpost.Pen.t ->
        ?dashed:Mlpost.Dash.t ->
        ?style:Mlpost.Path.joint ->
        ?outd:Mlpost.Path.direction ->
        ?ind:Mlpost.Path.direction ->
        ?pos:Mlpost.Command.position ->
        Mlpost.Box.t -> Mlpost.Box.t -> Mlpost.Box.t -> Mlpost.Command.t
    end
  module Tree :
    sig
      type t = Mlpost.Box.t
      type arrow_style = Directed | Undirected
      type edge_style = Straight | Curve | Square | HalfSquare
      val leaf : Mlpost.Box.t -> Mlpost.Tree.t
      val node :
        ?ls:Mlpost.Num.t ->
        ?cs:Mlpost.Num.t ->
        ?arrow_style:Mlpost.Tree.arrow_style ->
        ?edge_style:Mlpost.Tree.edge_style ->
        ?stroke:Mlpost.Color.t ->
        ?pen:Mlpost.Pen.t ->
        Mlpost.Box.t -> Mlpost.Tree.t list -> Mlpost.Tree.t
      val bin :
        ?ls:Mlpost.Num.t ->
        ?cs:Mlpost.Num.t ->
        ?arrow_style:Mlpost.Tree.arrow_style ->
        ?edge_style:Mlpost.Tree.edge_style ->
        ?stroke:Mlpost.Color.t ->
        ?pen:Mlpost.Pen.t ->
        Mlpost.Box.t -> Mlpost.Tree.t -> Mlpost.Tree.t -> Mlpost.Tree.t
    end
  module Diag :
    sig
      type node
      type node_style = Mlpost.Box.t -> Mlpost.Box.t
      val node :
        ?style:Mlpost.Diag.node_style ->
        ?fill:Mlpost.Color.t ->
        ?boxed:bool -> float -> float -> Mlpost.Box.t -> Mlpost.Diag.node
      type t
      val create : Mlpost.Diag.node list -> Mlpost.Diag.t
      type dir = Up | Down | Left | Right | Angle of float
      val arrow :
        Mlpost.Diag.t ->
        ?lab:string ->
        ?line_width:Mlpost.Num.t ->
        ?boxed:bool ->
        ?line_color:Mlpost.Color.t ->
        ?fill_color:Mlpost.Color.t ->
        ?pos:Mlpost.Command.position ->
        ?head:bool ->
        ?dashed:Mlpost.Dash.t ->
        ?outd:Mlpost.Diag.dir ->
        ?ind:Mlpost.Diag.dir -> Mlpost.Diag.node -> Mlpost.Diag.node -> unit
      val draw :
        ?scale:(float -> Mlpost.Num.t) ->
        ?style:Mlpost.Diag.node_style ->
        ?boxed:bool ->
        ?fill:Mlpost.Color.t ->
        ?stroke:Mlpost.Color.t ->
        ?pen:Mlpost.Pen.t -> Mlpost.Diag.t -> Mlpost.Command.t
    end
  module Plot :
    sig
      type skeleton
      val mk_skeleton :
        int -> int -> Mlpost.Num.t -> Mlpost.Num.t -> Mlpost.Plot.skeleton
      type labels = int -> Mlpost.Num.t -> Mlpost.Picture.t option
      type ticks = (Mlpost.Num.t * Mlpost.Pen.t) option
      type drawing = Stepwise | Normal
      val draw_grid :
        ?hdash:(int -> Mlpost.Dash.t) ->
        ?vdash:(int -> Mlpost.Dash.t) ->
        ?hpen:(int -> Mlpost.Pen.t) ->
        ?vpen:(int -> Mlpost.Pen.t) ->
        ?color:Mlpost.Color.t -> Mlpost.Plot.skeleton -> Mlpost.Command.t
      val draw_axes :
        ?hpen:Mlpost.Pen.t ->
        ?vpen:Mlpost.Pen.t ->
        ?hlabel:Mlpost.Plot.labels ->
        ?vlabel:Mlpost.Plot.labels ->
        ?ticks:Mlpost.Plot.ticks ->
        ?closed:bool ->
        ?hcaption:Mlpost.Picture.t ->
        ?vcaption:Mlpost.Picture.t ->
        Mlpost.Plot.skeleton -> Mlpost.Command.t
      val draw_simple_axes :
        ?hpen:Mlpost.Pen.t ->
        ?vpen:Mlpost.Pen.t ->
        string -> string -> Mlpost.Plot.skeleton -> Mlpost.Command.t
      val draw_func :
        ?pen:Mlpost.Pen.t ->
        ?drawing:Mlpost.Plot.drawing ->
        ?style:Mlpost.Path.joint ->
        ?dashed:Mlpost.Dash.t ->
        ?color:Mlpost.Color.t ->
        ?label:Mlpost.Picture.t * Mlpost.Command.position * int ->
        (int -> float) -> Mlpost.Plot.skeleton -> Mlpost.Command.t
    end
  module Misc :
    sig
      val write_to_file : string -> (Pervasives.out_channel -> 'a) -> unit
      val write_to_formatted_file :
        string -> (Format.formatter -> 'a) -> unit
      val print_option :
        string ->
        (Format.formatter -> '-> unit) ->
        Format.formatter -> 'a option -> unit
      val print_list :
        ('-> unit -> 'b) -> ('-> '-> unit) -> '-> 'c list -> unit
      val space : Format.formatter -> unit -> unit
      val comma : Format.formatter -> unit -> unit
      val fold_from_to : ('-> int -> 'a) -> '-> int -> int -> 'a
    end
  module Metapost :
    sig
      val generate_mp :
        string ->
        ?prelude:string -> ?eps:bool -> (int * Mlpost.Command.t) list -> unit
      val emit : string -> Mlpost.Command.t -> unit
      val dump : ?prelude:string -> ?pdf:bool -> ?eps:bool -> string -> unit
      val read_prelude_from_tex_file : string -> string
      val dump_tex : ?prelude:string -> string -> unit
      val slideshow :
        Mlpost.Command.t list -> int -> (int * Mlpost.Command.t) list
    end
  module Generate :
    sig
      val generate_tex :
        string -> string -> string -> (int * 'a) list -> unit
    end
end