MessageForm.cs 1020 B

1234567891011121314151617181920212223242526272829303132
  1. using System;
  2. using System.Collections.Generic;
  3. using System.ComponentModel;
  4. using System.Data;
  5. using System.Drawing;
  6. using System.Linq;
  7. using System.Text;
  8. using System.Threading.Tasks;
  9. using System.Windows.Forms;
  10. using Sunny.UI;
  11. namespace YangjieTester
  12. {
  13. public partial class MessageForm : UIForm
  14. {
  15. public MessageForm()
  16. {
  17. InitializeComponent();
  18. }
  19. public MessageForm(string caption,string info,Color captionBackColor):this()
  20. {
  21. this.Caption=caption;
  22. this.Info=info;
  23. this.CaptionBackColor=captionBackColor;
  24. lblCaption.Text=caption;
  25. lblInfo.Text=info;
  26. lblCaption.BackColor=captionBackColor;
  27. }
  28. public string Caption { get => lblCaption.Text; set => lblCaption.Text = value; }
  29. public string Info { get => lblInfo.Text; set => lblInfo.Text = value; }
  30. public Color CaptionBackColor { get => lblCaption.BackColor; set => lblCaption.BackColor = value; }
  31. }
  32. }