using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Text;
using System.Windows.Forms;

namespace FYEDrawDemo_CSharp
{
    public partial class TextPropForm : Form
    {
        public int m_iSeqNum;
        public string m_sContent;
        public int m_isDisplay;

        public TextPropForm()
        {
            InitializeComponent();
        }

        private void btnOK_Click(object sender, EventArgs e)
        {
            m_iSeqNum = Int32.Parse(txtSeqNum.Text);
            m_sContent = txtContent.Text;
            m_isDisplay = chkDisplay.Checked ? 1 : 0;

            this.DialogResult = DialogResult.OK;
        }

        private void btnCancel_Click(object sender, EventArgs e)
        {
            this.DialogResult = DialogResult.Cancel;
        }

        private void TextPropForm_Load(object sender, EventArgs e)
        {
            txtSeqNum.Text = string.Format("{0}", m_iSeqNum);
            txtContent.Text = m_sContent;
            chkDisplay.Checked = m_isDisplay != 0;
        }
    }
}
