]> matita.cs.unibo.it Git - helm.git/blob - helm/DEVEL/lablgtksourceview/gSourceView.mli
lablgtksourceview: first checkin, almost nothing bound ...
[helm.git] / helm / DEVEL / lablgtksourceview / gSourceView.mli
1 (* Copyright (C) 2005:
2  *      Stefano Zacchiroli     <zack@cs.unibo.it>
3  *      Claudio Sacerdoti Coen <sacerdot@cs.unibo.it>
4  *
5  * This file is part of lablgtksourceview, the OCaml binding for the
6  * GtkSourceView widget.
7  * 
8  * lablgtksourceview is free software; you can redistribute it and/or
9  * modify it under the terms of the GNU General Public License as
10  * published by the Free Software Foundation; either version 2 of the
11  * License, or (at your option) any later version.
12  *
13  * lablgtksourceview is distributed in the hope that it will be useful,
14  * but WITHOUT ANY WARRANTY; without even the implied warranty of
15  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
16  * General Public License for more details.
17  *
18  * You should have received a copy of the GNU General Public License
19  * along with lablgtksourceview; if not, write to the Free Software
20  * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
21  * 02111-1307, USA.
22  * 
23  * For details, send a mail to the authors.
24  *)
25
26 open Gtk
27
28 class source_view_signals :
29   ([> Gtk_sourceview.source_view ] as 'b) obj ->
30   object ('a)
31     method after : 'a
32     method copy_clipboard : callback:(unit -> unit) -> GtkSignal.id
33     method cut_clipboard : callback:(unit -> unit) -> GtkSignal.id
34     method delete_from_cursor :
35       callback:(Gtk.Tags.delete_type -> int -> unit) -> GtkSignal.id
36     method destroy : callback:(unit -> unit) -> GtkSignal.id
37     method insert_at_cursor : callback:(string -> unit) -> GtkSignal.id
38     method move_cursor :
39       callback:(Gtk.Tags.movement_step -> int -> extend:bool -> unit) ->
40         GtkSignal.id
41     method move_focus :
42       callback:(Gtk.Tags.direction_type -> unit) -> GtkSignal.id
43     method page_horizontally :
44       callback:(int -> extend:bool -> unit) -> GtkSignal.id
45     method paste_clipboard : callback:(unit -> unit) -> GtkSignal.id
46     method populate_popup :
47       callback:(Gtk.menu Gtk.obj -> unit) -> GtkSignal.id
48     method redo : callback:(unit -> unit) -> GtkSignal.id
49     method set_anchor : callback:(unit -> unit) -> GtkSignal.id
50     method set_scroll_adjustments :
51       callback:(GData.adjustment option -> GData.adjustment option -> unit) ->        GtkSignal.id
52     method toggle_overwrite : callback:(unit -> unit) -> GtkSignal.id
53     method undo : callback:(unit -> unit) -> GtkSignal.id
54   end
55
56 class source_view :
57   Gtk_sourceview.source_view Gtk.obj ->
58   object
59     method add_child_at_anchor : GObj.widget -> GText.child_anchor -> unit
60     method add_child_in_window :
61       child:GObj.widget ->
62       which_window:Gtk.Tags.text_window_type -> x:int -> y:int -> unit
63     method as_view : Gtk.text_view Gtk.obj
64     method as_widget : Gtk.widget Gtk.obj
65     method backward_display_line : GText.iter -> bool
66     method backward_display_line_start : GText.iter -> bool
67     method buffer : GText.buffer
68     method buffer_to_window_coords :
69       tag:Gtk.Tags.text_window_type -> x:int -> y:int -> int * int
70     method coerce : GObj.widget
71     method connect : source_view_signals
72     method cursor_visible : bool
73     method destroy : unit -> unit
74     method drag : GObj.drag_ops
75     method editable : bool
76     method event : GObj.event_ops
77     method forward_display_line : GText.iter -> bool
78     method forward_display_line_end : GText.iter -> bool
79     method get_border_window_size :
80       [ `BOTTOM | `LEFT | `RIGHT | `TOP ] -> int
81     method get_iter_at_location : x:int -> y:int -> GText.iter
82     method get_iter_location : GText.iter -> Gdk.Rectangle.t
83     method get_line_at_y : int -> GText.iter * int
84     method get_line_yrange : GText.iter -> int * int
85     method get_oid : int
86     method get_window : Gtk.Tags.text_window_type -> Gdk.window option
87     method get_window_type : Gdk.window -> Gtk.Tags.text_window_type
88     method indent : int
89     method justification : Gtk.Tags.justification
90     method left_margin : int
91     method misc : GObj.misc_ops
92     method move_child : child:GObj.widget -> x:int -> y:int -> unit
93     method move_mark_onscreen : GText.mark -> bool
94     method move_visually : GText.iter -> int -> bool
95     method pixels_above_lines : int
96     method pixels_below_lines : int
97     method pixels_inside_wrap : int
98     method place_cursor_onscreen : unit -> bool
99     method right_margin : int
100     method scroll_mark_onscreen : GText.mark -> unit
101     method scroll_to_iter :
102       ?within_margin:float ->
103       ?use_align:bool -> ?xalign:float -> ?yalign:float -> GText.iter -> bool
104     method scroll_to_mark :
105       ?within_margin:float ->
106       ?use_align:bool -> ?xalign:float -> ?yalign:float -> GText.mark -> unit
107     method set_border_window_size :
108       typ:[ `BOTTOM | `LEFT | `RIGHT | `TOP ] -> size:int -> unit
109     method set_buffer : GText.buffer -> unit
110     method set_cursor_visible : bool -> unit
111     method set_editable : bool -> unit
112     method set_indent : int -> unit
113     method set_justification : Gtk.Tags.justification -> unit
114     method set_left_margin : int -> unit
115     method set_pixels_above_lines : int -> unit
116     method set_pixels_below_lines : int -> unit
117     method set_pixels_inside_wrap : int -> unit
118     method set_right_margin : int -> unit
119     method set_show_line_numbers : bool -> unit
120     method set_wrap_mode : Gtk.Tags.wrap_mode -> unit
121     method show_line_numbers : bool
122     method starts_display_line : GText.iter -> bool
123     method visible_rect : Gdk.Rectangle.t
124     method window_to_buffer_coords :
125       tag:Gtk.Tags.text_window_type -> x:int -> y:int -> int * int
126     method wrap_mode : Gtk.Tags.wrap_mode
127   end
128
129 val source_view :
130   ?auto_indent:bool ->
131   ?insert_spaces_instead_of_tabs:bool ->
132   ?margin:int ->
133   ?show_line_markers:bool ->
134   ?show_line_numbers:bool ->
135   ?show_margin:bool ->
136   ?smart_home_end:bool ->
137   ?tabs_width:int ->
138   ?editable:bool ->
139   ?cursor_visible:bool ->
140   ?justification:GtkEnums.justification ->
141   ?wrap_mode:GtkEnums.wrap_mode ->
142   ?border_width:int ->
143   ?width:int ->
144   ?height:int ->
145   ?packing:(GObj.widget -> unit) ->
146   ?show:bool ->
147   unit ->
148     source_view
149