private void btnIncrement_Click(object sender, EventArgs e) { btnReset.Visible = true; WindowsViewModel.IncrementMuta(0.2f); WindowsViewModel.SetLayer(int.Parse(listBox1.SelectedItem.ToString()), trackBar3.Value); pictureBox1.Image = WindowsViewModel.Deseneaza(trackBar1.Value, trackBar2.Value); }
private void trackBar1_Scroll(object sender, EventArgs e) { label1.Text = "Nr Puncte=" + trackBar1.Value; trackBar2.Maximum = (int)Math.Floor((decimal)trackBar1.Value / 2); pictureBox1.Image = WindowsViewModel.Deseneaza(trackBar1.Value, trackBar2.Value); label2.Text = "Linii=" + trackBar2.Value; }
private void btnCuloare_Click(object sender, EventArgs e) { if (colorDialog1.ShowDialog() == DialogResult.OK) { WindowsViewModel.ChangeColor(new Pen(colorDialog1.Color)); pictureBox1.Image = WindowsViewModel.Deseneaza(trackBar1.Value, trackBar2.Value); } }
private void btnmuta2_Click(object sender, EventArgs e) { if (btnreset2.Visible == false) { btnreset2.Visible = true; } WindowsViewModel.IncrementMuta(0, 7.0f); pictureBox1.Image = WindowsViewModel.Deseneaza(trackBar1.Value, trackBar2.Value); }
private void trackBar3_Scroll(object sender, EventArgs e) { label3.Text = "Distanta=" + trackBar3.Value + "(units)"; if (listBox1.SelectedItem != null) { WindowsViewModel.SetLayer(int.Parse(listBox1.SelectedItem.ToString()), trackBar3.Value); pictureBox1.Image = WindowsViewModel.Deseneaza(trackBar1.Value, trackBar2.Value); } }
private void trackBar2_Scroll(object sender, EventArgs e) { label2.Text = "Linii=" + trackBar2.Value; if (trackBar1.Value <= trackBar2.Value) { MessageBox.Show("Nu se pot trage mai multe linii decat uncte existante!"); } else { pictureBox1.Image = WindowsViewModel.Deseneaza(trackBar1.Value, trackBar2.Value); } }
private void trackBar1_Scroll(object sender, EventArgs e) { label1.Text = "Nr Puncte=" + trackBar1.Value; if (trackBar1.Value <= trackBar2.Value) { MessageBox.Show("Nu se pot trage mai multe linii decat puncte existante!"); } else { pictureBox1.Image = WindowsViewModel.Deseneaza(trackBar1.Value, trackBar2.Value); } trackBar2.Maximum = (int)Math.Floor((decimal)trackBar1.Value / 2); label2.Text = "Linii=" + trackBar2.Value; }
private void btnreset2_Click(object sender, EventArgs e) { WindowsViewModel.ResetMuta(false, true); pictureBox1.Image = WindowsViewModel.Deseneaza(trackBar1.Value, trackBar2.Value); btnreset2.Visible = false; }
private void listBox1_SelectedIndexChanged(object sender, EventArgs e) { trackBar1.Minimum = int.Parse(listBox1.SelectedItem.ToString()); WindowsViewModel.SetLayer(int.Parse(listBox1.SelectedItem.ToString()), trackBar3.Value); pictureBox1.Image = WindowsViewModel.Deseneaza(trackBar1.Value, trackBar2.Value); }
private void trackBar2_Scroll(object sender, EventArgs e) { label2.Text = "Linii=" + trackBar2.Value; pictureBox1.Image = WindowsViewModel.Deseneaza(trackBar1.Value, trackBar2.Value); }