]> matita.cs.unibo.it Git - helm.git/commitdiff
merged transformations on top of notation code
authorStefano Zacchiroli <zack@upsilon.cc>
Mon, 25 Jul 2005 10:16:06 +0000 (10:16 +0000)
committerStefano Zacchiroli <zack@upsilon.cc>
Mon, 25 Jul 2005 10:16:06 +0000 (10:16 +0000)
helm/matita/.cvsignore
helm/matita/buildTimeConf.ml.in
helm/matita/configure.ac
helm/matita/core_notation.ma
helm/matita/dictionary-matita.xml [new file with mode: 0644]
helm/matita/gtkmathview.matita.conf.xml.in [new file with mode: 0644]
helm/matita/matita.ml

index bf527ad6ca0002ce86f91cbf4b9427a290218991..1498f48926b9e7406c41b7188b20e23f73217432 100644 (file)
@@ -38,3 +38,4 @@ matitamake.opt
 matita.conf.xml
 *.moo
 matita.conf.xml.sample
+gtkmathview.matita.conf.xml
index b38eb2ce4664b2196b49c00f5a9a67e15ac9843c..5ceabc66f7bcdd8cd4e187a17a501ab9087aeeff 100644 (file)
@@ -42,6 +42,7 @@ let lang_file  = runtime_base_dir ^ "/matita.lang"
 let script_template  = runtime_base_dir ^ "/matita.ma.templ"
 let core_notation_script = runtime_base_dir ^ "/core_notation.ma"
 let matita_conf  = runtime_base_dir ^ "/matita.conf.xml"
+let gtkmathview_conf = runtime_base_dir ^ "/gtkmathview.matita.conf.xml"
 
 let matitamake_makefile_template = runtime_base_dir ^ "/template_makefile.in"
 
index 678cc23422ec29fc69d298b2aeb3acfb7525c006..ce2d8243210910bec0a9e35c4f29884b9458f737 100644 (file)
@@ -112,4 +112,5 @@ AC_OUTPUT([
   matita.conf.xml.sample
   buildTimeConf.ml
   Makefile
+  gtkmathview.matita.conf.xml
 ])
index 486e921b5d4ba717bb317976e8ec8736c48def1d..680ebb7b5ac858a028708a4dbb4896bbe8175800 100644 (file)
@@ -2,6 +2,10 @@ notation "hvbox(a break \to b)"
   right associative with precedence 20
 for @{ \forall $_:$a.$b }.
 
+notation < "hvbox(a break \to b)" 
+  right associative with precedence 20
+for @{ \Pi $_:$a.$b }.
+
 notation "hvbox(a break = b)" 
   non associative with precedence 45
 for @{ 'eq $a $b }.
@@ -91,6 +95,13 @@ interpretation "real unary minus" 'uminus x = (cic:/Coq/Reals/Rdefinitions/Ropp.
 interpretation "binary integer negative sign" 'uminus x = (cic:/Coq/ZArith/BinInt/Z.ind#xpointer(1/1/3) x).
 interpretation "binary integer unary minus" 'uminus x = (cic:/Coq/ZArith/BinInt/Zopp.con x).
 
+(* logical operators *)
+
+interpretation "logical and" 'and x y = (cic:/Coq/Init/Logic/and.ind#xpointer(1/1) x y).
+interpretation "logical or" 'or x y = (cic:/Coq/Init/Logic/or.ind#xpointer(1/1) x y).
+interpretation "logical not" 'not x = (cic:/Coq/Init/Logic/not.con x).
+interpretation "exists" 'exists x y = (cic:/Coq/Init/Logic/ex.ind#xpointer(1/1) x y).
+
 (* relational operators *)
 
 interpretation "natural 'less or equal to'" 'leq x y = (cic:/Coq/Init/Peano/le.ind#xpointer(1/1) x y).
@@ -105,22 +116,3 @@ interpretation "real 'greater than'" 'gt x y = (cic:/Coq/Reals/Rdefinitions/Rgt.
 interpretation "leibnitz's equality" 'eq x y = (cic:/Coq/Init/Logic/eq.ind#xpointer(1/1) _ x y).
 interpretation "not equal to (leibnitz)" 'neq x y = (cic:/Coq/Init/Logic/not.con (cic:/Coq/Init/Logic/eq.ind#xpointer(1/1) _ x y)).
 
-(* logical operators *)
-
-interpretation "logical and" 'and x y = (cic:/Coq/Init/Logic/and.ind#xpointer(1/1) x y).
-interpretation "logical or" 'or x y = (cic:/Coq/Init/Logic/or.ind#xpointer(1/1) x y).
-interpretation "logical not" 'not x = (cic:/Coq/Init/Logic/not.con x).
-interpretation "exists" 'exists x y = (cic:/Coq/Init/Logic/ex.ind#xpointer(1/1) x y).
-
-(*
-  add_symbol_choice "cast"
-    ("type cast",
-      (fun env _ args ->
-        let t1, t2 =
-          match args with 
-          | [t1; t2] -> t1, t2
-          | _ -> raise Invalid_choice
-        in
-        Cic.Cast (t1, t2)));
-*)
-
diff --git a/helm/matita/dictionary-matita.xml b/helm/matita/dictionary-matita.xml
new file mode 100644 (file)
index 0000000..4f883e7
--- /dev/null
@@ -0,0 +1,15 @@
+<?xml version="1.0"?>
+<dictionary>
+ <operator name="(" form="prefix" fence="true" stretchy="false" lspace="2em" rspace="0em"/>
+ <operator name="(" form="infix" fence="true" stretchy="false" lspace="2em" rspace="0em"/>
+ <operator name=")" form="postfix" fence="true" stretchy="false" lspace="0em" rspace="0em"/>
+ <operator name=")" form="infix" fence="true" stretchy="false" lspace="0em" rspace="0em"/>
+ <operator name="[" form="prefix" fence="true" stretchy="false" lspace="0em" rspace="0em"/>
+ <operator name="[" form="infix" fence="true" stretchy="false" lspace="0em" rspace="0em"/>
+ <operator name="]" form="postfix" fence="true" stretchy="false" lspace="0em" rspace="0em"/>
+ <operator name="]" form="infix" fence="true" stretchy="false" lspace="0em" rspace="0em"/>
+ <operator name="{" form="prefix" fence="true" stretchy="false" lspace="0em" rspace="0em"/>
+ <operator name="{" form="infix" fence="true" stretchy="false" lspace="0em" rspace="0em"/>
+ <operator name="}" form="postfix" fence="true" stretchy="false" lspace="0em" rspace="0em"/>
+ <operator name="}" form="infix" fence="true" stretchy="false" lspace="0em" rspace="0em"/>
+</dictionary>
diff --git a/helm/matita/gtkmathview.matita.conf.xml.in b/helm/matita/gtkmathview.matita.conf.xml.in
new file mode 100644 (file)
index 0000000..0a33ae6
--- /dev/null
@@ -0,0 +1,15 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<math-engine-configuration>
+  <section name="dictionary">
+    <key name="path">@RT_BASE_DIR@/dictionary-matita.xml</key>
+  </section>
+  <section name="gtk-backend">
+    <section name="pango-default-shaper">
+      <section name="variants">
+        <section name="italic">
+          <key name="style">normal</key>
+        </section>
+      </section>
+    </section>
+  </section>
+</math-engine-configuration>
index d4f9c3fac85bd102e472bc2a9e06648b20b65e4a..aae334abd56e79927c748b3636c02a3160222468 100644 (file)
@@ -44,6 +44,8 @@ let _ =
   MatitaDb.create_owner_environment ();
   MatitamakeLib.initialize ();
   GtkMain.Rc.add_default_file BuildTimeConf.gtkrc_file; (* loads gtk rc *)
+  prerr_endline BuildTimeConf.gtkmathview_conf;
+  GMathView.add_configuration_path BuildTimeConf.gtkmathview_conf;
   ignore (GMain.Main.init ());
   CicEnvironment.set_trust (* environment trust *)
     (let trust = Helm_registry.get_bool "matita.environment_trust" in