package stk

  1. Overview
  2. Docs

This virtual class defines the item interface. Most of the virtual methods correspond to methods of Widget.widget and are defined by inherting from Widget.widget or other widgets.

method as_item : item
method virtual id : Stk.Oid.t
method virtual geometry : Stk.G.t
method virtual get_p : 'a. 'a Stk.Props.prop -> 'a
method virtual coerce : Stk.Widget.widget
method virtual wtree : Stk.Widget.widget Stk.Widget.tree
method virtual me : string
method virtual min_width : int
method virtual min_height : int
method virtual as_full_item : full_item

Coordinates

method x : int
method y : int
method set_x : int -> unit
method set_y : int -> unit
method set_xy : (int * int) -> unit
method move : ?x:int -> ?y:int -> unit -> unit
method to_canvas_coords : x:int -> y:int -> int * int

Group

method group : group option
method set_group : group option -> unit

Accessing items

method on_items_at : (full_item -> bool Lwt.t) -> x:int -> y:int -> bool Lwt.t
method get_item_at : x:int -> y:int -> full_item option
method get_leaf_items_at : full_item list -> x:int -> y:int -> full_item list
OCaml

Innovation. Community. Security.