module Gtk_helper: sig
.. end
Generic Gtk helpers.
Consult the Plugin Development Guide for additional details.
val apply_tag : GSourceView.source_buffer -> GText.tag -> int -> int -> unit
val remove_tag : GSourceView.source_buffer -> GText.tag -> int -> int -> unit
val cleanup_tag : GSourceView.source_buffer -> GText.tag -> unit
val cleanup_all_tags : GSourceView.source_buffer -> unit
val expand_to_path : GTree.view -> Gtk.tree_path -> unit
val make_tag : < create_tag : ?name:string -> GText.tag_property list -> GText.tag;
tag_table : Gtk.text_tag_table; .. > ->
name:string -> GText.tag_property list -> GText.tag
val make_formatter : ?flush:(unit -> unit) -> #GText.buffer -> Format.formatter
Build a formatter that redirects its output to the given buffer.
flush
is called whenever the formatter is flushed.
val channel_redirector : Unix.file_descr -> (string -> bool) -> unit
Redirects all strings written to the file descriptor
and call the given function on each.
val log_redirector : ?flush:(unit -> unit) -> (string -> unit) -> unit
Redirects all strings written to the terminal and call the given function
on each.
val redirect : Format.formatter -> #GText.buffer -> unit
Redirect the given formatter to the given buffer
val gui_unlocked : bool Pervasives.ref
This is a mutex you may use to prevent running some code while the GUI
is locked.
val register_locking_machinery : lock:(unit -> unit) -> unlock:(unit -> unit) -> unit
Add hooks to the locking mechanism of the GUI.
Since Beryllium-20090901
val refresh_gui : unit -> unit
Process pending events in the main Glib loop.
This is intended to be called only when !gui_unlocked == false
.
Since Beryllium-20090901
val string_selector : string list -> (GObj.widget -> unit) -> GEdit.entry
val make_string_list : packing:(GObj.widget -> unit) ->
(string -> unit) * (unit -> unit) * (unit -> string list)
Returns (add, remove_selected, get_elements)
type 'a
chooser = GPack.box -> string -> (unit -> 'a) -> ('a -> unit) -> unit -> unit
Pack a check button with the given getter and setter.
val on_bool : ?use_markup:bool -> bool chooser
val on_bool_radio : ?use_markup:bool ->
GPack.box ->
string -> string -> (unit -> bool) -> (bool -> unit) -> unit -> unit
val on_int : ?use_markup:bool ->
?lower:int ->
?upper:int -> ?sensitive:(unit -> bool) -> int chooser
Returns a function usable for refreshing purpose.
By default, sensitivity is set to true when this function is called.
val on_string : ?use_markup:bool -> ?validator:(string -> bool) -> string chooser
val on_string_set : ?use_markup:bool -> string chooser
val on_string_completion : ?use_markup:bool ->
?validator:(string -> bool) -> string list -> string chooser
val place_paned : GPack.paned -> float -> unit
Sets the position of the paned widget to the given ratio
val old_gtk_compat : ('a -> unit) -> 'a -> unit
Catch exception Not_found
and do nothing
module MAKE_CUSTOM_LIST: functor (
A
:
sig
type
t
val custom_value : Gobject.g_type ->
t -> column:int -> Gobject.basic
val column_list : GTree.column_list
end
) ->
sig
.. end
A functor to build custom Gtk lists.
class type host = object
.. end
A utility class to catch exceptions and report proper error messages.
class error_manager : GWindow.window_skel ->
host
A utility class to catch exceptions and report proper error messages.
val make_text_page : GPack.notebook -> string -> (GPack.notebook -> unit) * GText.view
Insert a GText.view in a new page of the notebook with the given title.
It returns a new GText.view together with a function to reparent the
inserted page in another notebook.
The tab label of the created page will be highlighted whenever its
contents changes.
Since Beryllium-20090901