示例#1
0
 /// <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();
 }
示例#2
0
 /// <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();
 }