diff --git a/WindowsFormsApplication1/WindowsFormsApplication1/MainForm.Designer.cs b/WindowsFormsApplication1/WindowsFormsApplication1/MainForm.Designer.cs index 7a17f4e..fc6b1bd 100644 --- a/WindowsFormsApplication1/WindowsFormsApplication1/MainForm.Designer.cs +++ b/WindowsFormsApplication1/WindowsFormsApplication1/MainForm.Designer.cs @@ -41,6 +41,7 @@ namespace WindowsFormsApplication1 this.panel2 = new System.Windows.Forms.Panel(); this.SaveCharButton = new System.Windows.Forms.Button(); this.panel3 = new System.Windows.Forms.Panel(); + this.openSpace = new System.Windows.Forms.PictureBox(); this.SpriteNumberLabel = new System.Windows.Forms.Label(); this.SpriteNumberTextBox = new System.Windows.Forms.TextBox(); this.OpenButton = new System.Windows.Forms.Button(); @@ -59,7 +60,7 @@ namespace WindowsFormsApplication1 this.ButtonAddChar = new System.Windows.Forms.Button(); this.saveFileDialog1 = new System.Windows.Forms.SaveFileDialog(); this.openFileDialog1 = new System.Windows.Forms.OpenFileDialog(); - this.openSpace = new System.Windows.Forms.PictureBox(); + this.label1 = new System.Windows.Forms.Label(); this.panel1.SuspendLayout(); ((System.ComponentModel.ISupportInitialize)(this.PictureBoxBackground)).BeginInit(); this.panel2.SuspendLayout(); @@ -104,6 +105,7 @@ namespace WindowsFormsApplication1 // // panel1 // + this.panel1.Controls.Add(this.label1); this.panel1.Controls.Add(this.label13); this.panel1.Controls.Add(this.PictureBoxBackground); this.panel1.Controls.Add(this.LabelBackground); @@ -126,6 +128,7 @@ namespace WindowsFormsApplication1 this.label13.Size = new System.Drawing.Size(180, 13); this.label13.TabIndex = 23; this.label13.Text = "ИНФОРМАЦИЯ О ПЕРСОНАЖАХ"; + this.label13.Click += new System.EventHandler(this.label13_Click); // // PictureBoxBackground // @@ -143,6 +146,7 @@ namespace WindowsFormsApplication1 this.LabelBackground.Size = new System.Drawing.Size(77, 13); this.LabelBackground.TabIndex = 11; this.LabelBackground.Text = "Выбрать фон:"; + this.LabelBackground.Click += new System.EventHandler(this.LabelBackground_Click); // // dobavitFonButton // @@ -209,6 +213,14 @@ namespace WindowsFormsApplication1 this.panel3.TabIndex = 2; this.panel3.Visible = false; // + // openSpace + // + this.openSpace.Location = new System.Drawing.Point(65, 206); + this.openSpace.Name = "openSpace"; + this.openSpace.Size = new System.Drawing.Size(245, 55); + this.openSpace.TabIndex = 17; + this.openSpace.TabStop = false; + // // SpriteNumberLabel // this.SpriteNumberLabel.AutoSize = true; @@ -300,6 +312,7 @@ namespace WindowsFormsApplication1 this.TextBoxWall2.Name = "TextBoxWall2"; this.TextBoxWall2.Size = new System.Drawing.Size(100, 20); this.TextBoxWall2.TabIndex = 3; + this.TextBoxWall2.KeyPress += new System.Windows.Forms.KeyPressEventHandler(this.TextBoxWall1_KeyPress); // // TextBoxWall1 // @@ -307,6 +320,7 @@ namespace WindowsFormsApplication1 this.TextBoxWall1.Name = "TextBoxWall1"; this.TextBoxWall1.Size = new System.Drawing.Size(100, 20); this.TextBoxWall1.TabIndex = 2; + this.TextBoxWall1.KeyPress += new System.Windows.Forms.KeyPressEventHandler(this.TextBoxWall1_KeyPress); // // ComboBoxMove // @@ -357,13 +371,15 @@ namespace WindowsFormsApplication1 // this.openFileDialog1.FileName = "openFileDialog1"; // - // openSpace + // label1 // - this.openSpace.Location = new System.Drawing.Point(65, 206); - this.openSpace.Name = "openSpace"; - this.openSpace.Size = new System.Drawing.Size(245, 55); - this.openSpace.TabIndex = 17; - this.openSpace.TabStop = false; + this.label1.AutoSize = true; + this.label1.Location = new System.Drawing.Point(14, 274); + this.label1.Name = "label1"; + this.label1.Size = new System.Drawing.Size(259, 13); + this.label1.TabIndex = 24; + this.label1.Text = "number name state view delete"; + this.label1.Click += new System.EventHandler(this.label1_Click); // // MainForm // @@ -421,5 +437,6 @@ namespace WindowsFormsApplication1 private System.Windows.Forms.PictureBox PictureBoxBackground; private System.Windows.Forms.Label label13; private System.Windows.Forms.PictureBox openSpace; + private System.Windows.Forms.Label label1; } -} +} \ No newline at end of file diff --git a/WindowsFormsApplication1/WindowsFormsApplication1/MainForm.cs b/WindowsFormsApplication1/WindowsFormsApplication1/MainForm.cs index 0757665..3b22819 100644 --- a/WindowsFormsApplication1/WindowsFormsApplication1/MainForm.cs +++ b/WindowsFormsApplication1/WindowsFormsApplication1/MainForm.cs @@ -34,7 +34,6 @@ namespace WindowsFormsApplication1 int yPersa = 300; int nomerPersa = 0; int pNomer = 0; - PictureBox[] pic1 = new PictureBox[1000]; public MainForm() @@ -43,6 +42,8 @@ namespace WindowsFormsApplication1 openFileDialog1.Filter = "Kartinki|*.bmp"; saveFileDialog1.Filter = "cpp files|*.cpp"; + + } private void buttonAddCharClick(object sender, EventArgs e) @@ -55,6 +56,7 @@ namespace WindowsFormsApplication1 { return "per" + nomer.ToString(); } + private void delete_pics2(string filename, int nomer) { @@ -102,13 +104,12 @@ namespace WindowsFormsApplication1 { if (pNomer == -120) { - persons[nomerPersa].l1 = new Label(); persons[nomerPersa].l1.Top = yPersa; persons[nomerPersa].l1.Left = 30; persons[nomerPersa].l1.Width = 20; persons[nomerPersa].l1.Visible = true; - persons[nomerPersa].l1.Text = "1"; + persons[nomerPersa].l1.Text = (nomerPersa + 1).ToString(); this.panel1.Controls.Add(persons[nomerPersa].l1); persons[nomerPersa].l2 = new Label(); @@ -116,7 +117,7 @@ namespace WindowsFormsApplication1 persons[nomerPersa].l2.Left = 60; persons[nomerPersa].l2.Width = 60; persons[nomerPersa].l2.Visible = true; - persons[nomerPersa].l2.Text = "Перс1"; + persons[nomerPersa].l2.Text = "Перс" + (nomerPersa + 1).ToString(); this.panel1.Controls.Add(persons[nomerPersa].l2); persons[nomerPersa].l3 = new Label(); @@ -124,7 +125,7 @@ namespace WindowsFormsApplication1 persons[nomerPersa].l3.Left = 120; persons[nomerPersa].l3.Width = 40; persons[nomerPersa].l3.Visible = true; - persons[nomerPersa].l3.Text = "ocphcghfgh"; + persons[nomerPersa].l3.Text = "saved"; this.panel1.Controls.Add(persons[nomerPersa].l3); persons[nomerPersa].b1 = new Button(); @@ -132,19 +133,35 @@ namespace WindowsFormsApplication1 persons[nomerPersa].b1.Left = 170; persons[nomerPersa].b1.Width = 50; persons[nomerPersa].b1.Visible = true; - persons[nomerPersa].b1.Text = "R" + nomerPersa.ToString(); + persons[nomerPersa].b1.Text = "Edit"; persons[nomerPersa].b1.MouseClick += new MouseEventHandler(this.button1_Click_2); this.panel1.Controls.Add(persons[nomerPersa].b1); + + ToolTip tView = new ToolTip(); + tView.IsBalloon = true; + tView.InitialDelay = 0; + tView.ShowAlways = true; + tView.AutoPopDelay = 2000; + tView.SetToolTip(persons[nomerPersa].b1, "View/edit person"); persons[nomerPersa].b2 = new Button(); persons[nomerPersa].b2.Top = yPersa; persons[nomerPersa].b2.Left = 230; persons[nomerPersa].b2.Width = 50; persons[nomerPersa].b2.Visible = true; - persons[nomerPersa].b2.Text = "X"; + persons[nomerPersa].b2.Text = "Del"; + persons[nomerPersa].b2.Click += + new System.EventHandler(this.label13_Click); this.panel1.Controls.Add(persons[nomerPersa].b2); + ToolTip tDelete = new ToolTip(); + tDelete.IsBalloon = true; + tDelete.InitialDelay = 0; + tDelete.ShowAlways = true; + tDelete.AutoPopDelay = 2000; + tDelete.SetToolTip(persons[nomerPersa].b2, "Delete this person"); + persons[nomerPersa].coord = TextBoxWall1.Text; persons[nomerPersa].coord2 = TextBoxWall2.Text; persons[nomerPersa].time1 = TextBoxTime1.Text; @@ -166,9 +183,10 @@ namespace WindowsFormsApplication1 persons[pNomer].sprite = SpriteNumberTextBox.Text; persons[pNomer].moveside = ComboBoxMove.Text; persons[pNomer].nomer = pNomer; - } + String[] arr = TextBoxWall1.Text.Split(new String[] { " " }, StringSplitOptions.None); + //MessageBox.Show(arr[0]); } private void circle_create_person(string filename, string name) @@ -333,5 +351,34 @@ namespace WindowsFormsApplication1 } } } + + private void LabelBackground_Click(object sender, EventArgs e) + { + } + + private void label1_Click(object sender, EventArgs e) + { + } + + private void label13_Click(object sender, EventArgs e) + { + this.panel1.Controls.Remove(persons[nomerPersa - 1].l1); + this.panel1.Controls.Remove(persons[nomerPersa - 1].l2); + this.panel1.Controls.Remove(persons[nomerPersa - 1].l3); + this.panel1.Controls.Remove(persons[nomerPersa - 1].b1); + this.panel1.Controls.Remove(persons[nomerPersa - 1].b2); + nomerPersa--; + yPersa = yPersa - 30; + } + + private void TextBoxWall1_KeyPress(object sender, KeyPressEventArgs e) + { + char c = e.KeyChar; + + if (!(char.IsDigit(c) || c == '\b' || c == ' ')) + { + e.Handled = true; + } + } } -} +} \ No newline at end of file diff --git a/WindowsFormsApplication1/WindowsFormsApplication1/bin/Debug/WindowsFormsApplication1.exe b/WindowsFormsApplication1/WindowsFormsApplication1/bin/Debug/WindowsFormsApplication1.exe index 3dbaf35..1649a59 100644 Binary files a/WindowsFormsApplication1/WindowsFormsApplication1/bin/Debug/WindowsFormsApplication1.exe and b/WindowsFormsApplication1/WindowsFormsApplication1/bin/Debug/WindowsFormsApplication1.exe differ diff --git a/WindowsFormsApplication1/WindowsFormsApplication1/bin/Debug/WindowsFormsApplication1.pdb b/WindowsFormsApplication1/WindowsFormsApplication1/bin/Debug/WindowsFormsApplication1.pdb index ec1cccb..aa65e96 100644 Binary files a/WindowsFormsApplication1/WindowsFormsApplication1/bin/Debug/WindowsFormsApplication1.pdb and b/WindowsFormsApplication1/WindowsFormsApplication1/bin/Debug/WindowsFormsApplication1.pdb differ diff --git a/WindowsFormsApplication1/WindowsFormsApplication1/obj/Debug/DesignTimeResolveAssemblyReferences.cache b/WindowsFormsApplication1/WindowsFormsApplication1/obj/Debug/DesignTimeResolveAssemblyReferences.cache index c13d716..223a82b 100644 Binary files a/WindowsFormsApplication1/WindowsFormsApplication1/obj/Debug/DesignTimeResolveAssemblyReferences.cache and b/WindowsFormsApplication1/WindowsFormsApplication1/obj/Debug/DesignTimeResolveAssemblyReferences.cache differ diff --git a/WindowsFormsApplication1/WindowsFormsApplication1/obj/Debug/DesignTimeResolveAssemblyReferencesInput.cache b/WindowsFormsApplication1/WindowsFormsApplication1/obj/Debug/DesignTimeResolveAssemblyReferencesInput.cache index 02833c5..e553162 100644 Binary files a/WindowsFormsApplication1/WindowsFormsApplication1/obj/Debug/DesignTimeResolveAssemblyReferencesInput.cache and b/WindowsFormsApplication1/WindowsFormsApplication1/obj/Debug/DesignTimeResolveAssemblyReferencesInput.cache differ diff --git a/WindowsFormsApplication1/WindowsFormsApplication1/obj/Debug/WindowsFormsApplication1.csproj.CoreCompileInputs.cache b/WindowsFormsApplication1/WindowsFormsApplication1/obj/Debug/WindowsFormsApplication1.csproj.CoreCompileInputs.cache index cd71255..e24b25d 100644 --- a/WindowsFormsApplication1/WindowsFormsApplication1/obj/Debug/WindowsFormsApplication1.csproj.CoreCompileInputs.cache +++ b/WindowsFormsApplication1/WindowsFormsApplication1/obj/Debug/WindowsFormsApplication1.csproj.CoreCompileInputs.cache @@ -1 +1 @@ -38bfce534dc3c0d959750689d6e2ad74c4628282 +9fcadd9ef444bb25b044c80f8ae2b04d1a041afd diff --git a/WindowsFormsApplication1/WindowsFormsApplication1/obj/Debug/WindowsFormsApplication1.csproj.FileListAbsolute.txt b/WindowsFormsApplication1/WindowsFormsApplication1/obj/Debug/WindowsFormsApplication1.csproj.FileListAbsolute.txt index 91f8800..76c0592 100644 --- a/WindowsFormsApplication1/WindowsFormsApplication1/obj/Debug/WindowsFormsApplication1.csproj.FileListAbsolute.txt +++ b/WindowsFormsApplication1/WindowsFormsApplication1/obj/Debug/WindowsFormsApplication1.csproj.FileListAbsolute.txt @@ -17,3 +17,13 @@ C:\Users\user\Desktop\Overnewing\vst\MultRedactor-master\WindowsFormsApplication C:\Users\user\Desktop\Overnewing\vst\MultRedactor-master\WindowsFormsApplication1\WindowsFormsApplication1\bin\Debug\WindowsFormsApplication1.exe.config C:\Users\user\Desktop\Overnewing\vst\MultRedactor-master\WindowsFormsApplication1\WindowsFormsApplication1\bin\Debug\WindowsFormsApplication1.exe C:\Users\user\Desktop\Overnewing\vst\MultRedactor-master\WindowsFormsApplication1\WindowsFormsApplication1\bin\Debug\WindowsFormsApplication1.pdb +C:\Users\Инженерка\Desktop\MultRedactor-master\WindowsFormsApplication1\WindowsFormsApplication1\bin\Debug\WindowsFormsApplication1.exe.config +C:\Users\Инженерка\Desktop\MultRedactor-master\WindowsFormsApplication1\WindowsFormsApplication1\bin\Debug\WindowsFormsApplication1.exe +C:\Users\Инженерка\Desktop\MultRedactor-master\WindowsFormsApplication1\WindowsFormsApplication1\bin\Debug\WindowsFormsApplication1.pdb +C:\Users\Инженерка\Desktop\MultRedactor-master\WindowsFormsApplication1\WindowsFormsApplication1\obj\Debug\WindowsFormsApplication1.csprojResolveAssemblyReference.cache +C:\Users\Инженерка\Desktop\MultRedactor-master\WindowsFormsApplication1\WindowsFormsApplication1\obj\Debug\WindowsFormsApplication1.MainForm.resources +C:\Users\Инженерка\Desktop\MultRedactor-master\WindowsFormsApplication1\WindowsFormsApplication1\obj\Debug\WindowsFormsApplication1.Properties.Resources.resources +C:\Users\Инженерка\Desktop\MultRedactor-master\WindowsFormsApplication1\WindowsFormsApplication1\obj\Debug\WindowsFormsApplication1.csproj.GenerateResource.Cache +C:\Users\Инженерка\Desktop\MultRedactor-master\WindowsFormsApplication1\WindowsFormsApplication1\obj\Debug\WindowsFormsApplication1.csproj.CoreCompileInputs.cache +C:\Users\Инженерка\Desktop\MultRedactor-master\WindowsFormsApplication1\WindowsFormsApplication1\obj\Debug\WindowsFormsApplication1.exe +C:\Users\Инженерка\Desktop\MultRedactor-master\WindowsFormsApplication1\WindowsFormsApplication1\obj\Debug\WindowsFormsApplication1.pdb diff --git a/WindowsFormsApplication1/WindowsFormsApplication1/obj/Debug/WindowsFormsApplication1.csproj.GenerateResource.Cache b/WindowsFormsApplication1/WindowsFormsApplication1/obj/Debug/WindowsFormsApplication1.csproj.GenerateResource.Cache index ca577a0..bb805bb 100644 Binary files a/WindowsFormsApplication1/WindowsFormsApplication1/obj/Debug/WindowsFormsApplication1.csproj.GenerateResource.Cache and b/WindowsFormsApplication1/WindowsFormsApplication1/obj/Debug/WindowsFormsApplication1.csproj.GenerateResource.Cache differ diff --git a/WindowsFormsApplication1/WindowsFormsApplication1/obj/Debug/WindowsFormsApplication1.exe b/WindowsFormsApplication1/WindowsFormsApplication1/obj/Debug/WindowsFormsApplication1.exe index 3dbaf35..1649a59 100644 Binary files a/WindowsFormsApplication1/WindowsFormsApplication1/obj/Debug/WindowsFormsApplication1.exe and b/WindowsFormsApplication1/WindowsFormsApplication1/obj/Debug/WindowsFormsApplication1.exe differ diff --git a/WindowsFormsApplication1/WindowsFormsApplication1/obj/Debug/WindowsFormsApplication1.pdb b/WindowsFormsApplication1/WindowsFormsApplication1/obj/Debug/WindowsFormsApplication1.pdb index ec1cccb..aa65e96 100644 Binary files a/WindowsFormsApplication1/WindowsFormsApplication1/obj/Debug/WindowsFormsApplication1.pdb and b/WindowsFormsApplication1/WindowsFormsApplication1/obj/Debug/WindowsFormsApplication1.pdb differ