2 * Stefano Zacchiroli <zack@cs.unibo.it>
3 * Claudio Sacerdoti Coen <sacerdot@cs.unibo.it>
5 * This file is part of lablgtksourceview, the OCaml binding for the
6 * GtkSourceView widget.
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.
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.
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
23 * For details, send a mail to the authors.
28 (** {2 GtkSourceLanguage} *)
30 class source_language_signals:
31 ([> Gtk_sourceview.source_language ] as 'b) obj ->
33 inherit ['b] GObj.gobject_signals
34 method tag_style_changed: callback:(string -> unit) -> GtkSignal.id
37 class source_language:
38 Gtk_sourceview.source_language obj ->
40 method as_source_language: Gtk_sourceview.source_language obj
41 method connect: source_language_signals
42 method get_escape_char: Glib.unichar
43 method get_name: string
44 method get_section: string
45 method misc: GObj.gobject_ops
48 (** {2 GtkSourceBuffer} *)
50 class source_buffer_signals:
51 ([> Gtk_sourceview.source_buffer ] as 'b) obj ->
53 inherit GText.buffer_signals
54 method can_redo: callback:(bool -> unit) -> GtkSignal.id
55 method can_undo: callback:(bool -> unit) -> GtkSignal.id
56 method highlight_updated:
57 callback:(Gtk.text_iter -> Gtk.text_iter -> unit) -> GtkSignal.id
58 method marker_updated: callback:(Gtk.text_iter -> unit) -> GtkSignal.id
62 Gtk_sourceview.source_buffer obj ->
64 inherit GText.buffer_skel
65 method connect: source_buffer_signals
66 method misc: GObj.gobject_ops
67 method check_brackets: bool
68 method set_check_brackets: bool -> unit
69 (* method set_bracket_match_style: tag_style -> unit *)
70 method highlight: bool
71 method set_highlight: bool -> unit
72 method max_undo_levels: int
73 method set_max_undo_levels: int -> unit
74 method language: source_language option
75 method set_language: source_language -> unit
76 method escape_char: Glib.unichar
77 method set_escape_char: Glib.unichar -> unit
80 method undo: unit -> unit
81 method redo: unit -> unit
82 method begin_not_undoable_action: unit -> unit
83 method end_not_undoable_action: unit -> unit
84 (* method create_marker: name:char -> typ:char -> source_marker *)
85 (* method move_marker: source_marker -> Gtext.text_iter -> unit *)
86 (* method delete_marker: source_marker -> unit *)
87 (* method get_marker: name:char -> source_marker *)
88 (* method get_markers_in_region:
89 start:text_iter -> stop:text_iter -> source_marker list *)
90 (* method get_first_marker: unit -> source_marker *)
91 (* method get_last_marker: unit -> source_marker *)
92 (* method get_iter_at_marker: ... *)
93 (* method get_next_marker: unit -> source_marker *)
94 (* method get_prev_marker: unit -> source_marker *)
98 ?language:source_language ->
99 (* ?tag_table:source_tag_table -> *)
101 ?check_brackets:bool ->
104 ?max_undo_levels:int ->
108 (** {2 GtkSourceView} *)
110 class source_view_signals:
111 ([> Gtk_sourceview.source_view ] as 'b) obj ->
113 inherit GText.view_signals
114 method redo: callback:(unit -> unit) -> GtkSignal.id
115 method undo: callback:(unit -> unit) -> GtkSignal.id
119 Gtk_sourceview.source_view obj ->
121 inherit GText.view_skel
122 val obj: Gtk_sourceview.source_view obj
123 method connect: source_view_signals
124 method source_buffer: source_buffer
125 method set_show_line_numbers: bool -> unit
126 method show_line_numbers: bool
127 method set_show_line_markers: bool -> unit
128 method show_line_markers: bool
129 method set_tabs_width: int -> unit
130 method tabs_width: int
131 method set_auto_indent: bool -> unit
132 method auto_indent: bool
133 method set_insert_spaces_instead_of_tabs: bool -> unit
134 method insert_spaces_instead_of_tabs: bool
135 method set_show_margin: bool -> unit
136 method show_margin: bool
137 method set_margin: int -> unit
139 (* method set_marker_pixbuf: GdkPixbuf.pixbuf -> unit *)
140 (* method marker_pixbuf: GdkPixbuf.pixbuf *)
141 method set_smart_home_end: bool -> unit
142 method smart_home_end: bool
146 ?source_buffer:source_buffer ->
148 ?insert_spaces_instead_of_tabs:bool ->
150 ?show_line_markers:bool ->
151 ?show_line_numbers:bool ->
153 ?smart_home_end:bool ->
156 ?cursor_visible:bool ->
157 ?justification:GtkEnums.justification ->
158 ?wrap_mode:GtkEnums.wrap_mode ->
162 ?packing:(GObj.widget -> unit) ->