beagle r4815 - in trunk/beagle: . Util conf-data/config-files search/Beagle.Search tools
- From: dbera svn gnome org
- To: svn-commits-list gnome org
- Subject: beagle r4815 - in trunk/beagle: . Util conf-data/config-files search/Beagle.Search tools
- Date: Tue, 8 Jul 2008 23:52:06 +0000 (UTC)
Author: dbera
Date: Tue Jul 8 23:52:06 2008
New Revision: 4815
URL: http://svn.gnome.org/viewvc/beagle?rev=4815&view=rev
Log:
Add a python script (from CCSM) to grab shortcut keys from user input. Use the script in beagle-settings to get the shortcut key for beagle-search. Store the entire binding string in config instead of separately storing ctrl, alt and the key. Note that CCSM is GPLv2+ so we are including the script as GPLv3. It is possible to create a C# program to do what the script does but I am not taking the risk yet.
Added:
trunk/beagle/tools/keygrabber.py
Modified:
trunk/beagle/COPYING
trunk/beagle/Util/Config.cs
trunk/beagle/Util/Makefile.am
trunk/beagle/conf-data/config-files/BeagleSearch.xml
trunk/beagle/search/Beagle.Search/Search.cs
trunk/beagle/tools/Makefile.am
trunk/beagle/tools/Settings.cs
trunk/beagle/tools/settings.glade
Modified: trunk/beagle/COPYING
==============================================================================
--- trunk/beagle/COPYING (original)
+++ trunk/beagle/COPYING Tue Jul 8 23:52:06 2008
@@ -16,6 +16,7 @@
* LZMA SDK - GNU LGPL v2
* xemail-net - GNU LGPL v2
* Util/SemWeb/Euler.cs - W3C software license
+ * tools/keygrabber.py - GPLv3
-----------------------------------------------------------------------------
Modified: trunk/beagle/Util/Config.cs
==============================================================================
--- trunk/beagle/Util/Config.cs (original)
+++ trunk/beagle/Util/Config.cs Tue Jul 8 23:52:06 2008
@@ -1338,7 +1338,7 @@
result += "<Alt>";
result += Key;
-
+
return result;
}
Modified: trunk/beagle/Util/Makefile.am
==============================================================================
--- trunk/beagle/Util/Makefile.am (original)
+++ trunk/beagle/Util/Makefile.am Tue Jul 8 23:52:06 2008
@@ -282,6 +282,7 @@
$(COND_CS_FILES) \
$(srcdir)/$(UI_UTIL_TARGET_CONFIG) \
$(srcdir)/$(UTIL_TARGET_CONFIG) \
+ $(srcdir)/SemWeb/Euler.cs
inotify-test
CLEANFILES = \
Modified: trunk/beagle/conf-data/config-files/BeagleSearch.xml
==============================================================================
--- trunk/beagle/conf-data/config-files/BeagleSearch.xml (original)
+++ trunk/beagle/conf-data/config-files/BeagleSearch.xml Tue Jul 8 23:52:06 2008
@@ -6,6 +6,7 @@
<BoolOption Name="KeyBinding_Ctrl" Description="Use ctrl as key-modifier">false</BoolOption>
<BoolOption Name="KeyBinding_Alt" Description="Use alt as key-modifier">false</BoolOption>
<StringOption Name="KeyBinding_Key" Description="Shortcut key">F12</StringOption>
+ <StringOption Name="KeyBinding" Description="Shortcut key (including modifiers)"></StringOption>
<StringOption Name="BeaglePosX" Description=""></StringOption>
<StringOption Name="BeaglePosY" Description=""></StringOption>
<StringOption Name="BeagleSearchWidth" Description=""></StringOption>
Modified: trunk/beagle/search/Beagle.Search/Search.cs
==============================================================================
--- trunk/beagle/search/Beagle.Search/Search.cs (original)
+++ trunk/beagle/search/Beagle.Search/Search.cs Tue Jul 8 23:52:06 2008
@@ -45,12 +45,8 @@
Config config = Conf.Get (Conf.Names.BeagleSearchConfig);
- bool binding_ctrl = config.GetOption (Conf.Names.KeyBinding_Ctrl, false);
- bool binding_alt = config.GetOption (Conf.Names.KeyBinding_Alt, false);
- string binding_key = config.GetOption (Conf.Names.KeyBinding_Key, "F12");
-
string tip_text = Catalog.GetString ("Desktop Search");
- string binding = new KeyBinding (binding_key, binding_ctrl, binding_alt).ToString ();
+ string binding = config.GetOption ("KeyBinding", "F12");
if (!String.IsNullOrEmpty (binding)) {
tip_text += String.Format (" ({0})", binding);
Modified: trunk/beagle/tools/Makefile.am
==============================================================================
--- trunk/beagle/tools/Makefile.am (original)
+++ trunk/beagle/tools/Makefile.am Tue Jul 8 23:52:06 2008
@@ -170,8 +170,11 @@
$(STATIC_QUERY_WRAPPER) \
$(CONFIG_WRAPPER)
+KEYGRABBER =
+
if ENABLE_GUI
BUILT_WRAPPERS += $(SETTINGS_WRAPPER)
+KEYGRABBER += $(srcdir)/keygrabber.py
endif
if ENABLE_WV1
@@ -234,6 +237,9 @@
$(mkinstalldirs) $(DESTDIR)$(crondir)
$(INSTALL_SCRIPT) $(CRAWL_WRAPPER) $(DESTDIR)$(crondir)
+if ENABLE_GUI
+ $(INSTALL_DATA) $(KEYGRABBER) $(DESTDIR)$(pkglibdir)
+endif
uninstall-local:
cd $(DESTDIR)$(pkglibdir) && rm -f $(TARGETS) && rm -f $(TARGETS_MDB)
@@ -244,6 +250,9 @@
done
cd $(DESTDIR)$(crondir) && rm -f $(CRAWL_WRAPPER)
+if ENABLE_GUI
+ cd $(DESTDIR)$(pkglibdir) && rm -f $(KEYGRABBER)
+endif
EXTRA_DIST = \
$(WRAPPER_IN) \
@@ -263,10 +272,7 @@
$(QT_SETTINGS_CSFILES) \
$(QT_SETTINGS_UIFILE) \
$(QT_SETTINGS_ICON) \
- beagle-index-info \
- beagle-ping \
- beagle-status \
- blocate \
+ $(KEYGRABBER) \
boot.inotify.init \
beagle-settings.desktop.in.in
Modified: trunk/beagle/tools/Settings.cs
==============================================================================
--- trunk/beagle/tools/Settings.cs (original)
+++ trunk/beagle/tools/Settings.cs Tue Jul 8 23:52:06 2008
@@ -74,10 +74,9 @@
[Widget] CheckButton battery_toggle;
[Widget] CheckButton screensaver_toggle;
[Widget] CheckButton auto_search_toggle;
- [Widget] CheckButton press_ctrl_toggle;
- [Widget] CheckButton press_alt_toggle;
-
- [Widget] Entry show_search_window_entry;
+ [Widget] Label shortcut_label;
+ [Widget] Button shortcut_button;
+ string binding;
[Widget] CheckButton index_home_toggle;
[Widget] Button remove_include_button;
@@ -162,6 +161,10 @@
networking_password_box.Sensitive = false;
require_password_toggle.Sensitive = false;
+ // Keybinding button
+
+ shortcut_button.Clicked += new EventHandler (OnKeybindingClicked);
+
LoadConfiguration ();
Conf.Subscribe (Conf.Names.FilesQueryableConfig, new Conf.ConfigUpdateHandler (OnConfigurationChanged));
@@ -216,13 +219,18 @@
autostart_toggle.Active = IsAutostartEnabled ();
- bool binding_ctrl = bs_config.GetOption (Conf.Names.KeyBinding_Ctrl, false);
- bool binding_alt = bs_config.GetOption (Conf.Names.KeyBinding_Alt, false);
- string binding_key = bs_config.GetOption (Conf.Names.KeyBinding_Key, "F12");
- KeyBinding show_binding = new KeyBinding (binding_key, binding_ctrl, binding_alt);
- press_ctrl_toggle.Active = show_binding.Ctrl;
- press_alt_toggle.Active = show_binding.Alt;
- show_search_window_entry.Text = show_binding.Key;
+ binding = bs_config.GetOption ("KeyBinding", null);
+ if (String.IsNullOrEmpty (binding)) {
+ // Move old preference value to new
+ bool binding_ctrl = bs_config.GetOption (Conf.Names.KeyBinding_Ctrl, false);
+ bool binding_alt = bs_config.GetOption (Conf.Names.KeyBinding_Alt, false);
+ string binding_key = bs_config.GetOption (Conf.Names.KeyBinding_Key, "F12");
+ KeyBinding show_binding = new KeyBinding (binding_key, binding_ctrl, binding_alt);
+
+ binding = show_binding.ToString ();
+ }
+
+ shortcut_label.Text = String.Format (Catalog.GetString ("Display the search window by pressing {0}"), binding);
if (fsq_config.GetOption (Conf.Names.IndexHomeDir, true))
index_home_toggle.Active = true;
@@ -282,13 +290,11 @@
Config bs_config = Conf.Get (Conf.Names.BeagleSearchConfig);
daemon_config.SetOption (Conf.Names.AllowRoot, allow_root_toggle.Active);
- bs_config.SetOption (Conf.Names.BeagleSearchAutoSearch,auto_search_toggle.Active);
daemon_config.SetOption (Conf.Names.IndexOnBattery,battery_toggle.Active);
daemon_config.SetOption (Conf.Names.IndexFasterOnScreensaver, screensaver_toggle.Active);
- bs_config.SetOption (Conf.Names.KeyBinding_Key, show_search_window_entry.Text);
- bs_config.SetOption (Conf.Names.KeyBinding_Ctrl, press_ctrl_toggle.Active);
- bs_config.SetOption (Conf.Names.KeyBinding_Alt, press_alt_toggle.Active);
+ bs_config.SetOption (Conf.Names.BeagleSearchAutoSearch,auto_search_toggle.Active);
+ bs_config.SetOption ("KeyBinding", binding);
fsq_config.SetOption (Conf.Names.IndexHomeDir, index_home_toggle.Active);
@@ -690,6 +696,48 @@
//networking_password_box.Sensitive = require_password_toggle.Active;
}
+ private void OnKeybindingClicked (object o, EventArgs args)
+ {
+ try {
+ string new_binding = GetBindingFromKeygrabber ();
+ if (! String.IsNullOrEmpty (new_binding))
+ binding = new_binding;
+ } catch (Exception e) {
+ Console.WriteLine ("Could not run python keygrabber: {0}", e.Message);
+ Console.WriteLine ("Showing old keybinding widget");
+ binding = GetBindingFromUserInput ();
+ }
+
+ shortcut_label.Text = String.Format (Catalog.GetString ("Display the search window by pressing {0}"), binding);
+ }
+
+ private static string GetBindingFromKeygrabber ()
+ {
+ SafeProcess pc = new SafeProcess ();
+
+ string keygrabber_file = Path.Combine (ExternalStringsHack.PkgLibDir, "keygrabber.py");
+ if (! File.Exists (keygrabber_file))
+ throw new Exception ("keygrabber.py not found");
+
+ pc.Arguments = new string[] {"python", keygrabber_file};
+ pc.RedirectStandardError = false;
+ pc.RedirectStandardOutput = true;
+
+ pc.Start ();
+ string output;
+ using (StreamReader pout = new StreamReader (pc.StandardOutput))
+ output = pout.ReadLine ();
+ pc.Close ();
+
+ Console.WriteLine ("New binding '{0}'", output);
+ return output;
+ }
+
+ private string GetBindingFromUserInput ()
+ {
+ return UserShortcutDialog.GetUserShortcut (settings_dialog, binding);
+ }
+
////////////////////////////////////////////////////////////////
// IncludeView
@@ -1344,6 +1392,83 @@
}
}
+ ////////////////////////////////////////////////////////////////
+ // ShortcutInput Dialog
+ // Simple dialog that is shown in case the python keygrabber script
+ // cannot be run.
+ // This deliberately does not try to cover all cases. We assume
+ // everyone has python installed.
+
+ public class UserShortcutDialog : Dialog
+ {
+ CheckButton ctrl_button, alt_button;
+ Entry entry;
+ string binding;
+
+ public UserShortcutDialog (Gtk.Window parent, string binding_string) : base (null, parent, DialogFlags.DestroyWithParent)
+ {
+ Title = "KeyGrabber";
+ Modal = true;
+ HasSeparator = false;
+
+ AddButton ("Ok", ResponseType.Ok);
+ AddButton ("Cancel", ResponseType.Cancel);
+
+ binding = binding_string;
+
+ ctrl_button = new CheckButton ("Ctrl");
+ int i = binding_string.IndexOf ("<ctrl>", StringComparison.InvariantCultureIgnoreCase);
+ if (i != -1) {
+ ctrl_button.Active = true;
+ binding_string = binding_string.Remove (i, 6);
+ }
+
+ alt_button = new CheckButton ("Alt");
+ i = binding_string.IndexOf ("<alt>", StringComparison.InvariantCultureIgnoreCase);
+ if (i != -1) {
+ alt_button.Active = true;
+ binding_string = binding_string.Remove (i, 5);
+ }
+
+ entry = new Entry ();
+ entry.Text = binding_string;
+
+ HBox box = new HBox (false, 0);
+ box.PackEnd (ctrl_button, true, false, 0);
+ ctrl_button.Show ();
+ box.PackEnd (alt_button, true, false, 0);
+ alt_button.Show ();
+ box.PackEnd (entry, true, false, 0);
+ entry.Show ();
+
+ VBox.PackStart (box, true, false, 0);
+ box.Show ();
+ }
+
+ public static string GetUserShortcut (Gtk.Window parent, string binding)
+ {
+ UserShortcutDialog dialog = new UserShortcutDialog (parent, binding);
+ dialog.Response += new ResponseHandler (OnResponse);
+ dialog.Run ();
+ dialog.Destroy ();
+
+ Console.WriteLine ("new binding = '{0}'", dialog.binding);
+ return dialog.binding;
+ }
+
+ private static void OnResponse (object obj, ResponseArgs args)
+ {
+ UserShortcutDialog dialog = (UserShortcutDialog) obj;
+ if (args.ResponseId != ResponseType.Ok)
+ return;
+
+ bool ctrl = dialog.ctrl_button.Active;
+ bool alt = dialog.alt_button.Active;
+ string key = dialog.entry.Text;
+ dialog.binding = (new KeyBinding (key, ctrl, alt)).ToString ();
+ }
+ }
+
////////////////////////////////////////////////////////////////
// AddHostDialog
Added: trunk/beagle/tools/keygrabber.py
==============================================================================
--- (empty file)
+++ trunk/beagle/tools/keygrabber.py Tue Jul 8 23:52:06 2008
@@ -0,0 +1,203 @@
+#!/usr/bin/env python
+# -*- coding: UTF-8 -*-
+
+# This program and all files included in this package are free software;
+# you can redistribute it and/or modify it under the terms
+# of the GNU General Public License as published by the Free
+# Software Foundation; either version 3 of the License,
+# or (at your option) any later version.
+#
+# This program is distributed in the hope that it will be useful,
+# but WITHOUT ANY WARRANTY; without even the implied warranty of
+# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
+# GNU General Public License for more details.
+#
+# You should have received a copy of the GNU General Public License
+# along with this program; if not, write to the Free Software
+# Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA.
+#
+# Authors: Quinn Storm (quinn beryl-project org)
+# Patrick Niklaus (marex opencompositing org)
+# Guillaume Seguin (guillaume segu in)
+# Christopher Williams (christopherw verizon net)
+# Copyright (C) 2007 Quinn Storm
+
+import pygtk
+import gtk
+import gtk.gdk
+import gobject
+pygtk.require('2.0')
+import gtk
+import time
+
+KeyModifier = ["Shift", "Control", "Mod1", "Mod2", "Mod3", "Mod4",
+ "Mod5", "Alt", "Meta", "Super", "Hyper", "ModeSwitch"]
+
+class GrabberWindow:
+
+ def delete_event(self, widget, event, data=None):
+ return False
+
+ def destroy(self, widget, data=None):
+ gtk.main_quit()
+
+ def __init__(self):
+ # create a new window
+ self.window = gtk.Window(gtk.WINDOW_TOPLEVEL)
+ self.window.connect("delete_event", self.delete_event)
+ self.window.connect("destroy", self.destroy)
+
+ self.window.set_border_width(10)
+ self.window.set_title("KeyGrabber")
+ self.window.set_position(gtk.WIN_POS_MOUSE)
+
+ self.button = KeyGrabber(label = _("Grab key combination"))
+
+ self.button.hide()
+ self.button.set_no_show_all(True)
+ self.button.connect('changed', self.GotKey)
+
+ # This packs the button into the window (a GTK container).
+ self.window.add(self.button)
+
+ # The final step is to display this newly created widget.
+ self.button.show()
+
+ # and the window
+ self.window.show()
+
+ def GotKey(self, widget, key, mods):
+ new = gtk.accelerator_name (key, mods)
+ for mod in KeyModifier:
+ if "%s_L" % mod in new:
+ new = new.replace ("%s_L" % mod, "<%s>" % mod)
+ if "%s_R" % mod in new:
+ new = new.replace ("%s_R" % mod, "<%s>" % mod)
+
+ print new
+ gtk.main_quit()
+
+ def main(self):
+ gtk.main()
+
+# Popup
+#
+class Popup (gtk.Window):
+
+ def __init__ (self, parent, text=None, child=None, decorated=True, mouse=False, modal=True):
+ gtk.Window.__init__ (self, gtk.WINDOW_TOPLEVEL)
+ self.set_type_hint (gtk.gdk.WINDOW_TYPE_HINT_UTILITY)
+ self.set_position (mouse and gtk.WIN_POS_MOUSE or gtk.WIN_POS_CENTER_ALWAYS)
+ self.set_transient_for (parent.get_toplevel ())
+ self.set_modal (modal)
+ self.set_decorated (decorated)
+ if text:
+ label = gtk.Label (text)
+ align = gtk.Alignment ()
+ align.set_padding (20, 20, 20, 20)
+ align.add (label)
+ self.add (align)
+ elif child:
+ self.add (child)
+ gtk_process_events ()
+
+ def destroy (self):
+ gtk.Window.destroy (self)
+ gtk_process_events ()
+
+# Key Grabber
+#
+class KeyGrabber (gtk.Button):
+
+ __gsignals__ = {"changed" : (gobject.SIGNAL_RUN_FIRST,
+ gobject.TYPE_NONE,
+ [gobject.TYPE_INT, gobject.TYPE_INT]),
+ "current-changed" : (gobject.SIGNAL_RUN_FIRST,
+ gobject.TYPE_NONE,
+ [gobject.TYPE_INT, gobject.TYPE_INT])}
+
+ key = 0
+ mods = 0
+ handler = None
+ popup = None
+
+ label = None
+
+ def __init__ (self, key = 0, mods = 0, label = None):
+ '''Prepare widget'''
+ super (KeyGrabber, self).__init__ ()
+
+ self.key = key
+ self.mods = mods
+
+ self.label = label
+
+ self.connect ("clicked", self.begin_key_grab)
+ self.set_label ()
+
+ def begin_key_grab (self, widget):
+ self.add_events (gtk.gdk.KEY_PRESS_MASK)
+ self.popup = Popup (self, _("Please press the new key combination"))
+ self.popup.show_all()
+ self.handler = self.popup.connect ("key-press-event",
+ self.on_key_press_event)
+ while gtk.gdk.keyboard_grab (self.popup.window) != gtk.gdk.GRAB_SUCCESS:
+ time.sleep (0.1)
+
+ def end_key_grab (self):
+ gtk.gdk.keyboard_ungrab (gtk.get_current_event_time ())
+ self.popup.disconnect (self.handler)
+ self.popup.destroy ()
+
+ def on_key_press_event (self, widget, event):
+ mods = event.state & gtk.accelerator_get_default_mod_mask ()
+
+ if event.keyval in (gtk.keysyms.Escape, gtk.keysyms.Return) \
+ and not mods:
+ if event.keyval == gtk.keysyms.Escape:
+ self.emit ("changed", self.key, self.mods)
+ self.end_key_grab ()
+ self.set_label ()
+ return
+
+ key = gtk.gdk.keyval_to_lower (event.keyval)
+ if (key == gtk.keysyms.ISO_Left_Tab):
+ key = gtk.keysyms.Tab
+
+ if gtk.accelerator_valid (key, mods) \
+ or (key == gtk.keysyms.Tab and mods):
+ self.set_label (key, mods)
+ self.end_key_grab ()
+ self.key = key
+ self.mods = mods
+ self.emit ("changed", self.key, self.mods)
+ return
+
+ self.set_label (key, mods)
+
+ def set_label (self, key = None, mods = None):
+ if self.label:
+ if key != None and mods != None:
+ self.emit ("current-changed", key, mods)
+ gtk.Button.set_label (self, self.label)
+ return
+ if key == None and mods == None:
+ key = self.key
+ mods = self.mods
+ label = gtk.accelerator_name (key, mods)
+ if not len (label):
+ label = _("Disabled")
+ gtk.Button.set_label (self, label)
+
+def _(x):
+ # how to mark python strings for translation ?
+ return x
+
+def gtk_process_events ():
+ while gtk.events_pending ():
+ gtk.main_iteration ()
+
+if __name__ == "__main__":
+ window = GrabberWindow()
+ window.main()
+
Modified: trunk/beagle/tools/settings.glade
==============================================================================
--- trunk/beagle/tools/settings.glade (original)
+++ trunk/beagle/tools/settings.glade Tue Jul 8 23:52:06 2008
@@ -242,67 +242,30 @@
<property name="column_spacing">5</property>
<property name="row_spacing">3</property>
<child>
- <widget class="GtkHBox" id="hbox17">
+ <widget class="GtkLabel" id="shortcut_label">
<property name="visible">True</property>
- <property name="spacing">5</property>
- <child>
- <widget class="GtkCheckButton" id="press_ctrl_toggle">
- <property name="visible">True</property>
- <property name="can_focus">True</property>
- <property name="label" translatable="yes">Ctrl</property>
- <property name="use_underline">True</property>
- <property name="response_id">0</property>
- <property name="draw_indicator">True</property>
- </widget>
- <packing>
- <property name="expand">False</property>
- <property name="fill">False</property>
- </packing>
- </child>
- <child>
- <widget class="GtkCheckButton" id="press_alt_toggle">
- <property name="visible">True</property>
- <property name="can_focus">True</property>
- <property name="label" translatable="yes">Alt</property>
- <property name="use_underline">True</property>
- <property name="response_id">0</property>
- <property name="draw_indicator">True</property>
- </widget>
- <packing>
- <property name="expand">False</property>
- <property name="fill">False</property>
- <property name="position">1</property>
- </packing>
- </child>
- <child>
- <widget class="GtkEntry" id="show_search_window_entry">
- <property name="visible">True</property>
- <property name="can_focus">True</property>
- <property name="width_chars">5</property>
- </widget>
- <packing>
- <property name="expand">False</property>
- <property name="fill">False</property>
- <property name="position">2</property>
- </packing>
- </child>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">Display the search window by pressing</property>
</widget>
<packing>
<property name="left_attach">1</property>
<property name="right_attach">2</property>
- <property name="y_options">GTK_FILL</property>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options"></property>
+ <property name="y_padding">4</property>
</packing>
</child>
<child>
- <widget class="GtkLabel" id="label48">
+ <widget class="GtkButton" id="shortcut_button">
<property name="visible">True</property>
- <property name="xalign">0</property>
- <property name="label" translatable="yes">Display the search window by pressing:</property>
+ <property name="can_focus">True</property>
+ <property name="receives_default">True</property>
+ <property name="label" translatable="yes">Change</property>
+ <property name="response_id">0</property>
</widget>
<packing>
<property name="x_options">GTK_FILL</property>
<property name="y_options"></property>
- <property name="y_padding">4</property>
</packing>
</child>
</widget>
@@ -1490,44 +1453,23 @@
<property name="column_spacing">6</property>
<property name="row_spacing">6</property>
<child>
- <widget class="GtkLabel" id="label60">
- <property name="visible">True</property>
- <property name="xalign">0</property>
- <property name="label" translatable="yes">_Password:</property>
- <property name="use_underline">True</property>
- <property name="mnemonic_widget">password_entry</property>
- </widget>
- <packing>
- <property name="top_attach">2</property>
- <property name="bottom_attach">3</property>
- <property name="x_options">GTK_FILL</property>
- <property name="y_options"></property>
- </packing>
- </child>
- <child>
- <widget class="GtkEntry" id="password_entry">
+ <widget class="GtkEntry" id="name_entry">
<property name="visible">True</property>
<property name="can_focus">True</property>
- <property name="visibility">False</property>
</widget>
<packing>
<property name="left_attach">1</property>
<property name="right_attach">2</property>
- <property name="top_attach">2</property>
- <property name="bottom_attach">3</property>
<property name="y_options"></property>
</packing>
</child>
<child>
- <widget class="GtkLabel" id="label59">
+ <widget class="GtkLabel" id="label62">
<property name="visible">True</property>
<property name="xalign">0</property>
- <property name="label" translatable="yes">_Hostname:</property>
- <property name="use_underline">True</property>
+ <property name="label" translatable="yes">Name:</property>
</widget>
<packing>
- <property name="top_attach">1</property>
- <property name="bottom_attach">2</property>
<property name="x_options">GTK_FILL</property>
<property name="y_options"></property>
</packing>
@@ -1574,24 +1516,45 @@
</packing>
</child>
<child>
- <widget class="GtkLabel" id="label62">
+ <widget class="GtkLabel" id="label59">
<property name="visible">True</property>
<property name="xalign">0</property>
- <property name="label" translatable="yes">Name:</property>
+ <property name="label" translatable="yes">_Hostname:</property>
+ <property name="use_underline">True</property>
</widget>
<packing>
+ <property name="top_attach">1</property>
+ <property name="bottom_attach">2</property>
<property name="x_options">GTK_FILL</property>
<property name="y_options"></property>
</packing>
</child>
<child>
- <widget class="GtkEntry" id="name_entry">
+ <widget class="GtkEntry" id="password_entry">
<property name="visible">True</property>
<property name="can_focus">True</property>
+ <property name="visibility">False</property>
</widget>
<packing>
<property name="left_attach">1</property>
<property name="right_attach">2</property>
+ <property name="top_attach">2</property>
+ <property name="bottom_attach">3</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+ <child>
+ <widget class="GtkLabel" id="label60">
+ <property name="visible">True</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">_Password:</property>
+ <property name="use_underline">True</property>
+ <property name="mnemonic_widget">password_entry</property>
+ </widget>
+ <packing>
+ <property name="top_attach">2</property>
+ <property name="bottom_attach">3</property>
+ <property name="x_options">GTK_FILL</property>
<property name="y_options"></property>
</packing>
</child>
@@ -1726,93 +1689,31 @@
<placeholder/>
</child>
<child>
- <widget class="GtkRadioButton" id="type_path_radio">
- <property name="visible">True</property>
- <property name="can_focus">True</property>
- <property name="label" translatable="yes">_Folder path</property>
- <property name="use_underline">True</property>
- <property name="focus_on_click">False</property>
- <property name="response_id">0</property>
- <property name="draw_indicator">True</property>
- <signal name="toggled" handler="OnRadioGroupChanged"/>
- </widget>
- <packing>
- <property name="left_attach">1</property>
- <property name="right_attach">2</property>
- <property name="x_options">GTK_FILL</property>
- <property name="y_options"></property>
- </packing>
- </child>
- <child>
- <widget class="GtkRadioButton" id="type_pattern_radio">
+ <widget class="GtkLabel" id="label25">
+ <property name="width_request">80</property>
<property name="visible">True</property>
- <property name="can_focus">True</property>
- <property name="label" translatable="yes">Filename _pattern</property>
- <property name="use_underline">True</property>
- <property name="focus_on_click">False</property>
- <property name="response_id">0</property>
- <property name="draw_indicator">True</property>
- <property name="group">type_path_radio</property>
- <signal name="toggled" handler="OnRadioGroupChanged"/>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">Type:</property>
+ <property name="mnemonic_widget">type_path_radio</property>
</widget>
<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>
<property name="x_options">GTK_FILL</property>
<property name="y_options"></property>
</packing>
</child>
<child>
- <widget class="GtkRadioButton" id="type_mailfolder_radio">
+ <widget class="GtkLabel" id="value_name_label">
<property name="visible">True</property>
- <property name="can_focus">True</property>
- <property name="label" translatable="yes">_Mail folder</property>
+ <property name="xalign">0</property>
+ <property name="label" translatable="yes">P_ath:</property>
<property name="use_underline">True</property>
- <property name="focus_on_click">False</property>
- <property name="response_id">0</property>
- <property name="draw_indicator">True</property>
- <property name="group">type_path_radio</property>
- <signal name="toggled" handler="OnRadioGroupChanged"/>
- </widget>
- <packing>
- <property name="left_attach">1</property>
- <property name="right_attach">2</property>
- <property name="top_attach">2</property>
- <property name="bottom_attach">3</property>
- <property name="x_options">GTK_FILL</property>
- <property name="y_options"></property>
- </packing>
- </child>
- <child>
- <widget class="GtkHBox" id="hbox7">
- <property name="visible">True</property>
- <child>
- <placeholder/>
- </child>
- <child>
- <widget class="GtkEntry" id="value_entry">
- <property name="visible">True</property>
- <property name="can_focus">True</property>
- <property name="has_focus">True</property>
- <property name="activates_default">True</property>
- <property name="width_chars">25</property>
- </widget>
- <packing>
- <property name="expand">False</property>
- <property name="fill">False</property>
- <property name="position">1</property>
- </packing>
- </child>
+ <property name="mnemonic_widget">value_entry</property>
</widget>
<packing>
- <property name="left_attach">1</property>
- <property name="right_attach">2</property>
<property name="top_attach">3</property>
<property name="bottom_attach">4</property>
<property name="x_options">GTK_FILL</property>
- <property name="y_options">GTK_FILL</property>
+ <property name="y_options"></property>
</packing>
</child>
<child>
@@ -1867,29 +1768,91 @@
</packing>
</child>
<child>
- <widget class="GtkLabel" id="value_name_label">
+ <widget class="GtkHBox" id="hbox7">
<property name="visible">True</property>
- <property name="xalign">0</property>
- <property name="label" translatable="yes">P_ath:</property>
- <property name="use_underline">True</property>
- <property name="mnemonic_widget">value_entry</property>
+ <child>
+ <placeholder/>
+ </child>
+ <child>
+ <widget class="GtkEntry" id="value_entry">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="has_focus">True</property>
+ <property name="activates_default">True</property>
+ <property name="width_chars">25</property>
+ </widget>
+ <packing>
+ <property name="expand">False</property>
+ <property name="fill">False</property>
+ <property name="position">1</property>
+ </packing>
+ </child>
</widget>
<packing>
+ <property name="left_attach">1</property>
+ <property name="right_attach">2</property>
<property name="top_attach">3</property>
<property name="bottom_attach">4</property>
<property name="x_options">GTK_FILL</property>
+ <property name="y_options">GTK_FILL</property>
+ </packing>
+ </child>
+ <child>
+ <widget class="GtkRadioButton" id="type_mailfolder_radio">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="label" translatable="yes">_Mail folder</property>
+ <property name="use_underline">True</property>
+ <property name="focus_on_click">False</property>
+ <property name="response_id">0</property>
+ <property name="draw_indicator">True</property>
+ <property name="group">type_path_radio</property>
+ <signal name="toggled" handler="OnRadioGroupChanged"/>
+ </widget>
+ <packing>
+ <property name="left_attach">1</property>
+ <property name="right_attach">2</property>
+ <property name="top_attach">2</property>
+ <property name="bottom_attach">3</property>
+ <property name="x_options">GTK_FILL</property>
<property name="y_options"></property>
</packing>
</child>
<child>
- <widget class="GtkLabel" id="label25">
- <property name="width_request">80</property>
+ <widget class="GtkRadioButton" id="type_pattern_radio">
<property name="visible">True</property>
- <property name="xalign">0</property>
- <property name="label" translatable="yes">Type:</property>
- <property name="mnemonic_widget">type_path_radio</property>
+ <property name="can_focus">True</property>
+ <property name="label" translatable="yes">Filename _pattern</property>
+ <property name="use_underline">True</property>
+ <property name="focus_on_click">False</property>
+ <property name="response_id">0</property>
+ <property name="draw_indicator">True</property>
+ <property name="group">type_path_radio</property>
+ <signal name="toggled" handler="OnRadioGroupChanged"/>
+ </widget>
+ <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>
+ <property name="x_options">GTK_FILL</property>
+ <property name="y_options"></property>
+ </packing>
+ </child>
+ <child>
+ <widget class="GtkRadioButton" id="type_path_radio">
+ <property name="visible">True</property>
+ <property name="can_focus">True</property>
+ <property name="label" translatable="yes">_Folder path</property>
+ <property name="use_underline">True</property>
+ <property name="focus_on_click">False</property>
+ <property name="response_id">0</property>
+ <property name="draw_indicator">True</property>
+ <signal name="toggled" handler="OnRadioGroupChanged"/>
</widget>
<packing>
+ <property name="left_attach">1</property>
+ <property name="right_attach">2</property>
<property name="x_options">GTK_FILL</property>
<property name="y_options"></property>
</packing>
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]