Esempio n. 1
0
        private void OnEditColorEscapeSequence(object sender, EventArgs args)
        {
            EditEscapeSequenceColor dlg = new EditEscapeSequenceColor(_fontSample.BackColor, _fontSample.ForeColor, _ESColorSet);

            if (GCUtil.ShowModalDialog(FindForm(), dlg) == DialogResult.OK)
            {
                _ESColorSet = dlg.Result;
                _bgColorBox.SelectedColor   = dlg.GBackColor;
                _textColorBox.SelectedColor = dlg.GForeColor;
                _fontSample.ForeColor       = dlg.GForeColor;
                _fontSample.BackColor       = dlg.GBackColor;
                _fontSample.Invalidate();
                _bgColorBox.Invalidate();
                _textColorBox.Invalidate();
            }
        }
        private void OnEditColorEscapeSequence(object sender, EventArgs args)
        {
            EditEscapeSequenceColor dlg = new EditEscapeSequenceColor(_fontSample.BackColor, _fontSample.ForeColor, _profile.ESColorSet);

            if (dlg.ShowDialog(this) == DialogResult.OK)
            {
                _profile.ESColorSet         = dlg.Result;
                _profile.ForeColor          = dlg.GForeColor;
                _profile.BackColor          = dlg.GBackColor;
                _bgColorBox.SelectedColor   = dlg.GBackColor;
                _textColorBox.SelectedColor = dlg.GForeColor;
                _fontSample.ForeColor       = dlg.GForeColor;
                _fontSample.BackColor       = dlg.GBackColor;
                _fontSample.Invalidate();
                _bgColorBox.Invalidate();
                _textColorBox.Invalidate();
            }
        }