コード例 #1
0
ファイル: BdfImporter.cs プロジェクト: drdnar/MFE
 public BdfImporter(MasterWindow m)
 {
     InitializeComponent();
     ImportedFont.WidthMustBeMultipleOfEight = false;
     Chart = new PreviewChart(this);
     Browser = new BdfBrowser(this);
     Master = m;
 }
コード例 #2
0
 public BdfImporter(MasterWindow m)
 {
     InitializeComponent();
     ImportedFont.WidthMustBeMultipleOfEight = false;
     Chart   = new PreviewChart(this);
     Browser = new BdfBrowser(this);
     Master  = m;
 }
コード例 #3
0
ファイル: CharEditorWindow.cs プロジェクト: drdnar/MFE
 public CharEditorWindow(MasterWindow master)
 {
     InitializeComponent();
     Master = master;
     charEditor.CurrentChar = CurrentFont[(int)charSelectorUpDown.Value];
     RefreshData();
     charEditor.FillOnDrag = true;
 }
コード例 #4
0
ファイル: CharEditorWindow.cs プロジェクト: drdnar/MFE
 public CharEditorWindow(MasterWindow master)
 {
     InitializeComponent();
     Master = master;
     charEditor.CurrentChar = CurrentFont[(int)charSelectorUpDown.Value];
     RefreshData();
     charEditor.FillOnDrag = true;
 }
コード例 #5
0
ファイル: ExportsWindow.cs プロジェクト: drdnar/MFE
 public ExportsWindow(MasterWindow master)
 {
     InitializeComponent();
     Master = master;
     this.MdiParent = master;
     this.Show();
     foreach (Exports.FontExporter.Export e in Exports.FontExporter.Exports)
         exporterListBox.Items.Add(e.FileTypeDescription);
 }
コード例 #6
0
ファイル: FontPropertiesEditor.cs プロジェクト: drdnar/MFE
 public FontPropertiesEditor(MasterWindow master)
 {
     Master = master;
     InitializeComponent();
     //keyComboBox.BeginUpdate();
     foreach (KeyValuePair<string, string> p in CurrentFont.AboutData)
         keyComboBox.Items.Add(p.Key);
     //keyComboBox.EndInvoke(
     RefreshData();
 }
コード例 #7
0
 public ExportsWindow(MasterWindow master)
 {
     InitializeComponent();
     Master         = master;
     this.MdiParent = master;
     this.Show();
     foreach (Exports.FontExporter.Export e in Exports.FontExporter.Exports)
     {
         exporterListBox.Items.Add(e.FileTypeDescription);
     }
 }
コード例 #8
0
ファイル: FontPropertiesEditor.cs プロジェクト: drdnar/MFE
 public FontPropertiesEditor(MasterWindow master)
 {
     Master = master;
     InitializeComponent();
     //keyComboBox.BeginUpdate();
     foreach (KeyValuePair <string, string> p in CurrentFont.AboutData)
     {
         keyComboBox.Items.Add(p.Key);
     }
     //keyComboBox.EndInvoke(
     RefreshData();
 }
コード例 #9
0
ファイル: PreviewText.cs プロジェクト: drdnar/MFE
 public PreviewText(MasterWindow master)
 {
     Master = master;
     InitializeComponent();
     SetStyle(ControlStyles.AllPaintingInWmPaint | ControlStyles.OptimizedDoubleBuffer | ControlStyles.ResizeRedraw | ControlStyles.UserPaint, true);
     fontTextPanel.CurrentFont = CurrentFont;
     backColorButton.BackColor = PreviewBackColor;
     foreColorButton.BackColor = PreviewForeColor;
     this.MdiParent            = master;
     Master.CharEditorWindow.charEditor.PixelChanged += charEditor_PixelChanged;
     fontTextPanel.ScaleFactor  = (int)sizeUpDown.Value;
     fontTextPanel.ScreenWidth  = (int)widthUpDown.Value;
     fontTextPanel.ScreenHeight = (int)heightUpDown.Value;
     Show();
 }
コード例 #10
0
ファイル: PreviewText.cs プロジェクト: drdnar/MFE
 public PreviewText(MasterWindow master)
 {
     Master = master;
     InitializeComponent();
     SetStyle(ControlStyles.AllPaintingInWmPaint | ControlStyles.OptimizedDoubleBuffer | ControlStyles.ResizeRedraw | ControlStyles.UserPaint, true);
     fontTextPanel.CurrentFont = CurrentFont;
     backColorButton.BackColor = PreviewBackColor;
     foreColorButton.BackColor = PreviewForeColor;
     this.MdiParent = master;
     Master.CharEditorWindow.charEditor.PixelChanged += charEditor_PixelChanged;
     fontTextPanel.ScaleFactor = (int)sizeUpDown.Value;
     fontTextPanel.ScreenWidth = (int)widthUpDown.Value;
     fontTextPanel.ScreenHeight = (int)heightUpDown.Value;
     Show();
 }
コード例 #11
0
ファイル: HelpWindow.cs プロジェクト: drdnar/MFE
        public HelpWindow(MasterWindow master)
        {
            Master = master;
            InitializeComponent();
            this.MdiParent = Master;
            this.Show();

            Index = XDocument.Parse(GetTextFile("index.xml"));
            TreeNode rootNode = new TreeNode();
            rootNode.Text = "MFE";
            topicsTreeView.Nodes.Add(rootNode);

            addNodes(Index.FirstNode, rootNode);

            currentItemRichTextBox.ReadOnly = true;
            currentItemRichTextBox.Rtf = GetTextFile("default.rtf");

            rootNode.ExpandAll();
        }
コード例 #12
0
ファイル: PreviewChart.cs プロジェクト: drdnar/MFE
        public PreviewChart(Form master)
        {
            MasterWindow masterWindow = master as MasterWindow;
            BdfImporter  importer     = master as BdfImporter;

            Master = master;
            InitializeComponent();
            SetStyle(ControlStyles.AllPaintingInWmPaint | ControlStyles.OptimizedDoubleBuffer | ControlStyles.ResizeRedraw | ControlStyles.UserPaint, true);
            if (masterWindow != null)
            {
                masterWindow.PreviewChart = this;
                masterWindow.CharEditorWindow.charEditor.PixelChanged += charEditor_PixelChanged;
            }
            else if (importer != null)
            {
                importer.Chart = this;
            }
            this.MdiParent = master;
            Show();
        }
コード例 #13
0
ファイル: HelpWindow.cs プロジェクト: drdnar/MFE
        public HelpWindow(MasterWindow master)
        {
            Master = master;
            InitializeComponent();
            this.MdiParent = Master;
            this.Show();

            Index = XDocument.Parse(GetTextFile("index.xml"));
            TreeNode rootNode = new TreeNode();

            rootNode.Text = "MFE";
            topicsTreeView.Nodes.Add(rootNode);

            addNodes(Index.FirstNode, rootNode);

            currentItemRichTextBox.ReadOnly = true;
            currentItemRichTextBox.Rtf      = GetTextFile("default.rtf");

            rootNode.ExpandAll();
        }
コード例 #14
0
ファイル: PreviewChart.cs プロジェクト: drdnar/MFE
        private void PreviewChart_MouseClick(object sender, MouseEventArgs e)
        {
            // I've found that off-by-one-half is a thing that happens with rounding. . . .
            int col = (int)Math.Round((e.X - basex) / (scalex * (maxwidth + 1)) - 0.5);
            int row = (int)Math.Round((e.Y - basey) / (scaley * (CurrentFont.Height + 1)) - 0.5);

            if (col >= cols)
            {
                return;
            }
            if (row >= rows)
            {
                return;
            }
            if (col < 0)
            {
                return;
            }
            if (row < 0)
            {
                return;
            }
            byte ch = (byte)(row * cols + col);

            codepointBox.Text = CurrentFont[ch].Codepoint.ToString();
            charNameBox.Text  = CurrentFont[ch].Name;
            MasterWindow master = Master as MasterWindow;

            if (master != null)
            {
                if (master.CharEditorWindow != null)
                {
                    if (master.CharEditorWindow.ChartNavigationMode)
                    {
                        master.CharEditorWindow.SelectChar(ch);
                    }
                }
            }
        }