void TransferProps (Gtk.MenuShell oldMenu, Gtk.MenuShell newMenu) { if (oldMenu.Visible) newMenu.Show (); if (!oldMenu.Sensitive) newMenu.Sensitive = false; }
public TreeViewCellContainer (Gtk.Widget child) { box = new EventBox (); box.ButtonPressEvent += new ButtonPressEventHandler (OnClickBox); box.Add (child); child.Show (); Show (); }
public TreeViewCellContainer (Gtk.Widget child) { box = new EventBox (); box.ButtonPressEvent += new ButtonPressEventHandler (OnClickBox); box.ModifyBg (StateType.Normal, Style.White); box.Add (child); child.Show (); Show (); }
// TODO: Centralize duplicated code private void AddRow (Gtk.Table table, Gtk.Widget widget, string labelText, uint row) { Gtk.Label l = new Gtk.Label (labelText); l.UseUnderline = true; l.Xalign = 0.0f; l.Show (); table.Attach (l, 0, 1, row, row + 1, Gtk.AttachOptions.Fill, Gtk.AttachOptions.Expand | Gtk.AttachOptions.Fill, 0, 0); widget.Show (); table.Attach (widget, 1, 2, row, row + 1, Gtk.AttachOptions.Expand | Gtk.AttachOptions.Fill, Gtk.AttachOptions.Expand | Gtk.AttachOptions.Fill, 0, 0); l.MnemonicWidget = widget; // TODO: Tooltips }
public static bool ShowWindow(Gtk.Window window) { #if DEBUG Console.WriteLine("Window.ShowWindow"); #endif window.Show (); return false; }
public MiniButton (Gtk.Widget label): this () { Add (label); label.Show (); }
private void AddWidget(Gtk.Widget widget) { widget.Show (); this.VBox.Add (widget); }
public static void PrepareFileTxtView(Gtk.TreeView tvTable) { try { Gtk.ListStore listStore = new Gtk.ListStore( new System.Type[]{ typeof(string) } ); tvTable.Model = listStore; // Delete existing columns while( tvTable.Columns.Length > 0 ) { tvTable.RemoveColumn( tvTable.Columns[ 0 ] ); } // Create data column var column = new Gtk.TreeViewColumn(); var cell = new Gtk.CellRendererText(); column.Title = "txt"; column.PackStart( cell, true ); cell.Editable = false; cell.Foreground = "black"; cell.Background = "white"; column.AddAttribute( cell, "text", 0 ); tvTable.AppendColumn( column ); } catch(Exception e) { Util.MsgError( null, Core.AppInfo.Name, "Error building view: '" + e.Message + '\'' ); } tvTable.EnableGridLines = TreeViewGridLines.Horizontal; tvTable.SetCursor( new TreePath( new int[]{ 0 } ), tvTable.Columns[ 0 ], false ); tvTable.Show(); }
internal void UseCustomWidget (Gtk.Widget widget) { toolbarProvider.Attach (null); ClearToolbar (); customWidget = true; frame.Remove (frame.Child); frame.Add (widget); widget.Show (); }
protected void addWidget(Gtk.Widget addMe, int posX, int posY) { fixed1.Put(addMe, posX, posY); addMe.Show(); }
internal void UseCustomWidget (Gtk.Widget widget) { customWidget = true; frame.Remove (frame.Child); frame.Add (widget); widget.Show (); }
internal void UseCustomWidget (Gtk.Widget widget) { if (container != null) { var toolbar = container.GetToolbar (Gtk.PositionType.Top); foreach (var w in toolbar.Children) toolbar.Remove (w); } customWidget = true; frame.Remove (frame.Child); frame.Add (widget); widget.Show (); }
/// <summary> /// Packs widget on the right side of the box. Every next packed widget /// gets packed before previous /// </summary> /// <param name="aWidget"> /// Widget to insert inside <see cref="Gtk.Widget"/> /// </param> public void PackEnd (Gtk.Widget aWidget) { if (aWidget == null) return; if (AfterAlignment.RightPadding == 0) AfterAlignment.RightPadding = 3; AfterBox.PackEnd (aWidget, false, false, 0); if (aWidget is Gtk.Entry) { (aWidget as Gtk.Entry).FocusInEvent += OnEntryFocusIn; (aWidget as Gtk.Entry).FocusOutEvent += OnEntryFocusOut; } else { aWidget.CanFocus = false; } aWidget.Show(); }
/// <summary> /// Packs widget on the left side of the box. Every next packed widget /// gets packed after previous /// </summary> /// <param name="aWidget"> /// Widget to insert inside <see cref="Gtk.Widget"/> /// </param> public void PackStart (Gtk.Widget aWidget) { if (aWidget == null) return; if (BeforeAlignment.LeftPadding == 0) BeforeAlignment.LeftPadding = 3; BeforeBox.PackEnd (aWidget, false, false, 0); aWidget.CanFocus = false; aWidget.Show(); }
protected override void OnAdded(Gtk.Widget widget) { if (widget.Equals(this.vboxWindow)) base.OnAdded (widget); this.vboxClient.PackStart (widget, true, true, 0); widget.Show(); }
private void AddButton(Gtk.Button button, Gtk.ResponseType response, bool is_default) { button.Show (); AddActionWidget (button, response); if (is_default) { DefaultResponse = response; button.AddAccelerator ("activate", accel_group, (uint) Gdk.Key.Escape, 0, Gtk.AccelFlags.Visible); } }
public void AddChild (Gtk.Widget child, ChildPosition position) { child.Parent = this; child.Show (); children.Add (new SmartScrolledWindowContainerChild (this, child) { ChildPosition = position }); }
void SetWidget (Gtk.Widget widget) { RemoveBoxChild (); box.Add (widget); widget.Show (); box.Show (); }
public void AddChild (Gtk.Widget child) { child.Parent = this; children.Add (new ContainerChild (this, child)); child.Show (); }
/// <summary> /// Packs widget on the left side of the box. Every next packed widget /// gets packed after previous /// </summary> /// <param name="aWidget"> /// Widget to insert inside <see cref="Gtk.Widget"/> /// </param> public void PackStart (Gtk.Widget aWidget) { if (aWidget == null) return; if (BeforeAlignment.LeftPadding == 0) BeforeAlignment.LeftPadding = 3; BeforeBox.PackEnd (aWidget, false, false, 0); if (aWidget is Gtk.Entry) { (aWidget as Gtk.Widget).FocusInEvent += OnEntryFocusIn; (aWidget as Gtk.Widget).FocusOutEvent += OnEntryFocusOut; } else { aWidget.CanFocus = false; } aWidget.Show(); }