public PListEditorViewContent (IPlistEditingHandler handler, Project proj) { if (handler != null) { widget = new PListEditorWidget (handler, proj); control = (Gtk.Widget) widget; } else { widget = new CustomPropertiesWidget (); var csw = new MonoDevelop.Components.CompactScrolledWindow (); csw.Show (); csw.AddWithViewport ((Gtk.Widget)widget); control = csw; } }
void SetText(IEnumerable <ISystemInformationProvider> text) { Clear(); var buf = new Gtk.Label(); buf.Selectable = true; buf.Xalign = 0; StringBuilder sb = new StringBuilder(); foreach (var info in text) { sb.Append("<b>").Append(GLib.Markup.EscapeText(info.Title)).Append("</b>\n"); sb.Append(GLib.Markup.EscapeText(info.Description.Trim())).Append("\n\n"); } buf.Markup = sb.ToString().Trim() + "\n"; var contentBox = new VBox(); contentBox.BorderWidth = 4; contentBox.PackStart(buf, false, false, 0); var asmButton = new Gtk.Button(GettextCatalog.GetString("Show loaded assemblies")); asmButton.Clicked += (sender, e) => { asmButton.Hide(); contentBox.PackStart(CreateAssembliesTable(), false, false, 0); }; var hb = new Gtk.HBox(); hb.PackStart(asmButton, false, false, 0); contentBox.PackStart(hb, false, false, 0); var sw = new MonoDevelop.Components.CompactScrolledWindow() { ShowBorderLine = true, BorderWidth = 2 }; sw.AddWithViewport(contentBox); sw.ShadowType = ShadowType.None; ((Gtk.Viewport)sw.Child).ShadowType = ShadowType.None; PackStart(sw, true, true, 0); ShowAll(); }
public PListEditorViewContent(IPlistEditingHandler handler, Project proj) { if (handler != null) { widget = new PListEditorWidget(handler, proj); control = (Gtk.Widget)widget; } else { widget = new CustomPropertiesWidget(); var csw = new MonoDevelop.Components.CompactScrolledWindow(); csw.Show(); csw.AddWithViewport((Gtk.Widget)widget); control = csw; } }
void SetText (IEnumerable<ISystemInformationProvider> text) { Clear (); var buf = new Gtk.Label (); buf.Selectable = true; buf.Xalign = 0; StringBuilder sb = new StringBuilder (); foreach (var info in text) { sb.Append ("<b>").Append (GLib.Markup.EscapeText (info.Title)).Append ("</b>\n"); sb.Append (GLib.Markup.EscapeText (info.Description.Trim ())).Append ("\n\n"); } buf.Markup = sb.ToString ().Trim () + "\n"; var contentBox = new VBox (); contentBox.BorderWidth = 4; contentBox.PackStart (buf, false, false, 0); var asmButton = new Gtk.Button ("Show loaded assemblies"); asmButton.Clicked += (sender, e) => { asmButton.Hide (); contentBox.PackStart (CreateAssembliesTable (), false, false, 0); }; var hb = new Gtk.HBox (); hb.PackStart (asmButton, false, false, 0); contentBox.PackStart (hb, false, false, 0); var sw = new MonoDevelop.Components.CompactScrolledWindow () { ShowBorderLine = true, BorderWidth = 2 }; sw.AddWithViewport (contentBox); sw.ShadowType = ShadowType.None; ((Gtk.Viewport)sw.Child).ShadowType = ShadowType.None; PackStart (sw, true, true, 0); ShowAll (); }