private void saveGlyphImageToolStripMenuItem_Click(object sender, EventArgs e)
        {
            int size;

            var sizeDlg = new SizeDialog();

            if (sizeDlg.ShowDialog(this) == DialogResult.OK)
            {
                size = sizeDlg.Size;
            }
            else
            {
                return;
            }

            var sfd = new SaveFileDialog();

            if (sfd.ShowDialog(this) == DialogResult.OK)
            {
                using (var bmp = GlyphPart.BuildGlyph(glyph, size))
                    bmp.Save(sfd.FileName, ImageFormat.Png);
            }
        }
Ejemplo n.º 2
0
        private void saveGlyphImageToolStripMenuItem_Click(object sender, EventArgs e)
        {
            int size;

            var sizeDlg = new SizeDialog();
            if (sizeDlg.ShowDialog(this) == DialogResult.OK)
                size = sizeDlg.Size;
            else
                return;

            var sfd = new SaveFileDialog();
            if (sfd.ShowDialog(this) == DialogResult.OK)
            {
                using (var bmp = GlyphPart.BuildGlyph(glyph, size))
                    bmp.Save(sfd.FileName, ImageFormat.Png);
            }
        }