示例#1
0
 private void ApplyConfig()
 {
     RichTextbox.Font             = new Font(configEditor.Fuente, configEditor.Tamaño, FontStyle.Regular);
     FontsCBox.SelectedItem       = configEditor.Fuente;
     FontSizeUpDown.Value         = configEditor.Tamaño;
     RichTextbox.BackColor        = ColorJson.ToColor(configEditor.ColorFondo);
     RichTextbox.ForeColor        = ColorJson.ToColor(configEditor.ColorTexto);
     ColoresSintxCheckBox.Checked = configEditor.SintaxisActivada;
 }
示例#2
0
        private void TextColorBut_Click(object sender, EventArgs e)
        {
            var colorDialog = new ColorDialog();

            colorDialog.FullOpen = true;
            colorDialog.ShowDialog();
            configEditor.ColorTexto = ColorJson.FromColor(colorDialog.Color);
            RichTextbox.ForeColor   = colorDialog.Color;
        }
示例#3
0
 public static Color ToColor(ColorJson json)
 {
     return(Color.FromArgb(json.A, json.R, json.G, json.B));
 }