Exemple #1
0
 private void pictureBox1_MouseUp(object sender, MouseEventArgs e)
 {
     isMouse = false;
     arrayPoints.ResetPoints();
     if (crc_OK == true)
     {
         Graphics gr = pictureBox1.CreateGraphics();
         gr.DrawEllipse(pen, firstp.X, firstp.Y, e.X - firstp.X, e.Y - firstp.Y);
         crc_OK = false;
     }
     else if (rec_OK == true)
     {
         Graphics gr = pictureBox1.CreateGraphics();
         gr.DrawRectangle(pen, firstp.X, firstp.Y, e.X - firstp.X, e.Y - firstp.Y);
         rec_OK = false;
     }
     else
     {
         return;
     }
 }
Exemple #2
0
 private void secondCanvas_MouseUp(object sender, MouseEventArgs e)
 {
     isMousePressed = false;
     secondArrayPoints.ResetPoints();
 } // непосредственно рисование на втором холсте
Exemple #3
0
        } // нажатие на холст

        private void firstCanvas_MouseUp(object sender, MouseEventArgs e)
        {
            isMousePressed = false;
            firstArrayPoints.ResetPoints();
        } // отжатие холста :)