frmRemark.cs
1.7 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Text;
using System.Windows.Forms;
namespace ZedGraph
{
public partial class frmRemark : Form
{
public frmRemark()
{
InitializeComponent();
}
private DialogResult _DialogResult;
private void btn_OK_Click(object sender, EventArgs e)
{
_DialogResult = DialogResult.OK;
this.Close();
}
public DialogResult DialogResult
{
get { return _DialogResult; }
}
public string text
{
get { return textBox1.Text; }
}
public Color backColor
{
get { return p_BackColor.BackColor; }
}
public Color lineColor
{
get { return line.ForeColor; }
}
private void btn_BackColor_Click(object sender, EventArgs e)
{
DialogResult result = colorDialog1.ShowDialog();
if (result == DialogResult.OK)//保存ʼþÏìÓ¦
{
p_BackColor.BackColor = colorDialog1.Color;//»ñÈ¡»òÉèÖÃÓû§Ñ¡ÖеÄÑÕÉ«
}
}
private void btn_ForColor_Click(object sender, EventArgs e)
{
DialogResult result = colorDialog1.ShowDialog();
if (result == DialogResult.OK)//保存ʼþÏìÓ¦
{
line.ForeColor = colorDialog1.Color;//»ñÈ¡»òÉèÖÃÓû§Ñ¡ÖеÄÑÕÉ«
}
}
private void btn_Cancle_Click(object sender, EventArgs e)
{
_DialogResult = DialogResult.Cancel;
this.Close();
}
}
}