Example #1
0
 public DXBezierControl()
 {
     Controller = new BezierController();
     Controller.DrawRequired += Controller_DrawRequired;
     InitializeComponent();
     Disposed += DXBezierControl_Disposed;
 }
Example #2
0
 public BezierControl()
 {
     Controller = new BezierController();
     Controller.DrawRequired += Controller_DrawRequired;
     InitializeComponent();
     SetStyle(ControlStyles.AllPaintingInWmPaint | ControlStyles.UserPaint, true);
     context = BufferedGraphicsManager.Current;
     context.MaximumBuffer = new Size(this.Width + 1, this.Height + 1);
     SetStyle(ControlStyles.OptimizedDoubleBuffer, true);
     grafx = context.Allocate(this.CreateGraphics(), new Rectangle(0, 0, this.Width, this.Height));
     DrawToBuffer(grafx.Graphics);
 }