]> matita.cs.unibo.it Git - helm.git/blob - helm/DEVEL/lablgtkmathview/gMathView.mli
* bind of method get_drawing_area
[helm.git] / helm / DEVEL / lablgtkmathview / gMathView.mli
1 (* Copyright (C) 2000-2003, Luca Padovani <luca.padovani@cs.unibo.it>,
2  *                          Claudio Sacerdoti Coen <sacerdot@cs.unibo.it>.
3  *
4  * This file is part of lablgtkmathview, the Ocaml binding
5  * for the GtkMathView widget.
6  * 
7  * lablgtkmathview is free software; you can redistribute it and/or
8  * modify it under the terms of the GNU General Public License
9  * as published by the Free Software Foundation; either version 2
10  * of the License, or (at your option) any later version.
11  *
12  * lablgtkmathview is distributed in the hope that it will be useful,
13  * but WITHOUT ANY WARRANTY; without even the implied warranty of
14  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
15  * GNU General Public License for more details.
16  *
17  * You should have received a copy of the GNU General Public License
18  * along with lablgtkmathview; if not, write to the Free Software
19  * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA  02111-1307, USA.
20  * 
21  * For details, send a mail to the author.
22  *)
23
24 exception ErrorLoadingFile of string
25 exception ErrorWritingFile of string
26 exception ErrorLoadingDOM
27 exception NoSelection
28
29 class math_view_signals :
30   ([> `container | `widget | `base | `math_view] as 'b) Gtk.obj ->
31   object ('a)
32     inherit GContainer.container_signals
33     val obj: 'b Gtk.obj
34     method click : callback:(Gdome.element -> int -> unit) -> GtkSignal.id
35     method element_over :
36       callback:(Gdome.element option -> int -> unit) -> GtkSignal.id
37     method select_begin :
38       callback:(Gdome.element option -> int -> unit) -> GtkSignal.id
39     method select_over :
40       callback:(Gdome.element option -> int -> unit) -> GtkSignal.id
41     method select_end :
42       callback:(Gdome.element option -> int -> unit) -> GtkSignal.id
43     method select_abort :
44       callback:(unit -> unit) -> GtkSignal.id
45   end
46
47 class math_view_skel :
48   (Gtk_mathview.math_view Gtk.obj as 'a)->
49   object
50     inherit GContainer.container
51     method freeze : unit
52     method thaw : unit
53     method export_to_postscript :
54       ?width:int ->
55       ?height:int ->
56       ?x_margin:int ->
57       ?y_margin:int ->
58       ?disable_colors:bool -> filename:string -> unit -> unit
59     method get_anti_aliasing : bool
60     method get_buffer : Gdk.pixmap
61     method get_font_manager_type : [ `font_manager_gtk | `font_manager_t1]
62     method get_font_size : int
63     method get_frame : GBin.frame
64     method get_drawing_area : GMisc.drawing_area
65     method get_hadjustment : GData.adjustment
66     method get_height : int
67     method get_log_verbosity : int
68     method get_top : int * int
69     method get_transparency : bool
70     method get_vadjustment : GData.adjustment
71     method get_width : int
72     method load_uri : filename:string -> unit
73     method load_doc : dom:Gdome.document -> unit
74     method set_adjustments : GData.adjustment -> GData.adjustment -> unit
75     method set_anti_aliasing : bool -> unit
76     method set_font_manager_type :
77       fm_type:[ `font_manager_gtk | `font_manager_t1] -> unit
78     method set_font_size : int -> unit
79     method set_log_verbosity : int -> unit
80     method select : Gdome.element -> unit
81     method unselect : Gdome.element -> unit
82     method get_element_at : int -> int -> Gdome.element option
83     method is_selected : Gdome.element -> bool
84     method set_top : int -> int -> unit
85     method set_transparency : bool -> unit
86     method unload : unit
87     val obj : 'a
88   end
89
90 class math_view :
91   Gtk_mathview.math_view Gtk.obj ->
92   object
93     inherit math_view_skel
94     method connect : math_view_signals
95   end
96
97 val math_view :
98   ?adjustmenth:GData.adjustment ->
99   ?adjustmentv:GData.adjustment ->
100   ?font_size:int ->
101   ?font_manager:[ `font_manager_gtk | `font_manager_t1] ->
102   ?border_width:int ->
103   ?width:int ->
104   ?height:int ->
105   ?packing:(GObj.widget -> unit) -> ?show:bool -> unit -> math_view