Пример #1
0
        public DropdownGroupTest()
            : base(WindowType.Toplevel)
        {
            AddEvents ((int)(Gdk.EventMask.ButtonPressMask | Gdk.EventMask.ButtonReleaseMask | Gdk.EventMask.PointerMotionMask));

            HBox master = new HBox ();
            master.AddEvents ((int)(Gdk.EventMask.ButtonPressMask | Gdk.EventMask.ButtonReleaseMask | Gdk.EventMask.PointerMotionMask));

            Title = "Ribbons Sample";
            AppPaintable = true;

            Ribbons.Button button0 = new Ribbons.Button ("Hello World");

            RibbonGroup group0 = new RibbonGroup ();
            group0.Label = "Summer of Code";
            group0.Child = button0;
            group0.Expand += onClick;

            DropdownRibbonGroup dropGroup0 = new DropdownRibbonGroup ();
            dropGroup0.Group = group0;
            dropGroup0.Label = "Drop 1";

            DropdownRibbonGroup dropGroup1 = new DropdownRibbonGroup ();
            dropGroup1.Group = group0;
            dropGroup1.Label = "Drop 2";

            master.PackStart (dropGroup0, false, false, 0);
            master.PackStart (dropGroup1, false, false, 0);

            Add (master);

            ScreenChanged += Window_OnScreenChanged;
            Window_OnScreenChanged (this, null);
            ExposeEvent += Window_OnExpose;
            DeleteEvent += Window_OnDelete;

            this.Resize (200, 200);
            this.ShowAll ();
        }
Пример #2
0
 private DropdownRibbonGroup CreateDropdownGroup2()
 {
     DropdownRibbonGroup ret = new DropdownRibbonGroup ();
     ret.Label = "Gallery";
     return ret;
 }
Пример #3
0
 private DropdownRibbonGroup CreateDropdownGroup1()
 {
     DropdownRibbonGroup ret = new DropdownRibbonGroup ();
     ret.Label = "I will be back";
     return ret;
 }
Пример #4
0
 private DropdownRibbonGroup CreateDropdownGroup0()
 {
     DropdownRibbonGroup ret = new DropdownRibbonGroup ();
     ret.Label = "Summer of Code";
     return ret;
 }