void UpdateConsoleMessages()
 {
     for (int i = 0; i < ConsoleMessagePanel.Controls.Count; i++)
     {
         ConsoleMessagePanel panel = (ConsoleMessagePanel)ConsoleMessagePanel.Controls[i];
         panel.Size = new Size(ConsoleMessagePanel.Size.Width, 20);
         panel.messageLabel.Size = panel.Size;
     }
     ConsoleMessagePanel.Refresh();
 }
 private void EreaseButton_Click(object sender, EventArgs e)
 {
     if (ConsoleMessagePanel.Controls.Count > 0)
     {
         foreach (Control c in messageControls)
         {
             c.Dispose();
         }
         messageControls.Clear();
         ConsoleMessagePanel.Refresh();
     }
 }