lablgtk3

OCaml interface to GTK+3
IN THIS PACKAGE
Module GTree

New GtkTreeView/Model framework

type 'a column = {
index : int;
conv : 'a Gobject.data_conv;
creator : int;
}
class column_list : object ... end
class row_reference : Gtk.row_reference -> model:[> `treemodel ] Gtk.obj -> object ... end
Models
class model_signals : [> `treemodel ] Gtk.obj -> object ... end

@gtkdoc gtk GtkTreeModel

val model_ids : ( int, int ) Hashtbl.t
class model : [> `treemodel ] as 'a Gtk.obj -> object ... end

@gtkdoc gtk GtkTreeModel

class tree_sortable_signals : [> `treesortable | `treemodel ] as 'a Gtk.obj -> object ... end

@gtkdoc gtk GtkTreeSortable

class tree_sortable : [> `treesortable | `treemodel ] as 'a Gtk.obj -> object ... end

@gtkdoc gtk GtkTreeSortable

Special value for the #set_sort_column_id method of GTree.tree_sortable.

val default_sort_column_id : int
val unsorted_sort_column_id : int
class tree_store : Gtk.tree_store -> object ... end

@gtkdoc gtk GtkTreeStore

val tree_store : column_list -> tree_store

@gtkdoc gtk GtkTreeStore

class list_store : Gtk.list_store -> object ... end

@gtkdoc gtk GtkListStore

val list_store : column_list -> list_store

@gtkdoc gtk GtkListStore

val store_of_list : 'a Gobject.data_conv -> 'a list -> list_store * 'a column

Convenience function to map a caml list into a GTree.list_store with a single column

class model_sort : Gtk.tree_model_sort -> object ... end

@gtkdoc gtk GtkTreeModelSort

val model_sort : model -> model_sort

@gtkdoc gtk GtkTreeModelSort

class model_filter : Gtk.tree_model_filter -> object ... end
val model_filter : ?virtual_root:Gtk.tree_path -> model -> model_filter
  • since GTK 2.4

@gtkdoc gtk GtkTreeModelFilter

module Path : sig ... end
Selection
class selection_signals : Gtk.tree_selection -> object ... end

@gtkdoc gtk GtkTreeSelection

class selection : Gtk.tree_selection -> object ... end

The selection object for GTree.view @gtkdoc gtk GtkTreeSelection

Views
class type cell_renderer = object ... end
class cell_layout : [> Gtk.cell_layout ] as 'a Gtk.obj -> object ... end
class view_column_signals : [> `gtk | `treeviewcolumn ] Gtk.obj -> object ... end

@gtkdoc gtk GtkTreeViewColumn

class view_column : Gtk.tree_view_column Gtk.obj -> object ... end

A visible column in a GTree.view widget @gtkdoc gtk GtkTreeViewColumn

val view_column : ?title:string -> ?renderer:(cell_renderer * (string * 'a column) list) -> unit -> view_column

@gtkdoc gtk GtkTreeViewColumn

class view_signals : [> Gtk.tree_view ] Gtk.obj -> object ... end

@gtkdoc gtk GtkTreeView

class view : Gtk.tree_view Gtk.obj -> object ... end

A widget for displaying both trees and lists @gtkdoc gtk GtkTreeView

val view : ?model:model -> ?hadjustment:GData.adjustment -> ?vadjustment:GData.adjustment -> ?enable_search:bool -> ?fixed_height_mode:bool -> ?headers_clickable:bool -> ?headers_visible:bool -> ?reorderable:bool -> ?rules_hint:bool -> ?search_column:int -> ?tooltip_column:int -> ?border_width:int -> ?width:int -> ?height:int -> ?packing:( GObj.widget -> unit ) -> ?show:bool -> unit -> view

@gtkdoc gtk GtkTreeView

  • parameter enable_search

    default value is true

  • parameter fixed_height_mode

    default value is false

  • parameter headers_clickable

    default value is false

  • parameter headers_visible

    default value is true

  • parameter reorderable

    default value is false

  • parameter rules_hint

    default value is false

Cell Renderers
type cell_properties = [
| `CELL_BACKGROUND of string
| `CELL_BACKGROUND_GDK of Gdk.color
| `CELL_BACKGROUND_SET of bool
| `HEIGHT of int
| `IS_EXPANDED of bool
| `IS_EXPANDER of bool
| `MODE of Gtk.Tags.cell_renderer_mode
| `VISIBLE of bool
| `WIDTH of int
| `XALIGN of float
| `XPAD of int
| `YALIGN of float
| `YPAD of int
]
type cell_properties_pixbuf = [
| cell_properties
| `PIXBUF of GdkPixbuf.pixbuf
| `PIXBUF_EXPANDER_CLOSED of GdkPixbuf.pixbuf
| `PIXBUF_EXPANDER_OPEN of GdkPixbuf.pixbuf
| `STOCK_DETAIL of string
| `STOCK_ID of string
| `STOCK_SIZE of Gtk.Tags.icon_size
]
type cell_properties_text = [
| cell_properties
| `BACKGROUND of string
| `BACKGROUND_GDK of Gdk.color
| `BACKGROUND_SET of bool
| `EDITABLE of bool
| `FAMILY of string
| `FONT of string
| `FONT_DESC of Pango.font_description
| `FOREGROUND of string
| `FOREGROUND_GDK of Gdk.color
| `FOREGROUND_SET of bool
| `MARKUP of string
| `RISE of int
| `SCALE of Pango.Tags.scale
| `SINGLE_PARAGRAPH_MODE of bool
| `SIZE of int
| `SIZE_POINTS of float
| `STRETCH of Pango.Tags.stretch
| `STRIKETHROUGH of bool
| `STYLE of Pango.Tags.style
| `TEXT of string
| `UNDERLINE of Pango.Tags.underline
| `VARIANT of Pango.Tags.variant
| `WEIGHT of Pango.Tags.weight
| `WRAP_MODE of Pango.Tags.wrap_mode
| `WRAP_WIDTH of int
]
type cell_properties_toggle = [
| cell_properties
| `ACTIVATABLE of bool
| `ACTIVE of bool
| `INCONSISTENT of bool
| `RADIO of bool
]
type cell_properties_progress = [
| cell_properties
| `VALUE of int
| `TEXT of string option
]
type cell_properties_combo = [
| cell_properties_text
| `MODEL of model option
| `TEXT_COLUMN of string column
| `HAS_ENTRY of bool
]
type cell_properties_accel = [
| cell_properties_text
| `KEY of Gdk.keysym
| `ACCEL_MODE of GtkEnums.cell_renderer_accel_mode
| `MODS of GdkEnums.modifier list
| `KEYCODE of int
]
class type ['a, 'b] cell_renderer_skel = object ... end

@gtkdoc gtk GtkCellRenderer

class virtual ['a, 'b] cell_renderer_impl : [> Gtk.cell_renderer ] as 'a Gtk.obj -> object ... end

@gtkdoc gtk GtkCellRenderer

@gtkdoc gtk GtkCellRendererPixbuf

class cell_renderer_text_signals : [> Gtk.cell_renderer_text ] as 'a Gtk.obj -> object ... end

@gtkdoc gtk GtkCellRendererText

@gtkdoc gtk GtkCellRendererText

@gtkdoc gtk GtkCellRendererToggle

@gtkdoc gtk GtkCellRendererToggle

class cell_renderer_combo_signals : [> Gtk.cell_renderer_combo ] as 'a Gtk.obj -> object ... end
val cell_renderer_pixbuf : cell_properties_pixbuf list -> cell_renderer_pixbuf

@gtkdoc gtk GtkCellRendererPixbuf

val cell_renderer_text : cell_properties_text list -> cell_renderer_text

@gtkdoc gtk GtkCellRendererText

val cell_renderer_toggle : cell_properties_toggle list -> cell_renderer_toggle

@gtkdoc gtk GtkCellRendererToggle

val cell_renderer_progress : cell_properties_progress list -> cell_renderer_progress
  • since GTK 2.6

@gtkdoc gtk GtkCellRendererProgress

val cell_renderer_combo : cell_properties_combo list -> cell_renderer_combo
  • since GTK 2.6

@gtkdoc gtk GtkCellRendererCombo

val cell_renderer_accel : cell_properties_accel list -> cell_renderer_accel
  • since GTK 2.10

@gtkdoc gtk GtkCellRendererAccel

GtkIconView

class icon_view_signals : [> Gtk.icon_view ] Gtk.obj -> object ... end

@gtkdoc gtk GtkIconView

class icon_view : [> Gtk.icon_view ] as 'a Gtk.obj -> object ... end

A widget which displays a list of icons in a grid @gtkdoc gtk GtkIconView

val icon_view : ?model:model -> ?columns:int -> ?orientation:GtkEnums.orientation -> ?selection_mode:GtkEnums.selection_mode -> ?border_width:int -> ?width:int -> ?height:int -> ?packing:( GObj.widget -> unit ) -> ?show:bool -> unit -> icon_view

A widget which displays a list of icons in a grid @gtkdoc gtk GtkIconView

  • since GTK 2.6
class type virtual ['obj, 'row, 'a, 'b, 'c] custom_tree_model_type = object ... end
class virtual ['row, 'a, 'b, 'c] custom_tree_model : column_list -> [ Gtk.tree_model_custom, 'row, 'a, 'b, 'c ] custom_tree_model_type

A base class to inherit from to make a custom tree model.