/// <summary> /// Constructor with parameters /// </summary> /// <param name="programManager">reference to programManager</param> /// <param name="terminal">reference to the terminal that the string will be writen</param> /// <param name="contorScrieText">constor used for naming</param> public WriteTextCommandPanel(ProgramManagerCommand programManager, ConsoleTextBox terminal, int contorScrieText) : base(programManager) { _terminal = terminal; RichTextBox richTextBox = new RichTextBox(); richTextBox.BackColor = System.Drawing.Color.White; richTextBox.Location = new System.Drawing.Point(21, 28); richTextBox.Name = "panelScrieText" + contorScrieText; richTextBox.Size = new System.Drawing.Size(136, 53); richTextBox.TabIndex = 0; richTextBox.Text = ""; richTextBox.KeyUp += new KeyEventHandler(this.ProcessString); label1 = new Label(); label1.AutoSize = true; label1.Font = new System.Drawing.Font("Microsoft Sans Serif", 14F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); label1.ForeColor = System.Drawing.Color.White; label1.Location = new System.Drawing.Point(79, -1); label1.Name = "label_up" + contorScrieText; label1.Size = new System.Drawing.Size(21, 24); label1.TabIndex = 0; label1.Text = "+"; label2 = new Label(); label2.AutoSize = true; label2.Font = new System.Drawing.Font("Microsoft Sans Serif", 14F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); label2.ForeColor = System.Drawing.Color.White; label2.Location = new System.Drawing.Point(80, 86); label2.Name = "label_down" + contorScrieText; label2.Size = new System.Drawing.Size(21, 24); label2.TabIndex = 0; label2.Text = "+"; label1.Click += new EventHandler(this.LabelUpClick); label2.Click += new EventHandler(this.LabelLeftClick); this.Controls.Add(label1); this.Controls.Add(label2); this.Controls.Add(richTextBox); }
/// <summary> /// Constructor with parameters /// </summary> /// <param name="programManager">reference to programManger</param> /// <param name="terminal">Terminal use to write</param> /// <param name="contorScrieVar">index used for naming</param> public WriteVariableCommandPanel(ProgramManagerCommand programManager, ConsoleTextBox terminal, int contorScrieVar) : base(programManager) { _terminal = terminal; TextBox textBox3 = new TextBox(); textBox3.BackColor = System.Drawing.Color.White; textBox3.Location = new System.Drawing.Point(13, 30); textBox3.Name = "panelScrieVar" + contorScrieVar; textBox3.Size = new System.Drawing.Size(145, 20); textBox3.TabIndex = 0; textBox3.KeyUp += new KeyEventHandler(this.ProcessString); this.Controls.Add(textBox3); label1 = new Label(); label1.AutoSize = true; label1.Font = new System.Drawing.Font("Microsoft Sans Serif", 14F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); label1.ForeColor = System.Drawing.Color.White; label1.Location = new System.Drawing.Point(76, -2); label1.Name = "label_up" + contorScrieVar; label1.Size = new System.Drawing.Size(21, 24); label1.TabIndex = 0; label1.Text = "+"; label2 = new Label(); label2.AutoSize = true; label2.Font = new System.Drawing.Font("Microsoft Sans Serif", 14F, System.Drawing.FontStyle.Regular, System.Drawing.GraphicsUnit.Point, ((byte)(0))); label2.ForeColor = System.Drawing.Color.White; label2.Location = new System.Drawing.Point(76, 58); label2.Name = "label_down" + contorScrieVar; label2.Size = new System.Drawing.Size(21, 24); label2.TabIndex = 0; label2.Text = "+"; label1.Click += new EventHandler(this.LabelUpClick); label2.Click += new EventHandler(this.LabelLeftClick); this.Controls.Add(label1); this.Controls.Add(label2); }