Esempio n. 1
0
		public FileScout()
		{
			string path = IdeApp.ProjectOperations.ProjectsDefaultPath;

			if (Directory.Exists(path))
			{
				fb.CurrentDir = path;
			}

			fb.DirectoryChangedEvent += new DirectoryChangedEventHandler (OnDirChanged);
			filelister.RowActivated += new Gtk.RowActivatedHandler (FileSelected);
			IdeApp.Workspace.FirstWorkspaceItemOpened += OnCombineOpened;
			IdeApp.Workspace.LastWorkspaceItemClosed += OnCombineClosed;

			Gtk.ScrolledWindow listsw = new Gtk.ScrolledWindow ();
			listsw.Add (filelister);
			
			fontChanger = new PadFontChanger (listsw, delegate (Pango.FontDescription desc) {
				filelister.SetCustomFont (desc);
				fb.SetCustomFont (desc);
			}, delegate () {
				filelister.ColumnsAutosize ();
				fb.ColumnsAutosize ();
			});
			
			this.Pack1 (fb, true, true);
			this.Pack2 (listsw, true, true);

			fb.SelectFirst ();
			
			OnDirChanged (fb.CurrentDir);
			this.ShowAll ();
		}
		public DisassemblyView ()
		{
			UntitledName = GettextCatalog.GetString ("Disassembly");
			sw = new Gtk.ScrolledWindow ();
			editor = new Mono.TextEditor.TextEditor ();
			editor.Document.ReadOnly = true;
			
			TextEditorOptions options = new TextEditorOptions ();
			options.CopyFrom (TextEditorOptions.DefaultOptions);
			options.ShowEolMarkers = false;
			options.ShowInvalidLines = false;
			options.ShowLineNumberMargin = false;
			editor.Options = options;
			
			sw.Add (editor);
			sw.HscrollbarPolicy = Gtk.PolicyType.Automatic;
			sw.VscrollbarPolicy = Gtk.PolicyType.Automatic;
			sw.ShowAll ();
			sw.Vadjustment.ValueChanged += OnScrollEditor;
			sw.VScrollbar.ButtonPressEvent += OnPress;
			sw.VScrollbar.ButtonReleaseEvent += OnRelease;
			sw.VScrollbar.Events |= Gdk.EventMask.ButtonPressMask | Gdk.EventMask.ButtonReleaseMask;
			sw.ShadowType = Gtk.ShadowType.In;
			
			sw.Sensitive = false;
			
			currentDebugLineMarker = new CurrentDebugLineTextMarker (editor);
			DebuggingService.StoppedEvent += OnStop;
		}
Esempio n. 3
0
        public void Run(FSpot.IBrowsableCollection photos)
        {
            if (null == photos)
            {
                throw new ArgumentNullException("photos");
            }

            this.photos = photos;

            Glade.XML glade_xml = new Glade.XML(
                null, "TabbloExport.glade", DialogName,
                "f-spot");
            glade_xml.Autoconnect(this);

            dialog = (Gtk.Dialog)glade_xml.GetWidget(DialogName);

            FSpot.Widgets.IconView icon_view =
                new FSpot.Widgets.IconView(photos);
            icon_view.DisplayDates = false;
            icon_view.DisplayTags  = false;

            username_entry.Changed += HandleAccountDataChanged;
            password_entry.Changed += HandleAccountDataChanged;
            ReadAccountData();
            HandleAccountDataChanged(null, null);

            dialog.Modal        = false;
            dialog.TransientFor = null;

            dialog.Response += HandleResponse;

            thumb_scrolled_window.Add(icon_view);
            icon_view.Show();
            dialog.Show();
        }
Esempio n. 4
0
        Gtk.Widget IOutlinedDocument.GetOutlineWidget()
        {
            if (outlineTreeView != null)
            {
                return(outlineTreeView);
            }

            outlineTreeStore          = new Gtk.TreeStore(typeof(string), typeof(Gdk.Color), typeof(Mono.TextTemplating.ISegment));
            outlineTreeView           = new MonoDevelop.Ide.Gui.Components.PadTreeView(outlineTreeStore);
            outlineTreeView.Realized += delegate { RefillOutlineStore(); };

            outlineTreeView.TextRenderer.Xpad = 0;
            outlineTreeView.TextRenderer.Ypad = 0;
            outlineTreeView.AppendColumn("Node", outlineTreeView.TextRenderer, "text", 0, "foreground-gdk", 1);

            outlineTreeView.HeadersVisible = false;

            outlineTreeView.Selection.Changed += delegate {
                Gtk.TreeIter iter;
                if (!outlineTreeView.Selection.GetSelected(out iter))
                {
                    return;
                }
                SelectSegment((Mono.TextTemplating.ISegment)outlineTreeStore.GetValue(iter, 2));
            };

            RefillOutlineStore();

            Gtk.ScrolledWindow sw = new Gtk.ScrolledWindow();
            sw.Add(outlineTreeView);
            sw.ShowAll();
            return(sw);
        }
Esempio n. 5
0
        public WindowView(Main _view, Controller.Window _ctl)
        {
            View = _view;
            Window = _ctl;
            Homogeneous = false;
            Spacing = 0;
            BorderWidth = 0;
            var topLevelBox = new Gtk.VBox();
            topLevelBox.Homogeneous = false;
            topLevelBox.Spacing = 0;
            topLevelBox.BorderWidth = 0;
            textView = new WindowTextView(Window);
            scroll = new Gtk.ScrolledWindow {
                HscrollbarPolicy = Gtk.PolicyType.Automatic,
                VscrollbarPolicy = Gtk.PolicyType.Automatic
            };
            scroll.Add(textView);
            Window.CursorMovedByCommand.Add(i =>
            {
                textView.ScrollToIter(i.GtkIter, 0, false, 0, 0);
            });
            topLevelBox.PackStart(scroll, true, true, 0);
            status = new Gtk.Statusbar();
            status.HasResizeGrip = false;
            status.Push(StatusbarMode, Window.CurrentMode.GetName());
            Window.CurrentMode.Event.Changed += m =>
            {
                status.Pop(StatusbarMode);
                status.Push(StatusbarMode, Window.CurrentMode.GetName());
            };
            Window.Model.Changed += m =>
            {
                textView.Buffer = m;
            };
            topLevelBox.PackStart(status, false, false, 0);

            // Wrap the topLevelBox with borders on the left and right
            var hlBox = new Gtk.DrawingArea();
            NormalColor = hlBox.Style.Background(Gtk.StateType.Normal);
            hlBox.WidthRequest = 10;
            var borderBox = new Gtk.HBox();
            borderBox.Homogeneous = false;
            borderBox.Spacing = 0;
            borderBox.BorderWidth = 0;
            borderBox.PackStart(hlBox, false, false, 0);
            borderBox.PackStart(topLevelBox, true, true, 0);

            textView.FocusInEvent += (object o, Gtk.FocusInEventArgs args) =>
            {
                Window.Controller.FocusedWindow.Value = Window;
                hlBox.ModifyBg(Gtk.StateType.Normal, HighlightColor);
            };

            textView.FocusOutEvent += (object o, Gtk.FocusOutEventArgs args) =>
            {
                hlBox.ModifyBg(Gtk.StateType.Normal, NormalColor);
            };

            Add(borderBox);
        }
Esempio n. 6
0
        public SyntaxHightlightTextAreaHandler()
        {
            scroll = new Gtk.ScrolledWindow
            {
                ShadowType = Gtk.ShadowType.In,
            };
            editor = new MonoTextEditor
            {
                Options = new TextEditorOptions
                {
                    HighlightMatchingBracket = true,
                    FontName                 = "Monaco 10",
                    ColorScheme              = "Visual Studio",
                    ShowWhitespaces          = ShowWhitespaces.Selection,
                    TabsToSpaces             = true,
                    ShowLineNumberMargin     = true,
                    EnableSyntaxHighlighting = true,
                    EnableAnimations         = true,
                },
            };

            //data.ModifyFont(Pango.FontDescription.FromString($"Courier 12"));
            UpdateLanguage();
            Control = editor;
            Size    = new Size(100, 60);
            scroll.Add(Control);
            Wrap = true;
        }
Esempio n. 7
0
        public DisassemblyView()
        {
            UntitledName             = GettextCatalog.GetString("Disassembly");
            sw                       = new Gtk.ScrolledWindow();
            editor                   = new Mono.TextEditor.TextEditor();
            editor.Document.ReadOnly = true;

            editor.Options = new MonoDevelop.Ide.Gui.CommonTextEditorOptions()
            {
                ShowEolMarkers       = false,
                ShowInvalidLines     = false,
                ShowLineNumberMargin = false,
            };

            sw.Add(editor);
            sw.HscrollbarPolicy = Gtk.PolicyType.Automatic;
            sw.VscrollbarPolicy = Gtk.PolicyType.Automatic;
            sw.ShowAll();
            sw.Vadjustment.ValueChanged      += OnScrollEditor;
            sw.VScrollbar.ButtonPressEvent   += OnPress;
            sw.VScrollbar.ButtonReleaseEvent += OnRelease;
            sw.VScrollbar.Events             |= Gdk.EventMask.ButtonPressMask | Gdk.EventMask.ButtonReleaseMask;
            sw.ShadowType = Gtk.ShadowType.In;

            sw.Sensitive = false;

            currentDebugLineMarker         = new CurrentDebugLineTextMarker(editor);
            DebuggingService.StoppedEvent += OnStop;
        }
Esempio n. 8
0
		public DisassemblyView ()
		{
			ContentName = GettextCatalog.GetString ("Disassembly");
			sw = new Gtk.ScrolledWindow ();
			editor = new TextEditor ();
			editor.Document.ReadOnly = true;
			
			editor.Options = new CommonTextEditorOptions {
				ShowLineNumberMargin = false,
			};
			
			sw.Add (editor);
			sw.HscrollbarPolicy = Gtk.PolicyType.Automatic;
			sw.VscrollbarPolicy = Gtk.PolicyType.Automatic;
			sw.ShowAll ();
			sw.Vadjustment.ValueChanged += OnScrollEditor;
			sw.VScrollbar.ButtonPressEvent += OnPress;
			sw.VScrollbar.ButtonReleaseEvent += OnRelease;
			sw.VScrollbar.Events |= Gdk.EventMask.ButtonPressMask | Gdk.EventMask.ButtonReleaseMask;
			sw.ShadowType = Gtk.ShadowType.In;
			
			sw.Sensitive = false;
			
			currentDebugLineMarker = new CurrentDebugLineTextMarker (editor);
			DebuggingService.StoppedEvent += OnStop;
		}
Esempio n. 9
0
        /// <summary>
        /// Initializes a new instance of the <see cref="Trilogic.CompareWindow"/> class.
        /// </summary>
        /// <param name="parent">The parent window.</param>
        /// <param name="compareName">Compare name.</param>
        /// <param name="fileSide">File side.</param>
        /// <param name="databaseSide">Database side.</param>
        public CompareWindow(MainWindow parent, string compareName, SchemaData fileSide, SchemaData databaseSide)
            : base(Gtk.WindowType.Toplevel)
        {
            this.Build();
            this.parent = parent;

            this.docLocal = new TextDocument();
            this.docDB = new TextDocument();

            this.editorLocal = new TextEditor(this.docLocal);
            this.editorDB = new TextEditor(this.docDB);

            Gtk.ScrolledWindow scrollLocal = new Gtk.ScrolledWindow();
            Gtk.ScrolledWindow scrollDB = new Gtk.ScrolledWindow();
            scrollLocal.Add(this.editorLocal);
            scrollDB.Add(this.editorDB);

            this.hbox1.Add(scrollDB);
            this.hbox1.Add(scrollLocal);

            Gtk.Box.BoxChild childLocal = (Gtk.Box.BoxChild)this.hbox1[scrollLocal];
            childLocal.Position = 2;

            Gtk.Box.BoxChild childDB = (Gtk.Box.BoxChild)this.hbox1[scrollDB];
            childDB.Position = 0;

            this.ShowAll();

            this.Title += " - " + compareName;

            this.fileSide = fileSide;
            this.databaseSide = databaseSide;

            this.ShowSchema();
        }
Esempio n. 10
0
        public FileScout()
        {
            string path = IdeApp.ProjectOperations.ProjectsDefaultPath;

            if (Directory.Exists(path))
            {
                fb.CurrentDir = path;
            }

            fb.DirectoryChangedEvent += new DirectoryChangedEventHandler(OnDirChanged);
            filelister.RowActivated  += new Gtk.RowActivatedHandler(FileSelected);
            IdeApp.Workspace.FirstWorkspaceItemOpened += OnCombineOpened;
            IdeApp.Workspace.LastWorkspaceItemClosed  += OnCombineClosed;

            Gtk.ScrolledWindow listsw = new Gtk.ScrolledWindow();
            listsw.Add(filelister);

            fontChanger = new PadFontChanger(listsw, delegate(Pango.FontDescription desc)
            {
                filelister.SetCustomFont(desc);
                fb.SetCustomFont(desc);
            }, delegate()
            {
                filelister.ColumnsAutosize();
                fb.ColumnsAutosize();
            });

            this.Pack1(fb, true, true);
            this.Pack2(listsw, true, true);

            fb.SelectFirst();

            OnDirChanged(fb.CurrentDir);
            this.ShowAll();
        }
Esempio n. 11
0
        void IPlugin.Init(object context)
        {
            solidIDE   = context as ISolidIDE;
            mainWindow = solidIDE.GetMainWindow();

            // Dock with PropertyGrid
            Gtk.ScrolledWindow inspectorGridScrollWindow = new Gtk.ScrolledWindow();
            Gtk.Viewport       inspectorGridViewport     = new Gtk.Viewport();
            inspectorGridScrollWindow.Add(inspectorGridViewport);
            inspectorGrid = new SolidV.Gtk.InspectorGrid.InspectorGrid();
            inspectorGridViewport.Add(inspectorGrid);
            inspectorGridScrollWindow.ShowAll();

            InspectorDockItem                = mainWindow.DockFrame.AddItem("Inspector");
            InspectorDockItem.Behavior       = DockItemBehavior.Normal;
            InspectorDockItem.Expand         = true;
            InspectorDockItem.DrawFrame      = true;
            InspectorDockItem.Label          = "Inspector";
            InspectorDockItem.Content        = inspectorGridScrollWindow;
            InspectorDockItem.DefaultVisible = true;
            InspectorDockItem.Visible        = true;

            IServiceContainer plugins  = solidIDE.GetServiceContainer();
            IDesigner         designer = plugins.GetService <IDesigner>();

            designer.CurrentSheetChanged += HandleDesignerCurrentSheetChanged;

            // Menu
            var viewMenuItem      = solidIDE.GetMenuItem <Gtk.ImageMenuItem>("View");
            var InspectorMenuItem = solidIDE.GetMenuItem <Gtk.ImageMenuItem>("View", "Inspector");

            InspectorMenuItem.Activated += HandleShowInspectorActivated;
        }
Esempio n. 12
0
 public TextAreaHandler()
 {
     scroll            = new Gtk.ScrolledWindow();
     scroll.ShadowType = Gtk.ShadowType.In;
     Control           = new Gtk.TextView();
     this.Size         = TextArea.DefaultSize;
     scroll.Add(Control);
 }
Esempio n. 13
0
        public WindowView(Main _view, Controller.Window _ctl)
        {
            View = _view;
            Window = _ctl;
            Homogeneous = false;
            Spacing = 0;
            BorderWidth = 0;
            var topLevelBox = new Gtk.VBox();
            topLevelBox.Homogeneous = false;
            topLevelBox.Spacing = 0;
            topLevelBox.BorderWidth = 0;
            textView = new WindowTextView(Window);
            scroll = new Gtk.ScrolledWindow {
                HscrollbarPolicy = Gtk.PolicyType.Automatic,
                VscrollbarPolicy = Gtk.PolicyType.Automatic
            };
            scroll.Add(textView);
            Window.CursorMovedByCommand.Add(i =>
            {
                textView.ScrollToIter(i.GtkIter, 0, false, 0, 0);
            });
            topLevelBox.PackStart(scroll, true, true, 0);

            status = new MultiStatusbar();
            status.Add(StatusbarItem.Create(100, () => Window.CurrentMode.GetName(), Window.CurrentMode.Changed));
            status.Add(StatusbarItem.Create(50, Window.Model.Value.HasUnsavedChanges, b => b ? "" : "Saved"));
            status.AddLast(StatusbarItem.Create(400, Window.Model.Value.File.ProjectRelativeFullName()));
            topLevelBox.PackStart(status, false, false, 0);

            Window.Model.Changed += m =>
            {
                textView.Buffer = m;
            };

            // Wrap the topLevelBox with borders on the left and right
            var hlBox = new Gtk.DrawingArea();
            NormalColor = hlBox.Style.Background(Gtk.StateType.Normal);
            hlBox.WidthRequest = 10;
            var borderBox = new Gtk.HBox();
            borderBox.Homogeneous = false;
            borderBox.Spacing = 0;
            borderBox.BorderWidth = 0;
            borderBox.PackStart(hlBox, false, false, 0);
            borderBox.PackStart(topLevelBox, true, true, 0);

            textView.FocusInEvent += (object o, Gtk.FocusInEventArgs args) =>
            {
                Window.Controller.Windows.Current = Window;
                hlBox.ModifyBg(Gtk.StateType.Normal, HighlightColor);
            };

            textView.FocusOutEvent += (object o, Gtk.FocusOutEventArgs args) =>
            {
                hlBox.ModifyBg(Gtk.StateType.Normal, NormalColor);
            };

            Add(borderBox);
        }
		public InfoDialog (Gtk.Window parent) : base (Catalog.GetString ("Metadata Browser"),
											    parent,
											    Gtk.DialogFlags.NoSeparator | Gtk.DialogFlags.DestroyWithParent)
		{
			info_display = new InfoDisplay ();
			SetDefaultSize (400, 400);
			Gtk.ScrolledWindow scrolled = new Gtk.ScrolledWindow ();
			VBox.PackStart (scrolled);
			scrolled.Add (info_display);
		}
Esempio n. 15
0
 public InfoDialog(Gtk.Window parent) : base(Catalog.GetString("Metadata Browser"),
                                             parent,
                                             Gtk.DialogFlags.NoSeparator | Gtk.DialogFlags.DestroyWithParent)
 {
     info_display = new InfoDisplay();
     SetDefaultSize(400, 400);
     Gtk.ScrolledWindow scrolled = new Gtk.ScrolledWindow();
     VBox.PackStart(scrolled);
     scrolled.Add(info_display);
 }
Esempio n. 16
0
        public CodeEditorControlHandler()
        {
            te = new Mono.TextEditor.TextEditor();
            te.Document.SyntaxMode = Mono.TextEditor.Highlighting.SyntaxModeService.GetSyntaxMode(te.Document, "text/x-python");
            //te.ColorStyle = Mono.TextEditor.Highlighting.SyntaxModeService.GetColorStyle("Light");
            var scroll = new Gtk.ScrolledWindow();

            scroll.BorderWidth = 1;
            scroll.Add(te);
            this.Control = scroll;
        }
Esempio n. 17
0
        void IPlugin.Init(object context)
        {
            solidIDE   = context as ISolidIDE;
            mainWindow = solidIDE.GetMainWindow();

            // Dock with Tree
            Gtk.ScrolledWindow treeViewScrollWindow = new Gtk.ScrolledWindow();
            Gtk.Viewport       treeViewViewport     = new Gtk.Viewport();
            treeViewScrollWindow.Add(treeViewViewport);
            treeView = new Gtk.TreeView();
            treeViewViewport.Add(treeView);
            treeViewScrollWindow.ShowAll();
            Gtk.TreeViewColumn   col             = new Gtk.TreeViewColumn();
            Gtk.CellRendererText colAssemblyCell = new Gtk.CellRendererText();
            col.PackStart(colAssemblyCell, true);
            col.AddAttribute(colAssemblyCell, "text", 0);
            treeView.AppendColumn(col);
            treeView.Model          = new Gtk.TreeStore(typeof(string), typeof(Tool <Gdk.Event, Cairo.Context, Model>), typeof(Shape));
            treeView.RowActivated  += HandleRowActivated;
            treeView.CursorChanged += HandleCursorChanged;
            Gtk.Drag.SourceSet(
                treeView,
                Gdk.ModifierType.Button1Mask,
                new Gtk.TargetEntry[] { new Gtk.TargetEntry("application/x-solidide.shape", Gtk.TargetFlags.App, 0) },
                Gdk.DragAction.Copy
                );

            /*treeView.EnableModelDragSource(
             * Gdk.ModifierType.None,
             * new Gtk.TargetEntry[] { new TargetEntry("application/SolidIDE", 0, 0) },
             * Gdk.DragAction.Default);*/
            treeView.DragBegin   += HandleTreeViewDragBegin;
            treeView.DragDataGet += HandleTreeViewDragDataGet;
            //treeView.DragDrop += HandleTreeViewDragDrop;

            toolboxDockItem                = mainWindow.DockFrame.AddItem("Toolbox");
            toolboxDockItem.Behavior       = DockItemBehavior.Normal;
            toolboxDockItem.Expand         = true;
            toolboxDockItem.DrawFrame      = true;
            toolboxDockItem.Label          = "Toolbox";
            toolboxDockItem.Content        = treeViewScrollWindow;
            toolboxDockItem.DefaultVisible = true;
            toolboxDockItem.Visible        = true;

            UpdateToolbox();

            // Menu
            var viewMenuItem = solidIDE.GetMenuItem <Gtk.ImageMenuItem>("View");

            solidIDE.GetMenuItem <Gtk.TearoffMenuItem>("View", "TearoffView");
            var toolboxMenuItem = solidIDE.GetMenuItem <Gtk.ImageMenuItem>("View", "Toolbox");

            toolboxMenuItem.Activated += HandleShowToolboxActivated;
        }
Esempio n. 18
0
        void IPlugin.Init(object context)
        {
            reflector = context as ISolidReflector;

            mainWindow = reflector.GetMainWindow();
            Gtk.MenuBar mainMenuBar = reflector.GetMainMenu();
            reflector.OnShutDown += HandleOnShutDown;

            Gtk.MenuItem fileMenu = null;
            // Find the File menu if present
            foreach (Gtk.Widget w in mainMenuBar.Children)
            {
                if (w.Name == "FileAction")
                {
                    fileMenu = w as Gtk.MenuItem;
                }
            }

            // If not present - create it
            if (fileMenu == null)
            {
                Gtk.Menu menu = new Gtk.Menu();
                fileMenu         = new Gtk.MenuItem("File");
                fileMenu.Submenu = menu;
                mainMenuBar.Append(fileMenu);
            }

            // Setting up the Open menu item in File
            Gtk.MenuItem open = new Gtk.MenuItem("Open");
            open.Activated += OnActivated;
            (fileMenu.Submenu as Gtk.Menu).Prepend(open);

            // Setting up the window scrollers
            Gtk.ScrolledWindow scrollWindow = new Gtk.ScrolledWindow();
            Gtk.Viewport       viewport     = new Gtk.Viewport();
            scrollWindow.Add(viewport);
            viewport.Add(assemblyTree);
            scrollWindow.ShowAll();

            // Attaching the current dockItem in the DockFrame
            dockItem           = mainWindow.DockFrame.AddItem("AssemblyBrowser");
            dockItem.DrawFrame = true;
            dockItem.Label     = "Assembly";
            dockItem.Content   = scrollWindow;

            LoadEnvironment();

            assemblyTree.RowActivated += HandleRowActivated;

            assemblyTree.Realized += delegate(object sender, EventArgs e) {
                LoadSelectedAssembliesTreePaths();
            };
        }
Esempio n. 19
0
        public CrashDialog(Gtk.Window parent, Exception e)
            : base()
        {
            SetDefaultSize(640, 480);
            Title = "smuxi - " + _("Oops, I did it again...");
            Parent = parent;

            Gtk.HBox hbox = new Gtk.HBox();

            Gtk.Image image = new Gtk.Image(Gtk.Stock.DialogError, Gtk.IconSize.Dialog);
            hbox.PackStart(image, false, false, 2);

            Gtk.VBox label_vbox = new Gtk.VBox();
            Gtk.Label label1 = new Gtk.Label();
            Gtk.Label label2 = new Gtk.Label();
            label1.Markup = "<b>" +
                            _("smuxi crashed because an unhandled exception was thrown!") +
                            "</b>";
            label2.Markup = _("Here is the stacktrace, please report this bug!");
            label_vbox.PackStart(label1, false, false, 0);
            label_vbox.PackStart(new Gtk.Fixed(), true, true, 0);
            label_vbox.PackStart(label2, false, false, 0);
            hbox.PackStart(label_vbox, true, true, 0);

            Gtk.VBox vbox = new Gtk.VBox();
            vbox.PackStart(hbox, false, false, 2);

            Gtk.ScrolledWindow sw = new Gtk.ScrolledWindow();
            sw.ShadowType = Gtk.ShadowType.In;
            Gtk.TextView tv = new Gtk.TextView();
            tv.Editable = false;
            tv.CursorVisible = false;
            sw.Add(tv);
            vbox.PackStart(sw, true, true, 2);

            // add to the dialog
            VBox.PackStart(vbox, true, true, 2);
            AddButton(Gtk.Stock.Quit, 0);

            string message = String.Empty;
            if (e.InnerException != null) {
                message = "Inner-Exception Type:\n"+e.InnerException.GetType()+"\n\n"+
                          "Inner-Exception Message:\n"+e.InnerException.Message+"\n\n"+
                          "Inner-Exception StackTrace:\n"+e.InnerException.StackTrace+"\n";
            }
            message += "Exception Type:\n"+e.GetType()+"\n\n"+
                       "Exception Message:\n"+e.Message+"\n\n"+
                       "Exception StackTrace:\n"+e.StackTrace;
            tv.Buffer.Text = message;

            ShowAll();
        }
Esempio n. 20
0
        public WebViewHandler()
        {
            scroll = new Gtk.ScrolledWindow();

            try {
                Control = new EtoWebView();
            } catch (Exception ex) {
                throw new EtoException("GTK WebView is only supported on Linux, and requires webkit-sharp", ex);
            }

            scroll.Add(Control);
            HandleEvent(WebView.DocumentLoadingEvent);
        }
Esempio n. 21
0
        public void Run(SupportedService service, IBrowsableCollection selection, bool display_tags)
        {
            this.selection       = selection;
            this.current_service = FlickrRemote.Service.FromSupported(service);

            IconView view = new IconView(selection);

            view.DisplayTags  = display_tags;
            view.DisplayDates = false;

            xml = new Glade.XML(null, "FlickrExport.glade", dialog_name, "f-spot");
            xml.Autoconnect(this);

            Dialog.Modal        = false;
            Dialog.TransientFor = null;

            thumb_scrolledwindow.Add(view);
            HandleSizeActive(null, null);

            public_radio.Toggled    += HandlePublicChanged;
            tag_check.Toggled       += HandleTagChanged;
            hierarchy_check.Toggled += HandleHierarchyChanged;
            HandleTagChanged(null, null);
            HandleHierarchyChanged(null, null);

            Dialog.ShowAll();
            Dialog.Response       += HandleResponse;
            auth_flickr.Clicked   += HandleClicked;
            auth_text              = string.Format(auth_label.Text, current_service.Name);
            auth_label.Text        = auth_text;
            used_bandwidth.Visible = false;

            LoadPreference(SCALE_KEY);
            LoadPreference(SIZE_KEY);
            LoadPreference(BROWSER_KEY);
            LoadPreference(TAGS_KEY);
            LoadPreference(TAG_HIERARCHY_KEY);
            LoadPreference(IGNORE_TOP_LEVEL_KEY);
            LoadPreference(STRIP_META_KEY);
            LoadPreference(PUBLIC_KEY);
            LoadPreference(FAMILY_KEY);
            LoadPreference(FRIENDS_KEY);
            LoadPreference(current_service.PreferencePath);

            do_export_flickr.Sensitive = false;
            fr = new FlickrRemote(token, current_service);
            if (token != null && token.Length > 0)
            {
                StartAuth();
            }
        }
Esempio n. 22
0
        public void Run(IBrowsableCollection selection)
        {
            this.selection = selection;

            var view = new TrayView(selection);

            view.DisplayDates = false;
            view.DisplayTags  = false;

            builder = new GtkBeans.Builder(null, "folder_export.ui", null);
            builder.Autoconnect(this);
            Dialog.Modal        = false;
            Dialog.TransientFor = null;

            thumb_scrolledwindow.Add(view);
            HandleSizeActive(null, null);
            name_entry.Text = gallery_name;

            string uri_path = System.IO.Path.Combine(FSpot.Core.Global.HomeDirectory, "Desktop");

            if (!System.IO.Directory.Exists(uri_path))
            {
                uri_path = FSpot.Core.Global.HomeDirectory;
            }

            uri_chooser = new Gtk.FileChooserButton(Catalog.GetString("Select Export Folder"),
                                                    Gtk.FileChooserAction.SelectFolder);

            uri_chooser.LocalOnly = false;

            if (!String.IsNullOrEmpty(Preferences.Get <string> (URI_KEY)))
            {
                uri_chooser.SetCurrentFolderUri(Preferences.Get <string> (URI_KEY));
            }
            else
            {
                uri_chooser.SetFilename(uri_path);
            }

            chooser_hbox.PackStart(uri_chooser);

            Dialog.ShowAll();
            Dialog.Response += HandleResponse;

            LoadPreference(SCALE_KEY);
            LoadPreference(SIZE_KEY);
            LoadPreference(OPEN_KEY);
            LoadPreference(EXPORT_TAGS_KEY);
            LoadPreference(EXPORT_TAG_ICONS_KEY);
            LoadPreference(METHOD_KEY);
        }
Esempio n. 23
0
        public WebViewHandler()
        {
            scroll = new Gtk.ScrolledWindow();

            try
            {
                Control = new EtoWebView();
            }
            catch (Exception ex)
            {
                throw new InvalidOperationException("GTK WebView is only supported on Linux, and requires webkit-sharp", ex);
            }
            scroll.Add(Control);
        }
Esempio n. 24
0
        public void Run(SupportedService service, IBrowsableCollection selection, bool display_tags)
        {
            this.selection  = selection;
            current_service = FlickrRemote.Service.FromSupported(service);

            var view = new TrayView(selection);

            view.DisplayTags  = display_tags;
            view.DisplayDates = false;

            builder = new GtkBeans.Builder(null, "flickr_export.ui", null);
            builder.Autoconnect(this);

            Dialog.Modal        = false;
            Dialog.TransientFor = null;

            thumb_scrolledwindow.Add(view);
            HandleSizeActive(null, null);

            public_radio.Toggled    += HandlePublicChanged;
            tag_check.Toggled       += HandleTagChanged;
            hierarchy_check.Toggled += HandleHierarchyChanged;
            HandleTagChanged(null, null);
            HandleHierarchyChanged(null, null);

            Dialog.ShowAll();
            Dialog.Response       += HandleResponse;
            auth_flickr.Clicked   += HandleClicked;
            auth_text              = string.Format(auth_label.Text, current_service.Name);
            auth_label.Text        = auth_text;
            used_bandwidth.Visible = false;

            LoadPreference(SCALE_KEY);
            LoadPreference(SIZE_KEY);
            LoadPreference(BROWSER_KEY);
            LoadPreference(TAGS_KEY);
            LoadPreference(TAG_HIERARCHY_KEY);
            LoadPreference(IGNORE_TOP_LEVEL_KEY);
            LoadPreference(PUBLIC_KEY);
            LoadPreference(FAMILY_KEY);
            LoadPreference(FRIENDS_KEY);
            LoadPreference(current_service.PreferencePath);

            do_export_flickr.Sensitive = false;
            fr = new FlickrRemote(token, current_service);
            if (!string.IsNullOrEmpty(token))
            {
                StartAuth();
            }
        }
Esempio n. 25
0
        public static UITabPage CreateUICanvasTab(Gtk.Notebook parentNotebook, GameConfigDB gameConfigDB, bool isInitializing = false)
        {
            Gtk.ScrolledWindow scrolledWindow = new Gtk.ScrolledWindow();
            scrolledWindow.Name       = "_scrolledWindow" + nextGeneratedTabIndex;
            scrolledWindow.ShadowType = ((Gtk.ShadowType)(1));
            scrolledWindow.ShowAll();

            Gtk.Viewport viewport = new Gtk.Viewport();
            viewport.ShadowType = ((Gtk.ShadowType)(0));

            Gtk.Fixed canvas = new Gtk.Fixed();
            canvas.WidthRequest  = 800;
            canvas.HeightRequest = 600;
            canvas.Name          = "_gameCanvas" + nextGeneratedTabIndex;
            canvas.HasWindow     = false;
            canvas.ShowAll();
            viewport.Add(canvas);
            viewport.ShowAll();
            scrolledWindow.Add(viewport);

            Gtk.Viewport viewportLabel = new Gtk.Viewport();
            viewportLabel.ShadowType    = ((Gtk.ShadowType)(0));
            viewportLabel.WidthRequest  = 80;
            viewportLabel.HeightRequest = 30;

            Gtk.Label label = new Gtk.Label();
            label.Name      = "label1";
            label.LabelProp = global::Mono.Unix.Catalog.GetString(gameConfigDB.GetName());
            label.ShowAll();
            viewportLabel.Add(label);

            if (parentNotebook.NPages <= 0 || isInitializing)
            {
                parentNotebook.Add(scrolledWindow);
                parentNotebook.SetTabLabel(scrolledWindow, viewportLabel);
            }
            else
            {
                parentNotebook.InsertPage(scrolledWindow, viewportLabel, parentNotebook.NPages - 1);
                parentNotebook.Page = parentNotebook.NPages - 2;
            }

            UITabPage tabPage = new UITabPage(gameConfigDB, scrolledWindow, viewport, label, canvas);

            tabPage.InitDropEvent();
            scrolledWindow.Data.Add("UITabPage", tabPage);

            return(tabPage);
        }
Esempio n. 26
0
        public TextEditorDialog()
        {
            Gtk.ScrolledWindow sc = new Gtk.ScrolledWindow();
            sc.HscrollbarPolicy = Gtk.PolicyType.Automatic;
            sc.VscrollbarPolicy = Gtk.PolicyType.Automatic;
            sc.ShadowType       = Gtk.ShadowType.In;
            sc.BorderWidth      = 6;

            textview = new Gtk.TextView();
            sc.Add(textview);

            dialog = new Gtk.Dialog();
            dialog.AddButton(Gtk.Stock.Cancel, Gtk.ResponseType.Cancel);
            dialog.AddButton(Gtk.Stock.Ok, Gtk.ResponseType.Ok);
            dialog.VBox.Add(sc);
        }
Esempio n. 27
0
		public TextEditorDialog ()
		{
			Gtk.ScrolledWindow sc = new Gtk.ScrolledWindow ();
			sc.HscrollbarPolicy = Gtk.PolicyType.Automatic;
			sc.VscrollbarPolicy = Gtk.PolicyType.Automatic;
			sc.ShadowType = Gtk.ShadowType.In;
			sc.BorderWidth = 6;
			
			textview = new Gtk.TextView ();
			sc.Add (textview);
			
			dialog = new Gtk.Dialog ();
			dialog.AddButton (Gtk.Stock.Cancel, Gtk.ResponseType.Cancel);
			dialog.AddButton (Gtk.Stock.Ok, Gtk.ResponseType.Ok);
			dialog.VBox.Add (sc);
		}
Esempio n. 28
0
		public LogWindow() : base("Log Model")
		{
			this.Move(0,0);

			this.SetSizeRequest(600, 500);

			Gtk.TreeView treeviewLog = new Gtk.TreeView();

			Gtk.TreeViewColumn idColumn = new Gtk.TreeViewColumn ();
			idColumn.Title = "Id";

			Gtk.TreeViewColumn typeColumn = new Gtk.TreeViewColumn ();
			typeColumn.Title = "Type";

			Gtk.TreeViewColumn descriptionColumn = new Gtk.TreeViewColumn ();
			descriptionColumn.Title = "Description";

			logListStore = new Gtk.ListStore (typeof (string), typeof (string), typeof (string));

			treeviewLog.AppendColumn(idColumn);
			treeviewLog.AppendColumn(typeColumn);
			treeviewLog.AppendColumn(descriptionColumn);

			treeviewLog.Model = logListStore;




			Gtk.CellRendererText idCell = new Gtk.CellRendererText ();
			idColumn.PackStart(idCell, true);

			Gtk.CellRendererText typeCell = new Gtk.CellRendererText ();
			typeColumn.PackStart(typeCell, true);

			Gtk.CellRendererText descriptionCell = new Gtk.CellRendererText ();
			descriptionColumn.PackStart(descriptionCell, true);

			idColumn.AddAttribute(idCell, "text", 0);
			typeColumn.AddAttribute(typeCell, "text", 1);
			descriptionColumn.AddAttribute(descriptionCell, "text", 2);

			Gtk.ScrolledWindow scWindow = new Gtk.ScrolledWindow();
			scWindow.Add(treeviewLog);

			this.Add(scWindow);

		}
Esempio n. 29
0
        /// <summary>
        /// Calcula la vista que mostrará la lista de ejercicios (<see cref="ExerciseTreeView"></see>).
        /// </summary>
        /// <returns>La vista en la que se muestra una lista de los ejercicios (<see cref="ExerciseTreeView"></see>).</returns>
        private Gtk.VBox ExercisesListView()
        {
            var ViewBox = new Gtk.VBox(false, 5);

            // ------------------INICIALIZACION---------------------

            // Tree.
            ExercisesTreeview = new Gtk.TreeView();
            ExercisesTreeview.HeightRequest = 150;

            // Tree model.
            ExercisesTreeview.Model =
                new Gtk.ListStore(typeof(string), typeof(string), typeof(string));

            // Tree events
            ExercisesTreeview.ButtonPressEvent += new Gtk.ButtonPressEventHandler(OnRightExercise);

            // Tree columns.
            var DistRender = new Gtk.CellRendererText();

            DistRender.Editable = true;
            DistRender.Edited  += ExercisesDistEdit;

            var MinsRender = new Gtk.CellRendererText();

            MinsRender.Editable = true;
            MinsRender.Edited  += ExercisesMinsEdit;

            // Boxes Creation.
            var TreeScroll = new Gtk.ScrolledWindow();
            var TreeSpace  = new Gtk.HBox(false, 5);

            // -------------------COMPOSICION------------------------

            // Tree Columns Append.
            ExercisesTreeview.AppendColumn("Dist", DistRender, "text", 0);
            ExercisesTreeview.AppendColumn("Mins", MinsRender, "text", 1);
            ExercisesTreeview.AppendColumn("Date", new Gtk.CellRendererText(), "text", 2);

            // Fill Boxes.
            TreeScroll.Add(ExercisesTreeview);
            TreeSpace.Add(TreeScroll);

            ViewBox.Add(TreeSpace);

            return(ViewBox);
        }
Esempio n. 30
0
        public LogWindow() : base("Log Model")
        {
            this.Move(0, 0);

            this.SetSizeRequest(600, 500);

            Gtk.TreeView treeviewLog = new Gtk.TreeView();

            Gtk.TreeViewColumn idColumn = new Gtk.TreeViewColumn();
            idColumn.Title = "Id";

            Gtk.TreeViewColumn typeColumn = new Gtk.TreeViewColumn();
            typeColumn.Title = "Type";

            Gtk.TreeViewColumn descriptionColumn = new Gtk.TreeViewColumn();
            descriptionColumn.Title = "Description";

            logListStore = new Gtk.ListStore(typeof(string), typeof(string), typeof(string));

            treeviewLog.AppendColumn(idColumn);
            treeviewLog.AppendColumn(typeColumn);
            treeviewLog.AppendColumn(descriptionColumn);

            treeviewLog.Model = logListStore;



            Gtk.CellRendererText idCell = new Gtk.CellRendererText();
            idColumn.PackStart(idCell, true);

            Gtk.CellRendererText typeCell = new Gtk.CellRendererText();
            typeColumn.PackStart(typeCell, true);

            Gtk.CellRendererText descriptionCell = new Gtk.CellRendererText();
            descriptionColumn.PackStart(descriptionCell, true);

            idColumn.AddAttribute(idCell, "text", 0);
            typeColumn.AddAttribute(typeCell, "text", 1);
            descriptionColumn.AddAttribute(descriptionCell, "text", 2);

            Gtk.ScrolledWindow scWindow = new Gtk.ScrolledWindow();
            scWindow.Add(treeviewLog);

            this.Add(scWindow);
        }
Esempio n. 31
0
		public ListBoxHandler()
		{
			model = new GtkEnumerableModel<object>{ Handler = this };
			
			scroll = new Gtk.ScrolledWindow();
			scroll.ShadowType = Gtk.ShadowType.In;
			Control = new Gtk.TreeView(new Gtk.TreeModelAdapter(model));
			Size = new Size(80, 80);
			//tree.FixedHeightMode = true;
			Control.ShowExpanders = false;
			scroll.Add(Control);

			Control.Events |= Gdk.EventMask.ButtonPressMask;

			Control.AppendColumn("Img", new Gtk.CellRendererPixbuf(), "pixbuf", 1);
			Control.AppendColumn("Data", new Gtk.CellRendererText(), "text", 0);
			Control.HeadersVisible = false;
		}
Esempio n. 32
0
        public FlagsSelectorDialog(Gtk.Window parent, Type enumDesc, ulong flags, string title)
        {
            this.flags  = flags;
            this.parent = parent;

            Gtk.ScrolledWindow sc = new Gtk.ScrolledWindow();
            sc.HscrollbarPolicy = Gtk.PolicyType.Automatic;
            sc.VscrollbarPolicy = Gtk.PolicyType.Automatic;
            sc.ShadowType       = Gtk.ShadowType.In;
            sc.BorderWidth      = 6;

            treeView = new Gtk.TreeView();
            sc.Add(treeView);

            dialog = new Gtk.Dialog();
            IdeTheme.ApplyTheme(dialog);
            dialog.VBox.Add(sc);
            dialog.AddButton(Gtk.Stock.Cancel, Gtk.ResponseType.Cancel);
            dialog.AddButton(Gtk.Stock.Ok, Gtk.ResponseType.Ok);

            store                   = new Gtk.ListStore(typeof(bool), typeof(string), typeof(ulong));
            treeView.Model          = store;
            treeView.HeadersVisible = false;

            Gtk.TreeViewColumn col = new Gtk.TreeViewColumn();

            Gtk.CellRendererToggle tog = new Gtk.CellRendererToggle();
            tog.Toggled += new Gtk.ToggledHandler(OnToggled);
            col.PackStart(tog, false);
            col.AddAttribute(tog, "active", 0);

            Gtk.CellRendererText crt = new Gtk.CellRendererText();
            col.PackStart(crt, true);
            col.AddAttribute(crt, "text", 1);

            treeView.AppendColumn(col);

            values = System.Enum.GetValues(enumDesc);
            foreach (object value in values)
            {
                ulong val = Convert.ToUInt64(value);
                store.AppendValues((flags == 0 && val == 0) || ((flags & val) != 0), value.ToString(), val);
            }
        }
Esempio n. 33
0
 private static void RunModalDialog(string title, string format, params object [] args)
 {
     Gtk.Dialog dlg = new Gtk.Dialog ("Tomboy.InsertImage - " + Catalog.GetString(title), null,
                                      Gtk.DialogFlags.Modal | Gtk.DialogFlags.DestroyWithParent);
     var text = new Gtk.TextView ();
     text.WrapMode = Gtk.WrapMode.Word;
     text.Editable = false;
     if (args.Length > 0)
         format = string.Format (format, args);
     text.Buffer.Text = format;
     var scroll = new Gtk.ScrolledWindow ();
     scroll.Add (text);
     dlg.AddButton (Catalog.GetString("Close"), Gtk.ResponseType.Close);
     dlg.VBox.PackStart (scroll, true, true, 0);
     dlg.SetSizeRequest (300, 240);
     scroll.ShowAll ();
     dlg.Run ();
     dlg.Destroy ();
 }
Esempio n. 34
0
 internal void UpdateScrolledWindow()
 {
     if (ParentWrapper == null)
     {
         return;
     }
     if (boundToScrollWindow)
     {
         if (!(Wrapped.Parent is Gtk.Viewport) && !(Wrapped.Parent is Gtk.ScrolledWindow))
         {
             Gtk.ScrolledWindow scw = new Gtk.ScrolledWindow();
             scw.HscrollbarPolicy = scw.VscrollbarPolicy = Gtk.PolicyType.Automatic;
             scw.ShadowType       = Gtk.ShadowType.In;
             ScrolledWindow wrapper = (ScrolledWindow)ObjectWrapper.Create(Project, scw, ParentWrapper);
             ParentWrapper.ReplaceChild(Wrapped, scw, false);
             if (Wrapped.SetScrollAdjustments(null, null))
             {
                 scw.Add(Wrapped);
             }
             else
             {
                 wrapper.AddWithViewport(Wrapped);
             }
             Select();
         }
     }
     else if (((Wrapped.Parent is Gtk.Viewport) || (Wrapped.Parent is Gtk.ScrolledWindow)) && ParentWrapper.ParentWrapper != null)
     {
         Gtk.Container parent = (Gtk.Container)Wrapped.Parent;
         parent.Remove(Wrapped);
         Container grandParent;
         if (parent is Gtk.Viewport)
         {
             parent      = (Gtk.Container)parent.Parent;
             grandParent = Container.LookupParent(parent);
         }
         else
         {
             grandParent = Container.LookupParent(parent);
         }
         grandParent.ReplaceChild(parent, Wrapped, true);
     }
 }
		public FlagsSelectorDialog (Gtk.Window parent, Type enumDesc, ulong flags, string title)
		{
			this.flags = flags;
			this.parent = parent;

			Gtk.ScrolledWindow sc = new Gtk.ScrolledWindow ();
			sc.HscrollbarPolicy = Gtk.PolicyType.Automatic;
			sc.VscrollbarPolicy = Gtk.PolicyType.Automatic;
			sc.ShadowType = Gtk.ShadowType.In;
			sc.BorderWidth = 6;
			
			treeView = new Gtk.TreeView ();
			sc.Add (treeView);
			
			dialog = new Gtk.Dialog ();
			IdeTheme.ApplyTheme (dialog);
			dialog.VBox.Add (sc);
			dialog.AddButton (Gtk.Stock.Cancel, Gtk.ResponseType.Cancel);
			dialog.AddButton (Gtk.Stock.Ok, Gtk.ResponseType.Ok);
			
			store = new Gtk.ListStore (typeof(bool), typeof(string), typeof(ulong));
			treeView.Model = store;
			treeView.HeadersVisible = false;
			
			Gtk.TreeViewColumn col = new Gtk.TreeViewColumn ();
			
			Gtk.CellRendererToggle tog = new Gtk.CellRendererToggle ();
			tog.Toggled += new Gtk.ToggledHandler (OnToggled);
			col.PackStart (tog, false);
			col.AddAttribute (tog, "active", 0);
			
			Gtk.CellRendererText crt = new Gtk.CellRendererText ();
			col.PackStart (crt, true);
			col.AddAttribute (crt, "text", 1);
			
			treeView.AppendColumn (col);

			values = System.Enum.GetValues (enumDesc);
			foreach (object value in values) {
				ulong val = Convert.ToUInt64 (value);
				store.AppendValues ((flags == 0 && val == 0) || ((flags & val) != 0), value.ToString (), val);
			}
		}
Esempio n. 36
0
        public void Run(IBrowsableCollection selection)
        {
            xml = new Glade.XML(null, "CDExport.glade", dialog_name, "f-spot");
            xml.Autoconnect(this);

            this.selection = selection;

            // Calculate the total size
            long   total_size = 0;
            string path;

            System.IO.FileInfo file_info;

            foreach (IBrowsableItem item in selection.Items)
            {
                path = item.DefaultVersionUri.LocalPath;
                if (System.IO.File.Exists(path))
                {
                    file_info   = new System.IO.FileInfo(path);
                    total_size += file_info.Length;
                }
            }

            IconView view = new IconView(selection);

            view.DisplayDates = false;
            view.DisplayTags  = false;

            Dialog.Modal        = false;
            Dialog.TransientFor = null;

            size_label.Text = SizeUtil.ToHumanReadable(total_size);

            thumb_scrolledwindow.Add(view);
            Dialog.ShowAll();

            previous_frame.Visible = IsEmpty(dest);
            //LoadHistory ();

            Dialog.Response += HandleResponse;
        }
        public void Run(SupportedService service, IBrowsableCollection selection, bool display_tags)
        {
            this.selection       = selection;
            this.current_service = FlickrRemote.Service.FromSupported(service);

            IconView view = new IconView(selection);

            view.DisplayTags  = display_tags;
            view.DisplayDates = false;

            Dialog.Modal        = false;
            Dialog.TransientFor = null;

            thumb_scrolledwindow.Add(view);
            HandleSizeActive(null, null);

            public_radio.Toggled += HandlePublicChanged;

            Dialog.ShowAll();
            Dialog.Response     += HandleResponse;
            auth_flickr.Clicked += HandleClicked;
            auth_text            = string.Format(auth_label.Text, current_service.Name);
            auth_label.Text      = auth_text;

            LoadPreference(Preferences.EXPORT_FLICKR_SCALE);
            LoadPreference(Preferences.EXPORT_FLICKR_SIZE);
            LoadPreference(Preferences.EXPORT_FLICKR_BROWSER);
            LoadPreference(Preferences.EXPORT_FLICKR_TAGS);
            LoadPreference(Preferences.EXPORT_FLICKR_STRIP_META);
            LoadPreference(Preferences.EXPORT_FLICKR_PUBLIC);
            LoadPreference(Preferences.EXPORT_FLICKR_FAMILY);
            LoadPreference(Preferences.EXPORT_FLICKR_FRIENDS);
            LoadPreference(current_service.PreferencePath);

            do_export_flickr.Sensitive = false;
            fr = new FlickrRemote(token, current_service);
            if (token != null && token.Length > 0)
            {
                StartAuth();
            }
        }
Esempio n. 38
0
        /// <summary>Create a new <see cref="AddWindow" />.</summary>
        /// <remarks>This is used as a base class for
        ///   <see cref="AddAlbumWindow" /> and
        ///   <see cref="AddSongWindow" />.</remarks>
        public AddWindow() : base(IntPtr.Zero)
        {
            Glade.XML gxml =
                new Glade.XML(null, "AddWindow.glade", "window", null);

            gxml.Autoconnect(this);

            base.Raw = this.window.Handle;

            this.play_button_image.SetFromStock
                ("stock_media-play", Gtk.IconSize.Button);

            this.queue_button_image.SetFromStock
                ("stock_timer", Gtk.IconSize.Button);

            // Cell Renderer
            this.text_renderer.Ellipsize = Pango.EllipsizeMode.End;
            // Label
            this.search_label.MnemonicWidget = this.entry;

            // Entry
            this.entry.KeyPressEvent += OnEntryKeyPressEvent;
            this.entry.Changed       += OnEntryChanged;
            this.entry_container.Add(this.entry);

            // List
            this.Response    += OnWindowResponse;
            this.DeleteEvent += OnWindowDeleteEvent;

            this.list.RowActivated      += OnRowActivated;
            this.list.Selection.Changed += OnSelectionChanged;
            scrolledwindow.Add(this.list);

            // Show widgets (except window)
            this.entry.Show();
            this.list.Show();

            // Realize
            //   Needed for the cursor changing later on
            this.window.Realize();
        }
Esempio n. 39
0
        public ListBoxHandler()
        {
            model = new GtkListModel <IListItem, IListStore> {
                Handler = this
            };

            scroll            = new Gtk.ScrolledWindow();
            scroll.ShadowType = Gtk.ShadowType.In;
            Control           = new Gtk.TreeView(new Gtk.TreeModelAdapter(model));
            //tree.FixedHeightMode = true;
            Control.ShowExpanders = false;
            scroll.Add(Control);

            Control.Events           |= Gdk.EventMask.ButtonPressMask;
            Control.ButtonPressEvent += HandleTreeButtonPressEvent;

            Control.AppendColumn("Img", new Gtk.CellRendererPixbuf(), "pixbuf", 1);
            Control.AppendColumn("Data", new Gtk.CellRendererText(), "text", 0);
            Control.HeadersVisible     = false;
            Control.Selection.Changed += selection_Changed;
            Control.RowActivated      += tree_RowActivated;
        }
Esempio n. 40
0
        public FileScout()
        {
            fb.DirectoryChangedEvent += new DirectoryChangedEventHandler (OnDirChanged);
            filelister.RowActivated += new Gtk.RowActivatedHandler (FileSelected);
            Runtime.ProjectService.CombineOpened += (CombineEventHandler) Runtime.DispatchService.GuiDispatch (new CombineEventHandler(OnCombineOpened));
            Runtime.ProjectService.CombineClosed += (CombineEventHandler) Runtime.DispatchService.GuiDispatch (new CombineEventHandler(OnCombineClosed));

            Gtk.Frame treef  = new Gtk.Frame ();
            treef.Add (fb);

            Gtk.ScrolledWindow listsw = new Gtk.ScrolledWindow ();
            listsw.ShadowType = Gtk.ShadowType.In;
            listsw.Add (filelister);

            this.Pack1 (treef, true, true);
            this.Pack2 (listsw, true, true);

            fb.SelectFirst ();

            OnDirChanged (fb.CurrentDir);
            this.ShowAll ();
        }
Esempio n. 41
0
        internal TabbloExportView(IBrowsableCollection photos)
            : base(Assembly.GetExecutingAssembly(),
                   "TabbloExport.ui", DialogName)
        {
            // Thumbnails
            var icon_view = new TrayView(photos);

            icon_view.DisplayDates = false;
            icon_view.DisplayTags  = false;

            thumb_scrolled_window.Add(icon_view);
            icon_view.Show();

            // Tags
            attached_tags_view = new FSpot.Widgets.TagView();
            attached_tags_alignment.Add(attached_tags_view);
            attached_tags_view.Show();

            removed_tags_view = new FSpot.Widgets.TagView();
            removed_tags_alignment.Add(removed_tags_view);
            removed_tags_view.Show();
        }
Esempio n. 42
0
        public WebViewHandler()
        {
            scroll = new Gtk.ScrolledWindow();

            try {
                Control = new EtoWebView();
            } catch (Exception ex) {
                throw new EtoException("GTK WebView is only supported on Linux, and requires webkit-sharp", ex);
            }
            Control.PopulatePopup += (o, args) => {
                if (BrowserContextMenuEnabled)
                {
                    return;
                }
                // don't allow context menu by default
                foreach (var child in args.Menu.Children)
                {
                    args.Menu.Remove(child);
                }
            };
            scroll.Add(Control);
            HandleEvent(WebView.DocumentLoadingEvent);
        }
Esempio n. 43
0
 public ElementChooserDialog(Type requestedType, string title)
 {
     base.Modal = true;
     base.HeightRequest = 400;
     base.WidthRequest = 250;
     //TODO: i18n
     base.Title = title;
     base.AddButton (GettextCatalog.GetString ("_Cancel"), Gtk.ResponseType.Cancel);
     base.AddButton (GettextCatalog.GetString ("_Accept"), Gtk.ResponseType.Accept);
     base.Response += new Gtk.ResponseHandler(OnResponse);
     base.SetResponseSensitive(Gtk.ResponseType.Accept, false);
     _requestedType = requestedType;
     Tree tree = new Tree();
     tree.IsReadOnly = true;
     tree.Draw(_elementList);
     tree.Show();
     _tree = tree;
     _tree.SetBroadcaster(this);
     Gtk.ScrolledWindow sw = new Gtk.ScrolledWindow();
     sw.Add(tree);
     base.VBox.Add(sw);
     sw.Show();
 }
Esempio n. 44
0
        public void Run(IBrowsableCollection selection)
        {
            this.selection = selection;

            // Calculate the total size
            long   total_size = 0;
            string path;

            System.IO.FileInfo file_info;

            foreach (IBrowsableItem item in selection.Items)
            {
                path = item.DefaultVersionUri.LocalPath;
                if (System.IO.File.Exists(path))
                {
                    file_info   = new System.IO.FileInfo(path);
                    total_size += file_info.Length;
                }
            }

            IconView view = new IconView(selection);

            view.DisplayDates = false;
            view.DisplayTags  = false;

            Dialog.Modal        = false;
            Dialog.TransientFor = null;

            size_label.Text = SizeUtil.ToHumanReadable(total_size);

            thumb_scrolledwindow.Add(view);
            Dialog.ShowAll();

            //LoadHistory ();

            Dialog.Response += HandleResponse;
        }
Esempio n. 45
0
 protected virtual void Build()
 {
     Name = "GtkSharpTest.Database";
     // Container child GtkSharpTest.Database.Gtk.Container+ContainerChild
     vbox5 = new Gtk.VBox();
     vbox5.Name = "vbox5";
     vbox5.Spacing = 6;
     // Container child vbox5.Gtk.Box+BoxChild
     CurrentPath = new Gtk.Label();
     CurrentPath.Name = "CurrentPath";
     CurrentPath.Xalign = 0F;
     CurrentPath.LabelProp = Mono.Unix.Catalog.GetString("label11");
     vbox5.Add(CurrentPath);
     Gtk.Box.BoxChild w1 = (Gtk.Box.BoxChild) vbox5[CurrentPath];
     w1.Position = 0;
     w1.Expand = false;
     w1.Fill = false;
     // Container child vbox5.Gtk.Box+BoxChild
     GtkScrolledWindow = new Gtk.ScrolledWindow();
     GtkScrolledWindow.Name = "GtkScrolledWindow";
     GtkScrolledWindow.ShadowType = (Gtk.ShadowType) 1;
     // Container child GtkScrolledWindow.Gtk.Container+ContainerChild
     Contents = new Gtk.IconView();
     Contents.CanFocus = true;
     Contents.Name = "Contents";
     GtkScrolledWindow.Add(Contents);
     vbox5.Add(GtkScrolledWindow);
     Gtk.Box.BoxChild w3 = (Gtk.Box.BoxChild) vbox5[GtkScrolledWindow];
     w3.Position = 1;
     Add(vbox5);
     /*if ((this.Child != null))
     {
         this.Child.ShowAll();
     }*/
     Hide();
 }
Esempio n. 46
0
 public static void Build(object obj, string id)
 {
     System.Collections.Hashtable bindings = new System.Collections.Hashtable();
     if ((id == "administrator.EditCreateUser")) {
         Gtk.Window cobj = ((Gtk.Window)(obj));
         // Widget administrator.EditCreateUser
         cobj.Title = "EditCreateUser";
         cobj.WindowPosition = ((Gtk.WindowPosition)(4));
         cobj.Events = ((Gdk.EventMask)(0));
         cobj.Name = "administrator.EditCreateUser";
         cobj.DefaultWidth = 400;
         cobj.DefaultHeight = 300;
         bindings["administrator.EditCreateUser"] = cobj;
         cobj.Show();
     }
     else {
         if ((id == "administrator.LoginWindow")) {
             Gtk.Window cobj = ((Gtk.Window)(obj));
             // Widget administrator.LoginWindow
             cobj.Title = "Boxerp Server Administrator";
             cobj.WindowPosition = ((Gtk.WindowPosition)(1));
             cobj.Modal = true;
             cobj.Resizable = false;
             cobj.AllowGrow = false;
             cobj.Events = ((Gdk.EventMask)(0));
             cobj.Name = "administrator.LoginWindow";
             // Container child administrator.LoginWindow.Gtk.Container+ContainerChild
             Gtk.VBox w1 = new Gtk.VBox();
             w1.BorderWidth = ((uint)(5));
             w1.Events = ((Gdk.EventMask)(0));
             w1.Name = "vbox1";
             // Container child vbox1.Gtk.Box+BoxChild
             Gtk.HBox w2 = new Gtk.HBox();
             w2.Events = ((Gdk.EventMask)(0));
             w2.Name = "hbox1";
             // Container child hbox1.Gtk.Box+BoxChild
             Gtk.Label w3 = new Gtk.Label();
             w3.LabelProp = "Login:"******"label1";
             w3.WidthRequest = 150;
             bindings["label1"] = w3;
             w2.Add(w3);
             Gtk.Box.BoxChild w4 = ((Gtk.Box.BoxChild)(w2[w3]));
             w4.Position = 0;
             // Container child hbox1.Gtk.Box+BoxChild
             Gtk.Entry w5 = new Gtk.Entry();
             w5.Text = "demo";
             w5.IsEditable = true;
             w5.MaxLength = 100;
             w5.InvisibleChar = '●';
             w5.CanFocus = true;
             w5.Events = ((Gdk.EventMask)(0));
             w5.Name = "entryLogin";
             w5.WidthRequest = 200;
             bindings["entryLogin"] = w5;
             w2.Add(w5);
             Gtk.Box.BoxChild w6 = ((Gtk.Box.BoxChild)(w2[w5]));
             w6.Position = 1;
             w6.Expand = false;
             w6.Fill = false;
             bindings["hbox1"] = w2;
             w1.Add(w2);
             Gtk.Box.BoxChild w7 = ((Gtk.Box.BoxChild)(w1[w2]));
             w7.Position = 0;
             w7.Expand = false;
             w7.Fill = false;
             // Container child vbox1.Gtk.Box+BoxChild
             Gtk.HBox w8 = new Gtk.HBox();
             w8.Events = ((Gdk.EventMask)(0));
             w8.Name = "hbox2";
             w8.WidthRequest = 150;
             // Container child hbox2.Gtk.Box+BoxChild
             Gtk.Label w9 = new Gtk.Label();
             w9.LabelProp = "Password:"******"label2";
             bindings["label2"] = w9;
             w8.Add(w9);
             Gtk.Box.BoxChild w10 = ((Gtk.Box.BoxChild)(w8[w9]));
             w10.Position = 0;
             w10.Fill = false;
             // Container child hbox2.Gtk.Box+BoxChild
             Gtk.Entry w11 = new Gtk.Entry();
             w11.Text = "pass";
             w11.IsEditable = true;
             w11.Visibility = false;
             w11.InvisibleChar = '●';
             w11.CanFocus = true;
             w11.Events = ((Gdk.EventMask)(0));
             w11.Name = "entryPassword";
             w11.WidthRequest = 200;
             bindings["entryPassword"] = w11;
             w8.Add(w11);
             Gtk.Box.BoxChild w12 = ((Gtk.Box.BoxChild)(w8[w11]));
             w12.Position = 1;
             w12.Expand = false;
             w12.Fill = false;
             bindings["hbox2"] = w8;
             w1.Add(w8);
             Gtk.Box.BoxChild w13 = ((Gtk.Box.BoxChild)(w1[w8]));
             w13.Position = 1;
             // Container child vbox1.Gtk.Box+BoxChild
             Gtk.HSeparator w14 = new Gtk.HSeparator();
             w14.Events = ((Gdk.EventMask)(0));
             w14.Name = "hseparator1";
             bindings["hseparator1"] = w14;
             w1.Add(w14);
             Gtk.Box.BoxChild w15 = ((Gtk.Box.BoxChild)(w1[w14]));
             w15.Position = 2;
             w15.Expand = false;
             w15.Fill = false;
             // Container child vbox1.Gtk.Box+BoxChild
             Gtk.HBox w16 = new Gtk.HBox();
             w16.Events = ((Gdk.EventMask)(0));
             w16.Name = "hbox3";
             // Container child hbox3.Gtk.Box+BoxChild
             Gtk.Button w17 = new Gtk.Button();
             w17.CanFocus = true;
             w17.Events = ((Gdk.EventMask)(0));
             w17.Name = "buttonConnect";
             // Container child buttonConnect.Gtk.Container+ContainerChild
             Gtk.Alignment w18 = new Gtk.Alignment(0.5F, 0.5F, 0F, 0F);
             w18.Events = ((Gdk.EventMask)(0));
             w18.Name = "GtkAlignment";
             // Container child GtkAlignment.Gtk.Container+ContainerChild
             Gtk.HBox w19 = new Gtk.HBox();
             w19.Spacing = 2;
             w19.Events = ((Gdk.EventMask)(0));
             w19.Name = "GtkHBox";
             // Container child GtkHBox.Gtk.Container+ContainerChild
             Gtk.Image w20 = new Gtk.Image();
             w20.Pixbuf = Gtk.IconTheme.Default.LoadIcon("gtk-connect", 16, 0);
             w20.Events = ((Gdk.EventMask)(0));
             w20.Name = "image15";
             bindings["image15"] = w20;
             w19.Add(w20);
             // Container child GtkHBox.Gtk.Container+ContainerChild
             Gtk.Label w22 = new Gtk.Label();
             w22.LabelProp = "Connect";
             w22.Events = ((Gdk.EventMask)(0));
             w22.Name = "GtkLabel";
             bindings["GtkLabel"] = w22;
             w19.Add(w22);
             bindings["GtkHBox"] = w19;
             w18.Add(w19);
             bindings["GtkAlignment"] = w18;
             w17.Add(w18);
             bindings["buttonConnect"] = w17;
             w16.Add(w17);
             Gtk.Box.BoxChild w26 = ((Gtk.Box.BoxChild)(w16[w17]));
             w26.PackType = ((Gtk.PackType)(1));
             w26.Position = 0;
             w26.Expand = false;
             w26.Fill = false;
             bindings["hbox3"] = w16;
             w1.Add(w16);
             Gtk.Box.BoxChild w27 = ((Gtk.Box.BoxChild)(w1[w16]));
             w27.Position = 3;
             w27.Expand = false;
             w27.Fill = false;
             bindings["vbox1"] = w1;
             cobj.Add(w1);
             cobj.DefaultWidth = 370;
             cobj.DefaultHeight = 129;
             bindings["administrator.LoginWindow"] = cobj;
             w3.Show();
             w5.Show();
             w2.Show();
             w9.Show();
             w11.Show();
             w8.Show();
             w14.Show();
             w20.Show();
             w22.Show();
             w19.Show();
             w18.Show();
             w17.Show();
             w16.Show();
             w1.Show();
             cobj.Show();
             cobj.DeleteEvent += ((Gtk.DeleteEventHandler)(System.Delegate.CreateDelegate(typeof(Gtk.DeleteEventHandler), cobj, "OnDeleteEvent")));
             w5.Activated += ((System.EventHandler)(System.Delegate.CreateDelegate(typeof(System.EventHandler), cobj, "OnConnect")));
             w11.Activated += ((System.EventHandler)(System.Delegate.CreateDelegate(typeof(System.EventHandler), cobj, "OnConnect")));
             w17.Clicked += ((System.EventHandler)(System.Delegate.CreateDelegate(typeof(System.EventHandler), cobj, "OnConnect")));
         }
         else {
             if ((id == "administrator.MainWindow")) {
                 Gtk.Window cobj = ((Gtk.Window)(obj));
                 // Widget administrator.MainWindow
                 cobj.Title = "Boxerp Administrator";
                 Gtk.UIManager w1 = new Gtk.UIManager();
                 Gtk.ActionGroup w2 = new Gtk.ActionGroup("Default");
                 Gtk.Action w3 = new Gtk.Action("File", "File", null, null);
                 w3.ShortLabel = "File";
                 bindings["File"] = w3;
                 w2.Add(w3, null);
                 Gtk.Action w4 = new Gtk.Action("Exit", "Exit", null, null);
                 w4.ShortLabel = "Exit";
                 bindings["Exit"] = w4;
                 w2.Add(w4, null);
                 Gtk.Action w5 = new Gtk.Action("Edit", "Edit", null, null);
                 w5.ShortLabel = "Edit";
                 bindings["Edit"] = w5;
                 w2.Add(w5, null);
                 Gtk.Action w6 = new Gtk.Action("Cut", "Cut", null, null);
                 w6.ShortLabel = "Cut";
                 bindings["Cut"] = w6;
                 w2.Add(w6, null);
                 Gtk.Action w7 = new Gtk.Action("Copy", "Copy", null, null);
                 w7.ShortLabel = "Copy";
                 bindings["Copy"] = w7;
                 w2.Add(w7, null);
                 Gtk.Action w8 = new Gtk.Action("Paste", "Paste", null, null);
                 w8.ShortLabel = "Paste";
                 bindings["Paste"] = w8;
                 w2.Add(w8, null);
                 Gtk.Action w9 = new Gtk.Action("Help", "Help", null, null);
                 w9.ShortLabel = "Help";
                 bindings["Help"] = w9;
                 w2.Add(w9, null);
                 Gtk.Action w10 = new Gtk.Action("About", "About", null, null);
                 w10.ShortLabel = "About";
                 bindings["About"] = w10;
                 w2.Add(w10, null);
                 w1.InsertActionGroup(w2, 0);
                 cobj.AddAccelGroup(w1.AccelGroup);
                 cobj.WindowPosition = ((Gtk.WindowPosition)(4));
                 cobj.DefaultWidth = 800;
                 cobj.DefaultHeight = 600;
                 cobj.Events = ((Gdk.EventMask)(0));
                 cobj.Name = "administrator.MainWindow";
                 // Container child administrator.MainWindow.Gtk.Container+ContainerChild
                 Gtk.VBox w11 = new Gtk.VBox();
                 w11.Events = ((Gdk.EventMask)(0));
                 w11.Name = "vbox1";
                 // Container child vbox1.Gtk.Box+BoxChild
                 w1.AddUiFromString("<ui><menubar name='menubar1'><menu action='File'><menuitem action='Exit'/></menu><menu action='Edit'><menuitem action='Cut'/><menuitem action='Copy'/><menuitem action='Paste'/></menu><menu action='Help'><menuitem action='About'/></menu></menubar></ui>");
                 Gtk.MenuBar w12 = ((Gtk.MenuBar)(w1.GetWidget("/menubar1")));
                 w12.Events = ((Gdk.EventMask)(0));
                 w12.Name = "menubar1";
                 bindings["menubar1"] = w12;
                 w11.Add(w12);
                 Gtk.Box.BoxChild w13 = ((Gtk.Box.BoxChild)(w11[w12]));
                 w13.Position = 0;
                 w13.Expand = false;
                 w13.Fill = false;
                 // Container child vbox1.Gtk.Box+BoxChild
                 w1.AddUiFromString("<ui><toolbar name='toolbar1'/></ui>");
                 Gtk.Toolbar w14 = ((Gtk.Toolbar)(w1.GetWidget("/toolbar1")));
                 w14.ShowArrow = false;
                 w14.ToolbarStyle = ((Gtk.ToolbarStyle)(0));
                 w14.IconSize = ((Gtk.IconSize)(3));
                 w14.Events = ((Gdk.EventMask)(0));
                 w14.Name = "toolbar1";
                 bindings["toolbar1"] = w14;
                 w11.Add(w14);
                 Gtk.Box.BoxChild w15 = ((Gtk.Box.BoxChild)(w11[w14]));
                 w15.Position = 1;
                 w15.Expand = false;
                 w15.Fill = false;
                 // Container child vbox1.Gtk.Box+BoxChild
                 Gtk.VBox w16 = new Gtk.VBox();
                 w16.BorderWidth = ((uint)(5));
                 w16.Events = ((Gdk.EventMask)(0));
                 w16.Name = "vbox2";
                 // Container child vbox2.Gtk.Box+BoxChild
                 Gtk.HBox w17 = new Gtk.HBox();
                 w17.Events = ((Gdk.EventMask)(0));
                 w17.Name = "hbox1";
                 // Container child hbox1.Gtk.Box+BoxChild
                 Gtk.Label w18 = new Gtk.Label();
                 w18.LabelProp = "<b>Enterprise:</b>";
                 w18.UseMarkup = true;
                 w18.Ypad = 6;
                 w18.Events = ((Gdk.EventMask)(256));
                 w18.Name = "labelEnterprise";
                 bindings["labelEnterprise"] = w18;
                 w17.Add(w18);
                 Gtk.Box.BoxChild w19 = ((Gtk.Box.BoxChild)(w17[w18]));
                 w19.Position = 0;
                 w19.Expand = false;
                 w19.Fill = false;
                 // Container child hbox1.Gtk.Box+BoxChild
                 Gtk.Entry w20 = new Gtk.Entry();
                 w20.IsEditable = true;
                 w20.InvisibleChar = '●';
                 w20.CanFocus = true;
                 w20.Events = ((Gdk.EventMask)(0));
                 w20.Name = "entryEnterprise";
                 bindings["entryEnterprise"] = w20;
                 w17.Add(w20);
                 Gtk.Box.BoxChild w21 = ((Gtk.Box.BoxChild)(w17[w20]));
                 w21.Position = 1;
                 w21.Expand = false;
                 w21.Fill = false;
                 // Container child hbox1.Gtk.Box+BoxChild
                 Gtk.Button w22 = new Gtk.Button();
                 Gtk.Tooltips w23 = new Gtk.Tooltips();
                 w23.SetTip(w22, "Añadir un Hecho", "Añadir un Hecho");
                 w22.CanFocus = true;
                 w22.Events = ((Gdk.EventMask)(0));
                 w22.Name = "buttonFindEnterprise";
                 w22.HasDefault = true;
                 // Container child buttonFindEnterprise.Gtk.Container+ContainerChild
                 Gtk.Alignment w24 = new Gtk.Alignment(0.5F, 0.5F, 0F, 0F);
                 w24.Events = ((Gdk.EventMask)(0));
                 w24.Name = "GtkAlignment";
                 // Container child GtkAlignment.Gtk.Container+ContainerChild
                 Gtk.HBox w25 = new Gtk.HBox();
                 w25.Spacing = 2;
                 w25.Events = ((Gdk.EventMask)(0));
                 w25.Name = "GtkHBox";
                 // Container child GtkHBox.Gtk.Container+ContainerChild
                 Gtk.Image w26 = new Gtk.Image();
                 w26.Pixbuf = Gtk.IconTheme.Default.LoadIcon("gtk-find", 16, 0);
                 w26.Events = ((Gdk.EventMask)(0));
                 w26.Name = "image1";
                 bindings["image1"] = w26;
                 w25.Add(w26);
                 // Container child GtkHBox.Gtk.Container+ContainerChild
                 Gtk.Label w28 = new Gtk.Label();
                 w28.LabelProp = "";
                 w28.Events = ((Gdk.EventMask)(0));
                 w28.Name = "GtkLabel";
                 bindings["GtkLabel"] = w28;
                 w25.Add(w28);
                 bindings["GtkHBox"] = w25;
                 w24.Add(w25);
                 bindings["GtkAlignment"] = w24;
                 w22.Add(w24);
                 bindings["buttonFindEnterprise"] = w22;
                 w17.Add(w22);
                 Gtk.Box.BoxChild w32 = ((Gtk.Box.BoxChild)(w17[w22]));
                 w32.Position = 2;
                 w32.Expand = false;
                 w32.Fill = false;
                 bindings["hbox1"] = w17;
                 w16.Add(w17);
                 Gtk.Box.BoxChild w33 = ((Gtk.Box.BoxChild)(w16[w17]));
                 w33.Position = 0;
                 w33.Expand = false;
                 w33.Fill = false;
                 // Container child vbox2.Gtk.Box+BoxChild
                 Gtk.ScrolledWindow w34 = new Gtk.ScrolledWindow();
                 w34.VscrollbarPolicy = ((Gtk.PolicyType)(1));
                 w34.HscrollbarPolicy = ((Gtk.PolicyType)(1));
                 w34.CanFocus = true;
                 w34.Events = ((Gdk.EventMask)(0));
                 w34.Name = "scrolledwindow1";
                 // Container child scrolledwindow1.Gtk.Container+ContainerChild
                 Gtk.Viewport w35 = new Gtk.Viewport();
                 w35.ShadowType = ((Gtk.ShadowType)(0));
                 w35.Events = ((Gdk.EventMask)(0));
                 w35.Name = "GtkViewport";
                 // Container child GtkViewport.Gtk.Container+ContainerChild
                 Boxerp.Client.GtkSharp.Lib.FilteredListView w36 = new Boxerp.Client.GtkSharp.Lib.FilteredListView();
                 w36.Events = ((Gdk.EventMask)(256));
                 w36.Name = "ftreeviewEnterprises";
                 bindings["ftreeviewEnterprises"] = w36;
                 w35.Add(w36);
                 bindings["GtkViewport"] = w35;
                 w34.Add(w35);
                 bindings["scrolledwindow1"] = w34;
                 w16.Add(w34);
                 Gtk.Box.BoxChild w39 = ((Gtk.Box.BoxChild)(w16[w34]));
                 w39.Position = 1;
                 // Container child vbox2.Gtk.Box+BoxChild
                 Gtk.HBox w40 = new Gtk.HBox();
                 w40.Events = ((Gdk.EventMask)(0));
                 w40.Name = "hbox14";
                 // Container child hbox14.Gtk.Box+BoxChild
                 Gtk.Button w41 = new Gtk.Button();
                 w23.SetTip(w41, "Añadir un Hecho", "Añadir un Hecho");
                 w41.CanFocus = true;
                 w41.Events = ((Gdk.EventMask)(0));
                 w41.Name = "buttonNewEnterprise";
                 w41.HasDefault = true;
                 // Container child buttonNewEnterprise.Gtk.Container+ContainerChild
                 Gtk.Alignment w42 = new Gtk.Alignment(0.5F, 0.5F, 0F, 0F);
                 w42.Events = ((Gdk.EventMask)(0));
                 w42.Name = "GtkAlignment";
                 // Container child GtkAlignment.Gtk.Container+ContainerChild
                 Gtk.HBox w43 = new Gtk.HBox();
                 w43.Spacing = 2;
                 w43.Events = ((Gdk.EventMask)(0));
                 w43.Name = "GtkHBox";
                 // Container child GtkHBox.Gtk.Container+ContainerChild
                 Gtk.Image w44 = new Gtk.Image();
                 w44.Pixbuf = Gtk.IconTheme.Default.LoadIcon("gtk-new", 16, 0);
                 w44.Events = ((Gdk.EventMask)(0));
                 w44.Name = "image2";
                 bindings["image2"] = w44;
                 w43.Add(w44);
                 // Container child GtkHBox.Gtk.Container+ContainerChild
                 Gtk.Label w46 = new Gtk.Label();
                 w46.LabelProp = "";
                 w46.Events = ((Gdk.EventMask)(0));
                 w46.Name = "GtkLabel";
                 bindings["GtkLabel"] = w46;
                 w43.Add(w46);
                 bindings["GtkHBox"] = w43;
                 w42.Add(w43);
                 bindings["GtkAlignment"] = w42;
                 w41.Add(w42);
                 bindings["buttonNewEnterprise"] = w41;
                 w40.Add(w41);
                 Gtk.Box.BoxChild w50 = ((Gtk.Box.BoxChild)(w40[w41]));
                 w50.PackType = ((Gtk.PackType)(1));
                 w50.Position = 0;
                 w50.Expand = false;
                 w50.Fill = false;
                 // Container child hbox14.Gtk.Box+BoxChild
                 Gtk.Button w51 = new Gtk.Button();
                 w23.SetTip(w51, "Editar el Hecho", "Editar el Hecho");
                 w51.CanFocus = true;
                 w51.Events = ((Gdk.EventMask)(0));
                 w51.Name = "buttonEditEnterprise";
                 // Container child buttonEditEnterprise.Gtk.Container+ContainerChild
                 Gtk.Alignment w52 = new Gtk.Alignment(0.5F, 0.5F, 0F, 0F);
                 w52.Events = ((Gdk.EventMask)(0));
                 w52.Name = "GtkAlignment";
                 // Container child GtkAlignment.Gtk.Container+ContainerChild
                 Gtk.HBox w53 = new Gtk.HBox();
                 w53.Spacing = 2;
                 w53.Events = ((Gdk.EventMask)(0));
                 w53.Name = "GtkHBox";
                 // Container child GtkHBox.Gtk.Container+ContainerChild
                 Gtk.Image w54 = new Gtk.Image();
                 w54.Pixbuf = Gtk.IconTheme.Default.LoadIcon("gtk-edit", 16, 0);
                 w54.Events = ((Gdk.EventMask)(0));
                 w54.Name = "image3";
                 bindings["image3"] = w54;
                 w53.Add(w54);
                 // Container child GtkHBox.Gtk.Container+ContainerChild
                 Gtk.Label w56 = new Gtk.Label();
                 w56.LabelProp = "";
                 w56.Events = ((Gdk.EventMask)(0));
                 w56.Name = "GtkLabel";
                 bindings["GtkLabel"] = w56;
                 w53.Add(w56);
                 bindings["GtkHBox"] = w53;
                 w52.Add(w53);
                 bindings["GtkAlignment"] = w52;
                 w51.Add(w52);
                 bindings["buttonEditEnterprise"] = w51;
                 w40.Add(w51);
                 Gtk.Box.BoxChild w60 = ((Gtk.Box.BoxChild)(w40[w51]));
                 w60.PackType = ((Gtk.PackType)(1));
                 w60.Position = 1;
                 w60.Expand = false;
                 w60.Fill = false;
                 // Container child hbox14.Gtk.Box+BoxChild
                 Gtk.Button w61 = new Gtk.Button();
                 w23.SetTip(w61, "Quitar el Hecho", "Quitar el Hecho");
                 w61.CanFocus = true;
                 w61.Events = ((Gdk.EventMask)(0));
                 w61.Name = "buttonDelEnterprise";
                 // Container child buttonDelEnterprise.Gtk.Container+ContainerChild
                 Gtk.Alignment w62 = new Gtk.Alignment(0.5F, 0.5F, 0F, 0F);
                 w62.Events = ((Gdk.EventMask)(0));
                 w62.Name = "GtkAlignment";
                 // Container child GtkAlignment.Gtk.Container+ContainerChild
                 Gtk.HBox w63 = new Gtk.HBox();
                 w63.Spacing = 2;
                 w63.Events = ((Gdk.EventMask)(0));
                 w63.Name = "GtkHBox";
                 // Container child GtkHBox.Gtk.Container+ContainerChild
                 Gtk.Image w64 = new Gtk.Image();
                 w64.Pixbuf = Gtk.IconTheme.Default.LoadIcon("gtk-delete", 16, 0);
                 w64.Events = ((Gdk.EventMask)(0));
                 w64.Name = "image4";
                 bindings["image4"] = w64;
                 w63.Add(w64);
                 // Container child GtkHBox.Gtk.Container+ContainerChild
                 Gtk.Label w66 = new Gtk.Label();
                 w66.LabelProp = "";
                 w66.Events = ((Gdk.EventMask)(0));
                 w66.Name = "GtkLabel";
                 bindings["GtkLabel"] = w66;
                 w63.Add(w66);
                 bindings["GtkHBox"] = w63;
                 w62.Add(w63);
                 bindings["GtkAlignment"] = w62;
                 w61.Add(w62);
                 bindings["buttonDelEnterprise"] = w61;
                 w40.Add(w61);
                 Gtk.Box.BoxChild w70 = ((Gtk.Box.BoxChild)(w40[w61]));
                 w70.PackType = ((Gtk.PackType)(1));
                 w70.Position = 2;
                 w70.Expand = false;
                 w70.Fill = false;
                 bindings["hbox14"] = w40;
                 w16.Add(w40);
                 Gtk.Box.BoxChild w71 = ((Gtk.Box.BoxChild)(w16[w40]));
                 w71.Position = 2;
                 w71.Expand = false;
                 w71.Fill = false;
                 bindings["vbox2"] = w16;
                 w11.Add(w16);
                 Gtk.Box.BoxChild w72 = ((Gtk.Box.BoxChild)(w11[w16]));
                 w72.Position = 2;
                 w72.Expand = false;
                 w72.Fill = false;
                 // Container child vbox1.Gtk.Box+BoxChild
                 Gtk.HSeparator w73 = new Gtk.HSeparator();
                 w73.Events = ((Gdk.EventMask)(0));
                 w73.Name = "hseparator2";
                 bindings["hseparator2"] = w73;
                 w11.Add(w73);
                 Gtk.Box.BoxChild w74 = ((Gtk.Box.BoxChild)(w11[w73]));
                 w74.Position = 3;
                 w74.Expand = false;
                 w74.Fill = false;
                 // Container child vbox1.Gtk.Box+BoxChild
                 Gtk.HBox w75 = new Gtk.HBox();
                 w75.Homogeneous = true;
                 w75.Events = ((Gdk.EventMask)(0));
                 w75.Name = "hbox2";
                 // Container child hbox2.Gtk.Box+BoxChild
                 Gtk.VBox w76 = new Gtk.VBox();
                 w76.BorderWidth = ((uint)(5));
                 w76.Events = ((Gdk.EventMask)(0));
                 w76.Name = "vbox3";
                 // Container child vbox3.Gtk.Box+BoxChild
                 Gtk.HBox w77 = new Gtk.HBox();
                 w77.Events = ((Gdk.EventMask)(0));
                 w77.Name = "hbox3";
                 // Container child hbox3.Gtk.Box+BoxChild
                 Gtk.Label w78 = new Gtk.Label();
                 w78.LabelProp = "<b>User:</b>";
                 w78.UseMarkup = true;
                 w78.Ypad = 6;
                 w78.Events = ((Gdk.EventMask)(256));
                 w78.Name = "labelUser";
                 bindings["labelUser"] = w78;
                 w77.Add(w78);
                 Gtk.Box.BoxChild w79 = ((Gtk.Box.BoxChild)(w77[w78]));
                 w79.Position = 0;
                 w79.Expand = false;
                 w79.Fill = false;
                 // Container child hbox3.Gtk.Box+BoxChild
                 Gtk.Entry w80 = new Gtk.Entry();
                 w80.IsEditable = true;
                 w80.InvisibleChar = '●';
                 w80.CanFocus = true;
                 w80.Events = ((Gdk.EventMask)(0));
                 w80.Name = "entryUser";
                 bindings["entryUser"] = w80;
                 w77.Add(w80);
                 Gtk.Box.BoxChild w81 = ((Gtk.Box.BoxChild)(w77[w80]));
                 w81.Position = 1;
                 w81.Expand = false;
                 w81.Fill = false;
                 // Container child hbox3.Gtk.Box+BoxChild
                 Gtk.Button w82 = new Gtk.Button();
                 w23.SetTip(w82, "Añadir un Hecho", "Añadir un Hecho");
                 w82.CanFocus = true;
                 w82.Events = ((Gdk.EventMask)(0));
                 w82.Name = "buttonFindUser";
                 w82.HasDefault = true;
                 // Container child buttonFindUser.Gtk.Container+ContainerChild
                 Gtk.Alignment w83 = new Gtk.Alignment(0.5F, 0.5F, 0F, 0F);
                 w83.Events = ((Gdk.EventMask)(0));
                 w83.Name = "GtkAlignment";
                 // Container child GtkAlignment.Gtk.Container+ContainerChild
                 Gtk.HBox w84 = new Gtk.HBox();
                 w84.Spacing = 2;
                 w84.Events = ((Gdk.EventMask)(0));
                 w84.Name = "GtkHBox";
                 // Container child GtkHBox.Gtk.Container+ContainerChild
                 Gtk.Image w85 = new Gtk.Image();
                 w85.Pixbuf = Gtk.IconTheme.Default.LoadIcon("gtk-find", 16, 0);
                 w85.Events = ((Gdk.EventMask)(0));
                 w85.Name = "image5";
                 bindings["image5"] = w85;
                 w84.Add(w85);
                 // Container child GtkHBox.Gtk.Container+ContainerChild
                 Gtk.Label w87 = new Gtk.Label();
                 w87.LabelProp = "";
                 w87.Events = ((Gdk.EventMask)(0));
                 w87.Name = "GtkLabel";
                 bindings["GtkLabel"] = w87;
                 w84.Add(w87);
                 bindings["GtkHBox"] = w84;
                 w83.Add(w84);
                 bindings["GtkAlignment"] = w83;
                 w82.Add(w83);
                 bindings["buttonFindUser"] = w82;
                 w77.Add(w82);
                 Gtk.Box.BoxChild w91 = ((Gtk.Box.BoxChild)(w77[w82]));
                 w91.Position = 2;
                 w91.Expand = false;
                 w91.Fill = false;
                 bindings["hbox3"] = w77;
                 w76.Add(w77);
                 Gtk.Box.BoxChild w92 = ((Gtk.Box.BoxChild)(w76[w77]));
                 w92.Position = 0;
                 w92.Expand = false;
                 w92.Fill = false;
                 // Container child vbox3.Gtk.Box+BoxChild
                 Gtk.ScrolledWindow w93 = new Gtk.ScrolledWindow();
                 w93.VscrollbarPolicy = ((Gtk.PolicyType)(1));
                 w93.HscrollbarPolicy = ((Gtk.PolicyType)(1));
                 w93.CanFocus = true;
                 w93.Events = ((Gdk.EventMask)(0));
                 w93.Name = "scrolledwindow2";
                 // Container child scrolledwindow2.Gtk.Container+ContainerChild
                 Gtk.Viewport w94 = new Gtk.Viewport();
                 w94.ShadowType = ((Gtk.ShadowType)(0));
                 w94.Events = ((Gdk.EventMask)(0));
                 w94.Name = "GtkViewport1";
                 // Container child GtkViewport1.Gtk.Container+ContainerChild
                 Boxerp.Client.GtkSharp.Lib.FilteredListView w95 = new Boxerp.Client.GtkSharp.Lib.FilteredListView();
                 w95.Events = ((Gdk.EventMask)(256));
                 w95.Name = "ftreeviewUsers";
                 bindings["ftreeviewUsers"] = w95;
                 w94.Add(w95);
                 bindings["GtkViewport1"] = w94;
                 w93.Add(w94);
                 bindings["scrolledwindow2"] = w93;
                 w76.Add(w93);
                 Gtk.Box.BoxChild w98 = ((Gtk.Box.BoxChild)(w76[w93]));
                 w98.Position = 1;
                 // Container child vbox3.Gtk.Box+BoxChild
                 Gtk.HBox w99 = new Gtk.HBox();
                 w99.Events = ((Gdk.EventMask)(0));
                 w99.Name = "hbox15";
                 // Container child hbox15.Gtk.Box+BoxChild
                 Gtk.Button w100 = new Gtk.Button();
                 w23.SetTip(w100, "Añadir un Hecho", "Añadir un Hecho");
                 w100.CanFocus = true;
                 w100.Events = ((Gdk.EventMask)(0));
                 w100.Name = "buttonNewUser";
                 w100.HasDefault = true;
                 // Container child buttonNewUser.Gtk.Container+ContainerChild
                 Gtk.Alignment w101 = new Gtk.Alignment(0.5F, 0.5F, 0F, 0F);
                 w101.Events = ((Gdk.EventMask)(0));
                 w101.Name = "GtkAlignment";
                 // Container child GtkAlignment.Gtk.Container+ContainerChild
                 Gtk.HBox w102 = new Gtk.HBox();
                 w102.Spacing = 2;
                 w102.Events = ((Gdk.EventMask)(0));
                 w102.Name = "GtkHBox";
                 // Container child GtkHBox.Gtk.Container+ContainerChild
                 Gtk.Image w103 = new Gtk.Image();
                 w103.Pixbuf = Gtk.IconTheme.Default.LoadIcon("gtk-new", 16, 0);
                 w103.Events = ((Gdk.EventMask)(0));
                 w103.Name = "image6";
                 bindings["image6"] = w103;
                 w102.Add(w103);
                 // Container child GtkHBox.Gtk.Container+ContainerChild
                 Gtk.Label w105 = new Gtk.Label();
                 w105.LabelProp = "";
                 w105.Events = ((Gdk.EventMask)(0));
                 w105.Name = "GtkLabel";
                 bindings["GtkLabel"] = w105;
                 w102.Add(w105);
                 bindings["GtkHBox"] = w102;
                 w101.Add(w102);
                 bindings["GtkAlignment"] = w101;
                 w100.Add(w101);
                 bindings["buttonNewUser"] = w100;
                 w99.Add(w100);
                 Gtk.Box.BoxChild w109 = ((Gtk.Box.BoxChild)(w99[w100]));
                 w109.PackType = ((Gtk.PackType)(1));
                 w109.Position = 0;
                 w109.Expand = false;
                 w109.Fill = false;
                 // Container child hbox15.Gtk.Box+BoxChild
                 Gtk.Button w110 = new Gtk.Button();
                 w23.SetTip(w110, "Editar el Hecho", "Editar el Hecho");
                 w110.CanFocus = true;
                 w110.Events = ((Gdk.EventMask)(0));
                 w110.Name = "buttonEditUser";
                 // Container child buttonEditUser.Gtk.Container+ContainerChild
                 Gtk.Alignment w111 = new Gtk.Alignment(0.5F, 0.5F, 0F, 0F);
                 w111.Events = ((Gdk.EventMask)(0));
                 w111.Name = "GtkAlignment";
                 // Container child GtkAlignment.Gtk.Container+ContainerChild
                 Gtk.HBox w112 = new Gtk.HBox();
                 w112.Spacing = 2;
                 w112.Events = ((Gdk.EventMask)(0));
                 w112.Name = "GtkHBox";
                 // Container child GtkHBox.Gtk.Container+ContainerChild
                 Gtk.Image w113 = new Gtk.Image();
                 w113.Pixbuf = Gtk.IconTheme.Default.LoadIcon("gtk-edit", 16, 0);
                 w113.Events = ((Gdk.EventMask)(0));
                 w113.Name = "image7";
                 bindings["image7"] = w113;
                 w112.Add(w113);
                 // Container child GtkHBox.Gtk.Container+ContainerChild
                 Gtk.Label w115 = new Gtk.Label();
                 w115.LabelProp = "";
                 w115.Events = ((Gdk.EventMask)(0));
                 w115.Name = "GtkLabel";
                 bindings["GtkLabel"] = w115;
                 w112.Add(w115);
                 bindings["GtkHBox"] = w112;
                 w111.Add(w112);
                 bindings["GtkAlignment"] = w111;
                 w110.Add(w111);
                 bindings["buttonEditUser"] = w110;
                 w99.Add(w110);
                 Gtk.Box.BoxChild w119 = ((Gtk.Box.BoxChild)(w99[w110]));
                 w119.PackType = ((Gtk.PackType)(1));
                 w119.Position = 1;
                 w119.Expand = false;
                 w119.Fill = false;
                 // Container child hbox15.Gtk.Box+BoxChild
                 Gtk.Button w120 = new Gtk.Button();
                 w23.SetTip(w120, "Quitar el Hecho", "Quitar el Hecho");
                 w120.CanFocus = true;
                 w120.Events = ((Gdk.EventMask)(0));
                 w120.Name = "buttonDelUser";
                 // Container child buttonDelUser.Gtk.Container+ContainerChild
                 Gtk.Alignment w121 = new Gtk.Alignment(0.5F, 0.5F, 0F, 0F);
                 w121.Events = ((Gdk.EventMask)(0));
                 w121.Name = "GtkAlignment";
                 // Container child GtkAlignment.Gtk.Container+ContainerChild
                 Gtk.HBox w122 = new Gtk.HBox();
                 w122.Spacing = 2;
                 w122.Events = ((Gdk.EventMask)(0));
                 w122.Name = "GtkHBox";
                 // Container child GtkHBox.Gtk.Container+ContainerChild
                 Gtk.Image w123 = new Gtk.Image();
                 w123.Pixbuf = Gtk.IconTheme.Default.LoadIcon("gtk-delete", 16, 0);
                 w123.Events = ((Gdk.EventMask)(0));
                 w123.Name = "image8";
                 bindings["image8"] = w123;
                 w122.Add(w123);
                 // Container child GtkHBox.Gtk.Container+ContainerChild
                 Gtk.Label w125 = new Gtk.Label();
                 w125.LabelProp = "";
                 w125.Events = ((Gdk.EventMask)(0));
                 w125.Name = "GtkLabel";
                 bindings["GtkLabel"] = w125;
                 w122.Add(w125);
                 bindings["GtkHBox"] = w122;
                 w121.Add(w122);
                 bindings["GtkAlignment"] = w121;
                 w120.Add(w121);
                 bindings["buttonDelUser"] = w120;
                 w99.Add(w120);
                 Gtk.Box.BoxChild w129 = ((Gtk.Box.BoxChild)(w99[w120]));
                 w129.PackType = ((Gtk.PackType)(1));
                 w129.Position = 2;
                 w129.Expand = false;
                 w129.Fill = false;
                 bindings["hbox15"] = w99;
                 w76.Add(w99);
                 Gtk.Box.BoxChild w130 = ((Gtk.Box.BoxChild)(w76[w99]));
                 w130.Position = 2;
                 w130.Expand = false;
                 w130.Fill = false;
                 bindings["vbox3"] = w76;
                 w75.Add(w76);
                 Gtk.Box.BoxChild w131 = ((Gtk.Box.BoxChild)(w75[w76]));
                 w131.Position = 0;
                 // Container child hbox2.Gtk.Box+BoxChild
                 Gtk.VBox w132 = new Gtk.VBox();
                 w132.BorderWidth = ((uint)(5));
                 w132.Events = ((Gdk.EventMask)(0));
                 w132.Name = "vbox4";
                 // Container child vbox4.Gtk.Box+BoxChild
                 Gtk.HBox w133 = new Gtk.HBox();
                 w133.Events = ((Gdk.EventMask)(0));
                 w133.Name = "hbox4";
                 // Container child hbox4.Gtk.Box+BoxChild
                 Gtk.Label w134 = new Gtk.Label();
                 w134.LabelProp = "<b>Group:</b>";
                 w134.UseMarkup = true;
                 w134.Ypad = 6;
                 w134.Events = ((Gdk.EventMask)(256));
                 w134.Name = "labelGroup";
                 bindings["labelGroup"] = w134;
                 w133.Add(w134);
                 Gtk.Box.BoxChild w135 = ((Gtk.Box.BoxChild)(w133[w134]));
                 w135.Position = 0;
                 w135.Expand = false;
                 w135.Fill = false;
                 // Container child hbox4.Gtk.Box+BoxChild
                 Gtk.Entry w136 = new Gtk.Entry();
                 w136.IsEditable = true;
                 w136.InvisibleChar = '●';
                 w136.CanFocus = true;
                 w136.Events = ((Gdk.EventMask)(0));
                 w136.Name = "entryGroup";
                 bindings["entryGroup"] = w136;
                 w133.Add(w136);
                 Gtk.Box.BoxChild w137 = ((Gtk.Box.BoxChild)(w133[w136]));
                 w137.Position = 1;
                 w137.Expand = false;
                 w137.Fill = false;
                 // Container child hbox4.Gtk.Box+BoxChild
                 Gtk.Button w138 = new Gtk.Button();
                 w23.SetTip(w138, "Añadir un Hecho", "Añadir un Hecho");
                 w138.CanFocus = true;
                 w138.Events = ((Gdk.EventMask)(0));
                 w138.Name = "buttonFindGroup";
                 w138.HasDefault = true;
                 // Container child buttonFindGroup.Gtk.Container+ContainerChild
                 Gtk.Alignment w139 = new Gtk.Alignment(0.5F, 0.5F, 0F, 0F);
                 w139.Events = ((Gdk.EventMask)(0));
                 w139.Name = "GtkAlignment";
                 // Container child GtkAlignment.Gtk.Container+ContainerChild
                 Gtk.HBox w140 = new Gtk.HBox();
                 w140.Spacing = 2;
                 w140.Events = ((Gdk.EventMask)(0));
                 w140.Name = "GtkHBox";
                 // Container child GtkHBox.Gtk.Container+ContainerChild
                 Gtk.Image w141 = new Gtk.Image();
                 w141.Pixbuf = Gtk.IconTheme.Default.LoadIcon("gtk-find", 16, 0);
                 w141.Events = ((Gdk.EventMask)(0));
                 w141.Name = "image9";
                 bindings["image9"] = w141;
                 w140.Add(w141);
                 // Container child GtkHBox.Gtk.Container+ContainerChild
                 Gtk.Label w143 = new Gtk.Label();
                 w143.LabelProp = "";
                 w143.Events = ((Gdk.EventMask)(0));
                 w143.Name = "GtkLabel";
                 bindings["GtkLabel"] = w143;
                 w140.Add(w143);
                 bindings["GtkHBox"] = w140;
                 w139.Add(w140);
                 bindings["GtkAlignment"] = w139;
                 w138.Add(w139);
                 bindings["buttonFindGroup"] = w138;
                 w133.Add(w138);
                 Gtk.Box.BoxChild w147 = ((Gtk.Box.BoxChild)(w133[w138]));
                 w147.Position = 2;
                 w147.Expand = false;
                 w147.Fill = false;
                 bindings["hbox4"] = w133;
                 w132.Add(w133);
                 Gtk.Box.BoxChild w148 = ((Gtk.Box.BoxChild)(w132[w133]));
                 w148.Position = 0;
                 w148.Expand = false;
                 w148.Fill = false;
                 // Container child vbox4.Gtk.Box+BoxChild
                 Gtk.ScrolledWindow w149 = new Gtk.ScrolledWindow();
                 w149.VscrollbarPolicy = ((Gtk.PolicyType)(1));
                 w149.HscrollbarPolicy = ((Gtk.PolicyType)(1));
                 w149.CanFocus = true;
                 w149.Events = ((Gdk.EventMask)(0));
                 w149.Name = "scrolledwindow3";
                 // Container child scrolledwindow3.Gtk.Container+ContainerChild
                 Gtk.Viewport w150 = new Gtk.Viewport();
                 w150.ShadowType = ((Gtk.ShadowType)(0));
                 w150.Events = ((Gdk.EventMask)(0));
                 w150.Name = "GtkViewport2";
                 // Container child GtkViewport2.Gtk.Container+ContainerChild
                 Boxerp.Client.GtkSharp.Lib.FilteredListView w151 = new Boxerp.Client.GtkSharp.Lib.FilteredListView();
                 w151.Events = ((Gdk.EventMask)(256));
                 w151.Name = "ftreeviewGroups";
                 bindings["ftreeviewGroups"] = w151;
                 w150.Add(w151);
                 bindings["GtkViewport2"] = w150;
                 w149.Add(w150);
                 bindings["scrolledwindow3"] = w149;
                 w132.Add(w149);
                 Gtk.Box.BoxChild w154 = ((Gtk.Box.BoxChild)(w132[w149]));
                 w154.Position = 1;
                 // Container child vbox4.Gtk.Box+BoxChild
                 Gtk.HBox w155 = new Gtk.HBox();
                 w155.Events = ((Gdk.EventMask)(0));
                 w155.Name = "hbox16";
                 // Container child hbox16.Gtk.Box+BoxChild
                 Gtk.Button w156 = new Gtk.Button();
                 w23.SetTip(w156, "Añadir un Hecho", "Añadir un Hecho");
                 w156.CanFocus = true;
                 w156.Events = ((Gdk.EventMask)(0));
                 w156.Name = "buttonNewGroup";
                 w156.HasDefault = true;
                 // Container child buttonNewGroup.Gtk.Container+ContainerChild
                 Gtk.Alignment w157 = new Gtk.Alignment(0.5F, 0.5F, 0F, 0F);
                 w157.Events = ((Gdk.EventMask)(0));
                 w157.Name = "GtkAlignment";
                 // Container child GtkAlignment.Gtk.Container+ContainerChild
                 Gtk.HBox w158 = new Gtk.HBox();
                 w158.Spacing = 2;
                 w158.Events = ((Gdk.EventMask)(0));
                 w158.Name = "GtkHBox";
                 // Container child GtkHBox.Gtk.Container+ContainerChild
                 Gtk.Image w159 = new Gtk.Image();
                 w159.Pixbuf = Gtk.IconTheme.Default.LoadIcon("gtk-new", 16, 0);
                 w159.Events = ((Gdk.EventMask)(0));
                 w159.Name = "image10";
                 bindings["image10"] = w159;
                 w158.Add(w159);
                 // Container child GtkHBox.Gtk.Container+ContainerChild
                 Gtk.Label w161 = new Gtk.Label();
                 w161.LabelProp = "";
                 w161.Events = ((Gdk.EventMask)(0));
                 w161.Name = "GtkLabel";
                 bindings["GtkLabel"] = w161;
                 w158.Add(w161);
                 bindings["GtkHBox"] = w158;
                 w157.Add(w158);
                 bindings["GtkAlignment"] = w157;
                 w156.Add(w157);
                 bindings["buttonNewGroup"] = w156;
                 w155.Add(w156);
                 Gtk.Box.BoxChild w165 = ((Gtk.Box.BoxChild)(w155[w156]));
                 w165.PackType = ((Gtk.PackType)(1));
                 w165.Position = 0;
                 w165.Expand = false;
                 w165.Fill = false;
                 // Container child hbox16.Gtk.Box+BoxChild
                 Gtk.Button w166 = new Gtk.Button();
                 w23.SetTip(w166, "Editar el Hecho", "Editar el Hecho");
                 w166.CanFocus = true;
                 w166.Events = ((Gdk.EventMask)(0));
                 w166.Name = "buttonEditGroup";
                 // Container child buttonEditGroup.Gtk.Container+ContainerChild
                 Gtk.Alignment w167 = new Gtk.Alignment(0.5F, 0.5F, 0F, 0F);
                 w167.Events = ((Gdk.EventMask)(0));
                 w167.Name = "GtkAlignment";
                 // Container child GtkAlignment.Gtk.Container+ContainerChild
                 Gtk.HBox w168 = new Gtk.HBox();
                 w168.Spacing = 2;
                 w168.Events = ((Gdk.EventMask)(0));
                 w168.Name = "GtkHBox";
                 // Container child GtkHBox.Gtk.Container+ContainerChild
                 Gtk.Image w169 = new Gtk.Image();
                 w169.Pixbuf = Gtk.IconTheme.Default.LoadIcon("gtk-edit", 16, 0);
                 w169.Events = ((Gdk.EventMask)(0));
                 w169.Name = "image11";
                 bindings["image11"] = w169;
                 w168.Add(w169);
                 // Container child GtkHBox.Gtk.Container+ContainerChild
                 Gtk.Label w171 = new Gtk.Label();
                 w171.LabelProp = "";
                 w171.Events = ((Gdk.EventMask)(0));
                 w171.Name = "GtkLabel";
                 bindings["GtkLabel"] = w171;
                 w168.Add(w171);
                 bindings["GtkHBox"] = w168;
                 w167.Add(w168);
                 bindings["GtkAlignment"] = w167;
                 w166.Add(w167);
                 bindings["buttonEditGroup"] = w166;
                 w155.Add(w166);
                 Gtk.Box.BoxChild w175 = ((Gtk.Box.BoxChild)(w155[w166]));
                 w175.PackType = ((Gtk.PackType)(1));
                 w175.Position = 1;
                 w175.Expand = false;
                 w175.Fill = false;
                 // Container child hbox16.Gtk.Box+BoxChild
                 Gtk.Button w176 = new Gtk.Button();
                 w23.SetTip(w176, "Quitar el Hecho", "Quitar el Hecho");
                 w176.CanFocus = true;
                 w176.Events = ((Gdk.EventMask)(0));
                 w176.Name = "buttonDelGroup";
                 // Container child buttonDelGroup.Gtk.Container+ContainerChild
                 Gtk.Alignment w177 = new Gtk.Alignment(0.5F, 0.5F, 0F, 0F);
                 w177.Events = ((Gdk.EventMask)(0));
                 w177.Name = "GtkAlignment";
                 // Container child GtkAlignment.Gtk.Container+ContainerChild
                 Gtk.HBox w178 = new Gtk.HBox();
                 w178.Spacing = 2;
                 w178.Events = ((Gdk.EventMask)(0));
                 w178.Name = "GtkHBox";
                 // Container child GtkHBox.Gtk.Container+ContainerChild
                 Gtk.Image w179 = new Gtk.Image();
                 w179.Pixbuf = Gtk.IconTheme.Default.LoadIcon("gtk-delete", 16, 0);
                 w179.Events = ((Gdk.EventMask)(0));
                 w179.Name = "image12";
                 bindings["image12"] = w179;
                 w178.Add(w179);
                 // Container child GtkHBox.Gtk.Container+ContainerChild
                 Gtk.Label w181 = new Gtk.Label();
                 w181.LabelProp = "";
                 w181.Events = ((Gdk.EventMask)(0));
                 w181.Name = "GtkLabel";
                 bindings["GtkLabel"] = w181;
                 w178.Add(w181);
                 bindings["GtkHBox"] = w178;
                 w177.Add(w178);
                 bindings["GtkAlignment"] = w177;
                 w176.Add(w177);
                 bindings["buttonDelGroup"] = w176;
                 w155.Add(w176);
                 Gtk.Box.BoxChild w185 = ((Gtk.Box.BoxChild)(w155[w176]));
                 w185.PackType = ((Gtk.PackType)(1));
                 w185.Position = 2;
                 w185.Expand = false;
                 w185.Fill = false;
                 bindings["hbox16"] = w155;
                 w132.Add(w155);
                 Gtk.Box.BoxChild w186 = ((Gtk.Box.BoxChild)(w132[w155]));
                 w186.Position = 2;
                 w186.Expand = false;
                 w186.Fill = false;
                 bindings["vbox4"] = w132;
                 w75.Add(w132);
                 Gtk.Box.BoxChild w187 = ((Gtk.Box.BoxChild)(w75[w132]));
                 w187.Position = 1;
                 bindings["hbox2"] = w75;
                 w11.Add(w75);
                 Gtk.Box.BoxChild w188 = ((Gtk.Box.BoxChild)(w11[w75]));
                 w188.Position = 4;
                 // Container child vbox1.Gtk.Box+BoxChild
                 Gtk.HSeparator w189 = new Gtk.HSeparator();
                 w189.Events = ((Gdk.EventMask)(0));
                 w189.Name = "hseparator1";
                 bindings["hseparator1"] = w189;
                 w11.Add(w189);
                 Gtk.Box.BoxChild w190 = ((Gtk.Box.BoxChild)(w11[w189]));
                 w190.Position = 6;
                 w190.Expand = false;
                 w190.Fill = false;
                 // Container child vbox1.Gtk.Box+BoxChild
                 Gtk.Statusbar w191 = new Gtk.Statusbar();
                 w191.Events = ((Gdk.EventMask)(0));
                 w191.Name = "statusbar1";
                 bindings["statusbar1"] = w191;
                 w11.Add(w191);
                 Gtk.Box.BoxChild w192 = ((Gtk.Box.BoxChild)(w11[w191]));
                 w192.Position = 7;
                 w192.Expand = false;
                 w192.Fill = false;
                 bindings["vbox1"] = w11;
                 cobj.Add(w11);
                 bindings["administrator.MainWindow"] = cobj;
                 w12.Show();
                 w14.Show();
                 w18.Show();
                 w20.Show();
                 w26.Show();
                 w28.Show();
                 w25.Show();
                 w24.Show();
                 w22.Show();
                 w17.Show();
                 w36.Show();
                 w35.Show();
                 w34.Show();
                 w44.Show();
                 w46.Show();
                 w43.Show();
                 w42.Show();
                 w41.Show();
                 w54.Show();
                 w56.Show();
                 w53.Show();
                 w52.Show();
                 w51.Show();
                 w64.Show();
                 w66.Show();
                 w63.Show();
                 w62.Show();
                 w61.Show();
                 w40.Show();
                 w16.Show();
                 w73.Show();
                 w78.Show();
                 w80.Show();
                 w85.Show();
                 w87.Show();
                 w84.Show();
                 w83.Show();
                 w82.Show();
                 w77.Show();
                 w95.Show();
                 w94.Show();
                 w93.Show();
                 w103.Show();
                 w105.Show();
                 w102.Show();
                 w101.Show();
                 w100.Show();
                 w113.Show();
                 w115.Show();
                 w112.Show();
                 w111.Show();
                 w110.Show();
                 w123.Show();
                 w125.Show();
                 w122.Show();
                 w121.Show();
                 w120.Show();
                 w99.Show();
                 w76.Show();
                 w134.Show();
                 w136.Show();
                 w141.Show();
                 w143.Show();
                 w140.Show();
                 w139.Show();
                 w138.Show();
                 w133.Show();
                 w151.Show();
                 w150.Show();
                 w149.Show();
                 w159.Show();
                 w161.Show();
                 w158.Show();
                 w157.Show();
                 w156.Show();
                 w169.Show();
                 w171.Show();
                 w168.Show();
                 w167.Show();
                 w166.Show();
                 w179.Show();
                 w181.Show();
                 w178.Show();
                 w177.Show();
                 w176.Show();
                 w155.Show();
                 w132.Show();
                 w75.Show();
                 w189.Show();
                 w191.Show();
                 w11.Show();
                 cobj.Show();
                 cobj.DeleteEvent += ((Gtk.DeleteEventHandler)(System.Delegate.CreateDelegate(typeof(Gtk.DeleteEventHandler), cobj, "OnDeleteEvent")));
                 w20.Activated += ((System.EventHandler)(System.Delegate.CreateDelegate(typeof(System.EventHandler), cobj, "OnFindEnterprise")));
                 w22.Clicked += ((System.EventHandler)(System.Delegate.CreateDelegate(typeof(System.EventHandler), cobj, "OnFindEnterprise")));
                 w61.Clicked += ((System.EventHandler)(System.Delegate.CreateDelegate(typeof(System.EventHandler), cobj, "OnDelEnterpriseClicked")));
                 w51.Clicked += ((System.EventHandler)(System.Delegate.CreateDelegate(typeof(System.EventHandler), cobj, "OnEditEnterpriseClicked")));
                 w41.Clicked += ((System.EventHandler)(System.Delegate.CreateDelegate(typeof(System.EventHandler), cobj, "OnNewEnterpriseClicked")));
                 w80.Activated += ((System.EventHandler)(System.Delegate.CreateDelegate(typeof(System.EventHandler), cobj, "OnFindUser")));
                 w82.Clicked += ((System.EventHandler)(System.Delegate.CreateDelegate(typeof(System.EventHandler), cobj, "OnFindUser")));
                 w120.Clicked += ((System.EventHandler)(System.Delegate.CreateDelegate(typeof(System.EventHandler), cobj, "OnDelUserClicked")));
                 w110.Clicked += ((System.EventHandler)(System.Delegate.CreateDelegate(typeof(System.EventHandler), cobj, "OnEditUserClicked")));
                 w100.Clicked += ((System.EventHandler)(System.Delegate.CreateDelegate(typeof(System.EventHandler), cobj, "OnNewUserClicked")));
                 w136.Activated += ((System.EventHandler)(System.Delegate.CreateDelegate(typeof(System.EventHandler), cobj, "OnFindGroup")));
                 w138.Clicked += ((System.EventHandler)(System.Delegate.CreateDelegate(typeof(System.EventHandler), cobj, "OnFindGroup")));
                 w176.Clicked += ((System.EventHandler)(System.Delegate.CreateDelegate(typeof(System.EventHandler), cobj, "OnDelGroupClicked")));
                 w166.Clicked += ((System.EventHandler)(System.Delegate.CreateDelegate(typeof(System.EventHandler), cobj, "OnEditGroupClicked")));
                 w156.Clicked += ((System.EventHandler)(System.Delegate.CreateDelegate(typeof(System.EventHandler), cobj, "OnNewGroupClicked")));
             }
             else {
                 if ((id == "administrator.EditUserWindow")) {
                     Gtk.Window cobj = ((Gtk.Window)(obj));
                     // Widget administrator.EditUserWindow
                     cobj.Title = "User";
                     cobj.WindowPosition = ((Gtk.WindowPosition)(4));
                     cobj.Events = ((Gdk.EventMask)(0));
                     cobj.Name = "administrator.EditUserWindow";
                     // Container child administrator.EditUserWindow.Gtk.Container+ContainerChild
                     Gtk.VBox w1 = new Gtk.VBox();
                     w1.Events = ((Gdk.EventMask)(0));
                     w1.Name = "vbox1";
                     // Container child vbox1.Gtk.Box+BoxChild
                     Gtk.Notebook w2 = new Gtk.Notebook();
                     w2.CanFocus = true;
                     w2.Events = ((Gdk.EventMask)(0));
                     w2.Name = "notebook1";
                     // Container child notebook1.Gtk.Notebook+NotebookChild
                     Gtk.VBox w3 = new Gtk.VBox();
                     w3.Events = ((Gdk.EventMask)(0));
                     w3.Name = "vbox2";
                     // Container child vbox2.Gtk.Box+BoxChild
                     Gtk.Table w4 = new Gtk.Table(((uint)(5)), ((uint)(2)), false);
                     w4.RowSpacing = ((uint)(1));
                     w4.ColumnSpacing = ((uint)(5));
                     w4.BorderWidth = ((uint)(5));
                     w4.Events = ((Gdk.EventMask)(0));
                     w4.Name = "table1";
                     // Container child table1.Gtk.Table+TableChild
                     Gtk.CheckButton w5 = new Gtk.CheckButton();
                     w5.Label = "";
                     w5.DrawIndicator = true;
                     w5.CanFocus = true;
                     w5.Events = ((Gdk.EventMask)(0));
                     w5.Name = "checkActive";
                     bindings["checkActive"] = w5;
                     w4.Add(w5);
                     Gtk.Table.TableChild w6 = ((Gtk.Table.TableChild)(w4[w5]));
                     w6.BottomAttach = ((uint)(5));
                     w6.LeftAttach = ((uint)(1));
                     w6.RightAttach = ((uint)(2));
                     w6.TopAttach = ((uint)(4));
                     w6.YOptions = ((Gtk.AttachOptions)(4));
                     // Container child table1.Gtk.Table+TableChild
                     Gtk.Label w7 = new Gtk.Label();
                     w7.LabelProp = "Active:";
                     w7.Events = ((Gdk.EventMask)(0));
                     w7.Name = "label4";
                     bindings["label4"] = w7;
                     w4.Add(w7);
                     Gtk.Table.TableChild w8 = ((Gtk.Table.TableChild)(w4[w7]));
                     w8.BottomAttach = ((uint)(5));
                     w8.TopAttach = ((uint)(4));
                     w8.YOptions = ((Gtk.AttachOptions)(4));
                     w8.XOptions = ((Gtk.AttachOptions)(4));
                     // Container child table1.Gtk.Table+TableChild
                     Gtk.Entry w9 = new Gtk.Entry();
                     w9.IsEditable = true;
                     w9.Visibility = false;
                     w9.InvisibleChar = '●';
                     w9.CanFocus = true;
                     w9.Events = ((Gdk.EventMask)(0));
                     w9.Name = "entryPassword";
                     bindings["entryPassword"] = w9;
                     w4.Add(w9);
                     Gtk.Table.TableChild w10 = ((Gtk.Table.TableChild)(w4[w9]));
                     w10.BottomAttach = ((uint)(4));
                     w10.LeftAttach = ((uint)(1));
                     w10.RightAttach = ((uint)(2));
                     w10.TopAttach = ((uint)(3));
                     w10.YOptions = ((Gtk.AttachOptions)(4));
                     // Container child table1.Gtk.Table+TableChild
                     Gtk.Entry w11 = new Gtk.Entry();
                     w11.IsEditable = true;
                     w11.InvisibleChar = '●';
                     w11.CanFocus = true;
                     w11.Events = ((Gdk.EventMask)(0));
                     w11.Name = "entryEmail";
                     bindings["entryEmail"] = w11;
                     w4.Add(w11);
                     Gtk.Table.TableChild w12 = ((Gtk.Table.TableChild)(w4[w11]));
                     w12.BottomAttach = ((uint)(3));
                     w12.LeftAttach = ((uint)(1));
                     w12.RightAttach = ((uint)(2));
                     w12.TopAttach = ((uint)(2));
                     w12.YOptions = ((Gtk.AttachOptions)(4));
                     // Container child table1.Gtk.Table+TableChild
                     Gtk.Entry w13 = new Gtk.Entry();
                     w13.IsEditable = true;
                     w13.InvisibleChar = '●';
                     w13.CanFocus = true;
                     w13.Events = ((Gdk.EventMask)(0));
                     w13.Name = "entryRealName";
                     bindings["entryRealName"] = w13;
                     w4.Add(w13);
                     Gtk.Table.TableChild w14 = ((Gtk.Table.TableChild)(w4[w13]));
                     w14.BottomAttach = ((uint)(2));
                     w14.LeftAttach = ((uint)(1));
                     w14.RightAttach = ((uint)(2));
                     w14.TopAttach = ((uint)(1));
                     w14.YOptions = ((Gtk.AttachOptions)(4));
                     // Container child table1.Gtk.Table+TableChild
                     Gtk.Label w15 = new Gtk.Label();
                     w15.LabelProp = "Password:"******"label14";
                     bindings["label14"] = w15;
                     w4.Add(w15);
                     Gtk.Table.TableChild w16 = ((Gtk.Table.TableChild)(w4[w15]));
                     w16.BottomAttach = ((uint)(4));
                     w16.TopAttach = ((uint)(3));
                     w16.YOptions = ((Gtk.AttachOptions)(4));
                     w16.XOptions = ((Gtk.AttachOptions)(4));
                     // Container child table1.Gtk.Table+TableChild
                     Gtk.Label w17 = new Gtk.Label();
                     w17.LabelProp = "Email:";
                     w17.Events = ((Gdk.EventMask)(0));
                     w17.Name = "label13";
                     bindings["label13"] = w17;
                     w4.Add(w17);
                     Gtk.Table.TableChild w18 = ((Gtk.Table.TableChild)(w4[w17]));
                     w18.BottomAttach = ((uint)(3));
                     w18.TopAttach = ((uint)(2));
                     w18.YOptions = ((Gtk.AttachOptions)(4));
                     w18.XOptions = ((Gtk.AttachOptions)(4));
                     // Container child table1.Gtk.Table+TableChild
                     Gtk.Label w19 = new Gtk.Label();
                     w19.LabelProp = "Real Name:";
                     w19.Events = ((Gdk.EventMask)(0));
                     w19.Name = "label12";
                     bindings["label12"] = w19;
                     w4.Add(w19);
                     Gtk.Table.TableChild w20 = ((Gtk.Table.TableChild)(w4[w19]));
                     w20.BottomAttach = ((uint)(2));
                     w20.TopAttach = ((uint)(1));
                     w20.YOptions = ((Gtk.AttachOptions)(4));
                     w20.XOptions = ((Gtk.AttachOptions)(4));
                     // Container child table1.Gtk.Table+TableChild
                     Gtk.Label w21 = new Gtk.Label();
                     w21.LabelProp = "User Name:";
                     w21.Events = ((Gdk.EventMask)(0));
                     w21.Name = "label10";
                     bindings["label10"] = w21;
                     w4.Add(w21);
                     Gtk.Table.TableChild w22 = ((Gtk.Table.TableChild)(w4[w21]));
                     w22.YOptions = ((Gtk.AttachOptions)(4));
                     w22.XOptions = ((Gtk.AttachOptions)(4));
                     // Container child table1.Gtk.Table+TableChild
                     Gtk.Entry w23 = new Gtk.Entry();
                     w23.IsEditable = true;
                     w23.InvisibleChar = '●';
                     w23.CanFocus = true;
                     w23.Events = ((Gdk.EventMask)(0));
                     w23.Name = "entryUserName";
                     bindings["entryUserName"] = w23;
                     w4.Add(w23);
                     Gtk.Table.TableChild w24 = ((Gtk.Table.TableChild)(w4[w23]));
                     w24.LeftAttach = ((uint)(1));
                     w24.RightAttach = ((uint)(2));
                     w24.YOptions = ((Gtk.AttachOptions)(4));
                     bindings["table1"] = w4;
                     w3.Add(w4);
                     Gtk.Box.BoxChild w25 = ((Gtk.Box.BoxChild)(w3[w4]));
                     w25.Position = 0;
                     w25.Expand = false;
                     w25.Fill = false;
                     // Container child vbox2.Gtk.Box+BoxChild
                     Boxerp.Client.GtkSharp.Lib.DoubleListView w26 = new Boxerp.Client.GtkSharp.Lib.DoubleListView();
                     w26.Events = ((Gdk.EventMask)(256));
                     w26.Name = "dtreeview";
                     bindings["dtreeview"] = w26;
                     w3.Add(w26);
                     Gtk.Box.BoxChild w27 = ((Gtk.Box.BoxChild)(w3[w26]));
                     w27.Position = 1;
                     bindings["vbox2"] = w3;
                     w2.Add(w3);
                     Gtk.Notebook.NotebookChild w28 = ((Gtk.Notebook.NotebookChild)(w2[w3]));
                     w28.TabExpand = false;
                     // Notebook tab
                     Gtk.Label w29 = new Gtk.Label();
                     w29.LabelProp = "Properties";
                     w29.Events = ((Gdk.EventMask)(0));
                     w29.Name = "label1";
                     bindings["label1"] = w29;
                     w2.SetTabLabel(w3, w29);
                     // Container child notebook1.Gtk.Notebook+NotebookChild
                     Gtk.VBox w30 = new Gtk.VBox();
                     w30.Events = ((Gdk.EventMask)(0));
                     w30.Name = "vbox3";
                     bindings["vbox3"] = w30;
                     w2.Add(w30);
                     Gtk.Notebook.NotebookChild w31 = ((Gtk.Notebook.NotebookChild)(w2[w30]));
                     w31.Position = 1;
                     w31.TabExpand = false;
                     // Notebook tab
                     Gtk.Label w32 = new Gtk.Label();
                     w32.LabelProp = "Permissions";
                     w32.Events = ((Gdk.EventMask)(0));
                     w32.Name = "label1";
                     bindings["label1"] = w32;
                     w2.SetTabLabel(w30, w32);
                     bindings["notebook1"] = w2;
                     w1.Add(w2);
                     Gtk.Box.BoxChild w33 = ((Gtk.Box.BoxChild)(w1[w2]));
                     w33.Position = 0;
                     w33.Padding = ((uint)(5));
                     // Container child vbox1.Gtk.Box+BoxChild
                     Gtk.HButtonBox w34 = new Gtk.HButtonBox();
                     w34.LayoutStyle = ((Gtk.ButtonBoxStyle)(4));
                     w34.Spacing = 2;
                     w34.BorderWidth = ((uint)(5));
                     w34.Events = ((Gdk.EventMask)(0));
                     w34.Name = "hbuttonbox1";
                     // Container child hbuttonbox1.Gtk.ButtonBox+ButtonBoxChild
                     Gtk.Button w35 = new Gtk.Button();
                     w35.CanFocus = true;
                     w35.Events = ((Gdk.EventMask)(0));
                     w35.Name = "buttonCancel";
                     // Container child buttonCancel.Gtk.Container+ContainerChild
                     Gtk.Alignment w36 = new Gtk.Alignment(0.5F, 0.5F, 0F, 0F);
                     w36.Events = ((Gdk.EventMask)(0));
                     w36.Name = "GtkAlignment";
                     // Container child GtkAlignment.Gtk.Container+ContainerChild
                     Gtk.HBox w37 = new Gtk.HBox();
                     w37.Spacing = 2;
                     w37.Events = ((Gdk.EventMask)(0));
                     w37.Name = "GtkHBox";
                     // Container child GtkHBox.Gtk.Container+ContainerChild
                     Gtk.Image w38 = new Gtk.Image();
                     w38.Pixbuf = Gtk.IconTheme.Default.LoadIcon("gtk-cancel", 16, 0);
                     w38.Events = ((Gdk.EventMask)(0));
                     w38.Name = "image13";
                     bindings["image13"] = w38;
                     w37.Add(w38);
                     // Container child GtkHBox.Gtk.Container+ContainerChild
                     Gtk.Label w40 = new Gtk.Label();
                     w40.LabelProp = "Cancel";
                     w40.Events = ((Gdk.EventMask)(0));
                     w40.Name = "GtkLabel";
                     bindings["GtkLabel"] = w40;
                     w37.Add(w40);
                     bindings["GtkHBox"] = w37;
                     w36.Add(w37);
                     bindings["GtkAlignment"] = w36;
                     w35.Add(w36);
                     bindings["buttonCancel"] = w35;
                     w34.Add(w35);
                     Gtk.ButtonBox.ButtonBoxChild w44 = ((Gtk.ButtonBox.ButtonBoxChild)(w34[w35]));
                     w44.Expand = false;
                     w44.Fill = false;
                     // Container child hbuttonbox1.Gtk.ButtonBox+ButtonBoxChild
                     Gtk.Button w45 = new Gtk.Button();
                     w45.CanFocus = true;
                     w45.Events = ((Gdk.EventMask)(0));
                     w45.Name = "buttonOk";
                     // Container child buttonOk.Gtk.Container+ContainerChild
                     Gtk.Alignment w46 = new Gtk.Alignment(0.5F, 0.5F, 0F, 0F);
                     w46.Events = ((Gdk.EventMask)(0));
                     w46.Name = "GtkAlignment";
                     // Container child GtkAlignment.Gtk.Container+ContainerChild
                     Gtk.HBox w47 = new Gtk.HBox();
                     w47.Spacing = 2;
                     w47.Events = ((Gdk.EventMask)(0));
                     w47.Name = "GtkHBox";
                     // Container child GtkHBox.Gtk.Container+ContainerChild
                     Gtk.Image w48 = new Gtk.Image();
                     w48.Pixbuf = Gtk.IconTheme.Default.LoadIcon("gtk-ok", 16, 0);
                     w48.Events = ((Gdk.EventMask)(0));
                     w48.Name = "image14";
                     bindings["image14"] = w48;
                     w47.Add(w48);
                     // Container child GtkHBox.Gtk.Container+ContainerChild
                     Gtk.Label w50 = new Gtk.Label();
                     w50.LabelProp = "Ok";
                     w50.Events = ((Gdk.EventMask)(0));
                     w50.Name = "GtkLabel";
                     bindings["GtkLabel"] = w50;
                     w47.Add(w50);
                     bindings["GtkHBox"] = w47;
                     w46.Add(w47);
                     bindings["GtkAlignment"] = w46;
                     w45.Add(w46);
                     bindings["buttonOk"] = w45;
                     w34.Add(w45);
                     Gtk.ButtonBox.ButtonBoxChild w54 = ((Gtk.ButtonBox.ButtonBoxChild)(w34[w45]));
                     w54.Position = 1;
                     w54.Expand = false;
                     w54.Fill = false;
                     bindings["hbuttonbox1"] = w34;
                     w1.Add(w34);
                     Gtk.Box.BoxChild w55 = ((Gtk.Box.BoxChild)(w1[w34]));
                     w55.PackType = ((Gtk.PackType)(1));
                     w55.Position = 1;
                     w55.Expand = false;
                     w55.Fill = false;
                     bindings["vbox1"] = w1;
                     cobj.Add(w1);
                     cobj.DefaultWidth = 400;
                     cobj.DefaultHeight = 273;
                     bindings["administrator.EditUserWindow"] = cobj;
                     w5.Show();
                     w7.Show();
                     w9.Show();
                     w11.Show();
                     w13.Show();
                     w15.Show();
                     w17.Show();
                     w19.Show();
                     w21.Show();
                     w23.Show();
                     w4.Show();
                     w26.Show();
                     w3.Show();
                     w29.Show();
                     w30.Show();
                     w32.Show();
                     w2.Show();
                     w38.Show();
                     w40.Show();
                     w37.Show();
                     w36.Show();
                     w35.Show();
                     w48.Show();
                     w50.Show();
                     w47.Show();
                     w46.Show();
                     w45.Show();
                     w34.Show();
                     w1.Show();
                     cobj.Show();
                     cobj.DeleteEvent += ((Gtk.DeleteEventHandler)(System.Delegate.CreateDelegate(typeof(Gtk.DeleteEventHandler), cobj, "OnClose")));
                     w35.Clicked += ((System.EventHandler)(System.Delegate.CreateDelegate(typeof(System.EventHandler), cobj, "OnCancelClicked")));
                     w45.Clicked += ((System.EventHandler)(System.Delegate.CreateDelegate(typeof(System.EventHandler), cobj, "OnOkClicked")));
                 }
             }
         }
     }
     System.Reflection.FieldInfo[] fields = obj.GetType().GetFields(((System.Reflection.BindingFlags.Public | System.Reflection.BindingFlags.NonPublic) | System.Reflection.BindingFlags.Instance));
     for (int n = 0; (n < fields.Length); n = (n + 1)) {
         System.Reflection.FieldInfo field = fields[n];
         object widget = bindings[field.Name];
         if (((widget != null) && field.FieldType.IsInstanceOfType(widget))) {
             field.SetValue(obj, widget);
         }
     }
 }
Esempio n. 47
0
        public ChatView(ChatModel chat)
        {
            Trace.Call(chat);

            _ChatModel = chat;

            IsAutoScrolling = true;
            MessageTextView tv = new MessageTextView();
            _EndMark = tv.Buffer.CreateMark("end", tv.Buffer.EndIter, false);
            tv.ShowTimestamps = true;
            tv.ShowMarkerline = true;
            tv.Editable = false;
            tv.CursorVisible = true;
            tv.WrapMode = Gtk.WrapMode.Char;
            tv.MessageAdded += OnMessageTextViewMessageAdded;
            tv.MessageHighlighted += OnMessageTextViewMessageHighlighted;
            tv.PopulatePopup += OnMessageTextViewPopulatePopup;
            tv.SizeRequested += delegate {
                AutoScroll();
            };
            tv.PersonClicked += OnMessageTextViewPersonClicked;
            _OutputMessageTextView = tv;

            Gtk.ScrolledWindow sw = new Gtk.ScrolledWindow();
            _OutputScrolledWindow = sw;
            //sw.HscrollbarPolicy = Gtk.PolicyType.Never;
            sw.HscrollbarPolicy = Gtk.PolicyType.Automatic;
            sw.VscrollbarPolicy = Gtk.PolicyType.Always;
            sw.ShadowType = Gtk.ShadowType.In;
            sw.Vadjustment.ValueChanged += OnVadjustmentValueChanged;
            sw.Add(_OutputMessageTextView);

            // popup menu
            _TabMenu = new Gtk.Menu();
            _TabMenu.Shown += OnTabMenuShown;

            //FocusChild = _OutputTextView;
            //CanFocus = false;

            _TabLabel = new Gtk.Label();

            TabImage = DefaultTabImage;
            _TabHBox = new Gtk.HBox();
            _TabHBox.PackEnd(new Gtk.Fixed(), true, true, 0);
            _TabHBox.PackEnd(_TabLabel, false, false, 0);
            _TabHBox.PackStart(TabImage, false, false, 2);
            _TabHBox.ShowAll();

            _TabEventBox = new Gtk.EventBox();
            _TabEventBox.VisibleWindow = false;
            _TabEventBox.ButtonPressEvent += new Gtk.ButtonPressEventHandler(OnTabButtonPress);
            _TabEventBox.Add(_TabHBox);
            _TabEventBox.ShowAll();

            _ThemeSettings = new ThemeSettings();

            // OPT-TODO: this should use a TaskStack instead of TaskQueue
            _LastSeenHighlightQueue = new TaskQueue("LastSeenHighlightQueue("+ID+")");
            _LastSeenHighlightQueue.AbortedEvent += OnLastSeenHighlightQueueAbortedEvent;
            _LastSeenHighlightQueue.ExceptionEvent += OnLastSeenHighlightQueueExceptionEvent;
        }
        public CueSheetsView(CueSheetsSource ms)
        {
            MySource=ms;

            basedir=MySource.getCueSheetDir ();

            store = new CS_TrackListModel();
            view  = new CS_TrackListView(this);

            {
                ColumnController colc=view.ColumnController;
                int i,N;
                for(i=0,N=colc.Count;i<N;i++) {
                    CS_Column col=(CS_Column) colc[i];
                    col.WidthChanged+=delegate(object sender,EventArgs args) {
                        Hyena.Log.Information ("set-column-sizes="+_set_column_sizes);
                        if (_set_column_sizes<=0) {
                            _set_column_sizes=0;
                            MySource.setColumnWidth (col.id(),MySource.getSheet ().id (),col.Width);
                        } else {
                            _set_column_sizes-=1;
                        }
                    };
                }
            }

            view.SetModel(store);
            this.setColumnSizes(null);

            Hyena.Log.Information("New albumlist");
            aview=new CS_AlbumListView(this);
            aaview=new CS_ArtistListView();
            ccview=new CS_ComposerListView();
            gview=new CS_GenreListView();
            try {
            plsview=new CS_PlayListsView(this);
            } catch (System.Exception ex) {
                Hyena.Log.Error (ex.ToString ());
            }

            Hyena.Log.Information("init models");
            aview.SetModel (MySource.getAlbumModel ());
            aaview.SetModel (MySource.getArtistModel ());
            gview.SetModel (MySource.getGenreModel ());
            ccview.SetModel (MySource.getComposerModel());
            plsview.SetModel(MySource.getPlayListsModel());

            plsadmin=new CS_PlayListAdmin(plsview,MySource.getPlayListsModel(),MySource.getPlayListCollection());

            MySource.getGenreModel();
            Hyena.Log.Information("model albumlist");
            Hyena.Log.Information("albumlist initialized");

            aview.RowActivated+=new Hyena.Data.Gui.RowActivatedHandler<AlbumInfo>(EvtRowActivated);
            aview.Selection.Changed += HandleAviewSelectionChanged;
            gview.RowActivated+=new Hyena.Data.Gui.RowActivatedHandler<CS_GenreInfo>(EvtGenreActivated);
            aaview.RowActivated+=new Hyena.Data.Gui.RowActivatedHandler<ArtistInfo>(EvtArtistActivated);
            ccview.RowActivated+=new Hyena.Data.Gui.RowActivatedHandler<CS_ComposerInfo>(EvtComposerActivated);
            plsview.RowActivated+=new Hyena.Data.Gui.RowActivatedHandler<CS_PlayList>(EvtPlayListActivated);
            view.RowActivated+=new RowActivatedHandler<CueSheetEntry>(EvtTrackRowActivated);

            bar=new Gtk.Toolbar();
            if (basedir==null) {
                Hyena.Log.Information("basedir="+basedir);
                Gtk.Label lbl=new Gtk.Label();
                lbl.Markup="<b>You need to configure the CueSheets music directory first, using the right mouse button on the extension</b>";
                bar.Add (lbl);
            }
            filling=new Gtk.Label();
            bar.Add (filling);

            ascroll=new Gtk.ScrolledWindow();
            ascroll.Add (aview);
            aascroll=new Gtk.ScrolledWindow();
            aascroll.Add (aaview);
            tscroll=new Gtk.ScrolledWindow();
            tscroll.Add (view);
            gscroll=new Gtk.ScrolledWindow();
            gscroll.Add (gview);
            ccscroll=new Gtk.ScrolledWindow();
            ccscroll.Add(ccview);

            bool view_artist=true;
            Gtk.VBox vac=new Gtk.VBox();
            Gtk.Button vab=new Gtk.Button("Artists");
            vab.Clicked+=delegate(object sender,EventArgs args) {
                if (view_artist) {
                    view_artist=false;
                    vab.Label="Composers";
                    vac.Remove (aascroll);
                    vac.PackEnd (ccscroll);
                    ccscroll.ShowAll ();
                } else {
                    view_artist=true;
                    vab.Label="Artists";
                    vac.Remove (ccscroll);
                    vac.PackEnd (aascroll);
                    aascroll.ShowAll ();
                }
            };
            vac.PackStart (vab,false,false,0);
            vac.PackEnd (aascroll);

            hb=new Gtk.HPaned();
            hb.Add(gscroll);
            hb.Add (vac);
            hb1=new Gtk.HPaned();
            hb1.Add (hb);
            hb1.Add (ascroll);

            vp=new Gtk.VPaned();
            vp.Add (hb1);
            vp.Add (tscroll);

            Gtk.HPaned hppls=new Gtk.HPaned();
            hppls.Add1 (vp);
            hppls.Add2 (plsadmin);
            hbpls=hppls;

            {
                int hb_pls,hb_p,hb1_p,vp_p;
                MySource.getPositions (out hb_pls,out hb_p,out hb1_p,out vp_p);
                hppls.Position=hb_pls;
                hb.Position=hb_p;
                hb1.Position=hb1_p;
                vp.Position=vp_p;
            }

            box   = new Gtk.VBox();
            box.PackStart (bar,false,true,0);
            box.PackStart (hppls);
            box.ShowAll();

            GLib.Timeout.Add ((uint) 1000,(GLib.TimeoutHandler) GardDividers);
            GLib.Timeout.Add ((uint) timeout,(GLib.TimeoutHandler) PositionDisplay);

            fill ();
        }
 public static void Build(object obj, string id)
 {
     System.Collections.Hashtable bindings = new System.Collections.Hashtable();
     if ((id == "SharpTranslator.ReversibleCombos")) {
         Gtk.Bin cobj = ((Gtk.Bin)(obj));
         // Widget SharpTranslator.ReversibleCombos
         BinContainer.Attach(cobj);
         cobj.Events = ((Gdk.EventMask)(256));
         cobj.Name = "SharpTranslator.ReversibleCombos";
         // Container child SharpTranslator.ReversibleCombos.Gtk.Container+ContainerChild
         Gtk.HBox w1 = new Gtk.HBox();
         w1.Spacing = 5;
         w1.BorderWidth = ((uint)(5));
         w1.Events = ((Gdk.EventMask)(0));
         w1.Name = "hbox1";
         // Container child hbox1.Gtk.Box+BoxChild
         Gtk.Label w2 = new Gtk.Label();
         w2.LabelProp = "Source:";
         w2.Events = ((Gdk.EventMask)(0));
         w2.Name = "labelSource";
         bindings["labelSource"] = w2;
         w1.Add(w2);
         Gtk.Box.BoxChild w3 = ((Gtk.Box.BoxChild)(w1[w2]));
         w3.Position = 0;
         w3.Expand = false;
         w3.Fill = false;
         // Container child hbox1.Gtk.Box+BoxChild
         Gtk.ComboBox w4 = Gtk.ComboBox.NewText();
         w4.Events = ((Gdk.EventMask)(0));
         w4.Name = "comboSource";
         bindings["comboSource"] = w4;
         w1.Add(w4);
         Gtk.Box.BoxChild w5 = ((Gtk.Box.BoxChild)(w1[w4]));
         w5.Position = 1;
         w5.Expand = false;
         w5.Fill = false;
         // Container child hbox1.Gtk.Box+BoxChild
         Gtk.VSeparator w6 = new Gtk.VSeparator();
         w6.Events = ((Gdk.EventMask)(0));
         w6.Name = "vseparator1";
         bindings["vseparator1"] = w6;
         w1.Add(w6);
         Gtk.Box.BoxChild w7 = ((Gtk.Box.BoxChild)(w1[w6]));
         w7.Position = 2;
         w7.Expand = false;
         w7.Fill = false;
         // Container child hbox1.Gtk.Box+BoxChild
         Gtk.CheckButton w8 = new Gtk.CheckButton();
         w8.Label = "reverse";
         w8.DrawIndicator = true;
         w8.BorderWidth = ((uint)(5));
         w8.CanFocus = true;
         w8.Events = ((Gdk.EventMask)(0));
         w8.Name = "checkbuttonReverse";
         bindings["checkbuttonReverse"] = w8;
         w1.Add(w8);
         Gtk.Box.BoxChild w9 = ((Gtk.Box.BoxChild)(w1[w8]));
         w9.Position = 3;
         w9.Expand = false;
         // Container child hbox1.Gtk.Box+BoxChild
         Gtk.VSeparator w10 = new Gtk.VSeparator();
         w10.Events = ((Gdk.EventMask)(0));
         w10.Name = "vseparator2";
         bindings["vseparator2"] = w10;
         w1.Add(w10);
         Gtk.Box.BoxChild w11 = ((Gtk.Box.BoxChild)(w1[w10]));
         w11.Position = 4;
         w11.Expand = false;
         w11.Fill = false;
         // Container child hbox1.Gtk.Box+BoxChild
         Gtk.Label w12 = new Gtk.Label();
         w12.LabelProp = "Target:";
         w12.Events = ((Gdk.EventMask)(0));
         w12.Name = "labelTarget";
         bindings["labelTarget"] = w12;
         w1.Add(w12);
         Gtk.Box.BoxChild w13 = ((Gtk.Box.BoxChild)(w1[w12]));
         w13.Position = 5;
         w13.Expand = false;
         w13.Fill = false;
         // Container child hbox1.Gtk.Box+BoxChild
         Gtk.ComboBox w14 = Gtk.ComboBox.NewText();
         w14.Events = ((Gdk.EventMask)(0));
         w14.Name = "comboTarget";
         bindings["comboTarget"] = w14;
         w1.Add(w14);
         Gtk.Box.BoxChild w15 = ((Gtk.Box.BoxChild)(w1[w14]));
         w15.Position = 6;
         w15.Expand = false;
         w15.Fill = false;
         bindings["hbox1"] = w1;
         cobj.Add(w1);
         bindings["SharpTranslator.ReversibleCombos"] = cobj;
         w2.Show();
         w4.Show();
         w6.Show();
         w8.Show();
         w10.Show();
         w12.Show();
         w14.Show();
         w1.Show();
         cobj.Show();
     }
     else {
         if ((id == "SharpTranslator.AboutDialog")) {
             Gtk.Dialog cobj = ((Gtk.Dialog)(obj));
             // Widget SharpTranslator.AboutDialog
             cobj.Title = "AboutDialog";
             cobj.WindowPosition = ((Gtk.WindowPosition)(4));
             cobj.HasSeparator = false;
             cobj.Events = ((Gdk.EventMask)(256));
             cobj.Name = "SharpTranslator.AboutDialog";
             // Internal child SharpTranslator.AboutDialog.VBox
             Gtk.VBox w1 = cobj.VBox;
             w1.BorderWidth = ((uint)(2));
             w1.Events = ((Gdk.EventMask)(256));
             w1.Name = "dialog_VBox";
             // Container child dialog_VBox.Gtk.Box+BoxChild
             Gtk.TextView w2 = new Gtk.TextView();
             w2.Buffer.Text = "\n         SharpTranslator\n\n    Version 0.1.3  (October 2006)\n\n    License: GPL\n\n    Author: Carlos Ble <http://www.shidix.com/carlosble>\n\n    English-Spanish dictionary was taken from i2e:\n          (Alfredo Casademunt, Jose Luis Triviño)\n\n";
             w2.CanFocus = true;
             w2.Events = ((Gdk.EventMask)(0));
             w2.Name = "textview1";
             bindings["textview1"] = w2;
             w1.Add(w2);
             Gtk.Box.BoxChild w3 = ((Gtk.Box.BoxChild)(w1[w2]));
             w3.Position = 0;
             // Container child dialog_VBox.Gtk.Box+BoxChild
             Gtk.HSeparator w4 = new Gtk.HSeparator();
             w4.Events = ((Gdk.EventMask)(0));
             w4.Name = "hseparator1";
             bindings["hseparator1"] = w4;
             w1.Add(w4);
             Gtk.Box.BoxChild w5 = ((Gtk.Box.BoxChild)(w1[w4]));
             w5.Position = 1;
             w5.Expand = false;
             w5.Fill = false;
             bindings["dialog_VBox"] = w1;
             // Internal child SharpTranslator.AboutDialog.ActionArea
             Gtk.HButtonBox w6 = cobj.ActionArea;
             w6.LayoutStyle = ((Gtk.ButtonBoxStyle)(4));
             w6.Spacing = 10;
             w6.BorderWidth = ((uint)(5));
             w6.Events = ((Gdk.EventMask)(256));
             w6.Name = "SharpTranslator.AboutDialog_ActionArea";
             // Container child SharpTranslator.AboutDialog_ActionArea.Gtk.ButtonBox+ButtonBoxChild
             Gtk.Button w7 = new Gtk.Button();
             w7.CanFocus = true;
             w7.Events = ((Gdk.EventMask)(0));
             w7.Name = "buttonClose";
             w7.CanDefault = true;
             // Container child buttonClose.Gtk.Container+ContainerChild
             Gtk.Alignment w8 = new Gtk.Alignment(0.5F, 0.5F, 0F, 0F);
             w8.Events = ((Gdk.EventMask)(0));
             w8.Name = "GtkAlignment";
             // Container child GtkAlignment.Gtk.Container+ContainerChild
             Gtk.HBox w9 = new Gtk.HBox();
             w9.Spacing = 2;
             w9.Events = ((Gdk.EventMask)(0));
             w9.Name = "GtkHBox";
             // Container child GtkHBox.Gtk.Container+ContainerChild
             Gtk.Image w10 = new Gtk.Image();
             w10.Pixbuf = Gtk.IconTheme.Default.LoadIcon("gtk-close", 16, 0);
             w10.Events = ((Gdk.EventMask)(0));
             w10.Name = "image1";
             bindings["image1"] = w10;
             w9.Add(w10);
             // Container child GtkHBox.Gtk.Container+ContainerChild
             Gtk.Label w12 = new Gtk.Label();
             w12.LabelProp = "Close";
             w12.Events = ((Gdk.EventMask)(0));
             w12.Name = "GtkLabel";
             bindings["GtkLabel"] = w12;
             w9.Add(w12);
             bindings["GtkHBox"] = w9;
             w8.Add(w9);
             bindings["GtkAlignment"] = w8;
             w7.Add(w8);
             bindings["buttonClose"] = w7;
             cobj.AddActionWidget(w7, 0);
             Gtk.ButtonBox.ButtonBoxChild w16 = ((Gtk.ButtonBox.ButtonBoxChild)(w6[w7]));
             w16.Expand = false;
             w16.Fill = false;
             bindings["SharpTranslator.AboutDialog_ActionArea"] = w6;
             cobj.DefaultWidth = 487;
             cobj.DefaultHeight = 303;
             bindings["SharpTranslator.AboutDialog"] = cobj;
             w2.Show();
             w4.Show();
             w1.Show();
             w10.Show();
             w12.Show();
             w9.Show();
             w8.Show();
             w7.Show();
             w6.Show();
             cobj.Show();
             w7.Clicked += ((System.EventHandler)(System.Delegate.CreateDelegate(typeof(System.EventHandler), cobj, "OnClose")));
         }
         else {
             if ((id == "SharpTranslator.LearnWindow")) {
                 Gtk.Window cobj = ((Gtk.Window)(obj));
                 // Widget SharpTranslator.LearnWindow
                 cobj.Title = "LearnWindow";
                 cobj.WindowPosition = ((Gtk.WindowPosition)(1));
                 cobj.Resizable = false;
                 cobj.AllowGrow = false;
                 cobj.Events = ((Gdk.EventMask)(0));
                 cobj.Name = "SharpTranslator.LearnWindow";
                 // Container child SharpTranslator.LearnWindow.Gtk.Container+ContainerChild
                 Gtk.VBox w1 = new Gtk.VBox();
                 w1.Spacing = 5;
                 w1.BorderWidth = ((uint)(3));
                 w1.Events = ((Gdk.EventMask)(0));
                 w1.Name = "vbox1";
                 // Container child vbox1.Gtk.Box+BoxChild
                 Gtk.HBox w2 = new Gtk.HBox();
                 w2.BorderWidth = ((uint)(3));
                 w2.Events = ((Gdk.EventMask)(0));
                 w2.Name = "hbox5";
                 // Container child hbox5.Gtk.Box+BoxChild
                 Gtk.Label w3 = new Gtk.Label();
                 w3.LabelProp = "Type of item:";
                 w3.Events = ((Gdk.EventMask)(0));
                 w3.Name = "label1";
                 bindings["label1"] = w3;
                 w2.Add(w3);
                 Gtk.Box.BoxChild w4 = ((Gtk.Box.BoxChild)(w2[w3]));
                 w4.Position = 0;
                 w4.Expand = false;
                 w4.Fill = false;
                 // Container child hbox5.Gtk.Box+BoxChild
                 Gtk.HBox w5 = new Gtk.HBox();
                 w5.Events = ((Gdk.EventMask)(0));
                 w5.Name = "hbox4";
                 // Container child hbox4.Gtk.Box+BoxChild
                 Gtk.CheckButton w6 = new Gtk.CheckButton();
                 w6.Label = "Word";
                 w6.Active = true;
                 w6.DrawIndicator = true;
                 w6.CanFocus = true;
                 w6.Events = ((Gdk.EventMask)(0));
                 w6.Name = "checkbWord";
                 bindings["checkbWord"] = w6;
                 w5.Add(w6);
                 Gtk.Box.BoxChild w7 = ((Gtk.Box.BoxChild)(w5[w6]));
                 w7.Position = 0;
                 // Container child hbox4.Gtk.Box+BoxChild
                 Gtk.CheckButton w8 = new Gtk.CheckButton();
                 w8.Label = "Expression";
                 w8.DrawIndicator = true;
                 w8.CanFocus = true;
                 w8.Events = ((Gdk.EventMask)(0));
                 w8.Name = "checkbExpression";
                 bindings["checkbExpression"] = w8;
                 w5.Add(w8);
                 Gtk.Box.BoxChild w9 = ((Gtk.Box.BoxChild)(w5[w8]));
                 w9.Position = 1;
                 bindings["hbox4"] = w5;
                 w2.Add(w5);
                 Gtk.Box.BoxChild w10 = ((Gtk.Box.BoxChild)(w2[w5]));
                 w10.Position = 1;
                 w10.Expand = false;
                 bindings["hbox5"] = w2;
                 w1.Add(w2);
                 Gtk.Box.BoxChild w11 = ((Gtk.Box.BoxChild)(w1[w2]));
                 w11.Position = 0;
                 w11.Expand = false;
                 w11.Fill = false;
                 // Container child vbox1.Gtk.Box+BoxChild
                 SharpTranslator.ReversibleCombos w12 = new SharpTranslator.ReversibleCombos();
                 w12.Events = ((Gdk.EventMask)(256));
                 w12.Name = "rCombos";
                 bindings["rCombos"] = w12;
                 w1.Add(w12);
                 Gtk.Box.BoxChild w13 = ((Gtk.Box.BoxChild)(w1[w12]));
                 w13.Position = 1;
                 w13.Expand = false;
                 w13.Fill = false;
                 // Container child vbox1.Gtk.Box+BoxChild
                 Gtk.HBox w14 = new Gtk.HBox();
                 w14.Spacing = 5;
                 w14.BorderWidth = ((uint)(3));
                 w14.Events = ((Gdk.EventMask)(0));
                 w14.Name = "hbox3";
                 // Container child hbox3.Gtk.Box+BoxChild
                 Gtk.Label w15 = new Gtk.Label();
                 w15.LabelProp = "Text:";
                 w15.Events = ((Gdk.EventMask)(0));
                 w15.Name = "labelText";
                 bindings["labelText"] = w15;
                 w14.Add(w15);
                 Gtk.Box.BoxChild w16 = ((Gtk.Box.BoxChild)(w14[w15]));
                 w16.Position = 0;
                 w16.Expand = false;
                 w16.Fill = false;
                 // Container child hbox3.Gtk.Box+BoxChild
                 Gtk.Entry w17 = new Gtk.Entry();
                 w17.IsEditable = true;
                 w17.InvisibleChar = '●';
                 w17.CanFocus = true;
                 w17.Events = ((Gdk.EventMask)(0));
                 w17.Name = "entryText";
                 bindings["entryText"] = w17;
                 w14.Add(w17);
                 Gtk.Box.BoxChild w18 = ((Gtk.Box.BoxChild)(w14[w17]));
                 w18.Position = 1;
                 // Container child hbox3.Gtk.Box+BoxChild
                 Gtk.Label w19 = new Gtk.Label();
                 w19.LabelProp = "Translation:";
                 w19.Events = ((Gdk.EventMask)(0));
                 w19.Name = "label3";
                 bindings["label3"] = w19;
                 w14.Add(w19);
                 Gtk.Box.BoxChild w20 = ((Gtk.Box.BoxChild)(w14[w19]));
                 w20.Position = 2;
                 w20.Expand = false;
                 w20.Fill = false;
                 // Container child hbox3.Gtk.Box+BoxChild
                 Gtk.Entry w21 = new Gtk.Entry();
                 w21.IsEditable = true;
                 w21.InvisibleChar = '●';
                 w21.CanFocus = true;
                 w21.Events = ((Gdk.EventMask)(0));
                 w21.Name = "entryTranslation";
                 bindings["entryTranslation"] = w21;
                 w14.Add(w21);
                 Gtk.Box.BoxChild w22 = ((Gtk.Box.BoxChild)(w14[w21]));
                 w22.Position = 3;
                 bindings["hbox3"] = w14;
                 w1.Add(w14);
                 Gtk.Box.BoxChild w23 = ((Gtk.Box.BoxChild)(w1[w14]));
                 w23.Position = 2;
                 w23.Expand = false;
                 w23.Fill = false;
                 // Container child vbox1.Gtk.Box+BoxChild
                 Gtk.HSeparator w24 = new Gtk.HSeparator();
                 w24.Events = ((Gdk.EventMask)(0));
                 w24.Name = "hseparator1";
                 bindings["hseparator1"] = w24;
                 w1.Add(w24);
                 Gtk.Box.BoxChild w25 = ((Gtk.Box.BoxChild)(w1[w24]));
                 w25.Position = 3;
                 w25.Expand = false;
                 w25.Fill = false;
                 // Container child vbox1.Gtk.Box+BoxChild
                 Gtk.HButtonBox w26 = new Gtk.HButtonBox();
                 w26.LayoutStyle = ((Gtk.ButtonBoxStyle)(4));
                 w26.Spacing = 3;
                 w26.BorderWidth = ((uint)(3));
                 w26.Events = ((Gdk.EventMask)(0));
                 w26.Name = "hbuttonbox1";
                 // Container child hbuttonbox1.Gtk.ButtonBox+ButtonBoxChild
                 Gtk.Button w27 = new Gtk.Button();
                 w27.CanFocus = true;
                 w27.Events = ((Gdk.EventMask)(0));
                 w27.Name = "buttonCancel";
                 // Container child buttonCancel.Gtk.Container+ContainerChild
                 Gtk.Alignment w28 = new Gtk.Alignment(0.5F, 0.5F, 0F, 0F);
                 w28.Events = ((Gdk.EventMask)(0));
                 w28.Name = "GtkAlignment";
                 // Container child GtkAlignment.Gtk.Container+ContainerChild
                 Gtk.HBox w29 = new Gtk.HBox();
                 w29.Spacing = 2;
                 w29.Events = ((Gdk.EventMask)(0));
                 w29.Name = "GtkHBox";
                 // Container child GtkHBox.Gtk.Container+ContainerChild
                 Gtk.Image w30 = new Gtk.Image();
                 w30.Pixbuf = Gtk.IconTheme.Default.LoadIcon("gtk-cancel", 16, 0);
                 w30.Events = ((Gdk.EventMask)(0));
                 w30.Name = "image2";
                 bindings["image2"] = w30;
                 w29.Add(w30);
                 // Container child GtkHBox.Gtk.Container+ContainerChild
                 Gtk.Label w32 = new Gtk.Label();
                 w32.LabelProp = "Cancel";
                 w32.Events = ((Gdk.EventMask)(0));
                 w32.Name = "GtkLabel";
                 bindings["GtkLabel"] = w32;
                 w29.Add(w32);
                 bindings["GtkHBox"] = w29;
                 w28.Add(w29);
                 bindings["GtkAlignment"] = w28;
                 w27.Add(w28);
                 bindings["buttonCancel"] = w27;
                 w26.Add(w27);
                 Gtk.ButtonBox.ButtonBoxChild w36 = ((Gtk.ButtonBox.ButtonBoxChild)(w26[w27]));
                 w36.Expand = false;
                 w36.Fill = false;
                 // Container child hbuttonbox1.Gtk.ButtonBox+ButtonBoxChild
                 Gtk.Button w37 = new Gtk.Button();
                 w37.CanFocus = true;
                 w37.Events = ((Gdk.EventMask)(0));
                 w37.Name = "buttonAccept";
                 // Container child buttonAccept.Gtk.Container+ContainerChild
                 Gtk.Alignment w38 = new Gtk.Alignment(0.5F, 0.5F, 0F, 0F);
                 w38.Events = ((Gdk.EventMask)(0));
                 w38.Name = "GtkAlignment";
                 // Container child GtkAlignment.Gtk.Container+ContainerChild
                 Gtk.HBox w39 = new Gtk.HBox();
                 w39.Spacing = 2;
                 w39.Events = ((Gdk.EventMask)(0));
                 w39.Name = "GtkHBox";
                 // Container child GtkHBox.Gtk.Container+ContainerChild
                 Gtk.Image w40 = new Gtk.Image();
                 w40.Pixbuf = Gtk.IconTheme.Default.LoadIcon("gtk-ok", 16, 0);
                 w40.Events = ((Gdk.EventMask)(0));
                 w40.Name = "image3";
                 bindings["image3"] = w40;
                 w39.Add(w40);
                 // Container child GtkHBox.Gtk.Container+ContainerChild
                 Gtk.Label w42 = new Gtk.Label();
                 w42.LabelProp = "Accept";
                 w42.Events = ((Gdk.EventMask)(0));
                 w42.Name = "GtkLabel";
                 bindings["GtkLabel"] = w42;
                 w39.Add(w42);
                 bindings["GtkHBox"] = w39;
                 w38.Add(w39);
                 bindings["GtkAlignment"] = w38;
                 w37.Add(w38);
                 bindings["buttonAccept"] = w37;
                 w26.Add(w37);
                 Gtk.ButtonBox.ButtonBoxChild w46 = ((Gtk.ButtonBox.ButtonBoxChild)(w26[w37]));
                 w46.Position = 1;
                 w46.Expand = false;
                 w46.Fill = false;
                 bindings["hbuttonbox1"] = w26;
                 w1.Add(w26);
                 Gtk.Box.BoxChild w47 = ((Gtk.Box.BoxChild)(w1[w26]));
                 w47.Position = 4;
                 w47.Expand = false;
                 w47.Fill = false;
                 bindings["vbox1"] = w1;
                 cobj.Add(w1);
                 cobj.DefaultWidth = 586;
                 cobj.DefaultHeight = 194;
                 bindings["SharpTranslator.LearnWindow"] = cobj;
                 w3.Show();
                 w6.Show();
                 w8.Show();
                 w5.Show();
                 w2.Show();
                 w12.Show();
                 w15.Show();
                 w17.Show();
                 w19.Show();
                 w21.Show();
                 w14.Show();
                 w24.Show();
                 w30.Show();
                 w32.Show();
                 w29.Show();
                 w28.Show();
                 w27.Show();
                 w40.Show();
                 w42.Show();
                 w39.Show();
                 w38.Show();
                 w37.Show();
                 w26.Show();
                 w1.Show();
                 cobj.Show();
                 cobj.DeleteEvent += ((Gtk.DeleteEventHandler)(System.Delegate.CreateDelegate(typeof(Gtk.DeleteEventHandler), cobj, "OnClose")));
                 w37.Clicked += ((System.EventHandler)(System.Delegate.CreateDelegate(typeof(System.EventHandler), cobj, "OnAccept")));
             }
             else {
                 if ((id == "SharpTranslator.MainWindow")) {
                     Gtk.Window cobj = ((Gtk.Window)(obj));
                     // Widget SharpTranslator.MainWindow
                     cobj.Title = "SharpTranslator";
                     Gtk.UIManager w1 = new Gtk.UIManager();
                     Gtk.ActionGroup w2 = new Gtk.ActionGroup("Default");
                     Gtk.Action w3 = new Gtk.Action("File", "File", null, null);
                     w3.ShortLabel = "Archivo";
                     bindings["File"] = w3;
                     w2.Add(w3, null);
                     Gtk.Action w4 = new Gtk.Action("Edit", "Edit", null, null);
                     w4.ShortLabel = "Editar";
                     bindings["Edit"] = w4;
                     w2.Add(w4, null);
                     Gtk.Action w5 = new Gtk.Action("Learn", "Learn", null, "gtk-new");
                     w5.ShortLabel = "Learn";
                     bindings["Learn"] = w5;
                     w2.Add(w5, null);
                     Gtk.Action w6 = new Gtk.Action("floppy", null, null, "gtk-floppy");
                     bindings["floppy"] = w6;
                     w2.Add(w6, null);
                     Gtk.Action w7 = new Gtk.Action("LearnWords", "Learn words", null, "gtk-new");
                     w7.ShortLabel = "Learn ";
                     bindings["LearnWords"] = w7;
                     w2.Add(w7, null);
                     Gtk.Action w8 = new Gtk.Action("AddLanguage", "Add Language", null, "gtk-add");
                     w8.ShortLabel = "Exit";
                     bindings["AddLanguage"] = w8;
                     w2.Add(w8, null);
                     Gtk.Action w9 = new Gtk.Action("Cut", "Cut", null, "gtk-cut");
                     w9.ShortLabel = "Cut";
                     bindings["Cut"] = w9;
                     w2.Add(w9, null);
                     Gtk.Action w10 = new Gtk.Action("Copy", "Copy", null, "gtk-copy");
                     w10.ShortLabel = "Copy";
                     bindings["Copy"] = w10;
                     w2.Add(w10, null);
                     Gtk.Action w11 = new Gtk.Action("Paste", "Paste", null, "gtk-paste");
                     w11.ShortLabel = "Paste";
                     bindings["Paste"] = w11;
                     w2.Add(w11, null);
                     Gtk.Action w12 = new Gtk.Action("Help", "Help", null, null);
                     w12.ShortLabel = "Help";
                     bindings["Help"] = w12;
                     w2.Add(w12, null);
                     Gtk.Action w13 = new Gtk.Action("About", "About", null, "gnome-stock-about");
                     w13.ShortLabel = "About";
                     bindings["About"] = w13;
                     w2.Add(w13, null);
                     Gtk.Action w14 = new Gtk.Action("ImportDictionary", "Import Dictionary", null, "gnome-stock-book-blue");
                     w14.ShortLabel = "Import Dictionary";
                     bindings["ImportDictionary"] = w14;
                     w2.Add(w14, null);
                     Gtk.Action w15 = new Gtk.Action("Preferences", "Preferences", null, "gtk-preferences");
                     w15.ShortLabel = "Preferences";
                     bindings["Preferences"] = w15;
                     w2.Add(w15, null);
                     Gtk.Action w16 = new Gtk.Action("Close", "Close", null, "gtk-close");
                     w16.ShortLabel = "Close";
                     bindings["Close"] = w16;
                     w2.Add(w16, null);
                     w1.InsertActionGroup(w2, 0);
                     cobj.AddAccelGroup(w1.AccelGroup);
                     cobj.Icon = Gtk.IconTheme.Default.LoadIcon("gtk-properties", 16, 0);
                     cobj.WindowPosition = ((Gtk.WindowPosition)(1));
                     cobj.DefaultWidth = 60;
                     cobj.Events = ((Gdk.EventMask)(0));
                     cobj.Name = "SharpTranslator.MainWindow";
                     // Container child SharpTranslator.MainWindow.Gtk.Container+ContainerChild
                     Gtk.VBox w17 = new Gtk.VBox();
                     w17.Events = ((Gdk.EventMask)(0));
                     w17.Name = "vbox1";
                     // Container child vbox1.Gtk.Box+BoxChild
                     w1.AddUiFromString("<ui><menubar name='menubar1'><menu action='File'><menuitem action='LearnWords'/><menuitem action='AddLanguage'/><menuitem action='ImportDictionary'/><menuitem action='Close'/></menu><menu action='Edit'><menuitem action='Cut'/><menuitem action='Copy'/><menuitem action='Paste'/><menuitem action='Preferences'/></menu><menu action='Help'><menuitem action='About'/></menu></menubar></ui>");
                     Gtk.MenuBar w18 = ((Gtk.MenuBar)(w1.GetWidget("/menubar1")));
                     w18.Events = ((Gdk.EventMask)(0));
                     w18.Name = "menubar1";
                     bindings["menubar1"] = w18;
                     w17.Add(w18);
                     Gtk.Box.BoxChild w19 = ((Gtk.Box.BoxChild)(w17[w18]));
                     w19.Position = 0;
                     w19.Expand = false;
                     w19.Fill = false;
                     // Container child vbox1.Gtk.Box+BoxChild
                     w1.AddUiFromString("<ui><toolbar name='toolbar1'><toolitem action='Learn'/></toolbar></ui>");
                     Gtk.Toolbar w20 = ((Gtk.Toolbar)(w1.GetWidget("/toolbar1")));
                     w20.ShowArrow = false;
                     w20.Tooltips = false;
                     w20.ToolbarStyle = ((Gtk.ToolbarStyle)(2));
                     w20.IconSize = ((Gtk.IconSize)(2));
                     w20.Events = ((Gdk.EventMask)(0));
                     w20.Name = "toolbar1";
                     bindings["toolbar1"] = w20;
                     w17.Add(w20);
                     Gtk.Box.BoxChild w21 = ((Gtk.Box.BoxChild)(w17[w20]));
                     w21.Position = 1;
                     w21.Expand = false;
                     w21.Fill = false;
                     // Container child vbox1.Gtk.Box+BoxChild
                     SharpTranslator.ReversibleCombos w22 = new SharpTranslator.ReversibleCombos();
                     w22.Events = ((Gdk.EventMask)(256));
                     w22.Name = "rCombos";
                     bindings["rCombos"] = w22;
                     w17.Add(w22);
                     Gtk.Box.BoxChild w23 = ((Gtk.Box.BoxChild)(w17[w22]));
                     w23.Position = 2;
                     w23.Expand = false;
                     w23.Fill = false;
                     // Container child vbox1.Gtk.Box+BoxChild
                     Gtk.ScrolledWindow w24 = new Gtk.ScrolledWindow();
                     w24.VscrollbarPolicy = ((Gtk.PolicyType)(1));
                     w24.HscrollbarPolicy = ((Gtk.PolicyType)(1));
                     w24.CanFocus = true;
                     w24.Events = ((Gdk.EventMask)(0));
                     w24.Name = "scrolledwindow1";
                     // Container child scrolledwindow1.Gtk.Container+ContainerChild
                     Gtk.TreeView w25 = new Gtk.TreeView();
                     w25.CanFocus = true;
                     w25.Events = ((Gdk.EventMask)(0));
                     w25.Name = "treeviewResults";
                     bindings["treeviewResults"] = w25;
                     w24.Add(w25);
                     bindings["scrolledwindow1"] = w24;
                     w17.Add(w24);
                     Gtk.Box.BoxChild w27 = ((Gtk.Box.BoxChild)(w17[w24]));
                     w27.Position = 3;
                     // Container child vbox1.Gtk.Box+BoxChild
                     Gtk.HBox w28 = new Gtk.HBox();
                     w28.Spacing = 5;
                     w28.BorderWidth = ((uint)(3));
                     w28.Events = ((Gdk.EventMask)(0));
                     w28.Name = "hbox3";
                     // Container child hbox3.Gtk.Box+BoxChild
                     Gtk.Label w29 = new Gtk.Label();
                     w29.LabelProp = "Word:";
                     w29.Events = ((Gdk.EventMask)(0));
                     w29.Name = "labelWord";
                     bindings["labelWord"] = w29;
                     w28.Add(w29);
                     Gtk.Box.BoxChild w30 = ((Gtk.Box.BoxChild)(w28[w29]));
                     w30.Position = 0;
                     w30.Expand = false;
                     w30.Fill = false;
                     // Container child hbox3.Gtk.Box+BoxChild
                     Gtk.Entry w31 = new Gtk.Entry();
                     w31.IsEditable = true;
                     w31.InvisibleChar = '●';
                     w31.CanFocus = true;
                     w31.Events = ((Gdk.EventMask)(0));
                     w31.Name = "entryKeyword";
                     w31.CanDefault = true;
                     bindings["entryKeyword"] = w31;
                     w28.Add(w31);
                     Gtk.Box.BoxChild w32 = ((Gtk.Box.BoxChild)(w28[w31]));
                     w32.Position = 1;
                     // Container child hbox3.Gtk.Box+BoxChild
                     Gtk.Button w33 = new Gtk.Button();
                     Gtk.Tooltips w34 = new Gtk.Tooltips();
                     w34.SetTip(w33, "Search keyword", "Search keyword");
                     w33.CanFocus = true;
                     w33.Events = ((Gdk.EventMask)(0));
                     w33.Name = "buttonSearch";
                     // Container child buttonSearch.Gtk.Container+ContainerChild
                     Gtk.Alignment w35 = new Gtk.Alignment(0.5F, 0.5F, 0F, 0F);
                     w35.Events = ((Gdk.EventMask)(0));
                     w35.Name = "GtkAlignment";
                     // Container child GtkAlignment.Gtk.Container+ContainerChild
                     Gtk.HBox w36 = new Gtk.HBox();
                     w36.Spacing = 2;
                     w36.Events = ((Gdk.EventMask)(0));
                     w36.Name = "GtkHBox";
                     // Container child GtkHBox.Gtk.Container+ContainerChild
                     Gtk.Image w37 = new Gtk.Image();
                     w37.Pixbuf = Gtk.IconTheme.Default.LoadIcon("gtk-find", 16, 0);
                     w37.Events = ((Gdk.EventMask)(0));
                     w37.Name = "image4";
                     bindings["image4"] = w37;
                     w36.Add(w37);
                     // Container child GtkHBox.Gtk.Container+ContainerChild
                     Gtk.Label w39 = new Gtk.Label();
                     w39.LabelProp = "Search";
                     w39.Events = ((Gdk.EventMask)(0));
                     w39.Name = "GtkLabel";
                     bindings["GtkLabel"] = w39;
                     w36.Add(w39);
                     bindings["GtkHBox"] = w36;
                     w35.Add(w36);
                     bindings["GtkAlignment"] = w35;
                     w33.Add(w35);
                     bindings["buttonSearch"] = w33;
                     w28.Add(w33);
                     Gtk.Box.BoxChild w43 = ((Gtk.Box.BoxChild)(w28[w33]));
                     w43.Position = 2;
                     w43.Expand = false;
                     w43.Fill = false;
                     bindings["hbox3"] = w28;
                     w17.Add(w28);
                     Gtk.Box.BoxChild w44 = ((Gtk.Box.BoxChild)(w17[w28]));
                     w44.Position = 4;
                     w44.Expand = false;
                     w44.Fill = false;
                     // Container child vbox1.Gtk.Box+BoxChild
                     Gtk.HBox w45 = new Gtk.HBox();
                     w45.Spacing = 5;
                     w45.BorderWidth = ((uint)(3));
                     w45.Events = ((Gdk.EventMask)(0));
                     w45.Name = "hbox4";
                     // Container child hbox4.Gtk.Box+BoxChild
                     Gtk.Label w46 = new Gtk.Label();
                     w46.LabelProp = "Expression:";
                     w46.Events = ((Gdk.EventMask)(0));
                     w46.Name = "labelExpression";
                     bindings["labelExpression"] = w46;
                     w45.Add(w46);
                     Gtk.Box.BoxChild w47 = ((Gtk.Box.BoxChild)(w45[w46]));
                     w47.Position = 0;
                     w47.Expand = false;
                     w47.Fill = false;
                     // Container child hbox4.Gtk.Box+BoxChild
                     Gtk.Entry w48 = new Gtk.Entry();
                     w48.IsEditable = true;
                     w48.InvisibleChar = '●';
                     w48.CanFocus = true;
                     w48.Events = ((Gdk.EventMask)(0));
                     w48.Name = "entryExpression";
                     bindings["entryExpression"] = w48;
                     w45.Add(w48);
                     Gtk.Box.BoxChild w49 = ((Gtk.Box.BoxChild)(w45[w48]));
                     w49.Position = 1;
                     // Container child hbox4.Gtk.Box+BoxChild
                     Gtk.Button w50 = new Gtk.Button();
                     w34.SetTip(w50, "Search keyword", "Search keyword");
                     w50.CanFocus = true;
                     w50.Events = ((Gdk.EventMask)(0));
                     w50.Name = "buttonSearchExpression";
                     // Container child buttonSearchExpression.Gtk.Container+ContainerChild
                     Gtk.Alignment w51 = new Gtk.Alignment(0.5F, 0.5F, 0F, 0F);
                     w51.Events = ((Gdk.EventMask)(0));
                     w51.Name = "GtkAlignment";
                     // Container child GtkAlignment.Gtk.Container+ContainerChild
                     Gtk.HBox w52 = new Gtk.HBox();
                     w52.Spacing = 2;
                     w52.Events = ((Gdk.EventMask)(0));
                     w52.Name = "GtkHBox";
                     // Container child GtkHBox.Gtk.Container+ContainerChild
                     Gtk.Image w53 = new Gtk.Image();
                     w53.Pixbuf = Gtk.IconTheme.Default.LoadIcon("gtk-find", 16, 0);
                     w53.Events = ((Gdk.EventMask)(0));
                     w53.Name = "image5";
                     bindings["image5"] = w53;
                     w52.Add(w53);
                     // Container child GtkHBox.Gtk.Container+ContainerChild
                     Gtk.Label w55 = new Gtk.Label();
                     w55.LabelProp = "Search";
                     w55.Events = ((Gdk.EventMask)(0));
                     w55.Name = "GtkLabel";
                     bindings["GtkLabel"] = w55;
                     w52.Add(w55);
                     bindings["GtkHBox"] = w52;
                     w51.Add(w52);
                     bindings["GtkAlignment"] = w51;
                     w50.Add(w51);
                     bindings["buttonSearchExpression"] = w50;
                     w45.Add(w50);
                     Gtk.Box.BoxChild w59 = ((Gtk.Box.BoxChild)(w45[w50]));
                     w59.Position = 2;
                     w59.Expand = false;
                     w59.Fill = false;
                     // Container child hbox4.Gtk.Box+BoxChild
                     Gtk.Button w60 = new Gtk.Button();
                     w34.SetTip(w60, "Search keyword", "Search keyword");
                     w60.CanFocus = true;
                     w60.Events = ((Gdk.EventMask)(0));
                     w60.Name = "buttonShowAll";
                     w60.Label = "Show All";
                     bindings["buttonShowAll"] = w60;
                     w45.Add(w60);
                     Gtk.Box.BoxChild w61 = ((Gtk.Box.BoxChild)(w45[w60]));
                     w61.Position = 3;
                     w61.Expand = false;
                     w61.Fill = false;
                     bindings["hbox4"] = w45;
                     w17.Add(w45);
                     Gtk.Box.BoxChild w62 = ((Gtk.Box.BoxChild)(w17[w45]));
                     w62.Position = 5;
                     w62.Expand = false;
                     w62.Fill = false;
                     // Container child vbox1.Gtk.Box+BoxChild
                     Gtk.HSeparator w63 = new Gtk.HSeparator();
                     w63.Events = ((Gdk.EventMask)(0));
                     w63.Name = "hseparator1";
                     bindings["hseparator1"] = w63;
                     w17.Add(w63);
                     Gtk.Box.BoxChild w64 = ((Gtk.Box.BoxChild)(w17[w63]));
                     w64.Position = 6;
                     w64.Expand = false;
                     w64.Fill = false;
                     // Container child vbox1.Gtk.Box+BoxChild
                     Gtk.HButtonBox w65 = new Gtk.HButtonBox();
                     w65.LayoutStyle = ((Gtk.ButtonBoxStyle)(4));
                     w65.BorderWidth = ((uint)(3));
                     w65.Events = ((Gdk.EventMask)(0));
                     w65.Name = "hbuttonbox1";
                     // Container child hbuttonbox1.Gtk.ButtonBox+ButtonBoxChild
                     Gtk.Button w66 = new Gtk.Button();
                     w66.CanFocus = true;
                     w66.Events = ((Gdk.EventMask)(0));
                     w66.Name = "buttonClose";
                     // Container child buttonClose.Gtk.Container+ContainerChild
                     Gtk.Alignment w67 = new Gtk.Alignment(0.5F, 0.5F, 0F, 0F);
                     w67.Events = ((Gdk.EventMask)(0));
                     w67.Name = "GtkAlignment";
                     // Container child GtkAlignment.Gtk.Container+ContainerChild
                     Gtk.HBox w68 = new Gtk.HBox();
                     w68.Spacing = 2;
                     w68.Events = ((Gdk.EventMask)(0));
                     w68.Name = "GtkHBox";
                     // Container child GtkHBox.Gtk.Container+ContainerChild
                     Gtk.Image w69 = new Gtk.Image();
                     w69.Pixbuf = Gtk.IconTheme.Default.LoadIcon("gtk-close", 16, 0);
                     w69.Events = ((Gdk.EventMask)(0));
                     w69.Name = "image6";
                     bindings["image6"] = w69;
                     w68.Add(w69);
                     // Container child GtkHBox.Gtk.Container+ContainerChild
                     Gtk.Label w71 = new Gtk.Label();
                     w71.LabelProp = "Close";
                     w71.Events = ((Gdk.EventMask)(0));
                     w71.Name = "GtkLabel";
                     bindings["GtkLabel"] = w71;
                     w68.Add(w71);
                     bindings["GtkHBox"] = w68;
                     w67.Add(w68);
                     bindings["GtkAlignment"] = w67;
                     w66.Add(w67);
                     bindings["buttonClose"] = w66;
                     w65.Add(w66);
                     Gtk.ButtonBox.ButtonBoxChild w75 = ((Gtk.ButtonBox.ButtonBoxChild)(w65[w66]));
                     w75.Expand = false;
                     w75.Fill = false;
                     bindings["hbuttonbox1"] = w65;
                     w17.Add(w65);
                     Gtk.Box.BoxChild w76 = ((Gtk.Box.BoxChild)(w17[w65]));
                     w76.Position = 7;
                     w76.Expand = false;
                     w76.Fill = false;
                     bindings["vbox1"] = w17;
                     cobj.Add(w17);
                     cobj.DefaultHeight = 480;
                     bindings["SharpTranslator.MainWindow"] = cobj;
                     w18.Show();
                     w20.Show();
                     w22.Show();
                     w25.Show();
                     w24.Show();
                     w29.Show();
                     w31.Show();
                     w37.Show();
                     w39.Show();
                     w36.Show();
                     w35.Show();
                     w33.Show();
                     w28.Show();
                     w46.Show();
                     w48.Show();
                     w53.Show();
                     w55.Show();
                     w52.Show();
                     w51.Show();
                     w50.Show();
                     w60.Show();
                     w45.Show();
                     w63.Show();
                     w69.Show();
                     w71.Show();
                     w68.Show();
                     w67.Show();
                     w66.Show();
                     w65.Show();
                     w17.Show();
                     cobj.Show();
                     cobj.DeleteEvent += ((Gtk.DeleteEventHandler)(System.Delegate.CreateDelegate(typeof(Gtk.DeleteEventHandler), cobj, "OnDeleteEvent")));
                     w5.Activated += ((System.EventHandler)(System.Delegate.CreateDelegate(typeof(System.EventHandler), cobj, "OnLearn")));
                     w7.Activated += ((System.EventHandler)(System.Delegate.CreateDelegate(typeof(System.EventHandler), cobj, "OnLearn")));
                     w13.Activated += ((System.EventHandler)(System.Delegate.CreateDelegate(typeof(System.EventHandler), cobj, "OnAbout")));
                     w16.Activated += ((System.EventHandler)(System.Delegate.CreateDelegate(typeof(System.EventHandler), cobj, "OnClose")));
                     w31.Activated += ((System.EventHandler)(System.Delegate.CreateDelegate(typeof(System.EventHandler), cobj, "OnSearch")));
                     w33.Clicked += ((System.EventHandler)(System.Delegate.CreateDelegate(typeof(System.EventHandler), cobj, "OnSearch")));
                     w48.Activated += ((System.EventHandler)(System.Delegate.CreateDelegate(typeof(System.EventHandler), cobj, "OnSearchExpression")));
                     w50.Clicked += ((System.EventHandler)(System.Delegate.CreateDelegate(typeof(System.EventHandler), cobj, "OnSearchExpression")));
                     w60.Clicked += ((System.EventHandler)(System.Delegate.CreateDelegate(typeof(System.EventHandler), cobj, "OnShowAll")));
                     w66.Clicked += ((System.EventHandler)(System.Delegate.CreateDelegate(typeof(System.EventHandler), cobj, "OnClose")));
                 }
             }
         }
     }
     System.Reflection.FieldInfo[] fields = obj.GetType().GetFields(((System.Reflection.BindingFlags.Public | System.Reflection.BindingFlags.NonPublic) | System.Reflection.BindingFlags.Instance));
     for (int n = 0; (n < fields.Length); n = (n + 1)) {
         System.Reflection.FieldInfo field = fields[n];
         object widget = bindings[field.Name];
         if (((widget != null) && field.FieldType.IsInstanceOfType(widget))) {
             field.SetValue(obj, widget);
         }
     }
 }
Esempio n. 50
0
        public GroupChatView(GroupChatModel groupChat)
            : base(groupChat)
        {
            Trace.Call(groupChat);

            _GroupChatModel = groupChat;

            // person list
            Participants = new List<PersonModel>();
            _OutputHPaned = new Gtk.HPaned();

            Gtk.TreeView tv = new Gtk.TreeView();
            _PersonTreeView = tv;
            Gtk.ScrolledWindow sw = new Gtk.ScrolledWindow();
            PersonScrolledWindow = sw;
            sw.ShadowType = Gtk.ShadowType.None;
            sw.HscrollbarPolicy = Gtk.PolicyType.Never;

            //tv.CanFocus = false;
            tv.BorderWidth = 0;
            tv.Selection.Mode = Gtk.SelectionMode.Multiple;
            sw.Add(tv);

            Gtk.TreeViewColumn column;
            var cellr = new Gtk.CellRendererText() {
                Ellipsize = Pango.EllipsizeMode.End
            };
            IdentityNameCellRenderer = cellr;
            column = new Gtk.TreeViewColumn(String.Empty, cellr);
            column.SortColumnId = 0;
            column.Spacing = 0;
            column.SortIndicator = false;
            column.Expand = true;
            column.Sizing = Gtk.TreeViewColumnSizing.Autosize;
            // FIXME: this callback leaks memory
            column.SetCellDataFunc(cellr, new Gtk.TreeCellDataFunc(RenderPersonIdentityName));
            tv.AppendColumn(column);
            _IdentityNameColumn = column;

            Gtk.ListStore liststore = new Gtk.ListStore(typeof(PersonModel));
            liststore.SetSortColumnId(0, Gtk.SortType.Ascending);
            liststore.SetSortFunc(0, new Gtk.TreeIterCompareFunc(SortPersonListStore));
            _PersonListStore = liststore;

            tv.Model = liststore;
            tv.SearchColumn = 0;
            tv.SearchEqualFunc = (model, col, key, iter) => {
                var person = (PersonModel) model.GetValue(iter, col);
                // Ladies and gentlemen welcome to C
                // 0 means it matched but 0 as bool is false. So if it matches
                // we have to return false. Still not clear? true is false and
                // false is true, weirdo! If you think this is retarded,
                // yes it is.
                return !person.IdentityName.StartsWith(key, StringComparison.InvariantCultureIgnoreCase);
            };
            tv.EnableSearch = true;
            tv.HeadersVisible = false;
            tv.RowActivated += new Gtk.RowActivatedHandler(OnPersonsRowActivated);
            tv.FocusOutEvent += OnPersonTreeViewFocusOutEvent;

            // popup menu
            _PersonMenu = new Gtk.Menu();
            // don't loose the focus else we lose the selection too!
            // see OnPersonTreeViewFocusOutEvent()
            _PersonMenu.TakeFocus = false;
            _PersonMenu.Shown += OnPersonMenuShown;

            _PersonTreeView.ButtonPressEvent += _OnPersonTreeViewButtonPressEvent;
            _PersonTreeView.KeyPressEvent += OnPersonTreeViewKeyPressEvent;
            // frame needed for events when selecting something in the treeview
            _PersonTreeViewFrame = new Gtk.Frame() {
                ShadowType = Gtk.ShadowType.In
            };
            _PersonTreeViewFrame.ButtonReleaseEvent += new Gtk.ButtonReleaseEventHandler(_OnUserListButtonReleaseEvent);
            _PersonTreeViewFrame.Add(sw);

            // topic
            // don't worry, ApplyConfig() will add us to the OutputVBox!
            _OutputVBox = new Gtk.VBox() {
                Spacing = 1
            };

            _TopicTextView = new MessageTextView();
            _TopicTextView.Editable = false;
            _TopicTextView.WrapMode = Gtk.WrapMode.WordChar;
            _TopicScrolledWindow = new Gtk.ScrolledWindow();
            _TopicScrolledWindow.ShadowType = Gtk.ShadowType.In;
            _TopicScrolledWindow.HscrollbarPolicy = Gtk.PolicyType.Never;
            _TopicScrolledWindow.Add(_TopicTextView);
            // make sure the topic is invisible and remains by default and
            // visible when a topic gets set
            _TopicScrolledWindow.ShowAll();
            _TopicScrolledWindow.Visible = false;
            _TopicScrolledWindow.NoShowAll = true;
            _TopicScrolledWindow.SizeRequested += delegate(object o, Gtk.SizeRequestedArgs args) {
                // predict and set useful topic heigth
                int lineWidth, lineHeight;
                using (var layout = _TopicTextView.CreatePangoLayout("Test Topic")) {
                    layout.GetPixelSize(out lineWidth, out lineHeight);
                }
                var lineSpacing = _TopicTextView.PixelsAboveLines +
                                  _TopicTextView.PixelsBelowLines;
                var it = _TopicTextView.Buffer.StartIter;
                int newLines = 1;
                // move to end of next visual line
                while (_TopicTextView.ForwardDisplayLineEnd(ref it)) {
                    newLines++;
                    // calling ForwardDisplayLineEnd repeatedly stays on the same position
                    // therefor we move one cursor position further
                    it.ForwardCursorPosition();
                }
                newLines = Math.Min(newLines, 3);
                var bestSize = new Gtk.Requisition() {
                    Height = ((lineHeight + lineSpacing) * newLines) + 4
                };
                args.Requisition = bestSize;
            };

            Add(_OutputHPaned);

            //ApplyConfig(Frontend.UserConfig);

            ShowAll();
        }
Esempio n. 51
0
		protected Gtk.Widget SetupOverviewPage()
		{
			var box = new Gtk.VBox();

			var btnBox = new Gtk.HBox();
			box.PackStart(btnBox, false, true, 2);

			addNoteBtn = new Gtk.Button()
			{
				Label = "Add note",
				HeightRequest = 25,
			};
			addNoteBtn.Clicked += OnAddNoteBtnClicked;
			btnBox.PackStart(addNoteBtn, true, true, 0);

			saveNoteBtn = new Gtk.Button()
			{
				Label = "Save note",
				HeightRequest = 25,
			};
			saveNoteBtn.Clicked += OnSaveNoteBtnClicked;
			btnBox.PackStart(saveNoteBtn, true, true, 0);

			rmNoteBtn = new Gtk.Button()
			{
				Label = "Remove note",
				HeightRequest = 25,
			};
			rmNoteBtn.Clicked += OnRmNoteBtnClicked;
			btnBox.PackStart(rmNoteBtn, true, true, 0);

			listView = new Gtk.NodeView(noteStore);
			listView.AppendColumn("Title", new Gtk.CellRendererText(), "text", 0);
			listView.AppendColumn("Created", new Gtk.CellRendererText(), "text", 1);
			listView.HeadersVisible = true;
			listView.NodeSelection.Changed += OnListViewNodeSelectionChanged;

			var listViewScrollable = new Gtk.ScrolledWindow();
			listViewScrollable.Add(listView);
			box.PackStart(listViewScrollable, true, true, 2);

			var separator = new Gtk.HSeparator();
			box.PackStart(separator, false, false, 2);

			noteView = new Gtk.TextView();

			var noteViewScrollable = new Gtk.ScrolledWindow();
			noteViewScrollable.Add(noteView);
			box.PackStart(noteViewScrollable, true, true, 2);

			return box;
		}
Esempio n. 52
0
 public static void Build(object obj, string id)
 {
     System.Collections.Hashtable bindings = new System.Collections.Hashtable();
     if ((id == "Boxerp.Client.GtkSharp.Lib.QuestionDialog")) {
         Gtk.Dialog cobj = ((Gtk.Dialog)(obj));
         // Widget Boxerp.Client.GtkSharp.Lib.QuestionDialog
         cobj.Title = "Question";
         cobj.WindowPosition = ((Gtk.WindowPosition)(4));
         cobj.Modal = true;
         cobj.HasSeparator = false;
         cobj.Events = ((Gdk.EventMask)(256));
         cobj.Name = "Boxerp.Client.GtkSharp.Lib.QuestionDialog";
         // Internal child Boxerp.Client.GtkSharp.Lib.QuestionDialog.VBox
         Gtk.VBox w1 = cobj.VBox;
         w1.BorderWidth = ((uint)(2));
         w1.Events = ((Gdk.EventMask)(256));
         w1.Name = "dialog_VBox";
         // Container child dialog_VBox.Gtk.Box+BoxChild
         Gtk.HBox w2 = new Gtk.HBox();
         w2.Events = ((Gdk.EventMask)(0));
         w2.Name = "hbox1";
         // Container child hbox1.Gtk.Box+BoxChild
         Gtk.Image w3 = new Gtk.Image();
         w3.Pixbuf = Gtk.IconTheme.Default.LoadIcon("gtk-dialog-info", 16, 0);
         w3.Events = ((Gdk.EventMask)(0));
         w3.Name = "image";
         bindings["image"] = w3;
         w2.Add(w3);
         Gtk.Box.BoxChild w4 = ((Gtk.Box.BoxChild)(w2[w3]));
         w4.Position = 0;
         w4.Expand = false;
         w4.Fill = false;
         w4.Padding = ((uint)(5));
         // Container child hbox1.Gtk.Box+BoxChild
         Gtk.Label w5 = new Gtk.Label();
         w5.LabelProp = "Info";
         w5.Events = ((Gdk.EventMask)(0));
         w5.Name = "label";
         bindings["label"] = w5;
         w2.Add(w5);
         Gtk.Box.BoxChild w6 = ((Gtk.Box.BoxChild)(w2[w5]));
         w6.Position = 1;
         bindings["hbox1"] = w2;
         w1.Add(w2);
         Gtk.Box.BoxChild w7 = ((Gtk.Box.BoxChild)(w1[w2]));
         w7.Position = 0;
         w7.Expand = false;
         w7.Fill = false;
         w7.Padding = ((uint)(5));
         bindings["dialog_VBox"] = w1;
         // Internal child Boxerp.Client.GtkSharp.Lib.QuestionDialog.ActionArea
         Gtk.HButtonBox w8 = cobj.ActionArea;
         w8.LayoutStyle = ((Gtk.ButtonBoxStyle)(4));
         w8.Spacing = 10;
         w8.BorderWidth = ((uint)(5));
         w8.Events = ((Gdk.EventMask)(256));
         w8.Name = "Boxerp.Client.GtkSharp.Lib.QuestionDialog_ActionArea";
         // Container child Boxerp.Client.GtkSharp.Lib.QuestionDialog_ActionArea.Gtk.ButtonBox+ButtonBoxChild
         Gtk.Button w9 = new Gtk.Button();
         w9.CanFocus = true;
         w9.Events = ((Gdk.EventMask)(0));
         w9.Name = "button22";
         w9.CanDefault = true;
         // Container child button22.Gtk.Container+ContainerChild
         Gtk.Alignment w10 = new Gtk.Alignment(0.5F, 0.5F, 0F, 0F);
         w10.Events = ((Gdk.EventMask)(0));
         w10.Name = "GtkAlignment";
         // Container child GtkAlignment.Gtk.Container+ContainerChild
         Gtk.HBox w11 = new Gtk.HBox();
         w11.Spacing = 2;
         w11.Events = ((Gdk.EventMask)(0));
         w11.Name = "GtkHBox";
         // Container child GtkHBox.Gtk.Container+ContainerChild
         Gtk.Image w12 = new Gtk.Image();
         w12.Pixbuf = Gtk.IconTheme.Default.LoadIcon("gtk-no", 16, 0);
         w12.Events = ((Gdk.EventMask)(0));
         w12.Name = "image2";
         bindings["image2"] = w12;
         w11.Add(w12);
         // Container child GtkHBox.Gtk.Container+ContainerChild
         Gtk.Label w14 = new Gtk.Label();
         w14.LabelProp = "No";
         w14.Events = ((Gdk.EventMask)(0));
         w14.Name = "GtkLabel";
         bindings["GtkLabel"] = w14;
         w11.Add(w14);
         bindings["GtkHBox"] = w11;
         w10.Add(w11);
         bindings["GtkAlignment"] = w10;
         w9.Add(w10);
         bindings["button22"] = w9;
         cobj.AddActionWidget(w9, -9);
         Gtk.ButtonBox.ButtonBoxChild w18 = ((Gtk.ButtonBox.ButtonBoxChild)(w8[w9]));
         w18.Expand = false;
         w18.Fill = false;
         // Container child Boxerp.Client.GtkSharp.Lib.QuestionDialog_ActionArea.Gtk.ButtonBox+ButtonBoxChild
         Gtk.Button w19 = new Gtk.Button();
         w19.CanFocus = true;
         w19.Events = ((Gdk.EventMask)(0));
         w19.Name = "button24";
         w19.CanDefault = true;
         // Container child button24.Gtk.Container+ContainerChild
         Gtk.Alignment w20 = new Gtk.Alignment(0.5F, 0.5F, 0F, 0F);
         w20.Events = ((Gdk.EventMask)(0));
         w20.Name = "GtkAlignment1";
         // Container child GtkAlignment1.Gtk.Container+ContainerChild
         Gtk.HBox w21 = new Gtk.HBox();
         w21.Spacing = 2;
         w21.Events = ((Gdk.EventMask)(0));
         w21.Name = "GtkHBox1";
         // Container child GtkHBox1.Gtk.Container+ContainerChild
         Gtk.Image w22 = new Gtk.Image();
         w22.Pixbuf = Gtk.IconTheme.Default.LoadIcon("gtk-yes", 16, 0);
         w22.Events = ((Gdk.EventMask)(0));
         w22.Name = "image3";
         bindings["image3"] = w22;
         w21.Add(w22);
         // Container child GtkHBox1.Gtk.Container+ContainerChild
         Gtk.Label w24 = new Gtk.Label();
         w24.LabelProp = "Yes";
         w24.Events = ((Gdk.EventMask)(0));
         w24.Name = "GtkLabel1";
         bindings["GtkLabel1"] = w24;
         w21.Add(w24);
         bindings["GtkHBox1"] = w21;
         w20.Add(w21);
         bindings["GtkAlignment1"] = w20;
         w19.Add(w20);
         bindings["button24"] = w19;
         cobj.AddActionWidget(w19, -8);
         Gtk.ButtonBox.ButtonBoxChild w28 = ((Gtk.ButtonBox.ButtonBoxChild)(w8[w19]));
         w28.Position = 1;
         w28.Expand = false;
         w28.Fill = false;
         bindings["Boxerp.Client.GtkSharp.Lib.QuestionDialog_ActionArea"] = w8;
         cobj.DefaultWidth = 400;
         cobj.DefaultHeight = 99;
         bindings["Boxerp.Client.GtkSharp.Lib.QuestionDialog"] = cobj;
         w3.Show();
         w5.Show();
         w2.Show();
         w1.Show();
         w12.Show();
         w14.Show();
         w11.Show();
         w10.Show();
         w9.Show();
         w22.Show();
         w24.Show();
         w21.Show();
         w20.Show();
         w19.Show();
         w8.Show();
         cobj.Show();
         w9.Clicked += ((System.EventHandler)(System.Delegate.CreateDelegate(typeof(System.EventHandler), cobj, "OnNo")));
         w19.Clicked += ((System.EventHandler)(System.Delegate.CreateDelegate(typeof(System.EventHandler), cobj, "OnYes")));
     }
     else {
         if ((id == "Boxerp.Client.GtkSharp.Lib.SimpleListView")) {
             Gtk.Bin cobj = ((Gtk.Bin)(obj));
             // Widget Boxerp.Client.GtkSharp.Lib.SimpleListView
             BinContainer.Attach(cobj);
             cobj.Events = ((Gdk.EventMask)(256));
             cobj.Name = "Boxerp.Client.GtkSharp.Lib.SimpleListView";
             // Container child Boxerp.Client.GtkSharp.Lib.SimpleListView.Gtk.Container+ContainerChild
             Gtk.TreeView w1 = new Gtk.TreeView();
             w1.CanFocus = true;
             w1.Events = ((Gdk.EventMask)(0));
             w1.Name = "treeview";
             bindings["treeview"] = w1;
             cobj.Add(w1);
             bindings["Boxerp.Client.GtkSharp.Lib.SimpleListView"] = cobj;
             w1.Show();
             cobj.Show();
         }
         else {
             if ((id == "Boxerp.Client.GtkSharp.Lib.WarningDialog")) {
                 Gtk.Dialog cobj = ((Gtk.Dialog)(obj));
                 // Widget Boxerp.Client.GtkSharp.Lib.WarningDialog
                 cobj.Title = "Warning";
                 cobj.Icon = Gtk.IconTheme.Default.LoadIcon("gtk-dialog-warning", 16, 0);
                 cobj.WindowPosition = ((Gtk.WindowPosition)(4));
                 cobj.HasSeparator = false;
                 cobj.Resizable = false;
                 cobj.AllowGrow = false;
                 cobj.DefaultWidth = 500;
                 cobj.Events = ((Gdk.EventMask)(256));
                 cobj.Name = "Boxerp.Client.GtkSharp.Lib.WarningDialog";
                 // Internal child Boxerp.Client.GtkSharp.Lib.WarningDialog.VBox
                 Gtk.VBox w1 = cobj.VBox;
                 w1.BorderWidth = ((uint)(2));
                 w1.Events = ((Gdk.EventMask)(256));
                 w1.Name = "dialog_VBox";
                 // Container child dialog_VBox.Gtk.Box+BoxChild
                 Gtk.HBox w2 = new Gtk.HBox();
                 w2.Spacing = 5;
                 w2.BorderWidth = ((uint)(5));
                 w2.Events = ((Gdk.EventMask)(0));
                 w2.Name = "hbox1";
                 // Container child hbox1.Gtk.Box+BoxChild
                 Gtk.Image w3 = new Gtk.Image();
                 w3.Pixbuf = Gtk.IconTheme.Default.LoadIcon("stock_dialog-warning", 16, 0);
                 w3.Events = ((Gdk.EventMask)(0));
                 w3.Name = "image";
                 bindings["image"] = w3;
                 w2.Add(w3);
                 Gtk.Box.BoxChild w4 = ((Gtk.Box.BoxChild)(w2[w3]));
                 w4.Position = 0;
                 w4.Expand = false;
                 w4.Fill = false;
                 // Container child hbox1.Gtk.Box+BoxChild
                 Gtk.Label w5 = new Gtk.Label();
                 w5.LabelProp = "Warning";
                 w5.Events = ((Gdk.EventMask)(0));
                 w5.Name = "label";
                 bindings["label"] = w5;
                 w2.Add(w5);
                 Gtk.Box.BoxChild w6 = ((Gtk.Box.BoxChild)(w2[w5]));
                 w6.Position = 1;
                 bindings["hbox1"] = w2;
                 w1.Add(w2);
                 Gtk.Box.BoxChild w7 = ((Gtk.Box.BoxChild)(w1[w2]));
                 w7.Position = 0;
                 w7.Expand = false;
                 w7.Fill = false;
                 bindings["dialog_VBox"] = w1;
                 // Internal child Boxerp.Client.GtkSharp.Lib.WarningDialog.ActionArea
                 Gtk.HButtonBox w8 = cobj.ActionArea;
                 w8.LayoutStyle = ((Gtk.ButtonBoxStyle)(4));
                 w8.Spacing = 10;
                 w8.BorderWidth = ((uint)(5));
                 w8.Events = ((Gdk.EventMask)(256));
                 w8.Name = "Boxerp.Client.GtkSharp.Lib.WarningDialog_ActionArea";
                 // Container child Boxerp.Client.GtkSharp.Lib.WarningDialog_ActionArea.Gtk.ButtonBox+ButtonBoxChild
                 Gtk.Button w9 = new Gtk.Button();
                 w9.CanFocus = true;
                 w9.Events = ((Gdk.EventMask)(0));
                 w9.Name = "buttonOk";
                 w9.CanDefault = true;
                 // Container child buttonOk.Gtk.Container+ContainerChild
                 Gtk.Alignment w10 = new Gtk.Alignment(0.5F, 0.5F, 0F, 0F);
                 w10.Events = ((Gdk.EventMask)(0));
                 w10.Name = "GtkAlignment";
                 // Container child GtkAlignment.Gtk.Container+ContainerChild
                 Gtk.HBox w11 = new Gtk.HBox();
                 w11.Spacing = 2;
                 w11.Events = ((Gdk.EventMask)(0));
                 w11.Name = "GtkHBox";
                 // Container child GtkHBox.Gtk.Container+ContainerChild
                 Gtk.Image w12 = new Gtk.Image();
                 w12.Pixbuf = Gtk.IconTheme.Default.LoadIcon("gtk-ok", 16, 0);
                 w12.Events = ((Gdk.EventMask)(0));
                 w12.Name = "image7";
                 bindings["image7"] = w12;
                 w11.Add(w12);
                 // Container child GtkHBox.Gtk.Container+ContainerChild
                 Gtk.Label w14 = new Gtk.Label();
                 w14.LabelProp = "Ok";
                 w14.Events = ((Gdk.EventMask)(0));
                 w14.Name = "GtkLabel";
                 bindings["GtkLabel"] = w14;
                 w11.Add(w14);
                 bindings["GtkHBox"] = w11;
                 w10.Add(w11);
                 bindings["GtkAlignment"] = w10;
                 w9.Add(w10);
                 bindings["buttonOk"] = w9;
                 cobj.AddActionWidget(w9, 0);
                 Gtk.ButtonBox.ButtonBoxChild w18 = ((Gtk.ButtonBox.ButtonBoxChild)(w8[w9]));
                 w18.Expand = false;
                 w18.Fill = false;
                 bindings["Boxerp.Client.GtkSharp.Lib.WarningDialog_ActionArea"] = w8;
                 cobj.DefaultHeight = 104;
                 bindings["Boxerp.Client.GtkSharp.Lib.WarningDialog"] = cobj;
                 w3.Show();
                 w5.Show();
                 w2.Show();
                 w1.Show();
                 w12.Show();
                 w14.Show();
                 w11.Show();
                 w10.Show();
                 w9.Show();
                 w8.Show();
                 cobj.Show();
                 w9.Clicked += ((System.EventHandler)(System.Delegate.CreateDelegate(typeof(System.EventHandler), cobj, "OnOk")));
             }
             else {
                 if ((id == "Boxerp.Client.GtkSharp.Lib.WaitWindow")) {
                     Gtk.Window cobj = ((Gtk.Window)(obj));
                     // Widget Boxerp.Client.GtkSharp.Lib.WaitWindow
                     cobj.Title = "Operation in progress...";
                     cobj.WindowPosition = ((Gtk.WindowPosition)(1));
                     cobj.Events = ((Gdk.EventMask)(0));
                     cobj.Name = "Boxerp.Client.GtkSharp.Lib.WaitWindow";
                     // Container child Boxerp.Client.GtkSharp.Lib.WaitWindow.Gtk.Container+ContainerChild
                     Gtk.VBox w1 = new Gtk.VBox();
                     w1.Spacing = 2;
                     w1.BorderWidth = ((uint)(5));
                     w1.Events = ((Gdk.EventMask)(256));
                     w1.Name = "vbox";
                     // Container child vbox.Gtk.Box+BoxChild
                     Gtk.Label w2 = new Gtk.Label();
                     w2.LabelProp = "Please wait";
                     w2.Events = ((Gdk.EventMask)(0));
                     w2.Name = "labelMsg";
                     bindings["labelMsg"] = w2;
                     w1.Add(w2);
                     Gtk.Box.BoxChild w3 = ((Gtk.Box.BoxChild)(w1[w2]));
                     w3.Position = 0;
                     // Container child vbox.Gtk.Box+BoxChild
                     Gtk.ProgressBar w4 = new Gtk.ProgressBar();
                     w4.Events = ((Gdk.EventMask)(0));
                     w4.Name = "progressbar";
                     bindings["progressbar"] = w4;
                     w1.Add(w4);
                     Gtk.Box.BoxChild w5 = ((Gtk.Box.BoxChild)(w1[w4]));
                     w5.Position = 1;
                     w5.Expand = false;
                     w5.Fill = false;
                     // Container child vbox.Gtk.Box+BoxChild
                     Gtk.HButtonBox w6 = new Gtk.HButtonBox();
                     w6.LayoutStyle = ((Gtk.ButtonBoxStyle)(2));
                     w6.Spacing = 10;
                     w6.BorderWidth = ((uint)(5));
                     w6.Events = ((Gdk.EventMask)(256));
                     w6.Name = "actionArea";
                     // Container child actionArea.Gtk.ButtonBox+ButtonBoxChild
                     Gtk.Button w7 = new Gtk.Button();
                     w7.CanFocus = true;
                     w7.Events = ((Gdk.EventMask)(0));
                     w7.Name = "button";
                     w7.CanDefault = true;
                     // Container child button.Gtk.Container+ContainerChild
                     Gtk.Alignment w8 = new Gtk.Alignment(0.5F, 0.5F, 0F, 0F);
                     w8.Events = ((Gdk.EventMask)(0));
                     w8.Name = "GtkAlignment";
                     // Container child GtkAlignment.Gtk.Container+ContainerChild
                     Gtk.HBox w9 = new Gtk.HBox();
                     w9.Spacing = 2;
                     w9.Events = ((Gdk.EventMask)(0));
                     w9.Name = "GtkHBox";
                     // Container child GtkHBox.Gtk.Container+ContainerChild
                     Gtk.Image w10 = new Gtk.Image();
                     w10.Pixbuf = Gtk.IconTheme.Default.LoadIcon("gtk-cancel", 16, 0);
                     w10.Events = ((Gdk.EventMask)(0));
                     w10.Name = "image1";
                     bindings["image1"] = w10;
                     w9.Add(w10);
                     // Container child GtkHBox.Gtk.Container+ContainerChild
                     Gtk.Label w12 = new Gtk.Label();
                     w12.LabelProp = "Cancel";
                     w12.Events = ((Gdk.EventMask)(0));
                     w12.Name = "GtkLabel";
                     bindings["GtkLabel"] = w12;
                     w9.Add(w12);
                     bindings["GtkHBox"] = w9;
                     w8.Add(w9);
                     bindings["GtkAlignment"] = w8;
                     w7.Add(w8);
                     bindings["button"] = w7;
                     w6.Add(w7);
                     Gtk.ButtonBox.ButtonBoxChild w16 = ((Gtk.ButtonBox.ButtonBoxChild)(w6[w7]));
                     w16.Expand = false;
                     w16.Fill = false;
                     bindings["actionArea"] = w6;
                     w1.Add(w6);
                     Gtk.Box.BoxChild w17 = ((Gtk.Box.BoxChild)(w1[w6]));
                     w17.Position = 2;
                     w17.Expand = false;
                     w17.Fill = false;
                     bindings["vbox"] = w1;
                     cobj.Add(w1);
                     cobj.DefaultWidth = 400;
                     cobj.DefaultHeight = 119;
                     bindings["Boxerp.Client.GtkSharp.Lib.WaitWindow"] = cobj;
                     w2.Show();
                     w4.Show();
                     w10.Show();
                     w12.Show();
                     w9.Show();
                     w8.Show();
                     w7.Show();
                     w6.Show();
                     w1.Show();
                     cobj.Show();
                     cobj.DeleteEvent += ((Gtk.DeleteEventHandler)(System.Delegate.CreateDelegate(typeof(Gtk.DeleteEventHandler), cobj, "OnDeleteEvent")));
                     w7.Clicked += ((System.EventHandler)(System.Delegate.CreateDelegate(typeof(System.EventHandler), cobj, "OnCancel")));
                 }
                 else {
                     if ((id == "Boxerp.Client.GtkSharp.Lib.WaitDialog")) {
                         Gtk.Dialog cobj = ((Gtk.Dialog)(obj));
                         // Widget Boxerp.Client.GtkSharp.Lib.WaitDialog
                         cobj.Title = "Operation in progress...";
                         cobj.WindowPosition = ((Gtk.WindowPosition)(1));
                         cobj.HasSeparator = false;
                         cobj.Events = ((Gdk.EventMask)(256));
                         cobj.Name = "Boxerp.Client.GtkSharp.Lib.WaitDialog";
                         // Internal child Boxerp.Client.GtkSharp.Lib.WaitDialog.VBox
                         Gtk.VBox w1 = cobj.VBox;
                         w1.Spacing = 2;
                         w1.BorderWidth = ((uint)(2));
                         w1.Events = ((Gdk.EventMask)(256));
                         w1.Name = "dialog_VBox";
                         // Container child dialog_VBox.Gtk.Box+BoxChild
                         Gtk.Label w2 = new Gtk.Label();
                         w2.LabelProp = "Please wait";
                         w2.Events = ((Gdk.EventMask)(0));
                         w2.Name = "labelMsg";
                         bindings["labelMsg"] = w2;
                         w1.Add(w2);
                         Gtk.Box.BoxChild w3 = ((Gtk.Box.BoxChild)(w1[w2]));
                         w3.Position = 0;
                         // Container child dialog_VBox.Gtk.Box+BoxChild
                         Gtk.ProgressBar w4 = new Gtk.ProgressBar();
                         w4.Events = ((Gdk.EventMask)(0));
                         w4.Name = "progressbar";
                         bindings["progressbar"] = w4;
                         w1.Add(w4);
                         Gtk.Box.BoxChild w5 = ((Gtk.Box.BoxChild)(w1[w4]));
                         w5.Position = 1;
                         w5.Expand = false;
                         w5.Fill = false;
                         bindings["dialog_VBox"] = w1;
                         // Internal child Boxerp.Client.GtkSharp.Lib.WaitDialog.ActionArea
                         Gtk.HButtonBox w6 = cobj.ActionArea;
                         w6.LayoutStyle = ((Gtk.ButtonBoxStyle)(2));
                         w6.Spacing = 10;
                         w6.BorderWidth = ((uint)(5));
                         w6.Events = ((Gdk.EventMask)(256));
                         w6.Name = "actionArea";
                         // Container child actionArea.Gtk.ButtonBox+ButtonBoxChild
                         Gtk.Button w7 = new Gtk.Button();
                         w7.CanFocus = true;
                         w7.Events = ((Gdk.EventMask)(0));
                         w7.Name = "button";
                         w7.CanDefault = true;
                         // Container child button.Gtk.Container+ContainerChild
                         Gtk.Alignment w8 = new Gtk.Alignment(0.5F, 0.5F, 0F, 0F);
                         w8.Events = ((Gdk.EventMask)(0));
                         w8.Name = "GtkAlignment";
                         // Container child GtkAlignment.Gtk.Container+ContainerChild
                         Gtk.HBox w9 = new Gtk.HBox();
                         w9.Spacing = 2;
                         w9.Events = ((Gdk.EventMask)(0));
                         w9.Name = "GtkHBox";
                         // Container child GtkHBox.Gtk.Container+ContainerChild
                         Gtk.Image w10 = new Gtk.Image();
                         w10.Pixbuf = Gtk.IconTheme.Default.LoadIcon("gtk-cancel", 16, 0);
                         w10.Events = ((Gdk.EventMask)(0));
                         w10.Name = "image8";
                         bindings["image8"] = w10;
                         w9.Add(w10);
                         // Container child GtkHBox.Gtk.Container+ContainerChild
                         Gtk.Label w12 = new Gtk.Label();
                         w12.LabelProp = "Cancel";
                         w12.Events = ((Gdk.EventMask)(0));
                         w12.Name = "GtkLabel";
                         bindings["GtkLabel"] = w12;
                         w9.Add(w12);
                         bindings["GtkHBox"] = w9;
                         w8.Add(w9);
                         bindings["GtkAlignment"] = w8;
                         w7.Add(w8);
                         bindings["button"] = w7;
                         cobj.AddActionWidget(w7, -7);
                         Gtk.ButtonBox.ButtonBoxChild w16 = ((Gtk.ButtonBox.ButtonBoxChild)(w6[w7]));
                         w16.Expand = false;
                         w16.Fill = false;
                         bindings["actionArea"] = w6;
                         cobj.DefaultWidth = 400;
                         cobj.DefaultHeight = 113;
                         bindings["Boxerp.Client.GtkSharp.Lib.WaitDialog"] = cobj;
                         w2.Show();
                         w4.Show();
                         w1.Show();
                         w10.Show();
                         w12.Show();
                         w9.Show();
                         w8.Show();
                         w7.Show();
                         w6.Show();
                         cobj.Show();
                         cobj.Close += ((System.EventHandler)(System.Delegate.CreateDelegate(typeof(System.EventHandler), cobj, "OnClose")));
                         cobj.DeleteEvent += ((Gtk.DeleteEventHandler)(System.Delegate.CreateDelegate(typeof(Gtk.DeleteEventHandler), cobj, "OnDeleteEvent")));
                         w7.Clicked += ((System.EventHandler)(System.Delegate.CreateDelegate(typeof(System.EventHandler), cobj, "OnCancel")));
                     }
                     else {
                         if ((id == "Boxerp.Client.GtkSharp.Lib.DoubleListView")) {
                             Gtk.Bin cobj = ((Gtk.Bin)(obj));
                             // Widget Boxerp.Client.GtkSharp.Lib.DoubleListView
                             BinContainer.Attach(cobj);
                             cobj.Events = ((Gdk.EventMask)(256));
                             cobj.Name = "Boxerp.Client.GtkSharp.Lib.DoubleListView";
                             // Container child Boxerp.Client.GtkSharp.Lib.DoubleListView.Gtk.Container+ContainerChild
                             Gtk.VBox w1 = new Gtk.VBox();
                             w1.Events = ((Gdk.EventMask)(0));
                             w1.Name = "vbox2";
                             // Container child vbox2.Gtk.Box+BoxChild
                             Gtk.HBox w2 = new Gtk.HBox();
                             w2.Events = ((Gdk.EventMask)(0));
                             w2.Name = "hbox2";
                             // Container child hbox2.Gtk.Box+BoxChild
                             Gtk.Label w3 = new Gtk.Label();
                             w3.LabelProp = "label1";
                             w3.Events = ((Gdk.EventMask)(0));
                             w3.Name = "labelLeft";
                             bindings["labelLeft"] = w3;
                             w2.Add(w3);
                             Gtk.Box.BoxChild w4 = ((Gtk.Box.BoxChild)(w2[w3]));
                             w4.Position = 0;
                             w4.Fill = false;
                             // Container child hbox2.Gtk.Box+BoxChild
                             Gtk.VSeparator w5 = new Gtk.VSeparator();
                             w5.Events = ((Gdk.EventMask)(0));
                             w5.Name = "vseparator1";
                             bindings["vseparator1"] = w5;
                             w2.Add(w5);
                             Gtk.Box.BoxChild w6 = ((Gtk.Box.BoxChild)(w2[w5]));
                             w6.Position = 1;
                             w6.Expand = false;
                             w6.Fill = false;
                             // Container child hbox2.Gtk.Box+BoxChild
                             Gtk.Label w7 = new Gtk.Label();
                             w7.LabelProp = "label2";
                             w7.Events = ((Gdk.EventMask)(0));
                             w7.Name = "labelRight";
                             bindings["labelRight"] = w7;
                             w2.Add(w7);
                             Gtk.Box.BoxChild w8 = ((Gtk.Box.BoxChild)(w2[w7]));
                             w8.Position = 2;
                             w8.Fill = false;
                             bindings["hbox2"] = w2;
                             w1.Add(w2);
                             Gtk.Box.BoxChild w9 = ((Gtk.Box.BoxChild)(w1[w2]));
                             w9.Position = 0;
                             w9.Expand = false;
                             // Container child vbox2.Gtk.Box+BoxChild
                             Gtk.HBox w10 = new Gtk.HBox();
                             w10.Spacing = 5;
                             w10.BorderWidth = ((uint)(5));
                             w10.Events = ((Gdk.EventMask)(0));
                             w10.Name = "hbox1";
                             // Container child hbox1.Gtk.Box+BoxChild
                             Gtk.ScrolledWindow w11 = new Gtk.ScrolledWindow();
                             w11.VscrollbarPolicy = ((Gtk.PolicyType)(1));
                             w11.HscrollbarPolicy = ((Gtk.PolicyType)(1));
                             w11.CanFocus = true;
                             w11.Events = ((Gdk.EventMask)(0));
                             w11.Name = "scrolledwindow1";
                             // Container child scrolledwindow1.Gtk.Container+ContainerChild
                             Gtk.Viewport w12 = new Gtk.Viewport();
                             w12.ShadowType = ((Gtk.ShadowType)(0));
                             w12.Events = ((Gdk.EventMask)(0));
                             w12.Name = "GtkViewport";
                             // Container child GtkViewport.Gtk.Container+ContainerChild
                             Boxerp.Client.GtkSharp.Lib.SimpleListView w13 = new Boxerp.Client.GtkSharp.Lib.SimpleListView();
                             w13.Events = ((Gdk.EventMask)(256));
                             w13.Name = "slistviewLeft";
                             bindings["slistviewLeft"] = w13;
                             w12.Add(w13);
                             bindings["GtkViewport"] = w12;
                             w11.Add(w12);
                             bindings["scrolledwindow1"] = w11;
                             w10.Add(w11);
                             Gtk.Box.BoxChild w16 = ((Gtk.Box.BoxChild)(w10[w11]));
                             w16.Position = 0;
                             // Container child hbox1.Gtk.Box+BoxChild
                             Gtk.VBox w17 = new Gtk.VBox();
                             w17.Homogeneous = true;
                             w17.Events = ((Gdk.EventMask)(0));
                             w17.Name = "vbox1";
                             // Container child vbox1.Gtk.Box+BoxChild
                             Gtk.Button w18 = new Gtk.Button();
                             w18.CanFocus = true;
                             w18.Events = ((Gdk.EventMask)(0));
                             w18.Name = "button5";
                             // Container child button5.Gtk.Container+ContainerChild
                             Gtk.Alignment w19 = new Gtk.Alignment(0.5F, 0.5F, 0F, 0F);
                             w19.Events = ((Gdk.EventMask)(0));
                             w19.Name = "GtkAlignment";
                             // Container child GtkAlignment.Gtk.Container+ContainerChild
                             Gtk.HBox w20 = new Gtk.HBox();
                             w20.Spacing = 2;
                             w20.Events = ((Gdk.EventMask)(0));
                             w20.Name = "GtkHBox";
                             // Container child GtkHBox.Gtk.Container+ContainerChild
                             Gtk.Image w21 = new Gtk.Image();
                             w21.Pixbuf = Gtk.IconTheme.Default.LoadIcon("stock_left", 16, 0);
                             w21.Events = ((Gdk.EventMask)(0));
                             w21.Name = "image5";
                             bindings["image5"] = w21;
                             w20.Add(w21);
                             // Container child GtkHBox.Gtk.Container+ContainerChild
                             Gtk.Label w23 = new Gtk.Label();
                             w23.LabelProp = "";
                             w23.Events = ((Gdk.EventMask)(0));
                             w23.Name = "GtkLabel";
                             bindings["GtkLabel"] = w23;
                             w20.Add(w23);
                             bindings["GtkHBox"] = w20;
                             w19.Add(w20);
                             bindings["GtkAlignment"] = w19;
                             w18.Add(w19);
                             bindings["button5"] = w18;
                             w17.Add(w18);
                             Gtk.Box.BoxChild w27 = ((Gtk.Box.BoxChild)(w17[w18]));
                             w27.Position = 1;
                             w27.Expand = false;
                             w27.Fill = false;
                             // Container child vbox1.Gtk.Box+BoxChild
                             Gtk.Button w28 = new Gtk.Button();
                             w28.CanFocus = true;
                             w28.Events = ((Gdk.EventMask)(0));
                             w28.Name = "button6";
                             // Container child button6.Gtk.Container+ContainerChild
                             Gtk.Alignment w29 = new Gtk.Alignment(0.5F, 0.5F, 0F, 0F);
                             w29.Events = ((Gdk.EventMask)(0));
                             w29.Name = "GtkAlignment";
                             // Container child GtkAlignment.Gtk.Container+ContainerChild
                             Gtk.HBox w30 = new Gtk.HBox();
                             w30.Spacing = 2;
                             w30.Events = ((Gdk.EventMask)(0));
                             w30.Name = "GtkHBox";
                             // Container child GtkHBox.Gtk.Container+ContainerChild
                             Gtk.Image w31 = new Gtk.Image();
                             w31.Pixbuf = Gtk.IconTheme.Default.LoadIcon("stock_right", 16, 0);
                             w31.Events = ((Gdk.EventMask)(0));
                             w31.Name = "image6";
                             bindings["image6"] = w31;
                             w30.Add(w31);
                             // Container child GtkHBox.Gtk.Container+ContainerChild
                             Gtk.Label w33 = new Gtk.Label();
                             w33.LabelProp = "";
                             w33.Events = ((Gdk.EventMask)(0));
                             w33.Name = "GtkLabel";
                             bindings["GtkLabel"] = w33;
                             w30.Add(w33);
                             bindings["GtkHBox"] = w30;
                             w29.Add(w30);
                             bindings["GtkAlignment"] = w29;
                             w28.Add(w29);
                             bindings["button6"] = w28;
                             w17.Add(w28);
                             Gtk.Box.BoxChild w37 = ((Gtk.Box.BoxChild)(w17[w28]));
                             w37.Position = 2;
                             w37.Expand = false;
                             w37.Fill = false;
                             bindings["vbox1"] = w17;
                             w10.Add(w17);
                             Gtk.Box.BoxChild w38 = ((Gtk.Box.BoxChild)(w10[w17]));
                             w38.Position = 1;
                             w38.Expand = false;
                             w38.Fill = false;
                             // Container child hbox1.Gtk.Box+BoxChild
                             Gtk.ScrolledWindow w39 = new Gtk.ScrolledWindow();
                             w39.VscrollbarPolicy = ((Gtk.PolicyType)(1));
                             w39.HscrollbarPolicy = ((Gtk.PolicyType)(1));
                             w39.CanFocus = true;
                             w39.Events = ((Gdk.EventMask)(0));
                             w39.Name = "scrolledwindow2";
                             // Container child scrolledwindow2.Gtk.Container+ContainerChild
                             Gtk.Viewport w40 = new Gtk.Viewport();
                             w40.ShadowType = ((Gtk.ShadowType)(0));
                             w40.Events = ((Gdk.EventMask)(0));
                             w40.Name = "GtkViewport1";
                             // Container child GtkViewport1.Gtk.Container+ContainerChild
                             Boxerp.Client.GtkSharp.Lib.SimpleListView w41 = new Boxerp.Client.GtkSharp.Lib.SimpleListView();
                             w41.Events = ((Gdk.EventMask)(256));
                             w41.Name = "slistviewRight";
                             bindings["slistviewRight"] = w41;
                             w40.Add(w41);
                             bindings["GtkViewport1"] = w40;
                             w39.Add(w40);
                             bindings["scrolledwindow2"] = w39;
                             w10.Add(w39);
                             Gtk.Box.BoxChild w44 = ((Gtk.Box.BoxChild)(w10[w39]));
                             w44.PackType = ((Gtk.PackType)(1));
                             w44.Position = 2;
                             bindings["hbox1"] = w10;
                             w1.Add(w10);
                             Gtk.Box.BoxChild w45 = ((Gtk.Box.BoxChild)(w1[w10]));
                             w45.Position = 1;
                             bindings["vbox2"] = w1;
                             cobj.Add(w1);
                             bindings["Boxerp.Client.GtkSharp.Lib.DoubleListView"] = cobj;
                             w3.Show();
                             w5.Show();
                             w7.Show();
                             w2.Show();
                             w13.Show();
                             w12.Show();
                             w11.Show();
                             w21.Show();
                             w23.Show();
                             w20.Show();
                             w19.Show();
                             w18.Show();
                             w31.Show();
                             w33.Show();
                             w30.Show();
                             w29.Show();
                             w28.Show();
                             w17.Show();
                             w41.Show();
                             w40.Show();
                             w39.Show();
                             w10.Show();
                             w1.Show();
                             cobj.Show();
                             w18.Clicked += ((System.EventHandler)(System.Delegate.CreateDelegate(typeof(System.EventHandler), cobj, "OnLeftClicked")));
                             w28.Clicked += ((System.EventHandler)(System.Delegate.CreateDelegate(typeof(System.EventHandler), cobj, "OnRightClicked")));
                         }
                         else {
                             if ((id == "Boxerp.Client.GtkSharp.Lib.InfoDialog")) {
                                 Gtk.Dialog cobj = ((Gtk.Dialog)(obj));
                                 // Widget Boxerp.Client.GtkSharp.Lib.InfoDialog
                                 cobj.Title = "Info";
                                 cobj.WindowPosition = ((Gtk.WindowPosition)(4));
                                 cobj.HasSeparator = false;
                                 cobj.Events = ((Gdk.EventMask)(256));
                                 cobj.Name = "Boxerp.Client.GtkSharp.Lib.InfoDialog";
                                 // Internal child Boxerp.Client.GtkSharp.Lib.InfoDialog.VBox
                                 Gtk.VBox w1 = cobj.VBox;
                                 w1.BorderWidth = ((uint)(2));
                                 w1.Events = ((Gdk.EventMask)(256));
                                 w1.Name = "dialog_VBox";
                                 // Container child dialog_VBox.Gtk.Box+BoxChild
                                 Gtk.HBox w2 = new Gtk.HBox();
                                 w2.Spacing = 5;
                                 w2.BorderWidth = ((uint)(5));
                                 w2.Events = ((Gdk.EventMask)(0));
                                 w2.Name = "hbox1";
                                 // Container child hbox1.Gtk.Box+BoxChild
                                 Gtk.Image w3 = new Gtk.Image();
                                 w3.Pixbuf = Gtk.IconTheme.Default.LoadIcon("gtk-dialog-info", 16, 0);
                                 w3.Events = ((Gdk.EventMask)(0));
                                 w3.Name = "image";
                                 bindings["image"] = w3;
                                 w2.Add(w3);
                                 Gtk.Box.BoxChild w4 = ((Gtk.Box.BoxChild)(w2[w3]));
                                 w4.Position = 0;
                                 w4.Expand = false;
                                 w4.Fill = false;
                                 // Container child hbox1.Gtk.Box+BoxChild
                                 Gtk.Label w5 = new Gtk.Label();
                                 w5.LabelProp = "Info";
                                 w5.Events = ((Gdk.EventMask)(0));
                                 w5.Name = "label";
                                 bindings["label"] = w5;
                                 w2.Add(w5);
                                 Gtk.Box.BoxChild w6 = ((Gtk.Box.BoxChild)(w2[w5]));
                                 w6.Position = 1;
                                 bindings["hbox1"] = w2;
                                 w1.Add(w2);
                                 Gtk.Box.BoxChild w7 = ((Gtk.Box.BoxChild)(w1[w2]));
                                 w7.Position = 0;
                                 w7.Expand = false;
                                 w7.Fill = false;
                                 bindings["dialog_VBox"] = w1;
                                 // Internal child Boxerp.Client.GtkSharp.Lib.InfoDialog.ActionArea
                                 Gtk.HButtonBox w8 = cobj.ActionArea;
                                 w8.LayoutStyle = ((Gtk.ButtonBoxStyle)(4));
                                 w8.Spacing = 10;
                                 w8.BorderWidth = ((uint)(5));
                                 w8.Events = ((Gdk.EventMask)(256));
                                 w8.Name = "Boxerp.Client.GtkSharp.Lib.InfoDialog_ActionArea";
                                 // Container child Boxerp.Client.GtkSharp.Lib.InfoDialog_ActionArea.Gtk.ButtonBox+ButtonBoxChild
                                 Gtk.Button w9 = new Gtk.Button();
                                 w9.CanFocus = true;
                                 w9.Events = ((Gdk.EventMask)(0));
                                 w9.Name = "button35";
                                 w9.CanDefault = true;
                                 // Container child button35.Gtk.Container+ContainerChild
                                 Gtk.Alignment w10 = new Gtk.Alignment(0.5F, 0.5F, 0F, 0F);
                                 w10.Events = ((Gdk.EventMask)(0));
                                 w10.Name = "GtkAlignment";
                                 // Container child GtkAlignment.Gtk.Container+ContainerChild
                                 Gtk.HBox w11 = new Gtk.HBox();
                                 w11.Spacing = 2;
                                 w11.Events = ((Gdk.EventMask)(0));
                                 w11.Name = "GtkHBox";
                                 // Container child GtkHBox.Gtk.Container+ContainerChild
                                 Gtk.Image w12 = new Gtk.Image();
                                 w12.Pixbuf = Gtk.IconTheme.Default.LoadIcon("gtk-ok", 16, 0);
                                 w12.Events = ((Gdk.EventMask)(0));
                                 w12.Name = "image4";
                                 bindings["image4"] = w12;
                                 w11.Add(w12);
                                 // Container child GtkHBox.Gtk.Container+ContainerChild
                                 Gtk.Label w14 = new Gtk.Label();
                                 w14.LabelProp = "Ok";
                                 w14.Events = ((Gdk.EventMask)(0));
                                 w14.Name = "GtkLabel";
                                 bindings["GtkLabel"] = w14;
                                 w11.Add(w14);
                                 bindings["GtkHBox"] = w11;
                                 w10.Add(w11);
                                 bindings["GtkAlignment"] = w10;
                                 w9.Add(w10);
                                 bindings["button35"] = w9;
                                 cobj.AddActionWidget(w9, 0);
                                 Gtk.ButtonBox.ButtonBoxChild w18 = ((Gtk.ButtonBox.ButtonBoxChild)(w8[w9]));
                                 w18.Expand = false;
                                 w18.Fill = false;
                                 bindings["Boxerp.Client.GtkSharp.Lib.InfoDialog_ActionArea"] = w8;
                                 cobj.DefaultWidth = 400;
                                 cobj.DefaultHeight = 104;
                                 bindings["Boxerp.Client.GtkSharp.Lib.InfoDialog"] = cobj;
                                 w3.Show();
                                 w5.Show();
                                 w2.Show();
                                 w1.Show();
                                 w12.Show();
                                 w14.Show();
                                 w11.Show();
                                 w10.Show();
                                 w9.Show();
                                 w8.Show();
                                 cobj.Show();
                                 w9.Clicked += ((System.EventHandler)(System.Delegate.CreateDelegate(typeof(System.EventHandler), cobj, "OnOkClicked")));
                             }
                             else {
                                 if ((id == "button7")) {
                                     Gtk.Button cobj = ((Gtk.Button)(obj));
                                     // Widget button7
                                     cobj.CanFocus = true;
                                     cobj.Events = ((Gdk.EventMask)(0));
                                     cobj.Name = "button7";
                                     cobj.CanDefault = true;
                                     cobj.Label = "button7";
                                     bindings["button7"] = cobj;
                                     cobj.Show();
                                 }
                                 else {
                                     if ((id == "Boxerp.Client.GtkSharp.Lib.FilteredListView")) {
                                         Gtk.Bin cobj = ((Gtk.Bin)(obj));
                                         // Widget Boxerp.Client.GtkSharp.Lib.FilteredListView
                                         BinContainer.Attach(cobj);
                                         cobj.Events = ((Gdk.EventMask)(256));
                                         cobj.Name = "Boxerp.Client.GtkSharp.Lib.FilteredListView";
                                         // Container child Boxerp.Client.GtkSharp.Lib.FilteredListView.Gtk.Container+ContainerChild
                                         Gtk.TreeView w1 = new Gtk.TreeView();
                                         w1.CanFocus = true;
                                         w1.Events = ((Gdk.EventMask)(0));
                                         w1.Name = "treeview";
                                         bindings["treeview"] = w1;
                                         cobj.Add(w1);
                                         bindings["Boxerp.Client.GtkSharp.Lib.FilteredListView"] = cobj;
                                         w1.Show();
                                         cobj.Show();
                                     }
                                     else {
                                         if ((id == "Boxerp.Client.GtkSharp.Lib.SimpleTreeView")) {
                                             Gtk.Bin cobj = ((Gtk.Bin)(obj));
                                             // Widget Boxerp.Client.GtkSharp.Lib.SimpleTreeView
                                             BinContainer.Attach(cobj);
                                             cobj.Events = ((Gdk.EventMask)(256));
                                             cobj.Name = "Boxerp.Client.GtkSharp.Lib.SimpleTreeView";
                                             // Container child Boxerp.Client.GtkSharp.Lib.SimpleTreeView.Gtk.Container+ContainerChild
                                             Gtk.TreeView w1 = new Gtk.TreeView();
                                             w1.CanFocus = true;
                                             w1.Events = ((Gdk.EventMask)(0));
                                             w1.Name = "treeview";
                                             bindings["treeview"] = w1;
                                             cobj.Add(w1);
                                             bindings["Boxerp.Client.GtkSharp.Lib.SimpleTreeView"] = cobj;
                                             w1.Show();
                                             cobj.Show();
                                         }
                                         else {
                                             if ((id == "Boxerp.Client.GtkSharp.Lib.LoginWindow")) {
                                                 Gtk.Window cobj = ((Gtk.Window)(obj));
                                                 // Widget Boxerp.Client.GtkSharp.Lib.LoginWindow
                                                 cobj.Title = "LoginWindow";
                                                 cobj.WindowPosition = ((Gtk.WindowPosition)(4));
                                                 cobj.Events = ((Gdk.EventMask)(0));
                                                 cobj.Name = "Boxerp.Client.GtkSharp.Lib.LoginWindow";
                                                 cobj.DefaultWidth = 400;
                                                 cobj.DefaultHeight = 300;
                                                 bindings["Boxerp.Client.GtkSharp.Lib.LoginWindow"] = cobj;
                                                 cobj.Show();
                                             }
                                             else {
                                                 if ((id == "MainWindow")) {
                                                     Gtk.Window cobj = ((Gtk.Window)(obj));
                                                     // Widget MainWindow
                                                     cobj.Title = "MainWindow";
                                                     cobj.WindowPosition = ((Gtk.WindowPosition)(4));
                                                     cobj.Events = ((Gdk.EventMask)(0));
                                                     cobj.Name = "MainWindow";
                                                     cobj.DefaultWidth = 400;
                                                     cobj.DefaultHeight = 300;
                                                     bindings["MainWindow"] = cobj;
                                                     cobj.Show();
                                                     cobj.DeleteEvent += ((Gtk.DeleteEventHandler)(System.Delegate.CreateDelegate(typeof(Gtk.DeleteEventHandler), cobj, "OnDeleteEvent")));
                                                 }
                                                 else {
                                                     if ((id == "Boxerp.Client.GtkSharp.Lib.InfoExtendedDialog")) {
                                                         Gtk.Dialog cobj = ((Gtk.Dialog)(obj));
                                                         // Widget Boxerp.Client.GtkSharp.Lib.InfoExtendedDialog
                                                         cobj.Title = "InfoExtendedDialog";
                                                         cobj.WindowPosition = ((Gtk.WindowPosition)(4));
                                                         cobj.HasSeparator = false;
                                                         cobj.Events = ((Gdk.EventMask)(256));
                                                         cobj.Name = "Boxerp.Client.GtkSharp.Lib.InfoExtendedDialog";
                                                         // Internal child Boxerp.Client.GtkSharp.Lib.InfoExtendedDialog.VBox
                                                         Gtk.VBox w1 = cobj.VBox;
                                                         w1.BorderWidth = ((uint)(2));
                                                         w1.Events = ((Gdk.EventMask)(256));
                                                         w1.Name = "dialog_VBox";
                                                         bindings["dialog_VBox"] = w1;
                                                         // Internal child Boxerp.Client.GtkSharp.Lib.InfoExtendedDialog.ActionArea
                                                         Gtk.HButtonBox w2 = cobj.ActionArea;
                                                         w2.LayoutStyle = ((Gtk.ButtonBoxStyle)(4));
                                                         w2.Events = ((Gdk.EventMask)(256));
                                                         w2.Name = "Boxerp.Client.GtkSharp.Lib.InfoExtendedDialog_ActionArea";
                                                         // Container child Boxerp.Client.GtkSharp.Lib.InfoExtendedDialog_ActionArea.Gtk.ButtonBox+ButtonBoxChild
                                                         Gtk.Button w3 = new Gtk.Button();
                                                         w3.CanFocus = true;
                                                         w3.Events = ((Gdk.EventMask)(0));
                                                         w3.Name = "button6";
                                                         w3.CanDefault = true;
                                                         w3.Label = "button6";
                                                         bindings["button6"] = w3;
                                                         cobj.AddActionWidget(w3, 0);
                                                         Gtk.ButtonBox.ButtonBoxChild w4 = ((Gtk.ButtonBox.ButtonBoxChild)(w2[w3]));
                                                         w4.Expand = false;
                                                         w4.Fill = false;
                                                         bindings["Boxerp.Client.GtkSharp.Lib.InfoExtendedDialog_ActionArea"] = w2;
                                                         cobj.DefaultWidth = 400;
                                                         cobj.DefaultHeight = 300;
                                                         bindings["Boxerp.Client.GtkSharp.Lib.InfoExtendedDialog"] = cobj;
                                                         w1.Show();
                                                         w3.Show();
                                                         w2.Show();
                                                         cobj.Show();
                                                     }
                                                 }
                                             }
                                         }
                                     }
                                 }
                             }
                         }
                     }
                 }
             }
         }
     }
     System.Reflection.FieldInfo[] fields = obj.GetType().GetFields(((System.Reflection.BindingFlags.Public | System.Reflection.BindingFlags.NonPublic) | System.Reflection.BindingFlags.Instance));
     for (int n = 0; (n < fields.Length); n = (n + 1)) {
         System.Reflection.FieldInfo field = fields[n];
         object widget = bindings[field.Name];
         if (((widget != null) && field.FieldType.IsInstanceOfType(widget))) {
             field.SetValue(obj, widget);
         }
     }
 }
Esempio n. 53
0
 protected MultipleObjectViewer(IBroadcaster hub, string caption)
     : base(false, 0)
 {
     _hub = hub;
     // --- first line: caption and buttons
     Gtk.HBox hbxFirstLine = new Gtk.HBox(false, 2);
     // Caption label
     Gtk.Alignment labelAlign = new Gtk.Alignment(0F, 0F, 1F, 1F);
     labelAlign.Add(new Gtk.Label(caption));
     hbxFirstLine.PackStart(labelAlign, false, false, 0);
     hbxFirstLine.PackStart(new Gtk.Label(String.Empty), true, true, 0);
     // "Add" button
     Gtk.Image image = new Gtk.Image();
     image.Stock = Gtk.Stock.Add;
     _btnAdd = new Gtk.Button();
     _btnAdd.Add(image);
     _btnAdd.Relief = Gtk.ReliefStyle.None;
     _btnAdd.Clicked += new EventHandler(OnAddButtonClicked);
     _btnAdd.Sensitive = false;
     hbxFirstLine.PackStart(_btnAdd, false, false, 0);
     // "Edit" button
     image = new Gtk.Image();
     image.Stock = Gtk.Stock.JumpTo;
     _btnEdit = new Gtk.Button();
     _btnEdit.Add(image);
     _btnEdit.Relief = Gtk.ReliefStyle.None;
     _btnEdit.Clicked += new EventHandler(OnEditButtonClicked);
     _btnEdit.Sensitive = false;
     hbxFirstLine.PackStart(_btnEdit, false, false, 0);
     // "Delete" button
     image = new Gtk.Image();
     image.Stock = Gtk.Stock.Remove;
     _btnDelete = new Gtk.Button();
     _btnDelete.Add(image);
     _btnDelete.Relief = Gtk.ReliefStyle.None;
     _btnDelete.Clicked += new EventHandler(OnDeleteButtonClicked);
     _btnDelete.Sensitive = false;
     hbxFirstLine.PackStart(_btnDelete, false, false, 0);
     base.PackStart(hbxFirstLine, false, false, 0);
     // --- second line: element list
     _store = new Gtk.TreeStore(typeof(string));
     _tvList = new Gtk.TreeView();
     _tvList.HeadersVisible = false;
     _tvList.AppendColumn("", new Gtk.CellRendererText(), "text", 0);
     _tvList.Model = _store;
     _tvList.FocusInEvent += new Gtk.FocusInEventHandler(EnableButtons);
     _tvList.ButtonPressEvent += new Gtk.ButtonPressEventHandler(ListClickedHandler);
     Gtk.ScrolledWindow sw = new Gtk.ScrolledWindow();
     sw.ShadowType = Gtk.ShadowType.In;
     sw.Add(_tvList);
     base.PackStart(sw, true, true, 0);
     sw.Show();
 }
		internal void UpdateScrolledWindow ()
		{
			if (ParentWrapper == null)
				return;
			if (boundToScrollWindow) {
				if (!(Wrapped.Parent is Gtk.Viewport) && !(Wrapped.Parent is Gtk.ScrolledWindow)) {
					Gtk.ScrolledWindow scw = new Gtk.ScrolledWindow ();
					scw.HscrollbarPolicy = scw.VscrollbarPolicy = Gtk.PolicyType.Automatic;
					scw.ShadowType = Gtk.ShadowType.In;
					ScrolledWindow wrapper = (ScrolledWindow) ObjectWrapper.Create (Project, scw);
					ParentWrapper.ReplaceChild (Wrapped, scw, false);
					if (Wrapped.SetScrollAdjustments (null, null))
						scw.Add (Wrapped);
					else
						wrapper.AddWithViewport (Wrapped);
					Select ();
				}
			}
			else if (((Wrapped.Parent is Gtk.Viewport) || (Wrapped.Parent is Gtk.ScrolledWindow)) && ParentWrapper.ParentWrapper != null) {
				Gtk.Container parent = (Gtk.Container) Wrapped.Parent;
				parent.Remove (Wrapped);
				Container grandParent;
				if (parent is Gtk.Viewport) {
					parent = (Gtk.Container) parent.Parent;
					grandParent = Container.LookupParent (parent);
				}
				else
					grandParent = Container.LookupParent (parent);
				grandParent.ReplaceChild (parent, Wrapped, true);
			}
		}
		public InsertTimestampPreferences () : base (false, 12)
		{	
			// Get current values
			String dateFormat = (string) Preferences.Get (
				Preferences.INSERT_TIMESTAMP_FORMAT);

			DateTime now = DateTime.Now;

			// Label
			Gtk.Label label = new Gtk.Label (Catalog.GetString (
				"Choose one of the predefined formats " +
				"or use your own."));
			label.Wrap = true;
			label.Xalign = 0;
			PackStart (label);

			// Use Selected Format
			selected_radio = new Gtk.RadioButton (Catalog.GetString (
				"Use _Selected Format"));
			PackStart (selected_radio);

			// 1st column (visible): formatted date
			// 2nd column (not visible): date format
			store = new Gtk.ListStore (typeof (string),
				typeof (string));
			foreach (String format in formats)
				store.AppendValues (now.ToString (format), format);

			scroll = new Gtk.ScrolledWindow();
			scroll.ShadowType = Gtk.ShadowType.In;
			PackStart (scroll);

			tv = new Gtk.TreeView (store);
			tv.HeadersVisible = false;
			tv.AppendColumn ("Format", new Gtk.CellRendererText (),
				"text", 0);
			scroll.Add (tv);

			// Use Custom Format
			Gtk.HBox customBox = new Gtk.HBox (false, 12);
			PackStart (customBox);

			custom_radio = new Gtk.RadioButton (
				selected_radio, Catalog.GetString ("_Use Custom Format"));
			customBox.PackStart (custom_radio);

			custom_entry = new Gtk.Entry ();
			customBox.PackStart (custom_entry);

			IPropertyEditor entryEditor = Services.Factory.CreatePropertyEditorEntry (
				Preferences.INSERT_TIMESTAMP_FORMAT, custom_entry);
			entryEditor.Setup ();

			// Activate/deactivate widgets
			bool useCustom = true;
			Gtk.TreeIter iter;
			store.GetIterFirst (out iter);

			foreach (object[] row in store) {
				if (dateFormat.Equals (row[1])) {
					// Found format in list
					useCustom = false;
					break;
				}	
				store.IterNext (ref iter);
			}

			if (useCustom) {
				custom_radio.Active = true;
				scroll.Sensitive = false;
			} else {
				selected_radio.Active = true;
				custom_entry.Sensitive = false;
				tv.Selection.SelectIter (iter);
				Gtk.TreePath path = store.GetPath (iter);				
				tv.ScrollToCell (path, null, false, 0, 0);
			}

			// Register Toggled event for one radio button only
			selected_radio.Toggled += OnSelectedRadioToggled;
			tv.Selection.Changed += OnSelectionChanged;

			ShowAll ();
		}
Esempio n. 56
0
        public GroupChatView(GroupChatModel groupChat)
            : base(groupChat)
        {
            Trace.Call(groupChat);

            _GroupChatModel = groupChat;

            // person list
            _OutputHPaned = new Gtk.HPaned();

            Gtk.ScrolledWindow sw = new Gtk.ScrolledWindow();
            _PersonScrolledWindow = sw;
            //sw.WidthRequest = 150;
            sw.HscrollbarPolicy = Gtk.PolicyType.Never;

            Gtk.TreeView tv = new Gtk.TreeView();
            _PersonTreeView = tv;
            //tv.CanFocus = false;
            tv.BorderWidth = 0;
            tv.Selection.Mode = Gtk.SelectionMode.Multiple;
            sw.Add(tv);

            Gtk.TreeViewColumn column;
            Gtk.CellRendererText cellr = new Gtk.CellRendererText();
            cellr.WidthChars = 12;
            column = new Gtk.TreeViewColumn(String.Empty, cellr);
            column.SortColumnId = 0;
            column.Spacing = 0;
            column.SortIndicator = false;
            column.Sizing = Gtk.TreeViewColumnSizing.Autosize;
            column.SetCellDataFunc(cellr, new Gtk.TreeCellDataFunc(RenderPersonIdentityName));
            tv.AppendColumn(column);
            _IdentityNameColumn = column;

            Gtk.ListStore liststore = new Gtk.ListStore(typeof(PersonModel));
            liststore.SetSortColumnId(0, Gtk.SortType.Ascending);
            liststore.SetSortFunc(0, new Gtk.TreeIterCompareFunc(SortPersonListStore));
            _PersonListStore = liststore;

            tv.Model = liststore;
            tv.RowActivated += new Gtk.RowActivatedHandler(OnPersonsRowActivated);
            tv.FocusOutEvent += OnPersonTreeViewFocusOutEvent;

            // popup menu
            _PersonMenu = new Gtk.Menu();
            // don't loose the focus else we lose the selection too!
            // see OnPersonTreeViewFocusOutEvent()
            _PersonMenu.TakeFocus = false;
            _PersonMenu.Shown += OnPersonMenuShown;

            _PersonTreeView.ButtonPressEvent += _OnPersonTreeViewButtonPressEvent;
            _PersonTreeView.KeyPressEvent += OnPersonTreeViewKeyPressEvent;
            // frame needed for events when selecting something in the treeview
            _PersonTreeViewFrame = new Gtk.Frame();
            _PersonTreeViewFrame.ButtonReleaseEvent += new Gtk.ButtonReleaseEventHandler(_OnUserListButtonReleaseEvent);
            _PersonTreeViewFrame.Add(sw);

            // topic
            // don't worry, ApplyConfig() will add us to the OutputVBox!
            _OutputVBox = new Gtk.VBox();

            _TopicTextView = new MessageTextView();
            _TopicTextView.Editable = false;
            _TopicTextView.WrapMode = Gtk.WrapMode.WordChar;
            _TopicScrolledWindow = new Gtk.ScrolledWindow();
            _TopicScrolledWindow.ShadowType = Gtk.ShadowType.In;
            // when using PolicyType.Never, it will try to grow but never shrinks!
            _TopicScrolledWindow.HscrollbarPolicy = Gtk.PolicyType.Automatic;
            _TopicScrolledWindow.VscrollbarPolicy = Gtk.PolicyType.Automatic;
            _TopicScrolledWindow.Add(_TopicTextView);
            // make sure the topic is invisible and remains by default and
            // visible when a topic gets set
            _TopicScrolledWindow.ShowAll();
            _TopicScrolledWindow.Visible = false;
            _TopicScrolledWindow.NoShowAll = true;
            _TopicScrolledWindow.SizeRequested += delegate(object o, Gtk.SizeRequestedArgs args) {
                // predict and set useful topic heigth
                Pango.Layout layout = _TopicTextView.CreatePangoLayout("Test Topic");
                int lineWidth, lineHeigth;
                layout.GetPixelSize(out lineWidth, out lineHeigth);
                var lineSpacing = _TopicTextView.PixelsAboveLines +
                                  _TopicTextView.PixelsBelowLines;
                var text = Topic != null ? Topic.ToString() : String.Empty;
                // hardcoded to 2 lines for now
                var newLines = text.Length > 0 ? 2 : 0;
                var bestSize = new Gtk.Requisition() {
                    Height = ((lineHeigth + lineSpacing) * newLines) + 2
                };
                args.Requisition = bestSize;
            };

            Add(_OutputHPaned);

            //ApplyConfig(Frontend.UserConfig);

            ShowAll();
        }
Esempio n. 57
0
        public MainWindow()
            : base("Smuxi")
        {
            // restore window size / position
            int width, heigth;
            if (Frontend.FrontendConfig[Frontend.UIName + "/Interface/Width"] != null) {
                width  = (int) Frontend.FrontendConfig[Frontend.UIName + "/Interface/Width"];
            } else {
                width = 800;
            }
            if (Frontend.FrontendConfig[Frontend.UIName + "/Interface/Heigth"] != null) {
                heigth = (int) Frontend.FrontendConfig[Frontend.UIName + "/Interface/Heigth"];
            } else {
                heigth = 600;
            }
            if (width < -1 || heigth < -1) {
                width = -1;
                heigth = -1;
            }
            if (width == -1 && heigth == -1) {
                SetDefaultSize(800, 600);
                Maximize();
            } else if (width == 0 && heigth == 0) {
                // HACK: map 0/0 to default size as it crashes on Windows :/
                SetDefaultSize(800, 600);
            } else {
                SetDefaultSize(width, heigth);
            }

            int x, y;
            if (Frontend.FrontendConfig[Frontend.UIName + "/Interface/XPosition"] != null) {
                x = (int) Frontend.FrontendConfig[Frontend.UIName + "/Interface/XPosition"];
            } else {
                x = 0;
            }
            if (Frontend.FrontendConfig[Frontend.UIName + "/Interface/YPosition"] != null) {
                y = (int) Frontend.FrontendConfig[Frontend.UIName + "/Interface/YPosition"];
            } else {
                y = 0;
            }
            if (x < 0 || y < 0) {
                x = 0;
                y = 0;
            }
            if (x == 0 && y == 0) {
                SetPosition(Gtk.WindowPosition.Center);
            } else {
                Move(x, y);
            }

            DeleteEvent += OnDeleteEvent;
            FocusInEvent += OnFocusInEvent;
            FocusOutEvent += OnFocusOutEvent;
            WindowStateEvent += OnWindowStateEvent;

            ChatTreeView = new ChatTreeView();

            Notebook = new Notebook();
            Notebook.SwitchPage += OnNotebookSwitchPage;
            Notebook.FocusInEvent += OnNotebookFocusInEvent;

            ChatViewManager = new ChatViewManager(Notebook, ChatTreeView);
            Assembly asm = Assembly.GetExecutingAssembly();
            ChatViewManager.Load(asm);
            ChatViewManager.LoadAll(System.IO.Path.GetDirectoryName(asm.Location),
                                     "smuxi-frontend-gnome-*.dll");
            ChatViewManager.ChatAdded += OnChatViewManagerChatAdded;
            ChatViewManager.ChatSynced += OnChatViewManagerChatSynced;
            ChatViewManager.ChatRemoved += OnChatViewManagerChatRemoved;

            #if GTK_SHARP_2_10
            StatusIconManager = new StatusIconManager(this, ChatViewManager);
            #endif
            #if INDICATE_SHARP || MESSAGING_MENU_SHARP
            IndicateManager = new IndicateManager(this, ChatViewManager);
            #endif
            #if NOTIFY_SHARP
            NotifyManager = new NotifyManager(this, ChatViewManager);
            #endif
            #if IPC_DBUS
            NetworkManager = new NetworkManager(ChatViewManager);
            #endif

            UI = new GnomeUI(ChatViewManager);

            // HACK: Frontend.FrontendConfig out of scope
            EngineManager = new EngineManager(Frontend.FrontendConfig, UI);

            Entry = new Entry(ChatViewManager);
            var entryScrolledWindow = new Gtk.ScrolledWindow();
            entryScrolledWindow.ShadowType = Gtk.ShadowType.EtchedIn;
            entryScrolledWindow.HscrollbarPolicy = Gtk.PolicyType.Never;
            entryScrolledWindow.SizeRequested += delegate(object o, Gtk.SizeRequestedArgs args) {
                // predict and set useful heigth
                int lineWidth, lineHeigth;
                using (var layout = Entry.CreatePangoLayout("Qp")) {
                    layout.GetPixelSize(out lineHeigth, out lineHeigth);
                }
                var it = Entry.Buffer.StartIter;
                int newLines = 1;
                // move to end of next visual line
                while (Entry.ForwardDisplayLineEnd(ref it)) {
                    newLines++;
                    // calling ForwardDisplayLineEnd repeatedly stays on the same position
                    // therefor we move one cursor position further
                    it.ForwardCursorPosition();
                }
                newLines = Math.Min(newLines, 3);
                // use text heigth + a bit extra
                var bestSize = new Gtk.Requisition() {
                    Height = (lineHeigth * newLines) + 5
                };
                args.Requisition = bestSize;
            };
            entryScrolledWindow.Add(Entry);

            ProgressBar = new Gtk.ProgressBar();
            StatusHBox = new Gtk.HBox();

            MenuWidget = new MenuWidget(this, ChatViewManager);

            var treeviewScrolledWindow = new Gtk.ScrolledWindow() {
                ShadowType = Gtk.ShadowType.EtchedIn,
                HscrollbarPolicy = Gtk.PolicyType.Never,
                VscrollbarPolicy = Gtk.PolicyType.Automatic
            };
            treeviewScrolledWindow.Add(ChatTreeView);
            ChatViewManager.ChatAdded += (sender, e) => {
                treeviewScrolledWindow.CheckResize();
            };

            var notebookPaned = new Gtk.VPaned();
            notebookPaned.Pack1(Notebook, true, false);
            notebookPaned.Pack2(entryScrolledWindow, false, false);

            var treeviewPaned = new Gtk.HPaned();
            treeviewPaned.Pack1(treeviewScrolledWindow, false, false);
            treeviewPaned.Pack2(notebookPaned, true, false);
            TreeViewHPaned = treeviewPaned;

            var entryPaned = new Gtk.VPaned();
            entryPaned.ButtonPressEvent += (sender, e) => {
                // reset entry size on double click
                if (e.Event.Type == Gdk.EventType.TwoButtonPress &&
                    e.Event.Button == 1) {
                    GLib.Timeout.Add(100, delegate {
                        entryPaned.Position = -1;
                        return false;
                    });
                }
            };
            entryPaned.Pack1(treeviewPaned, true, false);

            Gtk.VBox vbox = new Gtk.VBox();
            vbox.PackStart(MenuWidget, false, false, 0);
            vbox.PackStart(entryPaned, true, true, 0);

            NetworkStatusbar = new Gtk.Statusbar();
            NetworkStatusbar.WidthRequest = 300;
            NetworkStatusbar.HasResizeGrip = false;

            Statusbar = new Gtk.Statusbar();
            Statusbar.HasResizeGrip = false;

            Gtk.HBox status_bar_hbox = new Gtk.HBox();
            status_bar_hbox.Homogeneous = true;
            status_bar_hbox.PackStart(NetworkStatusbar, false, true, 0);
            status_bar_hbox.PackStart(Statusbar, true, true, 0);

            StatusHBox.PackStart(status_bar_hbox);
            StatusHBox.PackStart(ProgressBar, false, false, 0);
            StatusHBox.ShowAll();
            StatusHBox.NoShowAll = true;
            StatusHBox.Visible = (bool) Frontend.FrontendConfig["ShowStatusBar"];

            vbox.PackStart(StatusHBox, false, false, 0);
            Add(vbox);
        }
Esempio n. 58
0
		public FeedbackDialog (int x, int y): base (Gtk.WindowType.Toplevel)
		{
			SetDefaultSize (350, 200);
			if (x == -1 && y == -1) {
				int ww, wh;
				IdeApp.Workbench.RootWindow.GdkWindow.GetSize (out ww, out wh);
				IdeApp.Workbench.RootWindow.GdkWindow.GetOrigin (out x, out y);
				x = ww / 2 - 350 / 2;
				y = wh / 2 - 200 / 2;
				Move (x, y);
			} else
				Move (x - 350, y - 200);

			mainFrame = new Gtk.Frame ();
			
			mainBox = new Gtk.VBox ();
			mainBox.BorderWidth = 12;
			mainBox.Spacing = 6;
			headerBox = new Gtk.HBox ();
			mailEntry = new EntryWithEmptyMessage ();
			mailEntry.EmptyMessage = GettextCatalog.GetString ("email address");
			Decorated = false;
			mainFrame.ShadowType = Gtk.ShadowType.Out;
			
			// Header
			
			headerBox.Spacing = 6;
			mailLabel = new Gtk.Label ();
			headerBox.PackStart (mailLabel, false, false, 0);
			Gtk.Button changeButton = new Gtk.Button ("(Change)");
			changeButton.Relief = Gtk.ReliefStyle.None;
			headerBox.PackStart (changeButton, false, false, 0);
			changeButton.Clicked += HandleChangeButtonClicked;
			mainBox.PackStart (headerBox, false, false, 0);
			mainBox.PackStart (mailEntry, false, false, 0);
			mailWarningLabel = new Gtk.Label (GettextCatalog.GetString ("Please enter a valid e-mail address"));
			mailWarningLabel.Xalign = 0;
			mainBox.PackStart (mailWarningLabel, false, false, 0);
			
			// Body
			
			textEntry = new TextViewWithEmptyMessage ();
			textEntry.EmptyMessage = GettextCatalog.GetString (
				"Tell us how we can make {0} better.",
				BrandingService.SuiteName
			);
			textEntry.AcceptsTab = false;
			textEntry.WrapMode = Gtk.WrapMode.Word;
			textEntry.WidthRequest = 300;
			var sw = new Gtk.ScrolledWindow ();
			sw.ShadowType = Gtk.ShadowType.In;
			sw.VscrollbarPolicy = Gtk.PolicyType.Automatic;
			sw.HscrollbarPolicy = Gtk.PolicyType.Never;
			sw.Add (textEntry);
			mainBox.PackStart (sw, true, true, 0);
			bodyWarningLabel = new Gtk.Label (GettextCatalog.GetString ("Please enter some feedback"));
			bodyWarningLabel.Xalign = 0;
			mainBox.PackStart (bodyWarningLabel, false, false, 0);
			
			// Bottom
			
			Gtk.HBox bottomBox = new Gtk.HBox (false, 6);
			Gtk.Label countLabel = new Gtk.Label ();
			countLabel.Xalign = 0;
			bottomBox.PackStart (countLabel, false, false, 0);
			
			Gtk.Button sendButton = new Gtk.Button (GettextCatalog.GetString ("Send Feedback"));
			sendButton.Clicked += HandleSendButtonClicked;
			bottomBox.PackEnd (sendButton, false, false, 0);
			mainBox.PackStart (bottomBox, false, false, 0);
			
			// Init
			
			mainBox.ShowAll ();
			
			mailWarningLabel.Hide ();
			bodyWarningLabel.Hide ();
			
			string mail = FeedbackService.ReporterEMail;
			if (string.IsNullOrEmpty (mail))
				mail = AuthorInformation.Default.Email;
			
			if (string.IsNullOrEmpty (mail)) {
				headerBox.Hide ();
				mailEntry.GrabFocus ();
			}
			else {
				mailEntry.Text = mail;
				mailEntry.Hide ();
				mailLabel.Text = GettextCatalog.GetString ("From: {0}", mail);
				textEntry.GrabFocus ();
			}
			if (FeedbackService.FeedbacksSent > 0)
				countLabel.Text = GettextCatalog.GetString ("Your feedbacks: {0}", FeedbackService.FeedbacksSent);
			else
				countLabel.Hide ();
			
			mainFrame.Show ();
			mainFrame.Add (mainBox);
			Add (mainFrame);
		}
        public void CreateGui()
        {
            Gtk.Image icn_reload=new Gtk.Image(Gtk.Stock.Refresh,Gtk.IconSize.Button);
            _reload=new Gtk.Button(icn_reload);
            _reload.Clicked+=OnReload;

            _performer=new Gtk.Entry(200);
            _title=new Gtk.Entry(200);
            _title.WidthChars=60;
            _performer.WidthChars=60;
            _subtitle=new Gtk.Entry(300);
            _subtitle.WidthChars=60;
            _composer=new Gtk.Entry(200);
            _composer.WidthChars=60;
            _year=new Gtk.Entry(20);
            _year.WidthChars=20;

            _image=new Gtk.Image();
            _image.SetSizeRequest (100,100);
            _imagefile=new Gtk.FileChooserButton("Choose image file",Gtk.FileChooserAction.Open);
            _imagefile.FileSet+=new EventHandler(EvtImageSet);

            Gtk.Image icn_add_track=new Gtk.Image(Gtk.Stock.Add,Gtk.IconSize.Button);
            _add_track=new Gtk.Button(icn_add_track);
            _add_track.Clicked+=OnAddTrack;

            Gtk.Image icn_del_track=new Gtk.Image(Gtk.Stock.Delete,Gtk.IconSize.Button);
            _del_track=new Gtk.Button(icn_del_track);
            _del_track.Clicked+=OnDelTrack;

            Gtk.Image icn_save=new Gtk.Image(Gtk.Stock.Save,Gtk.IconSize.Button);
            _save=new Gtk.Button(icn_save);
            _save.Clicked+=OnSave;

            _store=new Gtk.ListStore(typeof(int),typeof(string),typeof(string),typeof(string),typeof(string),typeof(string));
            _tracks=new Gtk.TreeView();
            {
                Gtk.CellRendererText cr0=new Gtk.CellRendererText();
                cr0.Scale=0.8;
                _tracks.AppendColumn ("Nr.", cr0, "text", 0);

                Gtk.CellRendererText cr_title=new Gtk.CellRendererText();
                cr_title.Scale=0.8;
                cr_title.Editable=true;
                cr_title.Edited+=new Gtk.EditedHandler(delegate(object sender,Gtk.EditedArgs args) {
                    setCell(1,args.NewText,new Gtk.TreePath(args.Path));
                });
                _tracks.AppendColumn ("Title", cr_title, "text", 1);

                Gtk.CellRendererText cr_artist=new Gtk.CellRendererText();
                cr_artist.Editable=true;
                cr_artist.Scale=0.8;
                cr_artist.Edited+=new Gtk.EditedHandler(delegate(object sender,Gtk.EditedArgs args) {
                    setCell(2,args.NewText,new Gtk.TreePath(args.Path));
                });
                _tracks.AppendColumn ("Artist", cr_artist, "text", 2);

                Gtk.CellRendererText cr_composer=new Gtk.CellRendererText();
                cr_composer.Editable=true;
                cr_composer.Scale=0.8;
                cr_composer.Edited+=new Gtk.EditedHandler(delegate(object sender,Gtk.EditedArgs args) {
                    setCell(3,args.NewText,new Gtk.TreePath(args.Path));
                });
                _tracks.AppendColumn ("Composer", cr_composer, "text", 3);

                Gtk.CellRendererText cr_piece=new Gtk.CellRendererText();
                cr_piece.Editable=true;
                cr_piece.Scale=0.8;
                cr_piece.Edited+=new Gtk.EditedHandler(delegate(object sender,Gtk.EditedArgs args) {
                    setCell(4,args.NewText,new Gtk.TreePath(args.Path));
                });
                _tracks.AppendColumn ("Piece", cr_piece, "text", 4);

                Gtk.CellRendererText cr_time=new Gtk.CellRendererText();
                cr_time.Editable=true;
                cr_time.Scale=0.8;
                cr_time.Edited+=new Gtk.EditedHandler(delegate(object sender,Gtk.EditedArgs args) {
                    setCell (5,args.NewText,new Gtk.TreePath(args.Path));
                });
                _tracks.AppendColumn ("Offset", cr_time, "text", 5);
            }

            _tracks.Model = _store;

            Gtk.Table tbl=new Gtk.Table(2,5,false);
            tbl.Attach (new Gtk.Label("Album:"),0,1,0,1);
            tbl.Attach (_title,1,2,0,1);
            tbl.Attach (new Gtk.Label("Artist:"),0,1,1,2);
            tbl.Attach (_performer,1,2,1,2);
            tbl.Attach (new Gtk.Label("Composer:"),0,1,2,3);
            tbl.Attach (_composer,1,2,2,3);
            tbl.Attach (new Gtk.Label("Subtitle:"),0,1,3,4);
            tbl.Attach (_subtitle,1,2,3,4);
            tbl.Attach (new Gtk.Label("year:"),0,1,4,5);
            tbl.Attach (_year,1,2,4,5);

            Gtk.Frame frm=new Gtk.Frame();
            frm.Add (tbl);

            Gtk.HBox hb2=new Gtk.HBox();
            hb2.PackEnd (_reload,false,false,1);
            hb2.PackEnd (_del_track,false,false,1);
            hb2.PackEnd (_add_track,false,false,1);
            hb2.PackEnd (_save,false,false,1);

            Gtk.HBox hb=new Gtk.HBox();
            Gtk.VBox vb1=new Gtk.VBox();
            vb1.PackStart (frm,false,false,0);
            vb1.PackStart (hb2,true,true,0);
            hb.PackStart (vb1,false,false,0);

            Gtk.Frame frm2=new Gtk.Frame();
            frm2.Add (_image);
            Gtk.VBox vbi=new Gtk.VBox();
            Gtk.HBox bb=new Gtk.HBox();
            bb.PackStart(new Gtk.VBox(),true,true,0);
            bb.PackStart(frm2,false,false,0);
            bb.PackEnd (new Gtk.VBox(),true,true,0);

            vbi.PackStart (bb,true,true,2);
            vbi.PackEnd (_imagefile,false,false,2);
            hb.PackEnd (vbi,true,true,2);

            Gtk.ScrolledWindow scroll=new Gtk.ScrolledWindow();
            scroll.Add (_tracks);
            scroll.SetSizeRequest (800,300);

            base.VBox.PackStart(hb,false,false,4);
            base.VBox.PackStart(scroll,true,true,0);
            base.VBox.ShowAll ();

            base.AddButton ("Close",0);
        }
Esempio n. 60
0
        public GroupChatView(GroupChatModel groupChat)
            : base(groupChat)
        {
            Trace.Call(groupChat);

            _GroupChatModel = groupChat;

            // person list
            _OutputHPaned = new Gtk.HPaned();

            Gtk.ScrolledWindow sw = new Gtk.ScrolledWindow();
            _PersonScrolledWindow = sw;
            //sw.WidthRequest = 150;
            sw.HscrollbarPolicy = Gtk.PolicyType.Never;

            Gtk.TreeView tv = new Gtk.TreeView();
            _PersonTreeView = tv;
            //tv.CanFocus = false;
            tv.BorderWidth = 0;
            tv.Selection.Mode = Gtk.SelectionMode.Multiple;
            sw.Add(tv);

            Gtk.TreeViewColumn column;
            Gtk.CellRendererText cellr = new Gtk.CellRendererText();
            cellr.WidthChars = 12;
            column = new Gtk.TreeViewColumn(String.Empty, cellr);
            column.SortColumnId = 0;
            column.Spacing = 0;
            column.SortIndicator = false;
            column.Sizing = Gtk.TreeViewColumnSizing.Autosize;
            column.SetCellDataFunc(cellr, new Gtk.TreeCellDataFunc(RenderPersonIdentityName));
            tv.AppendColumn(column);
            _IdentityNameColumn = column;

            Gtk.ListStore liststore = new Gtk.ListStore(typeof(PersonModel));
            liststore.SetSortColumnId(0, Gtk.SortType.Ascending);
            liststore.SetSortFunc(0, new Gtk.TreeIterCompareFunc(SortPersonListStore));
            _PersonListStore = liststore;

            tv.Model = liststore;
            tv.RowActivated += new Gtk.RowActivatedHandler(OnPersonsRowActivated);
            tv.FocusOutEvent += OnPersonTreeViewFocusOutEvent;

            // popup menu
            _PersonMenu = new Gtk.Menu();
            // don't loose the focus else we lose the selection too!
            // see OnPersonTreeViewFocusOutEvent()
            _PersonMenu.TakeFocus = false;
            _PersonMenu.Shown += OnPersonMenuShown;

            _PersonTreeView.ButtonPressEvent += _OnPersonTreeViewButtonPressEvent;
            _PersonTreeView.KeyPressEvent += OnPersonTreeViewKeyPressEvent;
            // frame needed for events when selecting something in the treeview
            _PersonTreeViewFrame = new Gtk.Frame();
            _PersonTreeViewFrame.ButtonReleaseEvent += new Gtk.ButtonReleaseEventHandler(_OnUserListButtonReleaseEvent);
            _PersonTreeViewFrame.Add(sw);

            // topic
            // don't worry, ApplyConfig() will add us to the OutputVBox!
            _OutputVBox = new Gtk.VBox();

            _TopicTextView = new MessageTextView();
            _TopicTextView.Editable = false;
            _TopicTextView.WrapMode = Gtk.WrapMode.WordChar;
            _TopicScrolledWindow = new Gtk.ScrolledWindow();
            _TopicScrolledWindow.ShadowType = Gtk.ShadowType.In;
            // when using PolicyType.Never, it will try to grow but never shrinks!
            _TopicScrolledWindow.HscrollbarPolicy = Gtk.PolicyType.Automatic;
            _TopicScrolledWindow.VscrollbarPolicy = Gtk.PolicyType.Automatic;
            _TopicScrolledWindow.Add(_TopicTextView);
            // make sure the topic is invisible and remains by default and
            // visible when a topic gets set
            _TopicScrolledWindow.ShowAll();
            _TopicScrolledWindow.Visible = false;
            _TopicScrolledWindow.NoShowAll = true;

            Add(_OutputHPaned);

            //ApplyConfig(Frontend.UserConfig);

            ShowAll();
        }