]> matita.cs.unibo.it Git - helm.git/commitdiff
simplified cicBrowser: whelp bar is now always visible
authorStefano Zacchiroli <zack@upsilon.cc>
Thu, 9 Jun 2005 07:35:30 +0000 (07:35 +0000)
committerStefano Zacchiroli <zack@upsilon.cc>
Thu, 9 Jun 2005 07:35:30 +0000 (07:35 +0000)
helm/matita/matita.glade
helm/matita/matitaGui.ml
helm/matita/matitaMathView.ml

index 690e17749e63e91cc6ae835bff211f74ed2afe39..9444e6a9347b70be436ce46607ec38e2e8c62cb6 100644 (file)
@@ -122,14 +122,12 @@ Copyright (C) 2005,
                  <child>
                    <widget class="GtkButton" id="BrowserNewButton">
                      <property name="visible">True</property>
-                     <property name="tooltip" translatable="yes">new browser win</property>
-                     <property name="can_default">True</property>
                      <property name="can_focus">True</property>
                      <property name="relief">GTK_RELIEF_NONE</property>
-                     <property name="focus_on_click">False</property>
+                     <property name="focus_on_click">True</property>
 
                      <child>
-                       <widget class="GtkImage" id="image191">
+                       <widget class="GtkImage" id="image303">
                          <property name="visible">True</property>
                          <property name="stock">gtk-new</property>
                          <property name="icon_size">4</property>
@@ -150,69 +148,19 @@ Copyright (C) 2005,
                  <child>
                    <widget class="GtkButton" id="BrowserBackButton">
                      <property name="visible">True</property>
-                     <property name="tooltip" translatable="yes">history back</property>
-                     <property name="can_default">True</property>
                      <property name="can_focus">True</property>
                      <property name="relief">GTK_RELIEF_NONE</property>
                      <property name="focus_on_click">True</property>
 
                      <child>
-                       <widget class="GtkAlignment" id="alignment3">
+                       <widget class="GtkImage" id="image304">
                          <property name="visible">True</property>
+                         <property name="stock">gtk-go-back</property>
+                         <property name="icon_size">4</property>
                          <property name="xalign">0.5</property>
                          <property name="yalign">0.5</property>
-                         <property name="xscale">0</property>
-                         <property name="yscale">0</property>
-                         <property name="top_padding">0</property>
-                         <property name="bottom_padding">0</property>
-                         <property name="left_padding">0</property>
-                         <property name="right_padding">0</property>
-
-                         <child>
-                           <widget class="GtkHBox" id="hbox6">
-                             <property name="visible">True</property>
-                             <property name="homogeneous">False</property>
-                             <property name="spacing">2</property>
-
-                             <child>
-                               <widget class="GtkImage" id="image188">
-                                 <property name="visible">True</property>
-                                 <property name="stock">gtk-go-back</property>
-                                 <property name="icon_size">4</property>
-                                 <property name="xalign">0.5</property>
-                                 <property name="yalign">0.5</property>
-                                 <property name="xpad">0</property>
-                                 <property name="ypad">0</property>
-                               </widget>
-                               <packing>
-                                 <property name="padding">0</property>
-                                 <property name="expand">False</property>
-                                 <property name="fill">False</property>
-                               </packing>
-                             </child>
-
-                             <child>
-                               <widget class="GtkLabel" id="label10">
-                                 <property name="visible">True</property>
-                                 <property name="label" translatable="yes"></property>
-                                 <property name="use_underline">True</property>
-                                 <property name="use_markup">False</property>
-                                 <property name="justify">GTK_JUSTIFY_LEFT</property>
-                                 <property name="wrap">False</property>
-                                 <property name="selectable">False</property>
-                                 <property name="xalign">0.5</property>
-                                 <property name="yalign">0.5</property>
-                                 <property name="xpad">0</property>
-                                 <property name="ypad">0</property>
-                               </widget>
-                               <packing>
-                                 <property name="padding">0</property>
-                                 <property name="expand">False</property>
-                                 <property name="fill">False</property>
-                               </packing>
-                             </child>
-                           </widget>
-                         </child>
+                         <property name="xpad">0</property>
+                         <property name="ypad">0</property>
                        </widget>
                      </child>
                    </widget>
@@ -226,14 +174,12 @@ Copyright (C) 2005,
                  <child>
                    <widget class="GtkButton" id="BrowserForwardButton">
                      <property name="visible">True</property>
-                     <property name="tooltip" translatable="yes">history forward</property>
-                     <property name="can_default">True</property>
                      <property name="can_focus">True</property>
                      <property name="relief">GTK_RELIEF_NONE</property>
                      <property name="focus_on_click">True</property>
 
                      <child>
-                       <widget class="GtkImage" id="image189">
+                       <widget class="GtkImage" id="image305">
                          <property name="visible">True</property>
                          <property name="stock">gtk-go-forward</property>
                          <property name="icon_size">4</property>
@@ -311,7 +257,7 @@ Copyright (C) 2005,
                    <widget class="GtkImage" id="image301">
                      <property name="visible">True</property>
                      <property name="stock">gtk-jump-to</property>
-                     <property name="icon_size">4</property>
+                     <property name="icon_size">2</property>
                      <property name="xalign">0.5</property>
                      <property name="yalign">0.5</property>
                      <property name="xpad">0</property>
@@ -325,62 +271,19 @@ Copyright (C) 2005,
                  </child>
 
                  <child>
-                   <placeholder/>
-                 </child>
-
-                 <child>
-                   <widget class="GtkImage" id="whelpImage2">
-                     <property name="visible">True</property>
-                     <property name="xalign">0.5</property>
-                     <property name="yalign">0.5</property>
-                     <property name="xpad">0</property>
-                     <property name="ypad">0</property>
-                   </widget>
-                   <packing>
-                     <property name="padding">0</property>
-                     <property name="expand">False</property>
-                     <property name="fill">False</property>
-                   </packing>
-                 </child>
-
-                 <child>
-                   <widget class="GtkToggleButton" id="whelpBarToggleButton">
+                   <widget class="GtkHBox" id="UriHBox">
                      <property name="visible">True</property>
-                     <property name="can_focus">True</property>
-                     <property name="relief">GTK_RELIEF_NONE</property>
-                     <property name="focus_on_click">True</property>
-                     <property name="active">False</property>
-                     <property name="inconsistent">False</property>
+                     <property name="homogeneous">False</property>
+                     <property name="spacing">0</property>
 
                      <child>
-                       <widget class="GtkHBox" id="hbox15">
-                         <property name="visible">True</property>
-                         <property name="homogeneous">False</property>
-                         <property name="spacing">0</property>
-
-                         <child>
-                           <widget class="GtkArrow" id="arrow1">
-                             <property name="visible">True</property>
-                             <property name="arrow_type">GTK_ARROW_DOWN</property>
-                             <property name="shadow_type">GTK_SHADOW_NONE</property>
-                             <property name="xalign">0.5</property>
-                             <property name="yalign">0.5</property>
-                             <property name="xpad">0</property>
-                             <property name="ypad">0</property>
-                           </widget>
-                           <packing>
-                             <property name="padding">0</property>
-                             <property name="expand">True</property>
-                             <property name="fill">True</property>
-                           </packing>
-                         </child>
-                       </widget>
+                       <placeholder/>
                      </child>
                    </widget>
                    <packing>
                      <property name="padding">0</property>
-                     <property name="expand">False</property>
-                     <property name="fill">False</property>
+                     <property name="expand">True</property>
+                     <property name="fill">True</property>
                    </packing>
                  </child>
                </widget>
@@ -400,6 +303,21 @@ Copyright (C) 2005,
              <property name="homogeneous">False</property>
              <property name="spacing">6</property>
 
+             <child>
+               <widget class="GtkImage" id="WhelpBarImage">
+                 <property name="visible">True</property>
+                 <property name="xalign">0.5</property>
+                 <property name="yalign">0.5</property>
+                 <property name="xpad">0</property>
+                 <property name="ypad">0</property>
+               </widget>
+               <packing>
+                 <property name="padding">0</property>
+                 <property name="expand">False</property>
+                 <property name="fill">True</property>
+               </packing>
+             </child>
+
              <child>
                <widget class="GtkEntry" id="queryInputText">
                  <property name="visible">True</property>
@@ -420,7 +338,7 @@ Copyright (C) 2005,
              </child>
 
              <child>
-               <widget class="GtkVBox" id="comboVbox">
+               <widget class="GtkVBox" id="whelpBarComboVbox">
                  <property name="visible">True</property>
                  <property name="homogeneous">False</property>
                  <property name="spacing">0</property>
index a17b9bfb16942a8c62ba3cda6f6a186f8824fbad..08f097086fdc59540b7c9c683f3a6cf8d27b62f7 100644 (file)
@@ -289,8 +289,7 @@ class gui () =
         initializer
           self#check_widgets ();
           let combo_widget = combo#coerce in
-          browserHBox#add combo_widget;
-          browserHBox#reorder_child combo_widget ~pos:6
+          uriHBox#add combo_widget
         method browserUri = combo
       end
 
index 225738d581b88baee3bce8118e3d75fcc2f74d4f..75541ed9d49f93df76d54668e5c6e8502457410f 100644 (file)
@@ -359,7 +359,7 @@ class cicBrowser_impl ~(history:MatitaTypes.mathViewer_entry MatitaMisc.history)
 
     initializer
       activate_combo_query "" "locate";
-      win#comboVbox#add (combo :> GObj.widget);
+      win#whelpBarComboVbox#add combo#coerce;
       let start_query () = 
         let query = String.lowercase (List.nth queries combo#active) in
         let input = win#queryInputText#text in
@@ -368,16 +368,8 @@ class cicBrowser_impl ~(history:MatitaTypes.mathViewer_entry MatitaMisc.history)
       in
       ignore(win#queryInputText#connect#activate ~callback:start_query);
       ignore(combo#connect#changed ~callback:start_query);
-      win#whelpImage2#set_file "icons/whelp.png";
-      win#whelpBarToggleButton#set_active false;   
-      win#whelpBarBox#misc#hide ();
+      win#whelpBarImage#set_file (MatitaMisc.image_path "whelp.png");
       win#mathOrListNotebook#set_show_tabs false;
-      MatitaGtkMisc.connect_toggle_button win#whelpBarToggleButton 
-        (fun () -> 
-          if win#whelpBarToggleButton#active then
-            win#whelpBarBox#misc#show ()
-          else
-            win#whelpBarBox#misc#hide ());
 
       win#browserForwardButton#misc#set_sensitive false;
       win#browserBackButton#misc#set_sensitive false;