public IShellDocumentToolbar GetToolbar(DocumentToolbarKind kind) { if (kind == DocumentToolbarKind.Top) { if (topToolbar == null) { topToolbar = new GtkDocumentToolbar(); box.PackStart(topToolbar.Container, false, false, 0); box.ReorderChild(topToolbar.Container, 0); topToolbar.Visible = true; HidePathBar(); } return(topToolbar); } else { if (bottomToolbar == null) { bottomToolbar = new GtkDocumentToolbar(); box.PackStart(bottomToolbar.Container, false, false, 0); bottomToolbar.Visible = true; } return(bottomToolbar); } }
/// <summary> /// Moves the widget one position before the actual. /// </summary> private void OnUpBtnClicked(object sender, EventArgs args) { int position = (container[this] as Gtk.Box.BoxChild).Position; container.ReorderChild(this, position - 1); (container.Children[position] as LexicalExpressionWidget).CheckPosition(); CheckPosition(); }
/// <summary> /// Moves an item towards the beggining of the container. /// </summary> /// <param name="widget"> /// A <see cref="ExpressionItemWidget"/> /// </param> public void MoveItemBackwards(ExpressionItemWidget widget) { int position = this[widget].Position; itemOpRelatedItemsBox.ReorderChild(widget, position - 1); widget.CheckPosition(); ((RelatedItemWidget)itemOpRelatedItemsBox.Children[position]).CheckPosition(); }
/// <summary>Initializes a new instance of the <see cref="DataStoreView" /> class.</summary> public DataStoreView(ViewBase owner) : base(owner) { Builder builder = BuilderFromResource("ApsimNG.Resources.Glade.DataStoreView.glade"); vbox1 = (VBox)builder.GetObject("vbox1"); table1 = (Table)builder.GetObject("table1"); hbox1 = (HBox)builder.GetObject("hbox1"); _mainWidget = vbox1; gridView = new GridView(this) { ReadOnly = true, CanGrow = false }; vbox1.PackStart(gridView.MainWidget, true, true, 0); vbox1.ReorderChild(hbox1, 2); dropDownView1 = new DropDownView(this); editView1 = new EditView(this); rowFilter = new EditView(this); table1.Attach(dropDownView1.MainWidget, 1, 2, 0, 1); table1.Attach(editView1.MainWidget, 1, 2, 1, 2); table1.Attach(rowFilter.MainWidget, 1, 2, 2, 3); editView2 = new EditView(this); hbox1.PackStart(editView2.MainWidget, false, false, 0); _mainWidget.Destroyed += _mainWidget_Destroyed; }
private void AddHTML() { Application.Invoke(delegate { if (Spinner.Active) { LayoutVertical.Remove(Spinner); Spinner.Stop(); } else { LayoutVertical.Remove(ScrolledWindow); } ScrolledWindow = new ScrolledWindow() { HscrollbarPolicy = PolicyType.Never }; Viewport viewport = new Viewport(); WebView.Reparent(viewport); ScrolledWindow.Add(viewport); (ScrolledWindow.Child as Viewport).ShadowType = ShadowType.None; LayoutVertical.PackStart(ScrolledWindow, true, true, 0); LayoutVertical.ReorderChild(ScrolledWindow, 0); WebView.LoadString(HTML, null, null, "file://"); LayoutVertical.ShowAll(); }); }
private void PopulatePersonView() { List <Widget> children = new List <Widget> (vbox.Children); foreach (Widget child in children) { vbox.Remove(child); try { child.Destroy(); } catch {} } // personCardMap.Clear (); if (model == null) { Logger.Debug("PersonView.PopulatePersonView returning since the model is null."); return; } TreeIter iter; // Loop through the model, create the PersonCard objects and add // them into the vbox. if (model.GetIterFirst(out iter)) { do { Person person = model.GetValue(iter, 0) as Person; if (person == null) { continue; } TreePath path = model.GetPath(iter); PersonCard card = new PersonCard(person); card.Size = personCardSize; card.ShowAll(); vbox.PackStart(card, false, false, 0); vbox.ReorderChild(card, path.Indices [0]); // personCardMap[iter] = card; } while (model.IterNext(ref iter)); } }
private void ArrangePaymentWidget() { paymentWidget.ParentWindow = dlgEditNewAdvancePayment; paymentWidget.WidgetSeparator.Unparent(); hboxMain.PackStart(paymentWidget.WidgetSeparator, false, false, 4); paymentWidget.WidgetChooseMoney.Unparent(); hboxMain.PackStart(paymentWidget.WidgetChooseMoney, false, false, 0); paymentWidget.WidgetPayments.Unparent(); vboxPayments.PackStart(paymentWidget.WidgetPayments, true, true, 0); vboxPayments.ReorderChild(paymentWidget.WidgetPayments, 1); paymentWidget.WidgetPayments.Show(); }
public DocumentToolbar GetToolbar(IBaseViewContent targetView) { DocumentToolbar toolbar; if (!documentToolbars.TryGetValue(targetView, out toolbar)) { toolbar = new DocumentToolbar(); documentToolbars [targetView] = toolbar; box.PackStart(toolbar.Container, false, false, 0); box.ReorderChild(toolbar.Container, 0); toolbar.Visible = (targetView == ActiveViewContent); } return(toolbar); }
/// <summary>Initializes a new instance of the <see cref="DataStoreView" /> class.</summary> public DataStoreView(ViewBase owner) : base(owner) { Glade.XML gxml = new Glade.XML("ApsimNG.Resources.Glade.DataStoreView.glade", "vbox1"); gxml.Autoconnect(this); _mainWidget = vbox1; gridView = new GridView(this); vbox1.PackStart(gridView.MainWidget, true, true, 0); vbox1.ReorderChild(hbox1, 2); dropDownView1 = new DropDownView(this); editView1 = new EditView(this); table1.Attach(dropDownView1.MainWidget, 1, 2, 0, 1); table1.Attach(editView1.MainWidget, 1, 2, 1, 2); editView2 = new EditView(this); hbox1.PackStart(editView2.MainWidget, false, false, 0); }
/// <summary>Initializes a new instance of the <see cref="DataStoreView" /> class.</summary> public DataStoreView(ViewBase owner) : base(owner) { Builder builder = new Builder("ApsimNG.Resources.Glade.DataStoreView.glade"); vbox1 = (VBox)builder.GetObject("vbox1"); table1 = (Table)builder.GetObject("table1"); hbox1 = (HBox)builder.GetObject("hbox1"); _mainWidget = vbox1; gridView = new GridView(this); vbox1.PackStart(gridView.MainWidget, true, true, 0); vbox1.ReorderChild(hbox1, 2); dropDownView1 = new DropDownView(this); editView1 = new EditView(this); table1.Attach(dropDownView1.MainWidget, 1, 2, 0, 1); table1.Attach(editView1.MainWidget, 1, 2, 1, 2); editView2 = new EditView(this); hbox1.PackStart(editView2.MainWidget, false, false, 0); }
ListStore AddExpander(string name, int pos) { var tree_view = new TreeView { HeadersVisible = false, RulesHint = true }; var col = new TreeViewColumn { Sizing = TreeViewColumnSizing.Autosize }; CellRenderer colr = new CellRendererText(); col.PackStart(colr, false); col.AddAttribute(colr, "markup", 0); tree_view.AppendColumn(col); var model = new ListStore(typeof(string)); tree_view.Model = model; var expander = new Expander($"<span weight=\"bold\"><small>{name}</small></span>") { UseMarkup = true }; expander.Add(tree_view); expander.Expanded = true; metadata_vbox.PackStart(expander, false, false, 6); metadata_vbox.ReorderChild(expander, pos); if (open_list.Contains(name)) { expander.Expanded = true; } expander.Activated += HandleExpanderActivated; expander.ShowAll(); return(model); }
void UpdateImage() { if (string.IsNullOrEmpty(icon)) { if (image != null) { box.Remove(image); image.Destroy(); image = null; } return; } if (image == null) { image = new ImageView(); box.PackStart(image, false, false, 0); box.ReorderChild(image, 0); } image.Image = ImageService.GetIcon(icon, iconSize); }
public void UpdatePullToRefreshEnabled(bool isPullToRequestEnabled) { IsPullToRequestEnabled = isPullToRequestEnabled; if (_refreshHeader == null) { return; } if (IsPullToRequestEnabled) { _root.RemoveFromContainer(_refreshHeader); _root.PackStart(_refreshHeader, false, false, 0); _root.ReorderChild(_refreshHeader, 0); } else { _root.RemoveFromContainer(_refreshHeader); } }
private ListStore AddExpander(string name, int pos) { TreeView tree_view = new TreeView(); tree_view.HeadersVisible = false; tree_view.RulesHint = true; TreeViewColumn col = new TreeViewColumn(); col.Sizing = TreeViewColumnSizing.Autosize; CellRenderer colr = new CellRendererText(); col.PackStart(colr, false); col.AddAttribute(colr, "markup", 0); tree_view.AppendColumn(col); ListStore model = new ListStore(typeof(string)); tree_view.Model = model; Expander expander = new Expander(String.Format("<span weight=\"bold\"><small>{0}</small></span>", name)); expander.UseMarkup = true; expander.Add(tree_view); exif_vbox.PackStart(expander, false, false, 6); exif_vbox.ReorderChild(expander, pos); if (open_list.Contains(name)) { expander.Expanded = true; } expander.Activated += HandleExpanderActivated; expander.ShowAll(); return(model); }
protected override void InitializeFormStrings() { base.InitializeFormStrings(); dlgExchangeObjects.Title = Translator.GetString("Import Entities"); lblExchangeFile.SetText(Translator.GetString("Import from:")); VBox parent = (VBox)grbFile.Parent; parent.Remove(grbFile); hboExchangeFile.Unparent(); parent.Add(hboExchangeFile); parent.ReorderChild(hboExchangeFile, 1); hboExchangeFile.ShowAll(); chkExchangeFile.Visible = false; chkOpenFile.Visible = false; grbEmail.Visible = false; txtEmail.Visible = false; lblEmailSubject.Visible = false; txtEmailSubject.Visible = false; lblExchangeLocation.SetText(Translator.GetString("Import to location:")); }
public void PlaceFilmstrip(Orientation pos, bool force) { if (!force && filmstrip.Orientation == pos) { return; } filmstrip.Orientation = pos; System.Collections.IEnumerator widgets; switch (pos) { case Orientation.Horizontal: widgets = inner_hbox.AllChildren.GetEnumerator(); while (widgets.MoveNext()) { if (widgets.Current == filmstrip) { inner_hbox.Remove(filmstrip); break; } } inner_vbox.PackStart(filmstrip, false, false, 0); inner_vbox.ReorderChild(filmstrip, 0); break; case Orientation.Vertical: widgets = inner_vbox.AllChildren.GetEnumerator(); while (widgets.MoveNext()) { if (widgets.Current == filmstrip) { inner_vbox.Remove(filmstrip); break; } } inner_hbox.PackEnd(filmstrip, false, false, 0); break; } Preferences.Set(Preferences.FILMSTRIP_ORIENTATION, (int)pos); }
void UpdateImage() { if (string.IsNullOrEmpty(icon)) { if (image != null) { box.Remove(image); image.Destroy(); image = null; } return; } if (image == null) { image = new Gtk.Image(); int w, h; Gtk.Icon.SizeLookup(iconSize, out w, out h); image.IconSize = w; box.PackStart(image, false, false, 0); box.ReorderChild(image, 0); } image.Pixbuf = ImageService.GetPixbuf(icon, iconSize); }
/// <summary>Initializes a new instance of the <see cref="DataStoreView" /> class.</summary> public DataStoreView(ViewBase owner) : base(owner) { Builder builder = BuilderFromResource("ApsimNG.Resources.Glade.DataStoreView.glade"); vbox1 = (VBox)builder.GetObject("vbox1"); table1 = (Table)builder.GetObject("table1"); hbox1 = (HBox)builder.GetObject("hbox1"); mainWidget = vbox1; gridView = new GridView(this) { ReadOnly = true, CanGrow = false }; vbox1.PackStart(gridView.MainWidget, true, true, 0); vbox1.ReorderChild(hbox1, 2); fileName = new EditView(this); fileName.Leave += OnFileNameChanged; chooseFile = new Button("..."); chooseFile.Clicked += OnChooseFile; HBox fileNameContainer = new HBox(); fileNameContainer.PackStart(fileName.MainWidget, true, true, 0); fileNameContainer.PackStart(chooseFile, false, false, 0); dropDownView1 = new DropDownView(this); editView1 = new EditView(this); rowFilter = new EditView(this); table1.Attach(fileNameContainer, 1, 2, 0, 1); table1.Attach(dropDownView1.MainWidget, 1, 2, 1, 2); table1.Attach(editView1.MainWidget, 1, 2, 2, 3); table1.Attach(rowFilter.MainWidget, 1, 2, 3, 4); editView2 = new EditView(this); hbox1.PackStart(editView2.MainWidget, false, false, 0); mainWidget.Destroyed += _mainWidget_Destroyed; }
/// <summary>Initializes a new instance of the <see cref="SeriesView" /> class</summary> public SeriesView(ViewBase owner) : base(owner) { Builder builder = BuilderFromResource("ApsimNG.Resources.Glade.SeriesView.glade"); vbox1 = (VBox)builder.GetObject("vbox1"); Widget table = (Widget)builder.GetObject("table1"); vbox1.Remove(table); table1 = new Grid(); table1.ColumnSpacing = 10; // Set expand to false on this grid, to ensure that any extra space // is allocated to the graph (aka plotview). vbox1.PackStart(table1, false, true, 0); vbox1.ReorderChild(table1, 0); label4 = (Label)builder.GetObject("label4"); label5 = (Label)builder.GetObject("label5"); mainWidget = vbox1; graphView1 = new GraphView(this); vbox1.PackStart(graphView1.MainWidget, true, true, 0); dataSourceDropDown = new DropDownView(this); xDropDown = new DropDownView(this); yDropDown = new DropDownView(this); x2DropDown = new DropDownView(this); y2DropDown = new DropDownView(this); seriesDropDown = new DropDownView(this); lineTypeDropDown = new DropDownView(this); markerTypeDropDown = new DropDownView(this); colourDropDown = new ColourDropDownView(this); lineThicknessDropDown = new DropDownView(this); markerSizeDropDown = new DropDownView(this); checkBoxView1 = new CheckBoxView(this); checkBoxView1.TextOfLabel = "on top?"; checkBoxView2 = new CheckBoxView(this); checkBoxView2.TextOfLabel = "on right?"; checkBoxView3 = new CheckBoxView(this); checkBoxView3.TextOfLabel = "cumulative?"; checkBoxView4 = new CheckBoxView(this); checkBoxView4.TextOfLabel = "cumulative?"; checkBoxView5 = new CheckBoxView(this); checkBoxView5.TextOfLabel = "Show in legend?"; checkBoxView6 = new CheckBoxView(this); checkBoxView6.TextOfLabel = "Include series name in legend?"; editView1 = new EditView(this); Image helpImage = new Image(null, "ApsimNG.Resources.MenuImages.Help.svg"); helpBox = new EventBox(); helpBox.Add(helpImage); helpBox.ButtonReleaseEvent += Help_ButtonPressEvent; HBox filterBox = new HBox(); filterBox.PackStart(editView1.MainWidget, true, true, 0); filterBox.PackEnd(helpBox, false, true, 0); table1.Attach(new Label("Data Source:") { Xalign = 0 }, 0, 0, 1, 1); table1.Attach(new Label("X:") { Xalign = 0 }, 0, 1, 1, 1); table1.Attach(new Label("Y:") { Xalign = 0 }, 0, 2, 1, 1); label4 = new Label("Y2:") { Xalign = 0 }; label5 = new Label("X2:") { Xalign = 0 }; table1.Attach(label4, 0, 3, 1, 1); table1.Attach(label5, 0, 4, 1, 1); table1.Attach(new Label("Type:") { Xalign = 0 }, 0, 5, 1, 1); table1.Attach(new Label("Line type:") { Xalign = 0 }, 0, 6, 1, 1); table1.Attach(new Label("Marker type:") { Xalign = 0 }, 0, 7, 1, 1); table1.Attach(new Label("Colour:") { Xalign = 0 }, 0, 8, 1, 1); table1.Attach(new Label("Filter:") { Xalign = 0 }, 0, 9, 1, 1); // fixme: these widgets used to have 10px horizontal padding and 2px vertical padding. table1.Attach(dataSourceDropDown.MainWidget, 1, 0, 1, 1 /*, 10, 2*/); table1.Attach(xDropDown.MainWidget, 1, 1, 1, 1 /*10, 2*/); table1.Attach(yDropDown.MainWidget, 1, 2, 1, 1 /*10, 2*/); table1.Attach(y2DropDown.MainWidget, 1, 3, 1, 1 /*10, 2*/); table1.Attach(x2DropDown.MainWidget, 1, 4, 1, 1 /*10, 2*/); table1.Attach(seriesDropDown.MainWidget, 1, 5, 1, 1 /*10, 2*/); table1.Attach(lineTypeDropDown.MainWidget, 1, 6, 1, 1 /*10, 2*/); table1.Attach(markerTypeDropDown.MainWidget, 1, 7, 1, 1 /*10, 2*/); table1.Attach(colourDropDown.MainWidget, 1, 8, 1, 1 /*10, 2*/); table1.Attach(filterBox, 1, 9, 1, 1 /*10, 2*/); table1.Attach(checkBoxView1.MainWidget, 2, 1, 1, 1); table1.Attach(checkBoxView2.MainWidget, 2, 2, 1, 1); table1.Attach(checkBoxView3.MainWidget, 3, 1, 1, 1); table1.Attach(checkBoxView4.MainWidget, 3, 2, 1, 1); table1.Attach(checkBoxView5.MainWidget, 2, 8, 2, 1); table1.Attach(checkBoxView6.MainWidget, 2, 9, 2, 1); // fixme: These apparently used to have 5px vertical padding. table1.Attach(new Label("Line thickness:") { Xalign = 0 }, 2, 6, 1, 1 /*, 0, 5*/); table1.Attach(lineThicknessDropDown.MainWidget, 3, 6, 1, 1 /*, 0, 5*/); table1.Attach(new Label("Marker size:") { Xalign = 0 }, 2, 7, 1, 1 /*, 0, 5*/); table1.Attach(markerSizeDropDown.MainWidget, 3, 7, 1, 1 /*, 0, 5*/); mainWidget.Destroyed += _mainWidget_Destroyed; }
public void SetHeader(Widget w) { vbox.PackStart(w, false, false, 0); vbox.ReorderChild(w, 0); }
/// <summary>Initializes a new instance of the <see cref="SeriesView" /> class</summary> public SeriesView(ViewBase owner) : base(owner) { Builder builder = BuilderFromResource("ApsimNG.Resources.Glade.SeriesView.glade"); vbox1 = (VBox)builder.GetObject("vbox1"); #if NETFRAMEWORK table1 = (Table)builder.GetObject("table1"); #else Widget table = (Widget)builder.GetObject("table1"); vbox1.Remove(table); table1 = new Grid(); table1.ColumnSpacing = 10; // Set expand to false on this grid, to ensure that any extra space // is allocated to the graph (aka plotview). vbox1.PackStart(table1, false, true, 0); vbox1.ReorderChild(table1, 0); #endif label4 = (Label)builder.GetObject("label4"); label5 = (Label)builder.GetObject("label5"); mainWidget = vbox1; graphView1 = new GraphView(this); vbox1.PackStart(graphView1.MainWidget, true, true, 0); dataSourceDropDown = new DropDownView(this); xDropDown = new DropDownView(this); yDropDown = new DropDownView(this); x2DropDown = new DropDownView(this); y2DropDown = new DropDownView(this); seriesDropDown = new DropDownView(this); lineTypeDropDown = new DropDownView(this); markerTypeDropDown = new DropDownView(this); colourDropDown = new ColourDropDownView(this); lineThicknessDropDown = new DropDownView(this); markerSizeDropDown = new DropDownView(this); checkBoxView1 = new CheckBoxView(this); checkBoxView1.TextOfLabel = "on top?"; checkBoxView2 = new CheckBoxView(this); checkBoxView2.TextOfLabel = "on right?"; checkBoxView3 = new CheckBoxView(this); checkBoxView3.TextOfLabel = "cumulative?"; checkBoxView4 = new CheckBoxView(this); checkBoxView4.TextOfLabel = "cumulative?"; checkBoxView5 = new CheckBoxView(this); checkBoxView5.TextOfLabel = "Show in legend?"; checkBoxView6 = new CheckBoxView(this); checkBoxView6.TextOfLabel = "Include series name in legend?"; editView1 = new EditView(this); Image helpImage = new Image(null, "ApsimNG.Resources.help.png"); helpBox = new EventBox(); helpBox.Add(helpImage); helpBox.ButtonReleaseEvent += Help_ButtonPressEvent; HBox filterBox = new HBox(); filterBox.PackStart(editView1.MainWidget, true, true, 0); filterBox.PackEnd(helpBox, false, true, 0); #if NETCOREAPP table1.Attach(new Label("Data Source:") { Xalign = 0 }, 0, 1, 0, 1, AttachOptions.Fill, AttachOptions.Shrink, 0, 0); table1.Attach(new Label("X:") { Xalign = 0 }, 0, 1, 1, 2, AttachOptions.Fill, AttachOptions.Shrink, 0, 0); table1.Attach(new Label("Y:") { Xalign = 0 }, 0, 1, 2, 3, AttachOptions.Fill, AttachOptions.Shrink, 0, 0); label4 = new Label("Y2:") { Xalign = 0 }; label5 = new Label("X2:") { Xalign = 0 }; table1.Attach(label4, 0, 1, 3, 4, AttachOptions.Fill, AttachOptions.Shrink, 0, 0); table1.Attach(label5, 0, 1, 4, 5, AttachOptions.Fill, AttachOptions.Shrink, 0, 0); table1.Attach(new Label("Type:") { Xalign = 0 }, 0, 1, 5, 6, AttachOptions.Fill, AttachOptions.Shrink, 0, 0); table1.Attach(new Label("Line type:") { Xalign = 0 }, 0, 1, 6, 7, AttachOptions.Fill, AttachOptions.Shrink, 0, 0); table1.Attach(new Label("Marker type:") { Xalign = 0 }, 0, 1, 7, 8, AttachOptions.Fill, AttachOptions.Shrink, 0, 0); table1.Attach(new Label("Colour:") { Xalign = 0 }, 0, 1, 8, 9, AttachOptions.Fill, AttachOptions.Shrink, 0, 0); table1.Attach(new Label("Filter:") { Xalign = 0 }, 0, 1, 9, 10, AttachOptions.Fill, AttachOptions.Shrink, 0, 0); #endif table1.Attach(dataSourceDropDown.MainWidget, 1, 2, 0, 1, AttachOptions.Fill, 0, 10, 2); table1.Attach(xDropDown.MainWidget, 1, 2, 1, 2, AttachOptions.Fill, 0, 10, 2); table1.Attach(yDropDown.MainWidget, 1, 2, 2, 3, AttachOptions.Fill, 0, 10, 2); table1.Attach(y2DropDown.MainWidget, 1, 2, 3, 4, AttachOptions.Fill, 0, 10, 2); table1.Attach(x2DropDown.MainWidget, 1, 2, 4, 5, AttachOptions.Fill, 0, 10, 2); table1.Attach(seriesDropDown.MainWidget, 1, 2, 5, 6, AttachOptions.Fill, 0, 10, 2); table1.Attach(lineTypeDropDown.MainWidget, 1, 2, 6, 7, AttachOptions.Fill, 0, 10, 2); table1.Attach(markerTypeDropDown.MainWidget, 1, 2, 7, 8, AttachOptions.Fill, 0, 10, 2); table1.Attach(colourDropDown.MainWidget, 1, 2, 8, 9, AttachOptions.Fill, 0, 10, 2); //table1.Attach(editView1.MainWidget, 1, 2, 9, 10, AttachOptions.Fill, 0, 10, 2); table1.Attach(filterBox, 1, 2, 9, 10, AttachOptions.Fill, 0, 10, 2); table1.Attach(checkBoxView1.MainWidget, 2, 3, 1, 2, AttachOptions.Fill, 0, 0, 0); table1.Attach(checkBoxView2.MainWidget, 2, 3, 2, 3, AttachOptions.Fill, 0, 0, 0); table1.Attach(checkBoxView3.MainWidget, 3, 4, 1, 2, AttachOptions.Fill, 0, 0, 0); table1.Attach(checkBoxView4.MainWidget, 3, 4, 2, 3, AttachOptions.Fill, 0, 0, 0); table1.Attach(checkBoxView5.MainWidget, 2, 4, 8, 9, AttachOptions.Fill, 0, 0, 0); table1.Attach(checkBoxView6.MainWidget, 2, 4, 9, 10, AttachOptions.Fill, 0, 0, 0); table1.Attach(new Label("Line thickness:") { Xalign = 0 }, 2, 3, 6, 7, AttachOptions.Fill, 0, 0, 5); table1.Attach(lineThicknessDropDown.MainWidget, 3, 4, 6, 7, AttachOptions.Fill, 0, 0, 5); table1.Attach(new Label("Marker size:") { Xalign = 0 }, 2, 3, 7, 8, AttachOptions.Fill, 0, 0, 5); table1.Attach(markerSizeDropDown.MainWidget, 3, 4, 7, 8, AttachOptions.Fill, 0, 0, 5); mainWidget.Destroyed += _mainWidget_Destroyed; }