X-Git-Url: http://matita.cs.unibo.it/gitweb/?a=blobdiff_plain;f=helm%2FDEVEL%2Flablgtkmathview%2FgMathView.ml;h=00c239afc5e8e96caac61abff77a88bced64756a;hb=aa4eb8949201e7a7b54e3459ec0fe271e126049c;hp=41df006325aa26c0da20fbdd839e54518daa5a34;hpb=4a97b3700b140024e1783ac12501ad5dfa4be9b5;p=helm.git diff --git a/helm/DEVEL/lablgtkmathview/gMathView.ml b/helm/DEVEL/lablgtkmathview/gMathView.ml index 41df00632..00c239afc 100644 --- a/helm/DEVEL/lablgtkmathview/gMathView.ml +++ b/helm/DEVEL/lablgtkmathview/gMathView.ml @@ -20,24 +20,25 @@ * For details, send a mail to the author. *) -(*open Gaux*) +open Gaux open Gtk open Gtk_mathview open GtkBase open GtkMathView open GObj -open Misc exception ErrorLoadingFile of string;; exception ErrorWritingFile of string;; +exception ErrorLoadingDOM;; exception NoSelection;; class math_view_signals obj = object inherit GContainer.container_signals obj method clicked = GtkSignal.connect ~sgn:MathView.Signals.clicked obj ~after - method jump = GtkSignal.connect ~sgn:MathView.Signals.jump obj ~after method selection_changed = - GtkSignal.connect ~sgn:MathView.Signals.selection_changed obj ~after + GtkSignal.connect ~sgn:MathView.Signals.selection_changed obj ~after + method element_changed = + GtkSignal.connect ~sgn:MathView.Signals.element_changed obj ~after end class math_view obj = object @@ -45,6 +46,8 @@ class math_view obj = object method connect = new math_view_signals obj method load ~filename = if not (MathView.load obj ~filename) then raise (ErrorLoadingFile filename) + method load_tree ~dom = + if not (MathView.load_tree obj ~dom) then raise ErrorLoadingDOM method unload = MathView.unload obj method get_selection = MathView.get_selection obj method set_selection (node : Ominidom.o_mDOMNode option) = MathView.set_selection obj node @@ -59,13 +62,15 @@ class math_view obj = object method get_hadjustment = new GData.adjustment (MathView.get_hadjustment obj) method get_vadjustment = new GData.adjustment (MathView.get_vadjustment obj) method get_buffer = MathView.get_buffer obj - method get_frame = new GFrame.frame (MathView.get_frame obj) + method get_frame = new GBin.frame (MathView.get_frame obj) method set_font_size = MathView.set_font_size obj method get_font_size = MathView.get_font_size obj method set_anti_aliasing = MathView.set_anti_aliasing obj method get_anti_aliasing = MathView.get_anti_aliasing obj method set_kerning = MathView.set_kerning obj method get_kerning = MathView.get_kerning obj + method set_transparency = MathView.set_transparency obj + method get_transparency = MathView.get_transparency obj method set_log_verbosity = MathView.set_log_verbosity obj method get_log_verbosity = MathView.get_log_verbosity obj method export_to_postscript @@ -77,6 +82,11 @@ class math_view obj = object if not result then raise (ErrorWritingFile filename) method get_font_manager_type = MathView.get_font_manager_type obj method set_font_manager_type ~fm_type = MathView.set_font_manager_type obj ~fm_type + method get_element = MathView.get_element obj + method action_get_selected = MathView.action_get_selected obj + method action_set_selected = MathView.action_set_selected obj + method get_action = MathView.get_action obj + method action_toggle = MathView.action_toggle obj end let math_view ?adjustmenth ?adjustmentv ?font_size ?font_manager ?border_width