コード例 #1
0
 private KryptonCheckButton CreatePageLink( PagingLink link)
 {
     var button = new KryptonCheckButton();
     button.ButtonStyle = ComponentFactory.Krypton.Toolkit.ButtonStyle.LowProfile;
     button.Cursor = System.Windows.Forms.Cursors.Hand;
     button.Location = new System.Drawing.Point(0, 0);
     button.Margin = new System.Windows.Forms.Padding(0);
     button.Size = link.Text.Length == 1 ? new System.Drawing.Size(29, 25) : new System.Drawing.Size(10 + ( link.Text.Length * 10), 25);
     button.StateCommon.Border.DrawBorders = ((ComponentFactory.Krypton.Toolkit.PaletteDrawBorders)((((ComponentFactory.Krypton.Toolkit.PaletteDrawBorders.Top | ComponentFactory.Krypton.Toolkit.PaletteDrawBorders.Bottom)
     | ComponentFactory.Krypton.Toolkit.PaletteDrawBorders.Left)
     | ComponentFactory.Krypton.Toolkit.PaletteDrawBorders.Right)));
     button.StateCommon.Border.Width = 1;
     button.StateCommon.Content.ShortText.Font = new System.Drawing.Font("Tahoma", 8.25F, System.Drawing.FontStyle.Underline, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
     button.Values.Text = link.Text;
     button.Tag = link;
     button.Checked = link.IsSelected;
     button.CheckedChanged += delegate(object sender, EventArgs e)
     {
         var b = (KryptonCheckButton)sender;
         if (b.Checked)
         {
             OnPageSelected(this, new GalleryPageSelectedEventArgs(link));
             UpdatePagingButtons(b);
         }
     };
     return button;
 }
コード例 #2
0
 public GalleryPageSelectedEventArgs(PagingLink link)
 {
     Link = link;
 }