package tiny_appkits

  1. Overview
  2. Docs
Legend:
Page
Library
Module
Module type
Parameter
Class
Class type
Source

Module Cad_drawingSource

Sourcetype entity =
  1. | Line of pt * pt
  2. | Circle of pt * float
  3. | Arc of pt * float * float * float
  4. | Insert of string * pt * float * float
  5. | Dimension of pt * pt * pt
Sourcetype ent = {
  1. entity : entity;
  2. layer : string;
}
Sourcetype layer = {
  1. name : string;
  2. color : int;
  3. on : bool;
}
Sourcetype t = {
  1. ents : (int * ent) list;
  2. layers : layer list;
  3. current : string;
  4. blocks : (string * (pt * ent list)) list;
  5. next : int;
}
Sourceval empty : t
Sourceval add : entity -> t -> t * int
Sourceval get : t -> int -> ent option
Sourceval remove : int list -> t -> t
Sourceval replace : int -> entity list -> t -> t
Sourceval ids : t -> int list
Sourceval layer : t -> string -> layer
Sourceval ensure_layer : string -> t -> t
Sourceval set_layer : layer -> t -> t
Sourceval transform : pt -> float -> float -> pt -> pt
Sourceval move_entity : pt -> entity -> entity
Sourceval pieces : t -> ent -> (Cad_geom.curve * string) list
Sourceval dimension_value : pt -> pt -> pt -> float
Sourceval dimension_lines : pt -> pt -> pt -> (pt * pt) list
Sourceval dimension_text : pt -> pt -> pt -> pt * string
Sourceval extents : t -> (pt * pt) option
Sourceval pick : t -> float -> pt -> int option
Sourceval window : t -> pt -> pt -> crossing:bool -> int list