X-Git-Url: http://matita.cs.unibo.it/gitweb/?a=blobdiff_plain;f=helm%2Fmatita%2FmatitaMathView.ml;h=3c4997aeca09e8437e9c6e9f647543fbae340983;hb=2b2b90087f836c2f32291935216549e9370e68c3;hp=a7299879a3a3292ab31785e0e7a558a74a4599c1;hpb=99b249b23524cda2d91602ee088fef1a7be253ee;p=helm.git diff --git a/helm/matita/matitaMathView.ml b/helm/matita/matitaMathView.ml index a7299879a..3c4997aec 100644 --- a/helm/matita/matitaMathView.ml +++ b/helm/matita/matitaMathView.ml @@ -23,6 +23,8 @@ * http://cs.unibo.it/helm/. *) +(* $Id$ *) + open Printf open GrafiteTypes @@ -154,7 +156,6 @@ type selected_term = class clickableMathView obj = let text_width = 80 in -let dummy_loc = DisambiguateTypes.dummy_floc in object (self) inherit GMathViewAux.multi_selection_math_view obj @@ -244,13 +245,13 @@ object (self) let reduction_action kind () = let pat = self#tactic_text_pattern_of_selection in let statement = - let loc = DisambiguateTypes.dummy_floc in + let loc = HExtlib.dummy_floc in + "\n" ^ GrafiteAstPp.pp_executable ~term_pp:(fun s -> s) ~lazy_term_pp:(fun _ -> assert false) ~obj_pp:(fun _ -> assert false) (GrafiteAst.Tactical (loc, GrafiteAst.Tactic (loc, GrafiteAst.Reduce (loc, kind, pat)), Some (GrafiteAst.Semicolon loc))) in - HLog.debug ("soon I'll evaluate: " ^ statement); (MatitaScript.current ())#advance ~statement () in connect_menu_item copy gui#copy; connect_menu_item normalize (reduction_action `Normalize); @@ -578,7 +579,7 @@ class sequentsViewer ~(notebook:GPack.notebook) ~(cicMathView:cicMathView) () = goal2page <- []; goal2win <- []; _metasenv <- []; - self#script#setGoal ~-1; + self#script#setGoal None method load_sequents { proof = (_,metasenv,_,_) as proof; stack = stack } = _metasenv <- metasenv; @@ -653,7 +654,7 @@ class sequentsViewer ~(notebook:GPack.notebook) ~(cicMathView:cicMathView) () = let goal_switch = try List.assoc page page2goal with Not_found -> assert false in - self#script#setGoal (goal_of_switch goal_switch); + self#script#setGoal (Some (goal_of_switch goal_switch)); self#render_page ~page ~goal_switch)) method private render_page ~page ~goal_switch = @@ -906,7 +907,7 @@ class cicBrowser_impl ~(history:MatitaTypes.mathViewer_entry MatitaMisc.history) method private home () = self#_showMath; - match self#script#status.proof_status with + match self#script#grafite_status.proof_status with | Proof (uri, metasenv, bo, ty) -> let name = UriManager.name_of_uri (HExtlib.unopt uri) in let obj = Cic.CurrentProof (name, metasenv, bo, ty, [], []) in