2using System.Collections.Generic;
3using System.ComponentModel;
8using System.Threading.Tasks;
9using System.Windows.Forms;
13 public partial class TextInput : Form
15 string textValue =
"";
16 public Font font = DefaultFont;
17 public Color color = Color.Yellow;
18 public string TextValue
25 public TextInput(
string text)
27 InitializeComponent();
36 private void okBut_Click(
object sender, EventArgs e)
38 textValue = textBox.Text;
39 DialogResult = DialogResult.OK;
46 private void cancelBut_Click(
object sender, EventArgs e)
48 DialogResult=DialogResult.Cancel;
58 private void fontBut_Click(
object sender, EventArgs e)
60 if (fontDialog.ShowDialog() != DialogResult.OK)
62 font = fontDialog.Font;
72 private void colorBut_Click(
object sender, EventArgs e)
74 if (colorDialog.ShowDialog() != DialogResult.OK)
76 color = colorDialog.Color;