示例#1
0
 private void themeBox_SelectedIndexChanged(object sender, EventArgs e)
 {
     if (ColorScheme.GetThemes().Contains((string)themeBox.SelectedItem) && ColorScheme.GetCurrentTheme() != (string)themeBox.SelectedItem)
     {
         ColorScheme.ChangeTheme((string)themeBox.SelectedItem);
     }
 }
 private void button1_Click(object sender, EventArgs e)
 {
     try
     {
         foreach (DataGridViewRow row in dataGridView1.Rows)
         {
             theme[(string)row.Cells[0].Value] = ((string)row.Cells[1].Value) + ":" + ((string)row.Cells[2].Value) + ":" + ((string)row.Cells[3].Value) + ":" + ((string)row.Cells[4].Value);
         }
     }
     catch { }
     ColorScheme.themes[themeName] = theme;
     ColorScheme.Save();
     ColorScheme.ChangeTheme(themeName);
 }