[orca/new-settings] Move profiles UI from Profiles tab to General tab.



commit 9c10d7f8e69eaea8bd5ff4e91745ff1e3300941b
Author: Alejandro Leiva <aleiva emergya es>
Date:   Tue Oct 19 13:58:54 2010 +0200

    Move profiles UI from Profiles tab to General tab.

 src/orca/app_gui_prefs.py  |    3 -
 src/orca/orca-setup.ui     |  290 +++++++++++++++++++++++---------------------
 src/orca/orca_gui_prefs.py |    4 +-
 3 files changed, 151 insertions(+), 146 deletions(-)
---
diff --git a/src/orca/app_gui_prefs.py b/src/orca/app_gui_prefs.py
index 7840bdd..896dd4e 100644
--- a/src/orca/app_gui_prefs.py
+++ b/src/orca/app_gui_prefs.py
@@ -92,9 +92,6 @@ class OrcaSetupGUI(orca_gui_prefs.OrcaSetupGUI):
         # self.get_widget("notebook").remove_page(0)
         self.get_widget("generalVBox").hide()
 
-        # Hide the profiles tab
-        self.get_widget("profilesVbox").hide()
-
         self.get_widget("speechSystemsLabel").set_sensitive(False)
         self.get_widget("speechSystems").set_sensitive(False)
         self.get_widget("speechServersLabel").set_sensitive(False)
diff --git a/src/orca/orca-setup.ui b/src/orca/orca-setup.ui
index de2bbe7..6a3e89d 100644
--- a/src/orca/orca-setup.ui
+++ b/src/orca/orca-setup.ui
@@ -272,7 +272,6 @@
   <object class="GtkDialog" id="orcaSetupWindow">
     <property name="title" translatable="yes">Orca Preferences</property>
     <property name="type_hint">normal</property>
-    <property name="has_separator">False</property>
     <signal name="destroy" handler="windowDestroyed"/>
     <signal name="close" handler="windowClosed"/>
     <child internal-child="vbox">
@@ -541,6 +540,152 @@
                         <property name="position">7</property>
                       </packing>
                     </child>
+                    <child>
+                      <object class="GtkFrame" id="profilesFrame">
+                        <property name="visible">True</property>
+                        <property name="label_xalign">0</property>
+                        <property name="shadow_type">none</property>
+                        <child>
+                          <object class="GtkAlignment" id="alignment5">
+                            <property name="visible">True</property>
+                            <property name="left_padding">12</property>
+                            <child>
+                              <object class="GtkVBox" id="profilesVbox1">
+                                <property name="visible">True</property>
+                                <child>
+                                  <object class="GtkAspectFrame" id="aspectframe2">
+                                    <property name="visible">True</property>
+                                    <property name="label_xalign">0</property>
+                                    <property name="shadow_type">none</property>
+                                    <property name="xalign">0</property>
+                                    <child>
+                                      <object class="GtkTable" id="profilesTable1">
+                                        <property name="visible">True</property>
+                                        <property name="n_rows">2</property>
+                                        <property name="n_columns">4</property>
+                                        <property name="column_spacing">6</property>
+                                        <property name="row_spacing">2</property>
+                                        <child>
+                                          <object class="GtkLabel" id="profilesLabel1">
+                                            <property name="width_request">150</property>
+                                            <property name="visible">True</property>
+                                            <property name="xalign">0</property>
+                                            <property name="xpad">12</property>
+                                            <property name="label" translatable="yes">Active Profile:</property>
+                                            <property name="ellipsize">start</property>
+                                            <accessibility>
+                                              <relation type="label-for" target="speechServers"/>
+                                            </accessibility>
+                                          </object>
+                                        </child>
+                                        <child>
+                                          <object class="GtkComboBox" id="availableProfilesComboBox1">
+                                            <property name="width_request">200</property>
+                                            <property name="visible">True</property>
+                                            <property name="model">model9</property>
+                                            <child>
+                                              <object class="GtkCellRendererText" id="cellrenderertext5"/>
+                                              <attributes>
+                                                <attribute name="text">0</attribute>
+                                              </attributes>
+                                            </child>
+                                          </object>
+                                          <packing>
+                                            <property name="left_attach">1</property>
+                                            <property name="right_attach">2</property>
+                                          </packing>
+                                        </child>
+                                        <child>
+                                          <object class="GtkButton" id="loadProfileButton">
+                                            <property name="label" translatable="yes" comments="This button will load the selected settings profile in the application.">_Load</property>
+                                            <property name="visible">True</property>
+                                            <property name="can_focus">True</property>
+                                            <property name="receives_default">True</property>
+                                            <property name="use_underline">True</property>
+                                            <signal name="clicked" handler="loadProfileButtonClicked"/>
+                                          </object>
+                                          <packing>
+                                            <property name="left_attach">2</property>
+                                            <property name="right_attach">3</property>
+                                          </packing>
+                                        </child>
+                                        <child>
+                                          <object class="GtkButton" id="saveProfileButton">
+                                            <property name="label">gtk-save-as</property>
+                                            <property name="visible">True</property>
+                                            <property name="can_focus">True</property>
+                                            <property name="receives_default">True</property>
+                                            <property name="use_stock">True</property>
+                                            <signal name="clicked" handler="showProfileGUI"/>
+                                          </object>
+                                          <packing>
+                                            <property name="left_attach">3</property>
+                                            <property name="right_attach">4</property>
+                                          </packing>
+                                        </child>
+                                        <child>
+                                          <object class="GtkLabel" id="startupProfileLabel1">
+                                            <property name="visible">True</property>
+                                            <property name="xalign">0</property>
+                                            <property name="xpad">12</property>
+                                            <property name="label" translatable="yes">Start-up Profile:</property>
+                                            <property name="ellipsize">end</property>
+                                          </object>
+                                          <packing>
+                                            <property name="top_attach">1</property>
+                                            <property name="bottom_attach">2</property>
+                                          </packing>
+                                        </child>
+                                        <child>
+                                          <object class="GtkComboBox" id="availableProfilesComboBox2">
+                                            <property name="visible">True</property>
+                                            <property name="model">model9</property>
+                                            <child>
+                                              <object class="GtkCellRendererText" id="cellrenderertext6"/>
+                                              <attributes>
+                                                <attribute name="text">0</attribute>
+                                              </attributes>
+                                            </child>
+                                          </object>
+                                          <packing>
+                                            <property name="left_attach">1</property>
+                                            <property name="right_attach">2</property>
+                                            <property name="top_attach">1</property>
+                                            <property name="bottom_attach">2</property>
+                                          </packing>
+                                        </child>
+                                        <child>
+                                          <placeholder/>
+                                        </child>
+                                        <child>
+                                          <placeholder/>
+                                        </child>
+                                      </object>
+                                    </child>
+                                  </object>
+                                  <packing>
+                                    <property name="expand">False</property>
+                                    <property name="fill">False</property>
+                                    <property name="padding">12</property>
+                                    <property name="position">0</property>
+                                  </packing>
+                                </child>
+                              </object>
+                            </child>
+                          </object>
+                        </child>
+                        <child type="label">
+                          <object class="GtkLabel" id="form2">
+                            <property name="visible">True</property>
+                            <property name="label" translatable="yes">&lt;b&gt;Profiles&lt;/b&gt;</property>
+                            <property name="use_markup">True</property>
+                          </object>
+                        </child>
+                      </object>
+                      <packing>
+                        <property name="position">8</property>
+                      </packing>
+                    </child>
                   </object>
                 </child>
                 <child type="tab">
@@ -2671,8 +2816,8 @@
                                                             <property name="climb_rate">1</property>
                                                             <property name="numeric">True</property>
                                                             <accessibility>
-                                                            <relation type="labelled-by" target="magCrossHairSizeUnitsLabel"/>
                                                             <relation type="labelled-by" target="magCrossHairSizeLabel"/>
+                                                            <relation type="labelled-by" target="magCrossHairSizeUnitsLabel"/>
                                                             </accessibility>
                                                             <signal name="value_changed" handler="magCrossHairSizeValueChanged"/>
                                                           </object>
@@ -2875,8 +3020,8 @@
                                                             <property name="climb_rate">1</property>
                                                             <property name="numeric">True</property>
                                                             <accessibility>
-                                                            <relation type="labelled-by" target="magCursorSizeUnitsLabel"/>
                                                             <relation type="labelled-by" target="magCursorSizeLabel"/>
+                                                            <relation type="labelled-by" target="magCursorSizeUnitsLabel"/>
                                                             </accessibility>
                                                             <signal name="value_changed" handler="magCursorSizeValueChanged"/>
                                                           </object>
@@ -3454,8 +3599,8 @@
                                                     <property name="climb_rate">1</property>
                                                     <property name="numeric">True</property>
                                                     <accessibility>
-                                                      <relation type="labelled-by" target="magEdgeMarginLabel"/>
                                                       <relation type="labelled-by" target="magEdgeMarginUnitsLabel"/>
+                                                      <relation type="labelled-by" target="magEdgeMarginLabel"/>
                                                     </accessibility>
                                                     <signal name="value_changed" handler="magEdgeMarginValueChanged"/>
                                                   </object>
@@ -4118,143 +4263,6 @@ attributes&lt;/b&gt;</property>
                     <property name="tab_fill">False</property>
                   </packing>
                 </child>
-                <child>
-                  <object class="GtkVBox" id="profilesVbox">
-                    <property name="visible">True</property>
-                    <child>
-                      <object class="GtkAspectFrame" id="aspectframe1">
-                        <property name="visible">True</property>
-                        <property name="label_xalign">0</property>
-                        <property name="shadow_type">none</property>
-                        <property name="xalign">0</property>
-                        <child>
-                          <object class="GtkTable" id="profilesTable">
-                            <property name="visible">True</property>
-                            <property name="n_rows">2</property>
-                            <property name="n_columns">4</property>
-                            <property name="column_spacing">6</property>
-                            <property name="row_spacing">2</property>
-                            <child>
-                              <object class="GtkLabel" id="profilesLabel">
-                                <property name="width_request">150</property>
-                                <property name="visible">True</property>
-                                <property name="xalign">0</property>
-                                <property name="xpad">12</property>
-                                <property name="label" translatable="yes">Active Profile:</property>
-                                <property name="mnemonic_widget">availableProfilesComboBox</property>
-                                <property name="ellipsize">start</property>
-                                <accessibility>
-                                  <relation type="label-for" target="speechServers"/>
-                                </accessibility>
-                              </object>
-                            </child>
-                            <child>
-                              <object class="GtkComboBox" id="availableProfilesComboBox">
-                                <property name="width_request">200</property>
-                                <property name="visible">True</property>
-                                <property name="model">model9</property>
-                                <child>
-                                  <object class="GtkCellRendererText" id="cellrenderertext4"/>
-                                  <attributes>
-                                    <attribute name="text">0</attribute>
-                                  </attributes>
-                                </child>
-                              </object>
-                              <packing>
-                                <property name="left_attach">1</property>
-                                <property name="right_attach">2</property>
-                              </packing>
-                            </child>
-                            <child>
-                              <object class="GtkButton" id="loadProfileButton">
-                                <property name="label" translatable="yes" comments="This button will load the selected settings profile in the application.">_Load</property>
-                                <property name="visible">True</property>
-                                <property name="can_focus">True</property>
-                                <property name="receives_default">True</property>
-                                <property name="use_underline">True</property>
-                                <signal name="clicked" handler="loadProfileButtonClicked"/>
-                              </object>
-                              <packing>
-                                <property name="left_attach">2</property>
-                                <property name="right_attach">3</property>
-                              </packing>
-                            </child>
-                            <child>
-                              <object class="GtkButton" id="saveProfileButton">
-                                <property name="label">gtk-save-as</property>
-                                <property name="visible">True</property>
-                                <property name="can_focus">True</property>
-                                <property name="receives_default">True</property>
-                                <property name="use_stock">True</property>
-                                <signal name="clicked" handler="showProfileGUI"/>
-                              </object>
-                              <packing>
-                                <property name="left_attach">3</property>
-                                <property name="right_attach">4</property>
-                              </packing>
-                            </child>
-                            <child>
-                              <object class="GtkLabel" id="startupProfileLabel">
-                                <property name="visible">True</property>
-                                <property name="xalign">0</property>
-                                <property name="xpad">12</property>
-                                <property name="label" translatable="yes">Start-up Profile:</property>
-                                <property name="ellipsize">end</property>
-                              </object>
-                              <packing>
-                                <property name="top_attach">1</property>
-                                <property name="bottom_attach">2</property>
-                              </packing>
-                            </child>
-                            <child>
-                              <object class="GtkComboBox" id="availableProfilesComboBox2">
-                                <property name="visible">True</property>
-                                <property name="model">model9</property>
-                                <child>
-                                  <object class="GtkCellRendererText" id="cellrenderertext3"/>
-                                  <attributes>
-                                    <attribute name="text">0</attribute>
-                                  </attributes>
-                                </child>
-                              </object>
-                              <packing>
-                                <property name="left_attach">1</property>
-                                <property name="right_attach">2</property>
-                                <property name="top_attach">1</property>
-                                <property name="bottom_attach">2</property>
-                              </packing>
-                            </child>
-                            <child>
-                              <placeholder/>
-                            </child>
-                            <child>
-                              <placeholder/>
-                            </child>
-                          </object>
-                        </child>
-                      </object>
-                      <packing>
-                        <property name="expand">False</property>
-                        <property name="fill">False</property>
-                        <property name="padding">12</property>
-                        <property name="position">0</property>
-                      </packing>
-                    </child>
-                  </object>
-                  <packing>
-                    <property name="position">8</property>
-                  </packing>
-                </child>
-                <child type="tab">
-                  <object class="GtkLabel" id="profilesTabLabel">
-                    <property name="visible">True</property>
-                    <property name="label" translatable="yes">Profiles</property>
-                  </object>
-                  <packing>
-                    <property name="position">8</property>
-                    <property name="tab_fill">False</property>
-                  </packing>
-                </child>
               </object>
               <packing>
                 <property name="padding">3</property>
diff --git a/src/orca/orca_gui_prefs.py b/src/orca/orca_gui_prefs.py
index 0d8f5f1..77bd620 100644
--- a/src/orca/orca_gui_prefs.py
+++ b/src/orca/orca_gui_prefs.py
@@ -2206,10 +2206,10 @@ class OrcaSetupGUI(orca_gtkbuilder.GtkBuilderWrapper):
         # Orca User Profiles
         #
         if not self._profilesCapable:
-            self.get_widget("profilesVbox").hide()
+            self.get_widget("profilesFrame").set_sensitive(False)
             return
 
-        self.profilesCombo = self.get_widget('availableProfilesComboBox')
+        self.profilesCombo = self.get_widget('availableProfilesComboBox1')
         self.startingProfileCombo = self.get_widget('availableProfilesComboBox2')
         self.profilesComboModel = self.get_widget('model9')
         self.__initProfileCombo()



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]