Contains mouse event data for the StdPaint.Painter.
Inheritance: System.EventArgs
Exemple #1
0
 static void Painter_MouseMove(object sender, PainterMouseEventArgs e)
 {
     if (click)
     {
         center = e.UnitLocation;
     }
 }
Exemple #2
0
 static void Painter_MouseMove(object sender, PainterMouseEventArgs e)
 {
     if (penOn)
     {
         Painter.ActiveBuffer.DrawLine(prevPos.X, prevPos.Y, e.UnitLocation.X, e.UnitLocation.Y, BufferColor.White);
     }
     prevPos = e.UnitLocation;
 }
Exemple #3
0
 static void Painter_MouseMove(object sender, PainterMouseEventArgs e)
 {
     rotation = (-(double)e.UnitLocation.X / Painter.BackBuffer.Width);
 }
Exemple #4
0
 static void Painter_LeftButtonUp(object sender, PainterMouseEventArgs e)
 {
     penOn = false;
 }
Exemple #5
0
 static void Painter_LeftButtonDown(object sender, PainterMouseEventArgs e)
 {
     penOn = true;
     Painter.ActiveBuffer.Buffer[e.UnitLocation.Y, e.UnitLocation.X].BackColor = BufferColor.White;
 }
Exemple #6
0
 static void Painter_RightButtonDown(object sender, PainterMouseEventArgs e)
 {
     Painter.BackBuffer.DrawCircle(e.UnitLocation.X, e.UnitLocation.Y, 16, new RandomColorBufferBrush(BufferColor.Identity, BufferColor.White));
 }
Exemple #7
0
 static void Painter_RightButtonDown(object sender, PainterMouseEventArgs e)
 {
     paintBuffer.FloodFill(e.UnitLocation.X, e.UnitLocation.Y, pallette[pen]);
 }
Exemple #8
0
 static void Painter_MouseMove(object sender, PainterMouseEventArgs e)
 {
     if (penOn)
     {
         paintBuffer.DrawLine(pLast.X, pLast.Y, e.UnitLocation.X, e.UnitLocation.Y, pallette[pen]);
     }
     pLast = e.UnitLocation;
 }
Exemple #9
0
        static void Painter_LeftButtonDown(object sender, PainterMouseEventArgs e)
        {
            pLast = e.UnitLocation;

            if (!penOn && e.UnitLocation.X < 10 && e.UnitLocation.Y < pallette.Length * 5 / 2)
            {
                pen = e.UnitLocation.Y / 5 + (e.UnitLocation.X / 5) * 8;
            }

            penOn = true;
            paintBuffer.SetUnitBackColor(e.UnitLocation.X, e.UnitLocation.Y, pallette[pen]);
        }
Exemple #10
0
 static void Painter_LeftButtonDown(object sender, PainterMouseEventArgs e)
 {
     click = true;
 }