Пример #1
0
        /// <summary>
        /// 生成br资源包
        /// </summary>
        /// <param name="sender"></param>
        /// <param name="e"></param>
        private void button2_Click(object sender, EventArgs e)
        {
            var files = new List <string>();

            foreach (var item in this.listBox1.Items)
            {
                files.Add(item.ToString());
            }
            if (files.Count == 0)
            {
                MessageBox.Show("请拖入文件!");
                return;
            }
            PinyinBuild pinyinBuild = new PinyinBuild();

            pinyinBuild.Load(files);

            pinyinBuild.CreateBr("out/br", this.checkBox1.Checked);
            pinyinBuild = null;
            MessageBox.Show("完成!已保存在 out/br 目录内。");
        }
Пример #2
0
        /// <summary>
        /// 合并文件
        /// </summary>
        /// <param name="sender"></param>
        /// <param name="e"></param>
        private void button6_Click(object sender, EventArgs e)
        {
            var files = new List <string>();

            foreach (var item in this.listBox1.Items)
            {
                files.Add(item.ToString());
            }
            if (files.Count == 0)
            {
                MessageBox.Show("请拖入文件!");
                return;
            }

            PinyinBuild pinyinBuild = new PinyinBuild();

            pinyinBuild.Load(files);

            pinyinBuild.OutputSingleFile("out/allPinyin.txt");
            pinyinBuild = null;
            MessageBox.Show("完成!已保存在 out/allPinyin.txt 文件内。");
        }
Пример #3
0
        /// <summary>
        /// 拼音查错
        /// </summary>
        /// <param name="sender"></param>
        /// <param name="e"></param>
        private void button7_Click(object sender, EventArgs e)
        {
            var files = new List <string>();

            foreach (var item in this.listBox1.Items)
            {
                files.Add(item.ToString());
            }
            if (files.Count == 0)
            {
                MessageBox.Show("请拖入文件!");
                return;
            }

            PinyinBuild pinyinBuild = new PinyinBuild();

            pinyinBuild.Load(files);

            pinyinBuild.CheckPinyin("out/rightPinyin.txt", "out/errorPinyin.txt");
            pinyinBuild = null;
            MessageBox.Show("拼音查错完成!已保存在 out 目录内。");
            // out/rightPinyin.txt
            // out/errorPinyin.txt
        }